794{
801
803
807
809 Urb->UrbHeader.UsbdFlags = 0;
810
812
814 {
817
818 DPRINT1(
"USBPORT_HandleSubmitURB: Unknown URB function - %x !!!\n",
820
822 }
823
825 {
826 DPRINT1(
"USBPORT_HandleSubmitURB: Bad Request\n");
827
829
833
835 }
836
838
840 {
843 }
844
847 {
848 DPRINT1(
"USBPORT_HandleSubmitURB: Not valid device handle\n");
849
853
855 }
856
858
859 DPRINT_URB(
"USBPORT_HandleSubmitURB: Function - 0x%02X, DeviceHandle - %p\n",
861 Urb->UrbHeader.UsbdDeviceHandle);
862
864 {
866 DPRINT1(
"USBPORT_HandleSubmitURB: URB_FUNCTION_ISOCH_TRANSFER UNIMPLEMENTED. FIXME. \n");
867 break;
868
872
874 {
875 DPRINT1(
"USBPORT_HandleSubmitURB: Not valid URB\n");
876 break;
877 }
878
880 break;
881
891
893 {
894 DPRINT1(
"USBPORT_HandleSubmitURB: Not valid URB\n");
895 break;
896 }
897
899 break;
900
908
910 {
911 DPRINT1(
"USBPORT_HandleSubmitURB: Not valid URB\n");
912 break;
913 }
914
916 break;
917
918 case URB_FUNCTION_GET_MS_FEATURE_DESCRIPTOR:
919 DPRINT1(
"USBPORT_HandleSubmitURB: URB_FUNCTION_GET_MS_FEATURE_DESCRIPTOR (0x2A) NOT_SUPPORTED\n");
922
928
930 {
931 DPRINT1(
"USBPORT_HandleSubmitURB: Not valid URB\n");
932 break;
933 }
934
936 break;
937
941 Urb);
942 break;
943
947 Urb);
948 break;
949
952
954 {
955 DPRINT1(
"USBPORT_HandleSubmitURB: Not valid URB\n");
956 break;
957 }
958
960 break;
961
963 DPRINT1(
"USBPORT_HandleSubmitURB: URB_FUNCTION_GET_INTERFACE (0x27) NOT_SUPPORTED\n");
966
970 Urb);
971 break;
972
973 case URB_FUNCTION_SYNC_RESET_PIPE:
976 Urb);
977 break;
978
979 case URB_FUNCTION_SYNC_CLEAR_STALL:
982 Urb);
983 break;
984
988 Urb);
989 break;
990
999
1001 {
1002 DPRINT1(
"USBPORT_HandleSubmitURB: Not valid URB\n");
1003 break;
1004 }
1005
1007 break;
1008
1012 Urb);
1013 break;
1014
1016 DPRINT1(
"USBPORT_HandleSubmitURB: URB_FUNCTION_TAKE_FRAME_LENGTH_CONTROL (0x03) NOT_SUPPORTED\n");
1018
1020 DPRINT1(
"USBPORT_HandleSubmitURB: URB_FUNCTION_RELEASE_FRAME_LENGTH_CONTROL (0x04) NOT_SUPPORTED\n");
1022
1024 DPRINT1(
"USBPORT_HandleSubmitURB: URB_FUNCTION_GET_FRAME_LENGTH (0x05) NOT_SUPPORTED\n");
1026
1028 DPRINT1(
"USBPORT_HandleSubmitURB: URB_FUNCTION_SET_FRAME_LENGTH (0x06) NOT_SUPPORTED\n");
1030
1031 default:
1032 DPRINT1(
"USBPORT_HandleSubmitURB: Unknown URB Function - %x\n",
1034
1035
1036
1037
1038
1039
1040
1041 break;
1042 }
1043
1045 {
1047 }
1048
1050 {
1052
1053 Transfer = Urb->UrbControlTransfer.hca.Reserved8[0];
1054 Urb->UrbControlTransfer.hca.Reserved8[0] =
NULL;
1055 Urb->UrbHeader.UsbdFlags |= ~USBD_FLAG_ALLOCATED_TRANSFER;
1057 }
1058
1060
1063
1065}
#define InterlockedIncrement
#define InterlockedDecrement
_In_ CDROM_SCAN_FOR_SPECIAL_INFO _In_ PCDROM_SCAN_FOR_SPECIAL_HANDLER Function
NTKERNELAPI VOID NTAPI IoCsqInsertIrp(_Inout_ PIO_CSQ Csq, _Inout_ PIRP Irp, _Out_opt_ PIO_CSQ_IRP_CONTEXT Context)
Insert an IRP into the CSQ.
#define STATUS_NOT_IMPLEMENTED
#define NT_SUCCESS(StatCode)
BOOLEAN NTAPI USBPORT_ValidateDeviceHandle(IN PDEVICE_OBJECT FdoDevice, IN PUSBPORT_DEVICE_HANDLE DeviceHandle)
NTSTATUS NTAPI USBPORT_HandleSelectConfiguration(IN PDEVICE_OBJECT FdoDevice, IN PIRP Irp, IN PURB Urb)
NTSTATUS NTAPI USBPORT_HandleSelectInterface(IN PDEVICE_OBJECT FdoDevice, IN PIRP Irp, IN PURB Urb)
#define ExFreePoolWithTag(_P, _T)
#define IoCompleteRequest
NTSTATUS NTAPI USBPORT_HandleVendorOrClass(IN PIRP Irp, IN PURB Urb)
NTSTATUS NTAPI USBPORT_HandleGetCurrentFrame(IN PDEVICE_OBJECT FdoDevice, IN PIRP Irp, IN PURB Urb)
NTSTATUS NTAPI USBPORT_ClearStall(IN PDEVICE_OBJECT FdoDevice, IN PIRP Irp, IN PURB Urb)
NTSTATUS NTAPI USBPORT_ResetPipe(IN PDEVICE_OBJECT FdoDevice, IN PIRP Irp, IN PURB Urb)
NTSTATUS NTAPI USBPORT_AbortPipe(IN PDEVICE_OBJECT FdoDevice, IN PIRP Irp, IN PURB Urb)
NTSTATUS NTAPI USBPORT_SyncResetPipeAndClearStall(IN PDEVICE_OBJECT FdoDevice, IN PIRP Irp, IN PURB Urb)
NTSTATUS NTAPI USBPORT_HandleGetStatus(IN PIRP Irp, IN PURB Urb)
NTSTATUS NTAPI USBPORT_HandleGetSetDescriptor(IN PIRP Irp, IN PURB Urb)
NTSTATUS NTAPI USBPORT_ValidateURB(IN PDEVICE_OBJECT FdoDevice, IN PIRP Irp, IN PURB Urb, IN BOOLEAN IsControlTransfer, IN BOOLEAN IsNullTransfer)
NTSTATUS NTAPI USBPORT_HandleDataTransfers(IN PURB Urb)
NTSTATUS NTAPI USBPORT_HandleGetConfiguration(IN PURB Urb)
NTSTATUS NTAPI USBPORT_HandleSetOrClearFeature(IN PURB Urb)
#define URB_FUNCTION_CLASS_INTERFACE
#define URB_FUNCTION_GET_FRAME_LENGTH
#define USBD_STATUS_DEVICE_GONE
#define URB_FUNCTION_SELECT_INTERFACE
#define URB_FUNCTION_ABORT_PIPE
#define URB_FUNCTION_VENDOR_ENDPOINT
#define URB_FUNCTION_CONTROL_TRANSFER
#define USBD_STATUS_NOT_SUPPORTED
#define URB_FUNCTION_VENDOR_DEVICE
#define URB_FUNCTION_GET_CURRENT_FRAME_NUMBER
#define URB_FUNCTION_SELECT_CONFIGURATION
#define URB_FUNCTION_RELEASE_FRAME_LENGTH_CONTROL
#define URB_FUNCTION_CLASS_DEVICE
#define URB_FUNCTION_SET_FRAME_LENGTH
#define URB_FUNCTION_CLASS_OTHER
#define URB_FUNCTION_TAKE_FRAME_LENGTH_CONTROL
#define URB_FUNCTION_BULK_OR_INTERRUPT_TRANSFER
#define URB_FUNCTION_SYNC_RESET_PIPE_AND_CLEAR_STALL
#define URB_FUNCTION_GET_CONFIGURATION
#define URB_FUNCTION_CLASS_ENDPOINT
#define USBD_STATUS_INVALID_URB_FUNCTION
#define URB_FUNCTION_VENDOR_INTERFACE
#define URB_FUNCTION_VENDOR_OTHER
#define URB_FUNCTION_GET_INTERFACE
#define URB_FUNCTION_ISOCH_TRANSFER
#define USBD_FLAG_ALLOCATED_TRANSFER
#define USBPORT_TMFLAG_RH_SUSPENDED