]> err.no Git - linux-2.6/commitdiff
ieee1394: sbp2: safer agent reset in error handlers
authorStefan Richter <stefanr@s5r6.in-berlin.de>
Mon, 14 Aug 2006 16:44:00 +0000 (18:44 +0200)
committerStefan Richter <stefanr@s5r6.in-berlin.de>
Sun, 17 Sep 2006 17:34:30 +0000 (19:34 +0200)
The scsi_host_template's eh_abort_handler and eh_device_reset_handler
are allowed to sleep.  Use this to run sbp2_agent_reset in the more
reliable mode which returns _after_ its write transaction was finished.

Signed-off-by: Stefan Richter <stefanr@s5r6.in-berlin.de>
drivers/ieee1394/sbp2.c

index c4d30a7b8b1e4d703e03701d3d7ffd01ba67988b..b5bcca36d43ccc1c8dd6b8296cffe00a33ce00d8 100644 (file)
@@ -2578,7 +2578,7 @@ static int sbp2scsi_abort(struct scsi_cmnd *SCpnt)
                /*
                 * Initiate a fetch agent reset.
                 */
-               sbp2_agent_reset(scsi_id, 0);
+               sbp2_agent_reset(scsi_id, 1);
                sbp2scsi_complete_all_commands(scsi_id, DID_BUS_BUSY);
        }
 
@@ -2597,7 +2597,7 @@ static int sbp2scsi_reset(struct scsi_cmnd *SCpnt)
 
        if (sbp2util_node_is_available(scsi_id)) {
                SBP2_ERR("Generating sbp2 fetch agent reset");
-               sbp2_agent_reset(scsi_id, 0);
+               sbp2_agent_reset(scsi_id, 1);
        }
 
        return SUCCESS;