diff options
Diffstat (limited to 'drivers/scsi')
-rw-r--r-- | drivers/scsi/scsi_scan.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/scsi/scsi_scan.c b/drivers/scsi/scsi_scan.c index e36c21e06d31..4e6709f448e1 100644 --- a/drivers/scsi/scsi_scan.c +++ b/drivers/scsi/scsi_scan.c | |||
@@ -418,8 +418,9 @@ static void scsi_target_reap_work(void *data) { | |||
418 | if (--starget->reap_ref == 0 && list_empty(&starget->devices)) { | 418 | if (--starget->reap_ref == 0 && list_empty(&starget->devices)) { |
419 | list_del_init(&starget->siblings); | 419 | list_del_init(&starget->siblings); |
420 | spin_unlock_irqrestore(shost->host_lock, flags); | 420 | spin_unlock_irqrestore(shost->host_lock, flags); |
421 | transport_remove_device(&starget->dev); | ||
421 | device_del(&starget->dev); | 422 | device_del(&starget->dev); |
422 | transport_unregister_device(&starget->dev); | 423 | transport_destroy_device(&starget->dev); |
423 | put_device(&starget->dev); | 424 | put_device(&starget->dev); |
424 | return; | 425 | return; |
425 | 426 | ||