diff options
author | Anil Ravindranath <anil_ravindranath@pmc-sierra.com> | 2009-12-17 17:51:53 -0500 |
---|---|---|
committer | James Bottomley <James.Bottomley@suse.de> | 2009-12-30 12:53:22 -0500 |
commit | a70757ba9a3719f99760713c3b72134b21016c6e (patch) | |
tree | 51d8d3b0bc0376d4b74dc4ef3b83952286d05f00 /drivers/scsi | |
parent | 3b9c212a5cbb1e13ced92639ce83f7a48b8b2331 (diff) |
[SCSI] pmcraid: fix to avoid twice scsi_dma_unmap for a command
For a particular driver error condition, driver was doing double
scsi_dma_unmaps. Driver was calling scsi_dma_unmap in
pmcraid_error_handler and return 0. This pmcraid_error_handler is called
by pmcraid_io_done which will do scsi_dma_unmap again when it has
return 0 from pmcraid_error_handler.
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Diffstat (limited to 'drivers/scsi')
-rw-r--r-- | drivers/scsi/pmcraid.c | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/drivers/scsi/pmcraid.c b/drivers/scsi/pmcraid.c index e7d2688fbeba..b6f1ef954af1 100644 --- a/drivers/scsi/pmcraid.c +++ b/drivers/scsi/pmcraid.c | |||
@@ -2483,14 +2483,12 @@ static int pmcraid_error_handler(struct pmcraid_cmd *cmd) | |||
2483 | sense_copied = 1; | 2483 | sense_copied = 1; |
2484 | } | 2484 | } |
2485 | 2485 | ||
2486 | if (RES_IS_GSCSI(res->cfg_entry)) { | 2486 | if (RES_IS_GSCSI(res->cfg_entry)) |
2487 | pmcraid_cancel_all(cmd, sense_copied); | 2487 | pmcraid_cancel_all(cmd, sense_copied); |
2488 | } else if (sense_copied) { | 2488 | else if (sense_copied) |
2489 | pmcraid_erp_done(cmd); | 2489 | pmcraid_erp_done(cmd); |
2490 | return 0; | 2490 | else |
2491 | } else { | ||
2492 | pmcraid_request_sense(cmd); | 2491 | pmcraid_request_sense(cmd); |
2493 | } | ||
2494 | 2492 | ||
2495 | return 1; | 2493 | return 1; |
2496 | 2494 | ||