diff options
author | Andrew Vasquez <andrew.vasquez@qlogic.com> | 2005-08-26 22:09:20 -0400 |
---|---|---|
committer | James Bottomley <jejb@mulgrave.(none)> | 2005-09-04 20:53:28 -0400 |
commit | 131736d34ebc3251d79ddfd08a5e57a3e86decd4 (patch) | |
tree | b05ad75c24e50a3a177dd988814430e454615682 /drivers/scsi | |
parent | c32c4cb9fbe3bdc2a90c6eaae5ae30521d4ba9fc (diff) |
[SCSI] qla2xxx: Remove redundant call to pci_unmap_sg().
In a corner-case failure where the request-q does not
contain enough entries for a given request, pci_unmap_sg()
would be called twice. Remove direct call and let the
failure-path logic handle the unmapping.
Signed-off-by: Andrew Vasquez <andrew.vasquez@qlogic.com>
Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
Diffstat (limited to 'drivers/scsi')
-rw-r--r-- | drivers/scsi/qla2xxx/qla_iocb.c | 6 |
1 files changed, 1 insertions, 5 deletions
diff --git a/drivers/scsi/qla2xxx/qla_iocb.c b/drivers/scsi/qla2xxx/qla_iocb.c index ebdc3c54d155..37f82e2cd7fb 100644 --- a/drivers/scsi/qla2xxx/qla_iocb.c +++ b/drivers/scsi/qla2xxx/qla_iocb.c | |||
@@ -810,12 +810,8 @@ qla24xx_start_scsi(srb_t *sp) | |||
810 | ha->req_q_cnt = ha->request_q_length - | 810 | ha->req_q_cnt = ha->request_q_length - |
811 | (ha->req_ring_index - cnt); | 811 | (ha->req_ring_index - cnt); |
812 | } | 812 | } |
813 | if (ha->req_q_cnt < (req_cnt + 2)) { | 813 | if (ha->req_q_cnt < (req_cnt + 2)) |
814 | if (cmd->use_sg) | ||
815 | pci_unmap_sg(ha->pdev, sg, cmd->use_sg, | ||
816 | cmd->sc_data_direction); | ||
817 | goto queuing_error; | 814 | goto queuing_error; |
818 | } | ||
819 | 815 | ||
820 | /* Build command packet. */ | 816 | /* Build command packet. */ |
821 | ha->current_outstanding_cmd = handle; | 817 | ha->current_outstanding_cmd = handle; |