Source code of Windows XP (NT5)
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

90 lines
2.3 KiB

  1. /*++
  2. Copyright (c) Microsoft Corporation. All rights reserved.
  3. Module Name:
  4. USBKERN.H
  5. Abstract:
  6. This file contains KERNEL Mode IOCTLS supported by
  7. the HCD (PORT) drivers ROOT HUB PDO.
  8. Environment:
  9. kernel mode
  10. Revision History:
  11. --*/
  12. #ifndef __USBKERN_H__
  13. #define __USBKERN_H__
  14. #include "usbiodef.h"
  15. /*
  16. the following IOCTLS are supported by the ROOT HUB PDO
  17. */
  18. /* IOCTL_INTERNAL_USB_GET_HUB_COUNT
  19. This IOCTL is used internally by the hub driver, it returns the
  20. number of hubs between the device and the root hub.
  21. The HUB Driver passed this irp to its PDO.
  22. As the IRP is passed from HUB to HUB each hub FDO increments
  23. the count. When the irp reaches the root hub PDO it is completed
  24. Parameters.Others.Argument1 =
  25. pointer to be count of hubs in chain;
  26. */
  27. #define IOCTL_INTERNAL_USB_GET_HUB_COUNT USB_KERNEL_CTL(USB_GET_HUB_COUNT)
  28. /* IOCTL_INTERNAL_USB_GET_ROOTHUB_PDO
  29. This IOCTL is used internally by the hub driver. This API will
  30. return the PhysicalDeviceObject of the root hub enumerated by the
  31. controller.
  32. Parameters.Others.Argument1 =
  33. pointer to be filled in with PDO for the root hub;
  34. Parameters.Others.Argument2 =
  35. pointer to be filled in with FDO of the USB Host Controller;
  36. */
  37. #define IOCTL_INTERNAL_USB_GET_ROOTHUB_PDO USB_KERNEL_CTL(USB_GET_ROOTHUB_PDO)
  38. /* IOCTL_INTERNAL_USB_GET_DEVICE_ADDRESS
  39. This IOCTL returns the device address associated with a particular PDO.
  40. (INPUT)
  41. Parameters.Others.Argument1 =
  42. pointer to device handle
  43. (OUTPUT)
  44. Parameters.Others.Argument2 =
  45. pointer to device address
  46. The api travels all the way down the stack where it is handled by the
  47. port driver
  48. */
  49. #define IOCTL_INTERNAL_USB_GET_DEVICE_HANDLE CTL_CODE(FILE_DEVICE_USB, \
  50. USB_GET_DEVICE_HANDLE, \
  51. METHOD_NEITHER, \
  52. FILE_ANY_ACCESS)
  53. #endif //__USBKERN_H__