https://git.reactos.org/?p=reactos.git;a=commitdiff;h=da1e283837ada49a0d214f8cb1ba5e84782d40d8

commit da1e283837ada49a0d214f8cb1ba5e84782d40d8
Author:     Vadim Galyant <[email protected]>
AuthorDate: Mon Nov 27 18:19:05 2017 +0900
Commit:     Amine Khaldi <[email protected]>
CommitDate: Sun Jan 21 19:35:37 2018 +0100

    [USBPORT] Add USB2_InitTtEndpoint().
---
 drivers/usb/usbport/usb2.c | 21 +++++++++++++++++++++
 1 file changed, 21 insertions(+)

diff --git a/drivers/usb/usbport/usb2.c b/drivers/usb/usbport/usb2.c
index 6d71769376..1c4cd042de 100644
--- a/drivers/usb/usbport/usb2.c
+++ b/drivers/usb/usbport/usb2.c
@@ -10,6 +10,27 @@
 //#define NDEBUG
 #include <debug.h>
 
+VOID
+NTAPI
+USB2_InitTtEndpoint(IN PUSB2_TT_ENDPOINT TtEndpoint,
+                    IN UCHAR TransferType,
+                    IN UCHAR Direction,
+                    IN UCHAR DeviceSpeed,
+                    IN USHORT Period,
+                    IN USHORT MaxPacketSize,
+                    IN PUSB2_TT Tt)
+{
+    RtlZeroMemory(TtEndpoint, sizeof(USB2_TT_ENDPOINT));
+
+    TtEndpoint->TtEndpointParams.TransferType = TransferType;
+    TtEndpoint->TtEndpointParams.Direction = Direction;
+    TtEndpoint->TtEndpointParams.DeviceSpeed = DeviceSpeed;
+
+    TtEndpoint->Period = Period;
+    TtEndpoint->MaxPacketSize = MaxPacketSize;
+    TtEndpoint->Tt = Tt;
+}
+
 BOOLEAN
 NTAPI
 USBPORT_AllocateBandwidthUSB2(IN PDEVICE_OBJECT FdoDevice,

Reply via email to