Efi_usb_hc_protocol.getroothubportstatus(), Getroothubportstatus(), Func – Intel Extensible Firmware Interface User Manual
Page 566

Extensible Firmware Interface Specification
14-26 12/01/02
Version
1.10
EFI_USB_HC_PROTOCOL.GetRootHubPortStatus()
Summary
Retrieves the current status of a USB root hub port.
Prototype
typedef
EFI_STATUS
(EFIAPI *EFI_USB_HC_PROTOCOL_GET_ROOTHUB_PORT_STATUS) (
IN EFI_USB_HC_PROTOCOL
*This,
IN UINT8
PortNumber,
OUT EFI_USB_PORT_STATUS
*PortStatus
);
Parameters
This
A pointer to the
instance. Type
EFI_USB_HC_PROTOCOL
is defined in Section 14.1.
PortNumber
Specifies the root hub port from which the status is to be retrieved.
This value is zero based. For example, if a root hub has two ports,
then the first port is numbered 0, and the second port is
numbered 1.
PortStatus
A pointer to the current port status bits and port status change bits.
The type
is defined in “Related
Definitions” below.
Related Definitions
typedef struct{
UINT16
PortStatus;
UINT16
PortChangeStatus;
} EFI_USB_PORT_STATUS;
//**************************************************
// EFI_USB_PORT_STATUS.PortStatus bit definition
//**************************************************
#define USB_PORT_STAT_CONNECTION 0x0001
#define USB_PORT_STAT_ENABLE 0x0002
#define USB_PORT_STAT_SUSPEND 0x0004
#define USB_PORT_STAT_OVERCURRENT 0x0008
#define USB_PORT_STAT_RESET 0x0010
#define USB_PORT_STAT_POWER 0x0100
#define USB_PORT_STAT_LOW_SPEED 0x0200