aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/scsi/qla4xxx/ql4_os.c
diff options
context:
space:
mode:
authorFUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>2007-05-26 14:08:20 +0900
committerJames Bottomley <jejb@mulgrave.il.steeleye.com>2007-05-29 18:32:12 -0500
commit5f7186c841a13abff0bf81ee93754b4f46e19141 (patch)
tree381d9c0564edd1319513e40d3886b53da6057ea8 /drivers/scsi/qla4xxx/ql4_os.c
parent1928d73fac9a38be901dd5c9eb8b18b56ce9e18d (diff)
downloadkernel_samsung_smdk4412-5f7186c841a13abff0bf81ee93754b4f46e19141.zip
kernel_samsung_smdk4412-5f7186c841a13abff0bf81ee93754b4f46e19141.tar.gz
kernel_samsung_smdk4412-5f7186c841a13abff0bf81ee93754b4f46e19141.tar.bz2
[SCSI] qla4xxx: convert to use the data buffer accessors
- remove the unnecessary map_single path. - convert to use the new accessors for the sg lists and the parameters. Jens Axboe <jens.axboe@oracle.com> did the for_each_sg cleanup. Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp> Acked-by: David C Somayajulu <david.somayajulu@qlogic.com> Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
Diffstat (limited to 'drivers/scsi/qla4xxx/ql4_os.c')
-rw-r--r--drivers/scsi/qla4xxx/ql4_os.c9
1 files changed, 1 insertions, 8 deletions
diff --git a/drivers/scsi/qla4xxx/ql4_os.c b/drivers/scsi/qla4xxx/ql4_os.c
index 0e4688c..e09fc42 100644
--- a/drivers/scsi/qla4xxx/ql4_os.c
+++ b/drivers/scsi/qla4xxx/ql4_os.c
@@ -373,14 +373,7 @@ static void qla4xxx_srb_free_dma(struct scsi_qla_host *ha, struct srb *srb)
struct scsi_cmnd *cmd = srb->cmd;
if (srb->flags & SRB_DMA_VALID) {
- if (cmd->use_sg) {
- pci_unmap_sg(ha->pdev, cmd->request_buffer,
- cmd->use_sg, cmd->sc_data_direction);
- } else if (cmd->request_bufflen) {
- pci_unmap_single(ha->pdev, srb->dma_handle,
- cmd->request_bufflen,
- cmd->sc_data_direction);
- }
+ scsi_dma_unmap(cmd);
srb->flags &= ~SRB_DMA_VALID;
}
cmd->SCp.ptr = NULL;