[SCSI] iscsi_tcp: remove sk_sleep check
authorMike Christie <michaelc@cs.wisc.edu>
Fri, 21 May 2010 23:24:16 +0000 (18:24 -0500)
committerJames Bottomley <James.Bottomley@suse.de>
Tue, 25 May 2010 15:04:10 +0000 (10:04 -0500)
There is no need to call sk_sleep before calling wake_up_interruptible,
because the wait_queue_head is now with the socket.

Signed-off-by: Mike Christie <michaelc@cs.wisc.edu>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
drivers/scsi/iscsi_tcp.c

index bf55d305741306b0d35ef9584d942229e11152b4..fec47de72535984f1e36b83048f763e7cd0a15a8 100644 (file)
@@ -601,10 +601,8 @@ static void iscsi_sw_tcp_conn_stop(struct iscsi_cls_conn *cls_conn, int flag)
        set_bit(ISCSI_SUSPEND_BIT, &conn->suspend_rx);
        write_unlock_bh(&tcp_sw_conn->sock->sk->sk_callback_lock);
 
-       if (sk_sleep(sock->sk)) {
-               sock->sk->sk_err = EIO;
-               wake_up_interruptible(sk_sleep(sock->sk));
-       }
+       sock->sk->sk_err = EIO;
+       wake_up_interruptible(sk_sleep(sock->sk));
 
        iscsi_conn_stop(cls_conn, flag);
        iscsi_sw_tcp_release_conn(conn);