diff options
Diffstat (limited to 'drivers/scsi/iscsi_tcp.c')
-rw-r--r-- | drivers/scsi/iscsi_tcp.c | 19 |
1 files changed, 5 insertions, 14 deletions
diff --git a/drivers/scsi/iscsi_tcp.c b/drivers/scsi/iscsi_tcp.c index e31d350e6b67..4e4b1061a5e9 100644 --- a/drivers/scsi/iscsi_tcp.c +++ b/drivers/scsi/iscsi_tcp.c | |||
@@ -525,7 +525,7 @@ iscsi_r2t_rsp(struct iscsi_conn *conn, struct iscsi_cmd_task *ctask) | |||
525 | __kfifo_put(ctask->r2tqueue, (void*)&r2t, sizeof(void*)); | 525 | __kfifo_put(ctask->r2tqueue, (void*)&r2t, sizeof(void*)); |
526 | __kfifo_put(conn->writequeue, (void*)&ctask, sizeof(void*)); | 526 | __kfifo_put(conn->writequeue, (void*)&ctask, sizeof(void*)); |
527 | 527 | ||
528 | schedule_work(&conn->xmitwork); | 528 | scsi_queue_work(session->host, &conn->xmitwork); |
529 | conn->r2t_pdus_cnt++; | 529 | conn->r2t_pdus_cnt++; |
530 | spin_unlock(&session->lock); | 530 | spin_unlock(&session->lock); |
531 | 531 | ||
@@ -1267,7 +1267,7 @@ iscsi_write_space(struct sock *sk) | |||
1267 | conn->old_write_space(sk); | 1267 | conn->old_write_space(sk); |
1268 | debug_tcp("iscsi_write_space: cid %d\n", conn->id); | 1268 | debug_tcp("iscsi_write_space: cid %d\n", conn->id); |
1269 | clear_bit(SUSPEND_BIT, &conn->suspend_tx); | 1269 | clear_bit(SUSPEND_BIT, &conn->suspend_tx); |
1270 | schedule_work(&conn->xmitwork); | 1270 | scsi_queue_work(conn->session->host, &conn->xmitwork); |
1271 | } | 1271 | } |
1272 | 1272 | ||
1273 | static void | 1273 | static void |
@@ -2275,7 +2275,7 @@ iscsi_xmitworker(void *data) | |||
2275 | */ | 2275 | */ |
2276 | mutex_lock(&conn->xmitmutex); | 2276 | mutex_lock(&conn->xmitmutex); |
2277 | if (iscsi_data_xmit(conn)) | 2277 | if (iscsi_data_xmit(conn)) |
2278 | schedule_work(&conn->xmitwork); | 2278 | scsi_queue_work(conn->session->host, &conn->xmitwork); |
2279 | mutex_unlock(&conn->xmitmutex); | 2279 | mutex_unlock(&conn->xmitmutex); |
2280 | } | 2280 | } |
2281 | 2281 | ||
@@ -2340,15 +2340,7 @@ iscsi_queuecommand(struct scsi_cmnd *sc, void (*done)(struct scsi_cmnd *)) | |||
2340 | session->cmdsn, session->max_cmdsn - session->exp_cmdsn + 1); | 2340 | session->cmdsn, session->max_cmdsn - session->exp_cmdsn + 1); |
2341 | spin_unlock(&session->lock); | 2341 | spin_unlock(&session->lock); |
2342 | 2342 | ||
2343 | if (!in_interrupt() && mutex_trylock(&conn->xmitmutex)) { | 2343 | scsi_queue_work(host, &conn->xmitwork); |
2344 | spin_unlock_irq(host->host_lock); | ||
2345 | if (iscsi_data_xmit(conn)) | ||
2346 | schedule_work(&conn->xmitwork); | ||
2347 | mutex_unlock(&conn->xmitmutex); | ||
2348 | spin_lock_irq(host->host_lock); | ||
2349 | } else | ||
2350 | schedule_work(&conn->xmitwork); | ||
2351 | |||
2352 | return 0; | 2344 | return 0; |
2353 | 2345 | ||
2354 | reject: | 2346 | reject: |
@@ -2942,8 +2934,7 @@ iscsi_conn_send_generic(struct iscsi_conn *conn, struct iscsi_hdr *hdr, | |||
2942 | else | 2934 | else |
2943 | __kfifo_put(conn->mgmtqueue, (void*)&mtask, sizeof(void*)); | 2935 | __kfifo_put(conn->mgmtqueue, (void*)&mtask, sizeof(void*)); |
2944 | 2936 | ||
2945 | schedule_work(&conn->xmitwork); | 2937 | scsi_queue_work(session->host, &conn->xmitwork); |
2946 | |||
2947 | return 0; | 2938 | return 0; |
2948 | } | 2939 | } |
2949 | 2940 | ||