diff options
Diffstat (limited to 'drivers/scsi/scsi_transport_iscsi.c')
-rw-r--r-- | drivers/scsi/scsi_transport_iscsi.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/drivers/scsi/scsi_transport_iscsi.c b/drivers/scsi/scsi_transport_iscsi.c index 9b25124a989e..9c22f1342715 100644 --- a/drivers/scsi/scsi_transport_iscsi.c +++ b/drivers/scsi/scsi_transport_iscsi.c | |||
@@ -234,9 +234,11 @@ static int iscsi_user_scan(struct Scsi_Host *shost, uint channel, | |||
234 | return 0; | 234 | return 0; |
235 | } | 235 | } |
236 | 236 | ||
237 | static void session_recovery_timedout(void *data) | 237 | static void session_recovery_timedout(struct work_struct *work) |
238 | { | 238 | { |
239 | struct iscsi_cls_session *session = data; | 239 | struct iscsi_cls_session *session = |
240 | container_of(work, struct iscsi_cls_session, | ||
241 | recovery_work.work); | ||
240 | 242 | ||
241 | dev_printk(KERN_INFO, &session->dev, "iscsi: session recovery timed " | 243 | dev_printk(KERN_INFO, &session->dev, "iscsi: session recovery timed " |
242 | "out after %d secs\n", session->recovery_tmo); | 244 | "out after %d secs\n", session->recovery_tmo); |
@@ -276,7 +278,7 @@ iscsi_alloc_session(struct Scsi_Host *shost, | |||
276 | 278 | ||
277 | session->transport = transport; | 279 | session->transport = transport; |
278 | session->recovery_tmo = 120; | 280 | session->recovery_tmo = 120; |
279 | INIT_WORK(&session->recovery_work, session_recovery_timedout, session); | 281 | INIT_DELAYED_WORK(&session->recovery_work, session_recovery_timedout); |
280 | INIT_LIST_HEAD(&session->host_list); | 282 | INIT_LIST_HEAD(&session->host_list); |
281 | INIT_LIST_HEAD(&session->sess_list); | 283 | INIT_LIST_HEAD(&session->sess_list); |
282 | 284 | ||