mirror of
https://github.com/reactos/reactos.git
synced 2025-06-11 04:47:22 +00:00
[USBPORT] Fix incorrect transfer direction for URBs. Patch by Vadim Galyant. CORE-13546
svn path=/trunk/; revision=75351
This commit is contained in:
parent
c343d309f2
commit
e12241f5a1
2 changed files with 4 additions and 3 deletions
|
@ -385,13 +385,13 @@ USBPORT_HandleDataTransfers(IN PURB Urb)
|
||||||
|
|
||||||
if (Endpoint->EndpointProperties.TransferType != USBPORT_TRANSFER_TYPE_CONTROL)
|
if (Endpoint->EndpointProperties.TransferType != USBPORT_TRANSFER_TYPE_CONTROL)
|
||||||
{
|
{
|
||||||
if (Endpoint->EndpointProperties.Direction)
|
if (Endpoint->EndpointProperties.Direction == USBPORT_TRANSFER_DIRECTION_OUT)
|
||||||
{
|
{
|
||||||
Urb->UrbBulkOrInterruptTransfer.TransferFlags |= USBD_TRANSFER_DIRECTION_IN;
|
Urb->UrbBulkOrInterruptTransfer.TransferFlags &= ~USBD_TRANSFER_DIRECTION_IN;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
Urb->UrbBulkOrInterruptTransfer.TransferFlags &= ~USBD_TRANSFER_DIRECTION_IN;
|
Urb->UrbBulkOrInterruptTransfer.TransferFlags |= USBD_TRANSFER_DIRECTION_IN;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -580,6 +580,7 @@ typedef struct _USBPORT_MINIPORT_INTERFACE {
|
||||||
|
|
||||||
C_ASSERT(sizeof(USBPORT_MINIPORT_INTERFACE) == 336);
|
C_ASSERT(sizeof(USBPORT_MINIPORT_INTERFACE) == 336);
|
||||||
|
|
||||||
|
#define USBPORT_TRANSFER_DIRECTION_OUT 1 // From host to device
|
||||||
typedef struct _USBPORT_ENDPOINT_PROPERTIES {
|
typedef struct _USBPORT_ENDPOINT_PROPERTIES {
|
||||||
USHORT DeviceAddress;
|
USHORT DeviceAddress;
|
||||||
USHORT EndpointAddress;
|
USHORT EndpointAddress;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue