ReactOS  0.4.13-dev-1174-gdff75d7
usbport.h
Go to the documentation of this file.
1 /*
2  * PROJECT: ReactOS USB Port Driver
3  * LICENSE: GPL-2.0+ (https://spdx.org/licenses/GPL-2.0+)
4  * PURPOSE: USBPort declarations
5  * COPYRIGHT: Copyright 2017 Vadim Galyant <vgal@rambler.ru>
6  */
7 
8 #ifndef USBPORT_H__
9 #define USBPORT_H__
10 
11 #include <ntddk.h>
12 #include <windef.h>
13 #include <stdio.h>
14 #include <wdmguid.h>
15 #include <ntstrsafe.h>
16 #include <usb.h>
17 #include <hubbusif.h>
18 #include <usbbusif.h>
19 #include <usbdlib.h>
20 #include <usbuser.h>
22 
23 #define PCI_INTERFACE_USB_ID_UHCI 0x00
24 #define PCI_INTERFACE_USB_ID_OHCI 0x10
25 #define PCI_INTERFACE_USB_ID_EHCI 0x20
26 #define PCI_INTERFACE_USB_ID_XHCI 0x30
27 
28 #ifdef USBD_TRANSFER_DIRECTION // due hubbusif.h included usbdi.h (Which overwrites...)
29 #undef USBD_TRANSFER_DIRECTION
30 #define USBD_TRANSFER_DIRECTION 0x00000001
31 #endif
32 
33 #define USBPORT_RECIPIENT_HUB BMREQUEST_TO_DEVICE
34 #define USBPORT_RECIPIENT_PORT BMREQUEST_TO_OTHER
35 
36 #define INVALIDATE_ENDPOINT_ONLY 0
37 #define INVALIDATE_ENDPOINT_WORKER_THREAD 1
38 #define INVALIDATE_ENDPOINT_WORKER_DPC 2
39 #define INVALIDATE_ENDPOINT_INT_NEXT_SOF 3
40 
41 #define USBPORT_DMA_DIRECTION_FROM_DEVICE 1
42 #define USBPORT_DMA_DIRECTION_TO_DEVICE 2
43 
44 #define USB_PORT_TAG 'pbsu'
45 #define URB_FUNCTION_MAX 0x31
46 
47 /* Hub Class Feature Selectors (Recipient - Port) */
48 #define FEATURE_PORT_CONNECTION 0
49 #define FEATURE_PORT_ENABLE 1
50 #define FEATURE_PORT_SUSPEND 2
51 #define FEATURE_PORT_OVER_CURRENT 3
52 #define FEATURE_PORT_RESET 4
53 #define FEATURE_PORT_POWER 8
54 #define FEATURE_PORT_LOW_SPEED 9
55 #define FEATURE_C_PORT_CONNECTION 16
56 #define FEATURE_C_PORT_ENABLE 17
57 #define FEATURE_C_PORT_SUSPEND 18
58 #define FEATURE_C_PORT_OVER_CURRENT 19
59 #define FEATURE_C_PORT_RESET 20
60 
61 /* Hub Class Feature Selectors (Recipient - Hub) */
62 #define FEATURE_C_HUB_LOCAL_POWER 0
63 #define FEATURE_C_HUB_OVER_CURRENT 1
64 
65 /* Flags */
66 #define USBPORT_FLAG_INT_CONNECTED 0x00000001
67 #define USBPORT_FLAG_HC_STARTED 0x00000002
68 #define USBPORT_FLAG_HC_POLLING 0x00000004
69 #define USBPORT_FLAG_WORKER_THREAD_ON 0x00000008
70 #define USBPORT_FLAG_HC_SUSPEND 0x00000100
71 #define USBPORT_FLAG_INTERRUPT_ENABLED 0x00000400
72 #define USBPORT_FLAG_SELECTIVE_SUSPEND 0x00000800
73 #define USBPORT_FLAG_DOS_SYMBOLIC_NAME 0x00010000
74 #define USBPORT_FLAG_LEGACY_SUPPORT 0x00080000
75 #define USBPORT_FLAG_HC_WAKE_SUPPORT 0x00200000
76 #define USBPORT_FLAG_DIAGNOSTIC_MODE 0x00800000 //IOCTL_USB_DIAGNOSTIC_MODE_ON
77 #define USBPORT_FLAG_COMPANION_HC 0x01000000
78 #define USBPORT_FLAG_REGISTERED_FDO 0x02000000
79 #define USBPORT_FLAG_NO_HACTION 0x04000000
80 #define USBPORT_FLAG_BIOS_DISABLE_SS 0x08000000 //Selective Suspend
81 #define USBPORT_FLAG_PWR_AND_CHIRP_LOCK 0x10000000
82 #define USBPORT_FLAG_POWER_AND_CHIRP_OK 0x40000000
83 #define USBPORT_FLAG_RH_INIT_CALLBACK 0x80000000
84 
85 /* PnP state Flags */
86 #define USBPORT_PNP_STATE_NOT_INIT 0x00000001
87 #define USBPORT_PNP_STATE_STARTED 0x00000002
88 #define USBPORT_PNP_STATE_FAILED 0x00000004
89 #define USBPORT_PNP_STATE_STOPPED 0x00000008
90 
91 /* Timer Flags */
92 #define USBPORT_TMFLAG_TIMER_QUEUED 0x00000001
93 #define USBPORT_TMFLAG_HC_SUSPENDED 0x00000002
94 #define USBPORT_TMFLAG_HC_RESUME 0x00000004
95 #define USBPORT_TMFLAG_RH_SUSPENDED 0x00000008
96 #define USBPORT_TMFLAG_TIMER_STARTED 0x00000010
97 #define USBPORT_TMFLAG_WAKE 0x00000020
98 #define USBPORT_TMFLAG_IDLE_QUEUEITEM_ON 0x00000040
99 
100 /* Miniport Flags */
101 #define USBPORT_MPFLAG_INTERRUPTS_ENABLED 0x00000001
102 #define USBPORT_MPFLAG_SUSPENDED 0x00000002
103 
104 /* Device handle Flags (USBPORT_DEVICE_HANDLE) */
105 #define DEVICE_HANDLE_FLAG_ROOTHUB 0x00000002
106 #define DEVICE_HANDLE_FLAG_REMOVED 0x00000008
107 #define DEVICE_HANDLE_FLAG_USB2HUB 0x00000010
108 
109 /* Endpoint Flags (USBPORT_ENDPOINT) */
110 #define ENDPOINT_FLAG_DMA_TYPE 0x00000001
111 #define ENDPOINT_FLAG_ROOTHUB_EP0 0x00000002
112 #define ENDPOINT_FLAG_NUKE 0x00000008
113 #define ENDPOINT_FLAG_QUEUENE_EMPTY 0x00000010
114 #define ENDPOINT_FLAG_ABORTING 0x00000020
115 #define ENDPOINT_FLAG_IDLE 0x00000100
116 #define ENDPOINT_FLAG_OPENED 0x00000200
117 #define ENDPOINT_FLAG_CLOSED 0x00000400
118 
119 /* UsbdFlags Flags (URB) */
120 #define USBD_FLAG_ALLOCATED_MDL 0x00000002
121 #define USBD_FLAG_NOT_ISO_TRANSFER 0x00000010
122 #define USBD_FLAG_ALLOCATED_TRANSFER 0x00000020
123 
124 /* Pipe handle Flags (USBPORT_PIPE_HANDLE) */
125 #define PIPE_HANDLE_FLAG_CLOSED 0x00000001
126 #define PIPE_HANDLE_FLAG_NULL_PACKET_SIZE 0x00000002
127 
128 /* Transfer Flags (USBPORT_TRANSFER) */
129 #define TRANSFER_FLAG_CANCELED 0x00000001
130 #define TRANSFER_FLAG_DMA_MAPPED 0x00000002
131 #define TRANSFER_FLAG_HIGH_SPEED 0x00000004
132 #define TRANSFER_FLAG_SUBMITED 0x00000008
133 #define TRANSFER_FLAG_ABORTED 0x00000010
134 #define TRANSFER_FLAG_ISO 0x00000020
135 #define TRANSFER_FLAG_DEVICE_GONE 0x00000080
136 #define TRANSFER_FLAG_SPLITED 0x00000100
137 #define TRANSFER_FLAG_COMPLETED 0x00000200
138 #define TRANSFER_FLAG_PARENT 0x00000400
139 
142 
144 
153 
155 
158 typedef struct _USB2_TT *PUSB2_TT;
160 
161 typedef struct _USBPORT_PIPE_HANDLE {
169 
173  //USB_CONFIGURATION_DESCRIPTOR CfgDescriptor; // Body.
175 
184 
185 typedef struct _USBPORT_DEVICE_HANDLE {
199  PUSB2_TT_EXTENSION TtExtension; // Transaction Translator
202 
203 typedef struct _USBPORT_ENDPOINT {
208  PUSB2_TT_EXTENSION TtExtension; // Transaction Translator
213  /* Locks */
220  /* State */
225  /* Transfer lists */
230  /* Links */
241 
242 typedef struct _USBPORT_ISO_BLOCK *PUSBPORT_ISO_BLOCK;
243 
244 typedef struct _USBPORT_TRANSFER {
250  SIZE_T PortTransferLength; // Only port part
251  SIZE_T FullTransferLength; // Port + miniport
265  LIST_ENTRY SplitTransfersList; // for parent transfers
266  LIST_ENTRY SplitLink; // for splitted transfers
268  PUSBPORT_ISO_BLOCK IsoBlockPtr; // pointer on IsoBlock
269  // SgList should be LAST field
271  //USBPORT_ISO_BLOCK IsoBlock; // variable length
273 
274 typedef struct _USBPORT_IRP_TABLE {
276  PIRP irp[0X200];
278 
281  PDEVICE_OBJECT LowerPdoDevice; // PhysicalDeviceObject
282  PDEVICE_OBJECT LowerDevice; // TopOfStackDeviceObject
289 
293  PDEVICE_OBJECT RootHubPdo; // RootHubDeviceObject
303  /* Miniport */
310  /* Bus Interface */
318  /* Dma Adapter */
321  /* Interrupt */
329  /* Endpoints */
338  /* Transfers */
346  /* Timer */
347  ULONG TimerValue; // Timer period (500) msec. default
352  /* Worker Thread */
357  /* Usb Devices */
362  /* Device Capabilities */
368  /* Idle */
374  /* Bad Requests */
379  /* Irp Queues */
382  /* Power */
388  /* Usb 2.0 HC Extension */
392 
393  /* Miniport extension should be aligned on 0x100 */
394 #if !defined(_M_X64)
396 #else
397  ULONG Padded[30];
398 #endif
399 
401 
402 #if !defined(_M_X64)
403 C_ASSERT(sizeof(USBPORT_DEVICE_EXTENSION) == 0x500);
404 #else
405 C_ASSERT(sizeof(USBPORT_DEVICE_EXTENSION) == 0x700);
406 #endif
407 
408 typedef struct _USBPORT_RH_DESCRIPTORS {
413  USB_HUB_DESCRIPTOR Descriptor; // Size may be: 7 + 2[1..32] (7 + 2..64)
415 
430 
436  ASYNC_TIMER_CALLBACK *CallbackFunction;
439 
440 C_ASSERT(sizeof(USBPORT_ASYNC_CALLBACK_DATA) == 16 + 18 * sizeof(PVOID));
441 
442 typedef struct _TIMER_WORK_QUEUE_ITEM {
447 
448 /* Transaction Translator */
449 /* See Chapter 5 - USB Data Flow Model and Chapter 11 - Hub Specification */
450 
451 #define USB2_FRAMES 32
452 #define USB2_MICROFRAMES 8
453 #define USB2_MAX_MICROFRAMES (USB2_FRAMES * USB2_MICROFRAMES)
454 #define USB2_PREV_MICROFRAME 0xFF
455 
456 #define USB2_MAX_MICROFRAME_ALLOCATION 7000 // bytes
457 #define USB2_CONTROLLER_DELAY 100
458 #define USB2_FS_MAX_PERIODIC_ALLOCATION 1157 // ((12000 / 8 bits) * 0.9) / (7/6) - 90% max, and bits stuffing
459 #define USB2_FS_SOF_TIME 6
460 #define USB2_HUB_DELAY 30
461 #define USB2_MAX_FS_LS_TRANSACTIONS_IN_UFRAME 16
462 #define USB2_FS_RAW_BYTES_IN_MICROFRAME 188 // (12000 / 8 bits / USB2_MICROFRAMES) = 187,5. But we use "best case budget"
463 
464 /* Overheads */
465 #define USB2_LS_INTERRUPT_OVERHEAD 117 // FS-bytes
466 #define USB2_FS_INTERRUPT_OVERHEAD 13
467 #define USB2_HS_INTERRUPT_OUT_OVERHEAD 45
468 #define USB2_HS_INTERRUPT_IN_OVERHEAD 25
469 #define USB2_FS_ISOCHRONOUS_OVERHEAD 9
470 #define USB2_HS_ISOCHRONOUS_OUT_OVERHEAD 38
471 #define USB2_HS_ISOCHRONOUS_IN_OVERHEAD 18
472 
473 #define USB2_HS_SS_INTERRUPT_OUT_OVERHEAD 58
474 #define USB2_HS_CS_INTERRUPT_OUT_OVERHEAD 36
475 #define USB2_HS_SS_INTERRUPT_IN_OVERHEAD 39
476 #define USB2_HS_CS_INTERRUPT_IN_OVERHEAD 38
477 
478 #define USB2_HS_SS_ISOCHRONOUS_OUT_OVERHEAD 58
479 #define USB2_HS_SS_ISOCHRONOUS_IN_OVERHEAD 39
480 #define USB2_HS_CS_ISOCHRONOUS_IN_OVERHEAD 38
481 
482 #define USB2_BIT_STUFFING_OVERHEAD (8 * (7/6)) // 7.1.9 Bit Stuffing
483 
485  struct {
491  };
494 
495 C_ASSERT(sizeof(USB2_TT_ENDPOINT_PARAMS) == sizeof(ULONG));
496 
497 typedef union _USB2_TT_ENDPOINT_NUMS {
498  struct {
502  };
505 
506 C_ASSERT(sizeof(USB2_TT_ENDPOINT_NUMS) == sizeof(ULONG));
507 
508 typedef struct _USB2_TT_ENDPOINT {
525 
526 typedef struct _USB2_FRAME_BUDGET {
533 
534 typedef struct _USB2_TT {
543 } USB2_TT, *PUSB2_TT;
544 
545 #define USB2_TT_EXTENSION_FLAG_DELETED 1
546 
547 typedef struct _USB2_TT_EXTENSION {
560 
561 typedef struct _USB2_HC_EXTENSION {
567 
568 typedef struct _USB2_REBALANCE {
571 
572 /* usbport.c */
573 NTSTATUS
574 NTAPI
576  IN PURB Urb,
577  IN USBD_STATUS USBDStatus);
578 
579 NTSTATUS
580 NTAPI
582  IN PVOID MiniPortExtension,
583  IN ULONG Milliseconds);
584 
585 VOID
586 NTAPI
588  IN PRKDPC Dpc,
592 
593 NTSTATUS
594 NTAPI
596  IN PDEVICE_OBJECT FdoDevice);
597 
598 BOOLEAN
599 NTAPI
601  IN PDEVICE_OBJECT FdoDevice,
602  IN ULONG Time);
603 
605 NTAPI
607  IN PDEVICE_OBJECT FdoDevice,
609 
610 VOID
611 NTAPI
613  IN PDEVICE_OBJECT FdoDevice,
614  IN PUSBPORT_COMMON_BUFFER_HEADER HeaderBuffer);
615 
617 NTAPI
619  IN PDEVICE_OBJECT FdoDevice,
620  IN PURB Urb,
622  IN PIRP Irp,
623  IN PRKEVENT Event);
624 
625 VOID
626 NTAPI
628  IN PDEVICE_OBJECT FdoDevice);
629 
630 VOID
631 NTAPI
633  IN PRKDPC Dpc,
637 
638 BOOLEAN
639 NTAPI
641  IN PKINTERRUPT Interrupt,
643 
644 VOID
645 NTAPI
647  IN PDEVICE_OBJECT FdoDevice);
648 
649 VOID
650 NTAPI
652  IN PURB Urb,
653  IN USBD_STATUS TransferStatus);
654 
655 VOID
656 NTAPI
658  IN PDEVICE_OBJECT FdoDevice);
659 
660 VOID
661 NTAPI
663  IN PRKDPC Dpc,
667 
668 BOOLEAN
669 NTAPI
671  IN PUSBPORT_TRANSFER Transfer,
672  IN USBD_STATUS USBDStatus);
673 
674 VOID
675 NTAPI
677  IN PDEVICE_OBJECT FdoDevice,
678  IN BOOLEAN IsEnable);
679 
680 NTSTATUS
681 NTAPI
684  IN BOOL UseDriverKey,
685  IN ULONG Type,
686  IN PCWSTR ValueNameString,
687  IN PVOID Data,
688  IN ULONG DataSize);
689 
690 NTSTATUS
691 NTAPI
693  IN PDEVICE_OBJECT FdoDevice,
694  IN PDEVICE_OBJECT PdoDevice,
695  IN BOOL UseDriverKey,
697  IN ULONG LengthStr,
698  IN PVOID Buffer,
700 
701 VOID
702 NTAPI
704  IN PDEVICE_OBJECT FdoDevice);
705 
706 VOID
707 NTAPI
709  IN PDEVICE_OBJECT FdoDevice);
710 
711 VOID
712 NTAPI
714  IN PDEVICE_OBJECT FdoDevice);
715 
717 NTAPI
719  IN PDEVICE_OBJECT FdoDevice);
720 
722 NTAPI
724  IN PDEVICE_OBJECT USB2FdoDevice,
725  IN BOOLEAN IsObRefer,
726  IN BOOLEAN IsFDOsReturned);
727 
728 VOID
729 NTAPI
731  IN PDEVICE_OBJECT FdoDevice,
732  IN ULONG Type);
733 
734 VOID
735 NTAPI
737  IN PUSBPORT_TRANSFER Transfer);
738 
739 /* debug.c */
740 ULONG
741 NTAPI
743  IN PVOID MiniPortExtension,
744  IN ULONG Level,
745  IN PCH Format,
746  ...);
747 
748 ULONG
749 NTAPI
751  IN PVOID MiniPortExtension);
752 
753 ULONG
754 NTAPI
756  PVOID MiniPortExtension,
757  PVOID FailedAssertion,
758  PVOID FileName,
760  PCHAR Message);
761 
762 VOID
763 NTAPI
765  IN PVOID MiniPortExtension);
766 
767 ULONG
768 NTAPI
770  IN PVOID MiniPortExtension,
771  IN ULONG DriverTag,
772  IN ULONG EnumTag,
773  IN ULONG P1,
774  IN ULONG P2,
775  IN ULONG P3);
776 
777 VOID
778 NTAPI
781 
782 VOID
783 NTAPI
785  IN PUSB_CONFIGURATION_DESCRIPTOR ConfigDescriptor);
786 
787 VOID
788 NTAPI
791 
792 VOID
793 NTAPI
795  IN PUSB_DEFAULT_PIPE_SETUP_PACKET SetupPacket);
796 
797 VOID
798 NTAPI
800  IN PURB Urb);
801 
802 VOID
803 NTAPI
805  IN PVOID Buffer);
806 
807 /* device.c */
808 NTSTATUS
809 NTAPI
811  IN PDEVICE_OBJECT FdoDevice,
812  IN PIRP Irp,
813  IN PURB Urb);
814 
815 VOID
816 NTAPI
818  IN PDEVICE_OBJECT FdoDevice,
820 
821 VOID
822 NTAPI
824  IN PDEVICE_OBJECT FdoDevice,
826 
827 BOOLEAN
828 NTAPI
830  IN PDEVICE_OBJECT FdoDevice,
832 
833 NTSTATUS
834 NTAPI
836  IN OUT PUSB_DEVICE_HANDLE *pUsbdDeviceHandle,
837  IN PDEVICE_OBJECT FdoDevice,
840  IN USHORT Port);
841 
842 NTSTATUS
843 NTAPI
846  IN PDEVICE_OBJECT FdoDevice);
847 
848 NTSTATUS
849 NTAPI
852  IN PDEVICE_OBJECT FdoDevice,
853  IN UCHAR Type,
854  IN PUCHAR ConfigDesc,
855  IN PULONG ConfigDescSize);
856 
857 NTSTATUS
858 NTAPI
860  IN PDEVICE_OBJECT FdoDevice,
861  IN PIRP Irp,
862  IN PURB Urb);
863 
864 NTSTATUS
865 NTAPI
867  IN PDEVICE_OBJECT FdoDevice,
869  IN ULONG Flags);
870 
871 NTSTATUS
872 NTAPI
875  IN PDEVICE_OBJECT FdoDevice,
877  IN PVOID Buffer,
878  IN ULONG Length,
879  IN OUT PULONG TransferedLen,
880  IN OUT PUSBD_STATUS pUSBDStatus);
881 
882 NTSTATUS
883 NTAPI
885  IN PDEVICE_OBJECT FdoDevice,
888 
889 NTSTATUS
890 NTAPI
892  IN PDEVICE_OBJECT FdoDevice,
894  IN ULONG TtCount);
895 
896 /* endpoint.c */
897 NTSTATUS
898 NTAPI
900  IN PDEVICE_OBJECT FdoDevice,
903  IN PUSBD_STATUS UsbdStatus);
904 
905 MPSTATUS
906 NTAPI
908  IN PDEVICE_OBJECT FdoDevice,
909  IN PUSBPORT_ENDPOINT Endpoint);
910 
911 NTSTATUS
912 NTAPI
914  IN PDEVICE_OBJECT FdoDevice,
915  IN PUSBPORT_ENDPOINT Endpoint);
916 
917 VOID
918 NTAPI
921  IN PDEVICE_OBJECT FdoDevice,
923 
924 VOID
925 NTAPI
927  IN PDEVICE_OBJECT FdoDevice,
928  IN PUSBPORT_ENDPOINT Endpoint);
929 
930 VOID
931 NTAPI
935 
936 VOID
937 NTAPI
941 
942 BOOLEAN
943 NTAPI
947 
948 VOID
949 NTAPI
951  IN PDEVICE_OBJECT FdoDevice);
952 
953 VOID
954 NTAPI
956  IN PUSBPORT_ENDPOINT Endpoint,
957  IN ULONG State);
958 
959 ULONG
960 NTAPI
962  IN PUSBPORT_ENDPOINT Endpoint);
963 
964 VOID
965 NTAPI
967  IN PDEVICE_OBJECT FdoDevice,
968  IN PUSBPORT_ENDPOINT Endpoint,
969  IN ULONG Type);
970 
971 BOOLEAN
972 NTAPI
974  IN PUSBPORT_ENDPOINT Endpoint,
975  IN BOOLEAN Flag);
976 
977 VOID
978 NTAPI
980  IN PDEVICE_OBJECT FdoDevice);
981 
982 BOOLEAN
983 NTAPI
985  IN PDEVICE_OBJECT FdoDevice,
986  IN PUSBPORT_ENDPOINT Endpoint,
987  IN PULONG TransferCount);
988 
989 /* iface.c */
990 NTSTATUS
991 NTAPI
993  IN PDEVICE_OBJECT FdoDevice,
994  IN PDEVICE_OBJECT PdoDevice,
995  IN PIRP Irp);
996 
997 /* ioctl.c */
998 NTSTATUS
999 NTAPI
1001  PDEVICE_OBJECT PdoDevice,
1002  PIRP Irp);
1003 
1004 NTSTATUS
1005 NTAPI
1007  PDEVICE_OBJECT FdoDevice,
1008  PIRP Irp);
1009 
1010 NTSTATUS
1011 NTAPI
1013  IN PDEVICE_OBJECT FdoDevice,
1014  IN PIRP Irp);
1015 
1016 NTSTATUS
1017 NTAPI
1019  IN PDEVICE_OBJECT FdoDevice,
1020  IN PIRP Irp);
1021 
1022 NTSTATUS
1023 NTAPI
1025  IN PDEVICE_OBJECT RootHubPdo,
1027 
1028 /* iso.c */
1030 NTAPI
1032  IN PDEVICE_OBJECT FdoDevice,
1033  IN struct _URB_ISOCH_TRANSFER * Urb,
1034  IN PUSBPORT_TRANSFER Transfer);
1035 
1036 ULONG
1037 NTAPI
1039  IN PVOID MiniPortExtension,
1040  IN PVOID MiniPortEndpoint,
1041  IN PVOID TransferParameters,
1042  IN ULONG TransferLength);
1043 
1044 /* pnp.c */
1045 NTSTATUS
1046 NTAPI
1048  IN PDEVICE_OBJECT FdoDevice,
1049  IN PIRP Irp);
1050 
1051 NTSTATUS
1052 NTAPI
1054  IN PDEVICE_OBJECT FdoDevice,
1055  IN PIRP Irp);
1056 
1057 /* power.c */
1058 NTSTATUS
1059 NTAPI
1061  IN PDEVICE_OBJECT PdoDevice,
1062  IN PIRP Irp);
1063 
1064 NTSTATUS
1065 NTAPI
1067  IN PDEVICE_OBJECT FdoDevice,
1068  IN PIRP Irp);
1069 
1070 NTSTATUS
1071 NTAPI
1073  IN PDEVICE_OBJECT PdoDevice,
1074  IN PIRP Irp);
1075 
1076 VOID
1077 NTAPI
1079  IN PDEVICE_OBJECT FdoDevice,
1080  IN PDEVICE_OBJECT PdoDevice);
1081 
1082 VOID
1083 NTAPI
1085  IN PVOID Context);
1086 
1087 VOID
1088 NTAPI
1090  IN PDEVICE_OBJECT FdoDevice);
1091 
1092 VOID
1093 NTAPI
1095  IN PDEVICE_OBJECT FdoDevice);
1096 
1097 VOID
1098 NTAPI
1100  IN PRKDPC Dpc,
1104 
1105 VOID
1106 NTAPI
1108  IN PDEVICE_OBJECT FdoDevice);
1109 
1110 /* queue.c */
1111 VOID
1112 NTAPI
1114  IN PIO_CSQ Csq,
1115  IN PIRP Irp);
1116 
1117 VOID
1118 NTAPI
1120  IN PIO_CSQ Csq,
1121  IN PIRP Irp);
1122 
1123 PIRP
1124 NTAPI
1126  IN PIO_CSQ Csq,
1127  IN PIRP Irp,
1128  IN PVOID PeekContext);
1129 
1130 VOID
1131 NTAPI
1133  IN PIO_CSQ Csq,
1134  IN PKIRQL Irql);
1135 
1136 VOID
1137 NTAPI
1139  IN PIO_CSQ Csq,
1140  IN KIRQL Irql);
1141 
1142 VOID
1143 NTAPI
1145  IN PIO_CSQ Csq,
1146  IN PIRP Irp);
1147 
1148 VOID
1149 NTAPI
1151  IN PIO_CSQ Csq,
1152  IN PIRP Irp);
1153 
1154 VOID
1155 NTAPI
1157  IN PIO_CSQ Csq,
1158  IN PIRP Irp);
1159 
1160 PIRP
1161 NTAPI
1163  IN PIO_CSQ Csq,
1164  IN PIRP Irp,
1165  IN PVOID PeekContext);
1166 
1167 VOID
1168 NTAPI
1170  IN PIO_CSQ Csq,
1171  IN PKIRQL Irql);
1172 
1173 VOID
1174 NTAPI
1176  IN PIO_CSQ Csq,
1177  IN KIRQL Irql);
1178 
1179 VOID
1180 NTAPI
1182  IN PIO_CSQ Csq,
1183  IN PIRP Irp);
1184 
1185 VOID
1186 NTAPI
1188  IN PUSBPORT_IRP_TABLE IrpTable,
1189  IN PIRP Irp);
1190 
1191 PIRP
1192 NTAPI
1194  IN PDEVICE_OBJECT FdoDevice,
1195  IN PIRP Irp);
1196 
1197 PIRP
1198 NTAPI
1200  IN PDEVICE_OBJECT FdoDevice,
1201  IN PIRP Irp);
1202 
1203 VOID
1204 NTAPI
1206  IN PUSBPORT_IRP_TABLE IrpTable,
1207  IN PURB Urb,
1208  IN PIRP Irp);
1209 
1210 VOID
1211 NTAPI
1214  IN PIRP Irp);
1215 
1216 VOID
1217 NTAPI
1219  IN PUSBPORT_ENDPOINT Endpoint);
1220 
1221 VOID
1222 NTAPI
1224  IN PUSBPORT_ENDPOINT Endpoint);
1225 
1226 VOID
1227 NTAPI
1229  IN PURB Urb);
1230 
1231 VOID
1232 NTAPI
1234  IN PDEVICE_OBJECT FdoDevice);
1235 
1236 VOID
1237 NTAPI
1239  IN PUSBPORT_ENDPOINT Endpoint);
1240 
1241 BOOLEAN
1242 NTAPI
1244  IN PUSBPORT_ENDPOINT Endpoint,
1245  IN PURB Urb);
1246 
1247 VOID
1248 NTAPI
1250  IN PDEVICE_OBJECT FdoDevice);
1251 
1252 VOID
1253 NTAPI
1255  IN PDEVICE_OBJECT FdoDevice);
1256 
1257 VOID
1258 NTAPI
1260  IN PDEVICE_OBJECT FdoDevice,
1261  IN PUSBPORT_ENDPOINT Endpoint,
1262  IN PIRP Irp);
1263 
1264 /* roothub.c */
1265 VOID
1266 NTAPI
1268  PUSBPORT_ENDPOINT Endpoint);
1269 
1270 NTSTATUS
1271 NTAPI
1273  IN PDEVICE_OBJECT FdoDevice,
1274  IN PDEVICE_OBJECT PdoDevice);
1275 
1276 ULONG
1277 NTAPI
1279  PVOID MiniPortExtension);
1280 
1281 VOID
1282 NTAPI
1284  IN PDEVICE_OBJECT FdoDevice);
1285 
1286 /* trfsplit.c */
1287 VOID
1288 NTAPI
1290  IN PDEVICE_OBJECT FdoDevice,
1291  IN PUSBPORT_ENDPOINT Endpoint,
1292  IN PUSBPORT_TRANSFER Transfer,
1293  IN PLIST_ENTRY List);
1294 
1295 VOID
1296 NTAPI
1298  IN PUSBPORT_TRANSFER SplitTransfer);
1299 
1300 VOID
1301 NTAPI
1303  IN PUSBPORT_TRANSFER SplitTransfer);
1304 
1305 /* urb.c */
1306 NTSTATUS
1307 NTAPI
1309  IN PDEVICE_OBJECT PdoDevice,
1310  IN PIRP Irp,
1311  IN PURB Urb);
1312 
1313 /* usb2.c */
1314 BOOLEAN
1315 NTAPI
1317  IN PDEVICE_OBJECT FdoDevice,
1318  IN PUSBPORT_ENDPOINT Endpoint);
1319 
1320 VOID
1321 NTAPI
1323  IN PDEVICE_OBJECT FdoDevice,
1324  IN PUSBPORT_ENDPOINT Endpoint);
1325 
1326 VOID
1327 NTAPI
1329  IN PUSB2_TT_EXTENSION TtExtension);
1330 
1331 VOID
1332 NTAPI
1333 USB2_InitTT(
1334  IN PUSB2_HC_EXTENSION HcExtension,
1335  IN PUSB2_TT Tt);
1336 
1337 VOID
1338 NTAPI
1340  IN PUSB2_HC_EXTENSION HcExtension);
1341 
1342 VOID
1343 NTAPI
1345  IN PUSBPORT_ENDPOINT_PROPERTIES EndpointProperties);
1346 
1347 VOID
1348 NTAPI
1350  IN PUSB2_TT_ENDPOINT TtEndpoint);
1351 
1352 #endif /* USBPORT_H__ */
ULONG NumberOfMapRegisters
Definition: usbport.h:259
ULONG MPSTATUS
Definition: usbmport.h:131
#define USB2_MICROFRAMES
Definition: usbport.h:452
USB2_FRAME_BUDGET FrameBudget[USB2_FRAMES]
Definition: usbport.h:540
KSPIN_LOCK SetPowerD0SpinLock
Definition: usbport.h:385
signed char * PCHAR
Definition: retypes.h:7
LIST_ENTRY SplitLink
Definition: usbport.h:266
MPSTATUS NTAPI MiniportOpenEndpoint(IN PDEVICE_OBJECT FdoDevice, IN PUSBPORT_ENDPOINT Endpoint)
Definition: endpoint.c:722
BOOLEAN NTAPI USBPORT_EndpointWorker(IN PUSBPORT_ENDPOINT Endpoint, IN BOOLEAN Flag)
Definition: endpoint.c:1658
USBPORT_SCATTER_GATHER_LIST SgList
Definition: usbport.h:270
VOID NTAPI USBPORT_SetEndpointState(IN PUSBPORT_ENDPOINT Endpoint, IN ULONG State)
Definition: endpoint.c:363
struct _USB2_REBALANCE USB2_REBALANCE
BOOLEAN NTAPI USBPORT_InterruptService(IN PKINTERRUPT Interrupt, IN PVOID ServiceContext)
Definition: usbport.c:1077
CPPORT Port[4]
Definition: headless.c:34
const uint16_t * PCWSTR
Definition: typedefs.h:55
#define IN
Definition: typedefs.h:38
NTSTATUS NTAPI USBPORT_OpenPipe(IN PDEVICE_OBJECT FdoDevice, IN PUSBPORT_DEVICE_HANDLE DeviceHandle, IN PUSBPORT_PIPE_HANDLE PipeHandle, IN PUSBD_STATUS UsbdStatus)
PUSB2_TT_ENDPOINT TtEndpoint
Definition: usbport.h:209
PDEVICE_OBJECT FdoDevice
Definition: usbport.h:444
VOID NTAPI USBPORT_HcQueueWakeDpc(IN PDEVICE_OBJECT FdoDevice)
Definition: power.c:63
LIST_ENTRY EndpointLink
Definition: usbport.h:231
BOOLEAN NTAPI USBPORT_AllocateBandwidthUSB2(IN PDEVICE_OBJECT FdoDevice, IN PUSBPORT_ENDPOINT Endpoint)
Definition: usb2.c:1799
struct _USBPORT_TRANSFER USBPORT_TRANSFER
NTSTATUS NTAPI USBPORT_CreateWorkerThread(IN PDEVICE_OBJECT FdoDevice)
Definition: usbport.c:1422
BOOLEAN NTAPI USBPORT_QueueDoneTransfer(IN PUSBPORT_TRANSFER Transfer, IN USBD_STATUS USBDStatus)
Definition: usbport.c:839
_Inout_ PUSB_DEVICE_HANDLE DeviceHandle
Definition: hubbusif.h:121
LIST_ENTRY WorkerLink
Definition: usbport.h:232
NTSTATUS NTAPI USBPORT_RemoveDevice(IN PDEVICE_OBJECT FdoDevice, IN OUT PUSBPORT_DEVICE_HANDLE DeviceHandle, IN ULONG Flags)
Definition: device.c:1584
struct _USBPORT_ASYNC_CALLBACK_DATA * PUSBPORT_ASYNC_CALLBACK_DATA
USBD_STATUS NTAPI USBPORT_AllocateTransfer(IN PDEVICE_OBJECT FdoDevice, IN PURB Urb, IN PUSBPORT_DEVICE_HANDLE DeviceHandle, IN PIRP Irp, IN PRKEVENT Event)
Definition: usbport.c:2521
NTSTATUS NTAPI USBPORT_SendSetupPacket(IN PUSBPORT_DEVICE_HANDLE DeviceHandle, IN PDEVICE_OBJECT FdoDevice, IN PUSB_DEFAULT_PIPE_SETUP_PACKET SetupPacket, IN PVOID Buffer, IN ULONG Length, IN OUT PULONG TransferedLen, IN OUT PUSBD_STATUS pUSBDStatus)
Definition: device.c:15
KSPIN_LOCK DeviceHandleSpinLock
Definition: usbport.h:360
Type
Definition: Type.h:6
LIST_ENTRY FlushLink
Definition: usbport.h:235
struct _TIMER_WORK_QUEUE_ITEM * PTIMER_WORK_QUEUE_ITEM
NTSTATUS NTAPI USBPORT_FdoDeviceControl(PDEVICE_OBJECT FdoDevice, PIRP Irp)
VOID NTAPI USBPORT_BadRequestFlush(IN PDEVICE_OBJECT FdoDevice)
Definition: queue.c:1328
ULONG MinBandwidth
Definition: usbport.h:553
LIST_ENTRY ControllerLink
Definition: usbport.h:301
VOID NTAPI USBPORT_RemovePipeHandle(IN PUSBPORT_DEVICE_HANDLE DeviceHandle, IN PUSBPORT_PIPE_HANDLE PipeHandle)
Definition: endpoint.c:456
LARGE_INTEGER Time
Definition: usbport.h:262
VOID NTAPI USBPORT_FlushAllEndpoints(IN PDEVICE_OBJECT FdoDevice)
Definition: queue.c:1171
USB_CONFIGURATION_DESCRIPTOR ConfigDescriptor
Definition: usbport.h:410
LIST_ENTRY FlushAbortLink
Definition: usbport.h:237
LIST_ENTRY MapTransferList
Definition: usbport.h:339
VOID NTAPI USBPORT_DumpingDeviceDescriptor(IN PUSB_DEVICE_DESCRIPTOR DeviceDescriptor)
Definition: debug.c:80
ULONG TimeUsed[USB2_FRAMES][USB2_MICROFRAMES]
Definition: usbport.h:564
_In_ PIRP Irp
Definition: csq.h:116
VOID NTAPI USBPORT_DoneSplitTransfer(IN PUSBPORT_TRANSFER SplitTransfer)
Definition: trfsplit.c:278
KSPIN_LOCK BadRequestIoCsqSpinLock
Definition: usbport.h:376
PUSBPORT_COMMON_BUFFER_HEADER NTAPI USBPORT_AllocateCommonBuffer(IN PDEVICE_OBJECT FdoDevice, IN SIZE_T BufferLength)
Definition: usbport.c:1686
USHORT StartTime
Definition: usbport.h:520
PDEVICE_OBJECT LowerPdoDevice
Definition: usbport.h:281
struct _USB2_TT_EXTENSION * PUSB2_TT_EXTENSION
Definition: usbport.h:157
NTSTATUS NTAPI USBPORT_Initialize20Hub(IN PDEVICE_OBJECT FdoDevice, IN PUSBPORT_DEVICE_HANDLE HubDeviceHandle, IN ULONG TtCount)
Definition: device.c:2012
VOID NTAPI USBPORT_AdjustDeviceCapabilities(IN PDEVICE_OBJECT FdoDevice, IN PDEVICE_OBJECT PdoDevice)
Definition: power.c:668
NTSTATUS NTAPI USBPORT_Wait(IN PVOID MiniPortExtension, IN ULONG Milliseconds)
Definition: usbport.c:543
PUSB2_HC_EXTENSION HcExtension
Definition: usbport.h:535
unsigned char * PUCHAR
Definition: retypes.h:3
NTSTATUS NTAPI USBPORT_HandleSelectConfiguration(IN PDEVICE_OBJECT FdoDevice, IN PIRP Irp, IN PURB Urb)
Definition: device.c:574
USBPORT_TRANSFER_PARAMETERS TransferParameters
Definition: usbport.h:253
LONG NTSTATUS
Definition: precomp.h:26
VOID NTAPI USBPORT_InvalidateEndpointHandler(IN PDEVICE_OBJECT FdoDevice, IN PUSBPORT_ENDPOINT Endpoint, IN ULONG Type)
Definition: endpoint.c:1317
struct _USBPORT_DEVICE_HANDLE * HubDeviceHandle
Definition: usbport.h:194
VOID NTAPI USBPORT_AbortEndpoint(IN PDEVICE_OBJECT FdoDevice, IN PUSBPORT_ENDPOINT Endpoint, IN PIRP Irp)
Definition: queue.c:1354
UNICODE_STRING DosDeviceSymbolicName
Definition: usbport.h:299
LIST_ENTRY Link
Definition: usbport.h:557
struct _USBPORT_COMMON_DEVICE_EXTENSION * PUSBPORT_COMMON_DEVICE_EXTENSION
PDMA_ADAPTER DmaAdapter
Definition: usbport.h:319
NTSTATUS NTAPI USBPORT_PdoPnP(IN PDEVICE_OBJECT FdoDevice, IN PIRP Irp)
Definition: pnp.c:1517
VOID NTAPI USBPORT_AcquireIdleLock(IN PIO_CSQ Csq, IN PKIRQL Irql)
Definition: queue.c:91
_Outptr_ PUSB_DEVICE_HANDLE _In_ PUSB_DEVICE_HANDLE HubDeviceHandle
Definition: hubbusif.h:40
struct _USBPORT_COMMON_BUFFER_HEADER USBPORT_COMMON_BUFFER_HEADER
LIST_ENTRY IdleIrpList
Definition: usbport.h:372
VOID NTAPI USBPORT_CompleteCanceledIdleIrp(IN PIO_CSQ Csq, IN PIRP Irp)
Definition: queue.c:123
struct _USBPORT_COMMON_BUFFER_HEADER * PUSBPORT_COMMON_BUFFER_HEADER
LIST_ENTRY DoneTransferList
Definition: usbport.h:341
DEVICE_CAPABILITIES Capabilities
Definition: usbport.h:427
ULONG MaxBandwidth
Definition: usbport.h:552
LIST_ENTRY DeviceHandleLink
Definition: usbport.h:196
PMDL TransferBufferMDL
Definition: usbport.h:254
NTSTATUS NTAPI USBPORT_SetRegistryKeyValue(IN PDEVICE_OBJECT DeviceObject, IN BOOL UseDriverKey, IN ULONG Type, IN PCWSTR ValueNameString, IN PVOID Data, IN ULONG DataSize)
Definition: usbport.c:248
DEVICE_CAPABILITIES
Definition: iotypes.h:928
VOID NTAPI USBPORT_DumpingURB(IN PURB Urb)
Definition: debug.c:225
PDEVICE_OBJECT FdoDevice
Definition: usbport.h:433
_IRQL_requires_same_ typedef _In_ ULONG _In_ UCHAR Level
Definition: wmitypes.h:55
VOID NTAPI USBPORT_CancelActiveTransferIrp(IN PDEVICE_OBJECT DeviceObject, IN PIRP Irp)
Definition: queue.c:529
VOID NTAPI USBPORT_RemoveUSBxFdo(IN PDEVICE_OBJECT FdoDevice)
Definition: usbport.c:98
BOOLEAN NTAPI USBPORT_ValidateDeviceHandle(IN PDEVICE_OBJECT FdoDevice, IN PUSBPORT_DEVICE_HANDLE DeviceHandle)
Definition: device.c:801
VOID NTAPI USBPORT_TransferFlushDpc(IN PRKDPC Dpc, IN PVOID DeferredContext, IN PVOID SystemArgument1, IN PVOID SystemArgument2)
Definition: usbport.c:825
NTSTATUS NTAPI USBPORT_CreateDevice(IN OUT PUSB_DEVICE_HANDLE *pUsbdDeviceHandle, IN PDEVICE_OBJECT FdoDevice, IN PUSBPORT_DEVICE_HANDLE HubDeviceHandle, IN USHORT PortStatus, IN USHORT Port)
Definition: device.c:982
LARGE_INTEGER IdleTime
Definition: usbport.h:369
LIST_ENTRY AbortList
Definition: usbport.h:229
VOID NTAPI USBPORT_FreeBandwidthUSB2(IN PDEVICE_OBJECT FdoDevice, IN PUSBPORT_ENDPOINT Endpoint)
Definition: usb2.c:2040
VOID NTAPI USBPORT_SignalWorkerThread(IN PDEVICE_OBJECT FdoDevice)
Definition: usbport.c:1111
struct _USB2_TT * PUSB2_TT
Definition: usbport.h:158
VOID NTAPI USBPORT_ReleaseBadRequestLock(IN PIO_CSQ Csq, IN KIRQL Irql)
Definition: queue.c:230
NTSTATUS NTAPI USBPORT_FdoPower(IN PDEVICE_OBJECT FdoDevice, IN PIRP Irp)
Definition: power.c:489
VOID NTAPI USBPORT_FreeCommonBuffer(IN PDEVICE_OBJECT FdoDevice, IN PUSBPORT_COMMON_BUFFER_HEADER HeaderBuffer)
Definition: usbport.c:1748
PRH_INIT_CALLBACK RootHubInitCallback
Definition: usbport.h:425
ULONG NTAPI USBPORT_GetEndpointState(IN PUSBPORT_ENDPOINT Endpoint)
Definition: endpoint.c:332
PRKEVENT Event
Definition: usbport.h:248
LIST_ENTRY DeviceHandleList
Definition: usbport.h:359
ULONG NumStartSplits[USB2_FRAMES][USB2_MICROFRAMES]
Definition: usbport.h:541
_Out_ PKIRQL Irql
Definition: csq.h:179
USBPORT_COMMON_DEVICE_EXTENSION CommonExtension
Definition: usbport.h:291
ULONG NTAPI USBPORT_DbgPrint(IN PVOID MiniPortExtension, IN ULONG Level, IN PCH Format,...)
Definition: debug.c:20
VOID NTAPI USB2_InitController(IN PUSB2_HC_EXTENSION HcExtension)
Definition: usb2.c:2217
struct _USB2_HC_EXTENSION USB2_HC_EXTENSION
KSPIN_LOCK StateChangeSpinLock
Definition: usbport.h:224
NTSTATUS NTAPI USBPORT_HandleSubmitURB(IN PDEVICE_OBJECT PdoDevice, IN PIRP Irp, IN PURB Urb)
Definition: urb.c:791
VOID NTAPI USBPORT_DoIdleNotificationCallback(IN PVOID Context)
Definition: power.c:545
PUSB2_TT_EXTENSION TtExtension
Definition: usbport.h:208
PUSB_CONFIGURATION_DESCRIPTOR ConfigurationDescriptor
Definition: usbport.h:171
LIST_ENTRY DispatchLink
Definition: usbport.h:234
VOID NTAPI USBPORT_DoneTransfer(IN PUSBPORT_TRANSFER Transfer)
Definition: usbport.c:724
uint32_t ULONG_PTR
Definition: typedefs.h:63
VOID NTAPI USBPORT_DoSetPowerD0(IN PDEVICE_OBJECT FdoDevice)
Definition: power.c:104
KSPIN_LOCK FlushPendingTransferSpinLock
Definition: usbport.h:345
C_ASSERT(sizeof(USBPORT_DEVICE_EXTENSION)==0x500)
USHORT Reserved2
Definition: usbport.h:531
KSEMAPHORE ControllerSemaphore
Definition: usbport.h:297
struct _USB2_TT_ENDPOINT USB2_TT_ENDPOINT
struct _USBPORT_ISO_BLOCK * PUSBPORT_ISO_BLOCK
Definition: usbport.h:242
struct _USBPORT_RHDEVICE_EXTENSION * PUSBPORT_RHDEVICE_EXTENSION
UCHAR KIRQL
Definition: env_spec_w32.h:591
USBD_STATUS * PUSBD_STATUS
Definition: usbport.h:143
LIST_ENTRY EndpointList
Definition: usbport.h:556
USHORT ActualPeriod
Definition: usbport.h:518
VOID NTAPI USBPORT_InsertIdleIrp(IN PIO_CSQ Csq, IN PIRP Irp)
Definition: queue.c:20
_Inout_ PUSB_DEVICE_HANDLE OldDeviceHandle
Definition: hubbusif.h:161
_Must_inspect_result_ _In_ ULONG Flags
Definition: wsk.h:170
UCHAR StartFrame
Definition: usbport.h:522
struct _USBPORT_TRANSFER * ParentTransfer
Definition: usbport.h:263
KSPIN_LOCK MiniportSpinLock
Definition: usbport.h:309
KSPIN_LOCK EpStateChangeSpinLock
Definition: usbport.h:334
VOID NTAPI USBPORT_RemoveDeviceHandle(IN PDEVICE_OBJECT FdoDevice, IN PUSBPORT_DEVICE_HANDLE DeviceHandle)
Definition: device.c:784
NTSTATUS(* NTAPI)(IN PFILE_FULL_EA_INFORMATION EaBuffer, IN ULONG EaLength, OUT PULONG ErrorOffset)
Definition: IoEaTest.cpp:117
LIST_ENTRY BadRequestList
Definition: usbport.h:377
VOID NTAPI USBPORT_SplitTransfer(IN PDEVICE_OBJECT FdoDevice, IN PUSBPORT_ENDPOINT Endpoint, IN PUSBPORT_TRANSFER Transfer, IN PLIST_ENTRY List)
Definition: trfsplit.c:232
WORK_QUEUE_ITEM WqItem
Definition: usbport.h:443
PUSBPORT_IRP_TABLE PendingIrpTable
Definition: usbport.h:380
USB2_TT_ENDPOINT_PARAMS TtEndpointParams
Definition: usbport.h:512
VOID NTAPI USBPORT_BugCheck(IN PVOID MiniPortExtension)
Definition: debug.c:52
_Must_inspect_result_ typedef _Out_ PHIDP_CAPS Capabilities
Definition: hidclass.h:103
PDEVICE_OBJECT FdoDevice
Definition: usbport.h:205
unsigned int BOOL
Definition: ntddk_ex.h:94
LIST_ENTRY PendingTransferList
Definition: usbport.h:226
PUSBPORT_COMMON_BUFFER_HEADER HeaderBuffer
Definition: usbport.h:206
long LONG
Definition: pedump.c:60
VOID NTAPI MiniportCloseEndpoint(IN PDEVICE_OBJECT FdoDevice, IN PUSBPORT_ENDPOINT Endpoint)
Definition: endpoint.c:549
VOID NTAPI USBPORT_InsertIrpInTable(IN PUSBPORT_IRP_TABLE IrpTable, IN PIRP Irp)
Definition: queue.c:266
_In_ ULONG BufferLength
Definition: usbdlib.h:225
USB2_TT_ENDPOINT IsoEndpoint[USB2_FRAMES]
Definition: usbport.h:539
LIST_ENTRY TransferList
Definition: usbport.h:227
KIRQL EndpointOldIrql
Definition: usbport.h:215
USHORT MaxPacketSize
Definition: usbport.h:515
struct _USBPORT_IRP_TABLE * PUSBPORT_IRP_TABLE
struct _USBPORT_DEVICE_EXTENSION USBPORT_DEVICE_EXTENSION
VOID NTAPI USBPORT_ReleaseIdleLock(IN PIO_CSQ Csq, IN KIRQL Irql)
Definition: queue.c:107
VOID NTAPI USBPORT_DumpingTtEndpoint(IN PUSB2_TT_ENDPOINT TtEndpoint)
Definition: debug.c:301
NTSTATUS NTAPI USBPORT_RestoreDevice(IN PDEVICE_OBJECT FdoDevice, IN OUT PUSBPORT_DEVICE_HANDLE OldDeviceHandle, IN OUT PUSBPORT_DEVICE_HANDLE NewDeviceHandle)
Definition: device.c:1701
NTSTATUS NTAPI USBPORT_HandleSelectInterface(IN PDEVICE_OBJECT FdoDevice, IN PIRP Irp, IN PURB Urb)
Definition: device.c:1486
LIST_ENTRY InterfaceLink
Definition: usbport.h:177
CHAR * PCH
Definition: ntbasedef.h:398
DEVICE_CAPABILITIES Capabilities
Definition: usbport.h:363
PUSBPORT_IRP_TABLE ActiveIrpTable
Definition: usbport.h:381
ULONG NTAPI USBPORT_AssertFailure(PVOID MiniPortExtension, PVOID FailedAssertion, PVOID FileName, ULONG LineNumber, PCHAR Message)
Definition: debug.c:39
PUSB2_HC_EXTENSION Usb2Extension
Definition: usbport.h:389
unsigned char BOOLEAN
_Out_ _Inout_ POEM_STRING DestinationString
Definition: rtlfuncs.h:1869
PUSBPORT_MINIPORT_INTERFACE MiniPortInterface
Definition: usbport.h:306
union _USB2_TT_ENDPOINT_NUMS USB2_TT_ENDPOINT_NUMS
USBD_STATUS NTAPI USBPORT_InitializeIsoTransfer(IN PDEVICE_OBJECT FdoDevice, IN struct _URB_ISOCH_TRANSFER *Urb, IN PUSBPORT_TRANSFER Transfer)
PDEVICE_OBJECT RootHubPdo
Definition: usbport.h:293
struct _USBPORT_COMMON_DEVICE_EXTENSION USBPORT_COMMON_DEVICE_EXTENSION
struct _USB2_TT_ENDPOINT * PUSB2_TT_ENDPOINT
Definition: usbport.h:159
Definition: bufpool.h:45
VOID NTAPI USBPORT_DumpingIDs(IN PVOID Buffer)
Definition: debug.c:258
struct _USBPORT_PIPE_HANDLE USBPORT_PIPE_HANDLE
PUSBPORT_ENDPOINT Endpoint
Definition: usbport.h:423
PUSBPORT_CONFIGURATION_HANDLE ConfigHandle
Definition: usbport.h:193
ULONG NTAPI USBPORT_LogEntry(IN PVOID MiniPortExtension, IN ULONG DriverTag, IN ULONG EnumTag, IN ULONG P1, IN ULONG P2, IN ULONG P3)
Definition: debug.c:61
LIST_ENTRY EndpointList
Definition: usbport.h:331
VOID NTAPI USBPORT_WorkerRequestDpc(IN PRKDPC Dpc, IN PVOID DeferredContext, IN PVOID SystemArgument1, IN PVOID SystemArgument2)
Definition: usbport.c:701
SIZE_T PortTransferLength
Definition: usbport.h:250
enum _USB_DEVICE_SPEED USB_DEVICE_SPEED
USB_INTERFACE_DESCRIPTOR InterfaceDescriptor
Definition: usbport.h:180
PUSBPORT_ENDPOINT Endpoint
Definition: usbport.h:252
ULONG Bandwidth[USB2_FRAMES]
Definition: usbport.h:551
enum _DEVICE_POWER_STATE DEVICE_POWER_STATE
_In_opt_ PVOID _In_opt_ PVOID SystemArgument1
Definition: ketypes.h:675
PDEVICE_OBJECT RootHubPdo
Definition: usbport.h:548
LIST_ENTRY TransferLink
Definition: usbport.h:256
PUSB2_TT_ENDPOINT IsoEndpoint
Definition: usbport.h:527
PIRP NTAPI USBPORT_PeekNextIdleIrp(IN PIO_CSQ Csq, IN PIRP Irp, IN PVOID PeekContext)
Definition: queue.c:46
const KSDEVICE_DESCRIPTOR DeviceDescriptor
Definition: splitter.c:257
NTSTATUS NTAPI USBPORT_PdoInternalDeviceControl(IN PDEVICE_OBJECT FdoDevice, IN PIRP Irp)
Definition: ioctl.c:317
PUSBPORT_ENDPOINT Endpoint
Definition: usbport.h:510
_In_ LARGE_INTEGER _In_opt_ PKDPC Dpc
Definition: kefuncs.h:524
struct _USB2_TT_ENDPOINT * NextTtEndpoint
Definition: usbport.h:511
NTSTATUS NTAPI USBPORT_GetRegistryKeyValueFullInfo(IN PDEVICE_OBJECT FdoDevice, IN PDEVICE_OBJECT PdoDevice, IN BOOL UseDriverKey, IN PCWSTR SourceString, IN ULONG LengthStr, IN PVOID Buffer, IN ULONG NumberOfBytes)
Definition: usbport.c:296
KSPIN_LOCK DoneTransferSpinLock
Definition: usbport.h:342
NTSTATUS NTAPI USBPORT_IdleNotification(IN PDEVICE_OBJECT PdoDevice, IN PIRP Irp)
Definition: power.c:612
ULONG MaxHsBusAllocation
Definition: usbport.h:562
struct _USB2_FRAME_BUDGET USB2_FRAME_BUDGET
USBPORT_DEVICE_HANDLE DeviceHandle
Definition: usbport.h:421
LIST_ENTRY InterfaceHandleList
Definition: usbport.h:172
LIST_ENTRY List
Definition: psmgr.c:57
ASYNC_TIMER_CALLBACK * CallbackFunction
Definition: usbport.h:436
ULONG EndpointWorker
Definition: usbport.h:211
VOID NTAPI USBPORT_InvalidateControllerHandler(IN PDEVICE_OBJECT FdoDevice, IN ULONG Type)
Definition: usbport.c:635
BOOLEAN NTAPI USBPORT_StartTimer(IN PDEVICE_OBJECT FdoDevice, IN ULONG Time)
Definition: usbport.c:1653
struct _USBPORT_ENDPOINT USBPORT_ENDPOINT
USBPORT_RESOURCES UsbPortResources
Definition: usbport.h:307
ULONG MaxTime
Definition: usbport.h:537
Definition: xml2sdb.h:79
KSPIN_LOCK FlushTransferSpinLock
Definition: usbport.h:344
PVOID MiniportTransfer
Definition: usbport.h:249
struct _USBPORT_IRP_TABLE USBPORT_IRP_TABLE
KSPIN_LOCK EndpointClosedSpinLock
Definition: usbport.h:336
struct _USBPORT_ENDPOINT * PUSBPORT_ENDPOINT
Definition: usbport.h:154
USB2_TT_ENDPOINT IntEndpoint[USB2_FRAMES]
Definition: usbport.h:538
PUSBPORT_DEVICE_HANDLE DeviceHandle
Definition: usbport.h:207
RH_INIT_CALLBACK * PRH_INIT_CALLBACK
Definition: hubbusif.h:270
UCHAR StartMicroframe
Definition: usbport.h:523
BOOLEAN NTAPI USBPORT_QueueActiveUrbToEndpoint(IN PUSBPORT_ENDPOINT Endpoint, IN PURB Urb)
Definition: queue.c:988
struct _USBPORT_DEVICE_EXTENSION * PUSBPORT_DEVICE_EXTENSION
_In_ ULONG _In_ ULONG _In_ ULONG Length
Definition: ntddpcm.h:101
struct _USBPORT_RH_DESCRIPTORS * PUSBPORT_RH_DESCRIPTORS
VOID NTAPI USBPORT_HcWakeDpc(IN PRKDPC Dpc, IN PVOID DeferredContext, IN PVOID SystemArgument1, IN PVOID SystemArgument2)
Definition: power.c:52
LIST_ENTRY CloseLink
Definition: usbport.h:233
UCHAR Padded[2]
Definition: usbport.h:217
struct _USBPORT_IRP_TABLE * LinkNextTable
Definition: usbport.h:275
_In_ PKSERVICE_ROUTINE _In_opt_ PVOID ServiceContext
Definition: iofuncs.h:798
ULONG DelayTime
Definition: usbport.h:536
LIST_ENTRY EndpointClosedList
Definition: usbport.h:335
NTSTATUS NTAPI USBPORT_PdoQueryInterface(IN PDEVICE_OBJECT FdoDevice, IN PDEVICE_OBJECT PdoDevice, IN PIRP Irp)
Definition: iface.c:782
CHAR Message[80]
Definition: alive.c:5
VOID NTAPI USBPORT_FlushMapTransfers(IN PDEVICE_OBJECT FdoDevice)
Definition: usbport.c:2461
VOID NTAPI USBPORT_RootHubPowerAndChirpAllCcPorts(IN PDEVICE_OBJECT FdoDevice)
Definition: roothub.c:963
USHORT PreviosPeriod
Definition: usbport.h:516
VOID NTAPI USBPORT_CompleteCanceledBadRequest(IN PIO_CSQ Csq, IN PIRP Irp)
Definition: queue.c:246
USB_DEVICE_DESCRIPTOR DeviceDescriptor
Definition: usbport.h:409
unsigned char UCHAR
Definition: xmlstorage.h:181
VOID NTAPI USBPORT_AcquireBadRequestLock(IN PIO_CSQ Csq, IN PKIRQL Irql)
Definition: queue.c:214
NTSTATUS NTAPI USBPORT_PdoDeviceControl(PDEVICE_OBJECT PdoDevice, PIRP Irp)
struct _USB2_HC_EXTENSION * PUSB2_HC_EXTENSION
Definition: usbport.h:156
_Out_ _Inout_ POEM_STRING _In_ PCUNICODE_STRING SourceString
Definition: rtlfuncs.h:1869
VOID NTAPI USBPORT_MiniportInterrupts(IN PDEVICE_OBJECT FdoDevice, IN BOOLEAN IsEnable)
Definition: usbport.c:555
ULONG BusBandwidth
Definition: usbport.h:550
VOID NTAPI USBPORT_CompleteTransfer(IN PURB Urb, IN USBD_STATUS TransferStatus)
Definition: usbport.c:2176
LIST_ENTRY FlushControllerLink
Definition: usbport.h:236
Definition: ketypes.h:687
LONG USBD_STATUS
Definition: usb.h:165
struct _USBPORT_CONFIGURATION_HANDLE * PUSBPORT_CONFIGURATION_HANDLE
USHORT CalcBusTime
Definition: usbport.h:519
NTSTATUS NTAPI USBPORT_InitializeDevice(IN PUSBPORT_DEVICE_HANDLE DeviceHandle, IN PDEVICE_OBJECT FdoDevice)
Definition: device.c:1316
LIST_ENTRY PipeHandleList
Definition: usbport.h:192
KIRQL * PKIRQL
Definition: env_spec_w32.h:592
ULONG NTAPI USBPORT_CompleteIsoTransfer(IN PVOID MiniPortExtension, IN PVOID MiniPortEndpoint, IN PVOID TransferParameters, IN ULONG TransferLength)
Definition: iso.c:25
USB_DEVICE_SPEED DeviceSpeed
Definition: usbport.h:488
struct _USBPORT_CONFIGURATION_HANDLE USBPORT_CONFIGURATION_HANDLE
PUSB2_TT Tt
Definition: usbport.h:509
USB2_TT_ENDPOINT_NUMS Nums
Definition: usbport.h:513
struct _USB2_FRAME_BUDGET * PUSB2_FRAME_BUDGET
Definition: typedefs.h:117
NTSTATUS NTAPI USBPORT_USBDStatusToNtStatus(IN PURB Urb, IN USBD_STATUS USBDStatus)
Definition: usbport.c:485
LONG FlushPendingLock
Definition: usbport.h:219
VOID NTAPI USBPORT_QueueTransferUrb(IN PURB Urb)
Definition: queue.c:1085
struct _USBPORT_PIPE_HANDLE * PUSBPORT_PIPE_HANDLE
VOID NTAPI USBPORT_UpdateAllocatedBwTt(IN PUSB2_TT_EXTENSION TtExtension)
Definition: usb2.c:1768
USB_HUB_DESCRIPTOR Descriptor
Definition: usbport.h:413
PUSBPORT_COMMON_BUFFER_HEADER MiniPortCommonBuffer
Definition: usbport.h:308
_Outptr_ PUSB_DEVICE_HANDLE _In_ PUSB_DEVICE_HANDLE _In_ USHORT PortStatus
Definition: hubbusif.h:40
USB_ENDPOINT_DESCRIPTOR EndpointDescriptor
Definition: usbport.h:164
VOID NTAPI USBPORT_AddDeviceHandle(IN PDEVICE_OBJECT FdoDevice, IN PUSBPORT_DEVICE_HANDLE DeviceHandle)
Definition: device.c:769
PIRP NTAPI USBPORT_RemovePendingTransferIrp(IN PDEVICE_OBJECT FdoDevice, IN PIRP Irp)
Definition: queue.c:369
USBPORT_PIPE_HANDLE PipeHandle
Definition: usbport.h:189
PUSB2_TT_ENDPOINT AltEndpoint
Definition: usbport.h:529
* PDEVICE_CAPABILITIES
Definition: iotypes.h:928
VOID NTAPI USBPORT_FlushCancelList(IN PUSBPORT_ENDPOINT Endpoint)
Definition: queue.c:714
VOID NTAPI USBPORT_DumpingConfiguration(IN PUSB_CONFIGURATION_DESCRIPTOR ConfigDescriptor)
Definition: debug.c:106
USBPORT_ENDPOINT_PROPERTIES EndpointProperties
Definition: usbport.h:210
struct _USBPORT_TRANSFER * PUSBPORT_TRANSFER
VOID NTAPI USBPORT_AddPipeHandle(IN PUSBPORT_DEVICE_HANDLE DeviceHandle, IN PUSBPORT_PIPE_HANDLE PipeHandle)
Definition: endpoint.c:444
_In_opt_ PVOID _In_opt_ PVOID _In_opt_ PVOID SystemArgument2
Definition: ketypes.h:675
struct _USBPORT_DEVICE_HANDLE * PUSBPORT_DEVICE_HANDLE
VOID NTAPI USBPORT_DumpingEndpointProperties(IN PUSBPORT_ENDPOINT_PROPERTIES EndpointProperties)
Definition: debug.c:281
VOID NTAPI USBPORT_DumpingCapabilities(IN PDEVICE_CAPABILITIES Capabilities)
Definition: debug.c:171
BOOLEAN NTAPI USBPORT_EndpointHasQueuedTransfers(IN PDEVICE_OBJECT FdoDevice, IN PUSBPORT_ENDPOINT Endpoint, IN PULONG TransferCount)
Definition: endpoint.c:254
Definition: csq.h:222
IN PDEVICE_OBJECT DeviceObject
Definition: fatprocs.h:1560
SIZE_T FullTransferLength
Definition: usbport.h:251
ULONG_PTR SIZE_T
Definition: typedefs.h:78
VOID NTAPI USBPORT_InsertBadRequest(IN PIO_CSQ Csq, IN PIRP Irp)
Definition: queue.c:143
KIRQL EndpointStateOldIrql
Definition: usbport.h:216
KSPIN_LOCK WorkerThreadEventSpinLock
Definition: usbport.h:356
VOID NTAPI USBPORT_DpcHandler(IN PDEVICE_OBJECT FdoDevice)
Definition: usbport.c:864
DEVICE_POWER_STATE DevicePowerState
Definition: usbport.h:286
LIST_ENTRY PipeLink
Definition: usbport.h:167
VOID NTAPI USBPORT_DumpingSetupPacket(IN PUSB_DEFAULT_PIPE_SETUP_PACKET SetupPacket)
Definition: debug.c:213
struct _USBPORT_DEVICE_HANDLE USBPORT_DEVICE_HANDLE
PUSB2_TT_ENDPOINT RebalanceEndpoint[USB2_FRAMES - 2]
Definition: usbport.h:569
VOID NTAPI USBPORT_IsrDpc(IN PRKDPC Dpc, IN PVOID DeferredContext, IN PVOID SystemArgument1, IN PVOID SystemArgument2)
Definition: usbport.c:1031
NTSTATUS NTAPI USBPORT_GetSymbolicName(IN PDEVICE_OBJECT RootHubPdo, IN PUNICODE_STRING DestinationString)
Definition: ioctl.c:62
ACPI_BUFFER *RetBuffer ACPI_BUFFER *RetBuffer char ACPI_WALK_RESOURCE_CALLBACK void *Context ACPI_BUFFER *RetBuffer UINT16 ACPI_RESOURCE **ResourcePtr ACPI_GENERIC_ADDRESS *Reg UINT32 *ReturnValue UINT8 UINT8 *Slp_TypB ACPI_PHYSICAL_ADDRESS PhysicalAddress64 UINT32 UINT32 *TimeElapsed UINT32 LineNumber
Definition: acpixf.h:1206
KSPIN_LOCK TimerFlagsSpinLock
Definition: usbport.h:351
UNICODE_STRING SymbolicLinkName
Definition: usbport.h:284
ULONG NTAPI USBPORT_TestDebugBreak(IN PVOID MiniPortExtension)
Definition: debug.c:31
LIST_ENTRY RebalanceLink
Definition: usbport.h:239
Definition: usb.h:529
struct _USB2_TT USB2_TT
unsigned short USHORT
Definition: pedump.c:61
PIRP NTAPI USBPORT_PeekNextBadRequest(IN PIO_CSQ Csq, IN PIRP Irp, IN PVOID PeekContext)
Definition: queue.c:169
PDEVICE_OBJECT FdoDevice
Definition: usbport.h:419
ULONG KSPIN_LOCK
Definition: env_spec_w32.h:72
USBPORT_PIPE_HANDLE PipeHandle[1]
Definition: usbport.h:182
LIST_ENTRY StateChangeLink
Definition: usbport.h:223
NTSTATUS NTAPI USBPORT_RootHubCreateDevice(IN PDEVICE_OBJECT FdoDevice, IN PDEVICE_OBJECT PdoDevice)
Definition: roothub.c:747
unsigned int * PULONG
Definition: retypes.h:1
static HANDLE PipeHandle
Definition: dhcpcsvc.c:21
union _USB2_TT_ENDPOINT_PARAMS USB2_TT_ENDPOINT_PARAMS
VOID NTAPI USBPORT_AddUSB1Fdo(IN PDEVICE_OBJECT FdoDevice)
Definition: usbport.c:66
PDEVICE_OBJECT NTAPI USBPORT_FindUSB2Controller(IN PDEVICE_OBJECT FdoDevice)
Definition: usbport.c:27
struct _USBPORT_ASYNC_CALLBACK_DATA USBPORT_ASYNC_CALLBACK_DATA
ULONG NTAPI USBPORT_InvalidateRootHub(PVOID MiniPortExtension)
Definition: roothub.c:917
VOID NTAPI USBPORT_NukeAllEndpoints(IN PDEVICE_OBJECT FdoDevice)
Definition: endpoint.c:300
PHYSICAL_ADDRESS LogicalAddress
Definition: usbport.h:148
USB_INTERFACE_DESCRIPTOR InterfaceDescriptor
Definition: usbport.h:411
NTSTATUS NTAPI USBPORT_ReopenPipe(IN PDEVICE_OBJECT FdoDevice, IN PUSBPORT_ENDPOINT Endpoint)
Definition: endpoint.c:1165
struct _TIMER_WORK_QUEUE_ITEM TIMER_WORK_QUEUE_ITEM
LIST_ENTRY EpStateChangeList
Definition: usbport.h:333
LIST_ENTRY SplitTransfersList
Definition: usbport.h:265
_In_opt_ PIRP _In_opt_ PVOID PeekContext
Definition: csq.h:159
struct _USB2_REBALANCE * PUSB2_REBALANCE
#define USB2_FRAMES
Definition: usbport.h:451
KSEMAPHORE DeviceSemaphore
Definition: usbport.h:361
KSPIN_LOCK IdleIoCsqSpinLock
Definition: usbport.h:371
KSPIN_LOCK EndpointListSpinLock
Definition: usbport.h:332
PUSBPORT_ISO_BLOCK IsoBlockPtr
Definition: usbport.h:268
IO_CSQ Csq
Definition: csqrtns.c:46
PIRP NTAPI USBPORT_RemoveActiveTransferIrp(IN PDEVICE_OBJECT FdoDevice, IN PIRP Irp)
Definition: queue.c:357
VOID NTAPI USBPORT_FlushPendingTransfers(IN PUSBPORT_ENDPOINT Endpoint)
Definition: queue.c:785
NTSTATUS NTAPI USBPORT_FdoPnP(IN PDEVICE_OBJECT FdoDevice, IN PIRP Irp)
Definition: pnp.c:1110
USHORT DeviceAddress
Definition: usbport.h:554
_In_ PUSB_DEVICE_HANDLE _In_ ULONG TtCount
Definition: hubbusif.h:239
PKINTERRUPT InterruptObject
Definition: usbport.h:322
struct _USBPORT_RHDEVICE_EXTENSION USBPORT_RHDEVICE_EXTENSION
BOOLEAN NTAPI USBPORT_ValidatePipeHandle(IN PUSBPORT_DEVICE_HANDLE DeviceHandle, IN PUSBPORT_PIPE_HANDLE PipeHandle)
Definition: endpoint.c:469
#define OUT
Definition: typedefs.h:39
KSPIN_LOCK RootHubCallbackSpinLock
Definition: usbport.h:294
PIRP irp[0X200]
Definition: usbport.h:276
VOID NTAPI USBPORT_FlushAbortList(IN PUSBPORT_ENDPOINT Endpoint)
Definition: queue.c:605
_Must_inspect_result_ typedef _In_ PHYSICAL_ADDRESS _Inout_ PLARGE_INTEGER NumberOfBytes
Definition: iotypes.h:998
PDEVICE_RELATIONS NTAPI USBPORT_FindCompanionControllers(IN PDEVICE_OBJECT USB2FdoDevice, IN BOOLEAN IsObRefer, IN BOOLEAN IsFDOsReturned)
Definition: usbport.c:136
unsigned int ULONG
Definition: retypes.h:1
ULONG FrameNumber
Definition: usbport.h:212
LIST_ENTRY TtList
Definition: usbport.h:200
USHORT Reserved2
Definition: usbport.h:521
KSPIN_LOCK PowerWakeSpinLock
Definition: usbport.h:384
PUSBPORT_RH_DESCRIPTORS RootHubDescriptors
Definition: usbport.h:422
KSPIN_LOCK TransferSpinLock
Definition: usbport.h:264
KSPIN_LOCK MapTransferSpinLock
Definition: usbport.h:340
VOID NTAPI USBPORT_RemoveBadRequest(IN PIO_CSQ Csq, IN PIRP Irp)
Definition: queue.c:160
_Outptr_ PUSB_DEVICE_HANDLE * NewDeviceHandle
Definition: hubbusif.h:40
USB_DEVICE_DESCRIPTOR DeviceDescriptor
Definition: usbport.h:195
VOID NTAPI USBPORT_FlushController(IN PDEVICE_OBJECT FdoDevice)
Definition: queue.c:1259
ULONG TimeCS[USB2_FRAMES][USB2_MICROFRAMES]
Definition: usbport.h:542
USB_ENDPOINT_DESCRIPTOR EndPointDescriptor
Definition: usbport.h:412
PUSBPORT_ENDPOINT Endpoint
Definition: usbport.h:166
VOID NTAPI USB2_InitTT(IN PUSB2_HC_EXTENSION HcExtension, IN PUSB2_TT Tt)
Definition: usb2.c:2160
USBD_STATUS USBDStatus
Definition: usbport.h:257
struct _USBPORT_RH_DESCRIPTORS USBPORT_RH_DESCRIPTORS
VOID NTAPI USBPORT_FlushClosedEndpointList(IN PDEVICE_OBJECT FdoDevice)
Definition: endpoint.c:1281
ULONG CompletedTransferLen
Definition: usbport.h:258
PUSB2_TT_EXTENSION TtExtension
Definition: usbport.h:199
PVOID MapRegisterBase
Definition: usbport.h:260
USBPORT_COMMON_DEVICE_EXTENSION CommonExtension
Definition: usbport.h:417
LIST_ENTRY TtLink
Definition: usbport.h:238
LIST_ENTRY CancelList
Definition: usbport.h:228
VOID NTAPI USBPORT_AddUSB2Fdo(IN PDEVICE_OBJECT FdoDevice)
Definition: usbport.c:82
KSPIN_LOCK EndpointSpinLock
Definition: usbport.h:214
VOID NTAPI USBPORT_CancelSplitTransfer(IN PUSBPORT_TRANSFER SplitTransfer)
Definition: trfsplit.c:314
struct _USB2_TT_EXTENSION USB2_TT_EXTENSION
KSPIN_LOCK USBPORT_SpinLock
Definition: usbport.c:22
struct _USBPORT_INTERFACE_HANDLE * PUSBPORT_INTERFACE_HANDLE
_In_ NDIS_STATUS _In_ ULONG _In_ USHORT _In_opt_ PVOID _In_ ULONG DataSize
Definition: ndis.h:4751
BUS_INTERFACE_STANDARD BusInterface
Definition: usbport.h:311
VOID NTAPI USBPORT_RemoveIdleIrp(IN PIO_CSQ Csq, IN PIRP Irp)
Definition: queue.c:37
static PLARGE_INTEGER Time
Definition: time.c:105
LIST_ENTRY USBPORT_MiniPortDrivers
Definition: usbport.c:18
VOID NTAPI USBPORT_ClosePipe(IN PUSBPORT_DEVICE_HANDLE DeviceHandle, IN PDEVICE_OBJECT FdoDevice, IN PUSBPORT_PIPE_HANDLE PipeHandle)
Definition: endpoint.c:590
NTSTATUS NTAPI USBPORT_FdoInternalDeviceControl(IN PDEVICE_OBJECT FdoDevice, IN PIRP Irp)
Definition: ioctl.c:454
VOID NTAPI USBPORT_FindUrbInIrpTable(IN PUSBPORT_IRP_TABLE IrpTable, IN PURB Urb, IN PIRP Irp)
Definition: queue.c:381
KSPIN_LOCK MiniportInterruptsSpinLock
Definition: usbport.h:326
NTSTATUS NTAPI USBPORT_GetUsbDescriptor(IN PUSBPORT_DEVICE_HANDLE DeviceHandle, IN PDEVICE_OBJECT FdoDevice, IN UCHAR Type, IN PUCHAR ConfigDesc, IN PULONG ConfigDescSize)
Definition: device.c:1425
PUSB2_TT_ENDPOINT IntEndpoint
Definition: usbport.h:528
VOID NTAPI USBPORT_RootHubEndpointWorker(PUSBPORT_ENDPOINT Endpoint)
VOID NTAPI USBPORT_CompletePdoWaitWake(IN PDEVICE_OBJECT FdoDevice)
Definition: power.c:15
NTSTATUS NTAPI USBPORT_PdoPower(IN PDEVICE_OBJECT PdoDevice, IN PIRP Irp)
Definition: power.c:322
_In_opt_ PVOID DeferredContext
Definition: ketypes.h:675
struct _USBPORT_INTERFACE_HANDLE USBPORT_INTERFACE_HANDLE