aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/scsi/pci2000.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/scsi/pci2000.c')
-rw-r--r--drivers/scsi/pci2000.c16
1 files changed, 9 insertions, 7 deletions
diff --git a/drivers/scsi/pci2000.c b/drivers/scsi/pci2000.c
index d58f303127f5..377a4666b568 100644
--- a/drivers/scsi/pci2000.c
+++ b/drivers/scsi/pci2000.c
@@ -209,7 +209,7 @@ static int BuildSgList (Scsi_Cmnd *SCpnt, PADAPTER2000 padapter, PDEV2000 pdev)
209 if ( SCpnt->use_sg ) 209 if ( SCpnt->use_sg )
210 { 210 {
211 sg = (struct scatterlist *)SCpnt->request_buffer; 211 sg = (struct scatterlist *)SCpnt->request_buffer;
212 zc = pci_map_sg (padapter->pdev, sg, SCpnt->use_sg, scsi_to_pci_dma_dir (SCpnt->sc_data_direction)); 212 zc = pci_map_sg (padapter->pdev, sg, SCpnt->use_sg, SCpnt->sc_data_direction);
213 for ( z = 0; z < zc; z++ ) 213 for ( z = 0; z < zc; z++ )
214 { 214 {
215 pdev->scatGath[z].address = cpu_to_le32 (sg_dma_address (sg)); 215 pdev->scatGath[z].address = cpu_to_le32 (sg_dma_address (sg));
@@ -225,7 +225,9 @@ static int BuildSgList (Scsi_Cmnd *SCpnt, PADAPTER2000 padapter, PDEV2000 pdev)
225 outl (0, padapter->mb3); 225 outl (0, padapter->mb3);
226 return TRUE; 226 return TRUE;
227 } 227 }
228 SCpnt->SCp.have_data_in = pci_map_single (padapter->pdev, SCpnt->request_buffer, SCpnt->request_bufflen, scsi_to_pci_dma_dir (SCpnt->sc_data_direction)); 228 SCpnt->SCp.have_data_in = pci_map_single (padapter->pdev,
229 SCpnt->request_buffer, SCpnt->request_bufflen,
230 SCpnt->sc_data_direction);
229 outl (SCpnt->SCp.have_data_in, padapter->mb2); 231 outl (SCpnt->SCp.have_data_in, padapter->mb2);
230 outl (SCpnt->request_bufflen, padapter->mb3); 232 outl (SCpnt->request_bufflen, padapter->mb3);
231 return TRUE; 233 return TRUE;
@@ -340,11 +342,11 @@ unmapProceed:;
340 } 342 }
341 } 343 }
342 if ( SCpnt->SCp.have_data_in ) 344 if ( SCpnt->SCp.have_data_in )
343 pci_unmap_single (padapter->pdev, SCpnt->SCp.have_data_in, SCpnt->request_bufflen, scsi_to_pci_dma_dir(SCpnt->sc_data_direction)); 345 pci_unmap_single (padapter->pdev, SCpnt->SCp.have_data_in, SCpnt->request_bufflen, SCpnt->sc_data_direction);
344 else 346 else
345 { 347 {
346 if ( SCpnt->use_sg ) 348 if ( SCpnt->use_sg )
347 pci_unmap_sg (padapter->pdev, (struct scatterlist *)SCpnt->request_buffer, SCpnt->use_sg, scsi_to_pci_dma_dir(SCpnt->sc_data_direction)); 349 pci_unmap_sg (padapter->pdev, (struct scatterlist *)SCpnt->request_buffer, SCpnt->use_sg, SCpnt->sc_data_direction);
348 } 350 }
349 351
350irqProceed:; 352irqProceed:;
@@ -495,7 +497,7 @@ int Pci2000_QueueCommand (Scsi_Cmnd *SCpnt, void (*done)(Scsi_Cmnd *))
495 else 497 else
496 { 498 {
497 SCpnt->SCp.have_data_in = pci_map_single (padapter->pdev, SCpnt->request_buffer, SCpnt->request_bufflen, 499 SCpnt->SCp.have_data_in = pci_map_single (padapter->pdev, SCpnt->request_buffer, SCpnt->request_bufflen,
498 scsi_to_pci_dma_dir(SCpnt->sc_data_direction)); 500 SCpnt->sc_data_direction);
499 outl (SCpnt->SCp.have_data_in, padapter->mb2); 501 outl (SCpnt->SCp.have_data_in, padapter->mb2);
500 } 502 }
501 outl (cdb[5], padapter->mb0); 503 outl (cdb[5], padapter->mb0);
@@ -511,13 +513,13 @@ int Pci2000_QueueCommand (Scsi_Cmnd *SCpnt, void (*done)(Scsi_Cmnd *))
511 SCpnt->SCp.have_data_in = pci_map_single (padapter->pdev, 513 SCpnt->SCp.have_data_in = pci_map_single (padapter->pdev,
512 ((struct scatterlist *)SCpnt->request_buffer)->address, 514 ((struct scatterlist *)SCpnt->request_buffer)->address,
513 SCpnt->request_bufflen, 515 SCpnt->request_bufflen,
514 scsi_to_pci_dma_dir (SCpnt->sc_data_direction)); 516 SCpnt->sc_data_direction);
515 } 517 }
516 else 518 else
517 { 519 {
518 SCpnt->SCp.have_data_in = pci_map_single (padapter->pdev, SCpnt->request_buffer, 520 SCpnt->SCp.have_data_in = pci_map_single (padapter->pdev, SCpnt->request_buffer,
519 SCpnt->request_bufflen, 521 SCpnt->request_bufflen,
520 scsi_to_pci_dma_dir (SCpnt->sc_data_direction)); 522 SCpnt->sc_data_direction);
521 } 523 }
522 outl (SCpnt->SCp.have_data_in, padapter->mb2); 524 outl (SCpnt->SCp.have_data_in, padapter->mb2);
523 outl (SCpnt->request_bufflen, padapter->mb3); 525 outl (SCpnt->request_bufflen, padapter->mb3);