diff options
author | Boaz Harrosh <bharrosh@panasas.com> | 2007-09-09 13:47:26 -0400 |
---|---|---|
committer | James Bottomley <James.Bottomley@HansenPartnership.com> | 2008-01-11 19:22:36 -0500 |
commit | 41c2497b188a641c542328d08a45cf3214d453bd (patch) | |
tree | 31ca9b40b714bbe43e5c814090bf280834c43eb2 /drivers/usb/storage/sddr09.c | |
parent | dd829d2302c6b0f88542ca367229d676cb9ca212 (diff) |
[SCSI] usb: freecom & sddr09 - convert to accessors and !use_sg cleanup
- Use scsi data accessors and remove of !use_sg code path
- This patch is dependent on cleanup patch to usb transport.c/h
Signed-off-by: Boaz Harrosh <bharrosh@panasas.com>
Acked-by: Matthew Dharm <mdharm-scsi@one-eyed-alien.net>
Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
Diffstat (limited to 'drivers/usb/storage/sddr09.c')
-rw-r--r-- | drivers/usb/storage/sddr09.c | 9 |
1 files changed, 3 insertions, 6 deletions
diff --git a/drivers/usb/storage/sddr09.c b/drivers/usb/storage/sddr09.c index b12202c5da2d..8972b17da843 100644 --- a/drivers/usb/storage/sddr09.c +++ b/drivers/usb/storage/sddr09.c | |||
@@ -1623,7 +1623,7 @@ int sddr09_transport(struct scsi_cmnd *srb, struct us_data *us) | |||
1623 | return USB_STOR_TRANSPORT_ERROR; | 1623 | return USB_STOR_TRANSPORT_ERROR; |
1624 | } | 1624 | } |
1625 | 1625 | ||
1626 | if (srb->request_bufflen == 0) | 1626 | if (scsi_bufflen(srb) == 0) |
1627 | return USB_STOR_TRANSPORT_GOOD; | 1627 | return USB_STOR_TRANSPORT_GOOD; |
1628 | 1628 | ||
1629 | if (srb->sc_data_direction == DMA_TO_DEVICE || | 1629 | if (srb->sc_data_direction == DMA_TO_DEVICE || |
@@ -1634,12 +1634,9 @@ int sddr09_transport(struct scsi_cmnd *srb, struct us_data *us) | |||
1634 | US_DEBUGP("SDDR09: %s %d bytes\n", | 1634 | US_DEBUGP("SDDR09: %s %d bytes\n", |
1635 | (srb->sc_data_direction == DMA_TO_DEVICE) ? | 1635 | (srb->sc_data_direction == DMA_TO_DEVICE) ? |
1636 | "sending" : "receiving", | 1636 | "sending" : "receiving", |
1637 | srb->request_bufflen); | 1637 | scsi_bufflen(srb)); |
1638 | 1638 | ||
1639 | result = usb_stor_bulk_transfer_sg(us, pipe, | 1639 | result = usb_stor_bulk_srb(us, pipe, srb); |
1640 | srb->request_buffer, | ||
1641 | srb->request_bufflen, | ||
1642 | srb->use_sg, &srb->resid); | ||
1643 | 1640 | ||
1644 | return (result == USB_STOR_XFER_GOOD ? | 1641 | return (result == USB_STOR_XFER_GOOD ? |
1645 | USB_STOR_TRANSPORT_GOOD : USB_STOR_TRANSPORT_ERROR); | 1642 | USB_STOR_TRANSPORT_GOOD : USB_STOR_TRANSPORT_ERROR); |