|
@@ -3154,9 +3154,14 @@ accept_wait:
|
|
|
return -ENODEV;
|
|
|
|
|
|
spin_lock_bh(&np->np_thread_lock);
|
|
|
- if (np->np_thread_state == ISCSI_NP_THREAD_RESET) {
|
|
|
+ if (np->np_thread_state >= ISCSI_NP_THREAD_RESET) {
|
|
|
spin_unlock_bh(&np->np_thread_lock);
|
|
|
- pr_debug("ISCSI_NP_THREAD_RESET for isert_accept_np\n");
|
|
|
+ pr_debug("np_thread_state %d for isert_accept_np\n",
|
|
|
+ np->np_thread_state);
|
|
|
+ /**
|
|
|
+ * No point in stalling here when np_thread
|
|
|
+ * is in state RESET/SHUTDOWN/EXIT - bail
|
|
|
+ **/
|
|
|
return -ENODEV;
|
|
|
}
|
|
|
spin_unlock_bh(&np->np_thread_lock);
|