[SCSI] allow sleeping in ->eh_device_reset_handler()
[deliverable/linux.git] / drivers / scsi / sym53c8xx_2 / sym_glue.c
index e2d055ed5b6f866447e37ab20600600de38a4ee0..5ea62552d47d3775f0b90a85d6a2b37dd08a2da2 100644 (file)
@@ -867,7 +867,13 @@ static int sym53c8xx_eh_abort_handler(struct scsi_cmnd *cmd)
 
 static int sym53c8xx_eh_device_reset_handler(struct scsi_cmnd *cmd)
 {
-       return sym_eh_handler(SYM_EH_DEVICE_RESET, "DEVICE RESET", cmd);
+       int rc;
+
+       spin_lock_irq(cmd->device->host->host_lock);
+       rc = sym_eh_handler(SYM_EH_DEVICE_RESET, "DEVICE RESET", cmd);
+       spin_unlock_irq(cmd->device->host->host_lock);
+
+       return rc;
 }
 
 static int sym53c8xx_eh_bus_reset_handler(struct scsi_cmnd *cmd)
This page took 0.054263 seconds and 5 git commands to generate.