[USBSTOR]
authorCameron Gutman <aicommander@gmail.com>
Wed, 25 Jan 2012 06:09:24 +0000 (06:09 +0000)
committerCameron Gutman <aicommander@gmail.com>
Wed, 25 Jan 2012 06:09:24 +0000 (06:09 +0000)
- Use the correct USBD_TRANSFER_DIRECTION value for write operations

svn path=/branches/usb-bringup-trunk/; revision=55169

drivers/usb/usbstor/scsi.c

index 62c25de..5e80749 100644 (file)
@@ -447,7 +447,7 @@ USBSTOR_CBWCompletionRoutine(
                                                NULL,
                                                Context->TransferBufferMDL,
                                                Context->TransferDataLength,
                                                NULL,
                                                Context->TransferBufferMDL,
                                                Context->TransferDataLength,
-                                               USBD_TRANSFER_DIRECTION_IN | USBD_SHORT_TRANSFER_OK,
+                                               ((Code == SCSIOP_WRITE) ? USBD_TRANSFER_DIRECTION_OUT : USBD_TRANSFER_DIRECTION_IN) | USBD_SHORT_TRANSFER_OK,
                                                NULL);
 
         //
                                                NULL);
 
         //