On 03/13/12 15:56, Michael Tokarev wrote: > WARNING: at block/genhd.c:1474 __disk_unblock_events+0x123/0x130() Does the patch below help ? This patch prevents that sd_probe_async() races with scsi_host_remove(). --- drivers/scsi/sd.c | 2 ++ 1 files changed, 2 insertions(+), 0 deletions(-) diff --git a/drivers/scsi/sd.c b/drivers/scsi/sd.c index c691fb5..7161fc1 100644 --- a/drivers/scsi/sd.c +++ b/drivers/scsi/sd.c @@ -2544,6 +2544,7 @@ static void sd_probe_async(void *data, async_cookie_t cookie) sd_printk(KERN_NOTICE, sdkp, "Attached SCSI %sdisk\n", sdp->removable ? "removable " : ""); scsi_autopm_put_device(sdp); + scsi_host_put(sdp->host); put_device(&sdkp->dev); } @@ -2635,6 +2636,7 @@ static int sd_probe(struct device *dev) dev_set_drvdata(dev, sdkp); get_device(&sdkp->dev); /* prevent release before async_schedule */ + scsi_host_get(sdp->host); async_schedule(sd_probe_async, sdkp); return 0; -- 1.7.7 -- To unsubscribe from this list: send the line "unsubscribe linux-scsi" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html