]> git.proxmox.com Git - mirror_edk2.git/blobdiff - MdePkg/Include/Protocol/Usb2HostController.h
Add comments for most of enum data type.
[mirror_edk2.git] / MdePkg / Include / Protocol / Usb2HostController.h
index 84c40a01dc4284f43ecd3d9b1479df1bb338a93d..6687e323aaae0f515a8e153b863d1a6a583e4476 100644 (file)
@@ -33,13 +33,13 @@ typedef struct _EFI_USB2_HC_PROTOCOL EFI_USB2_HC_PROTOCOL;
 \r
 \r
 typedef struct {\r
-  UINT16          PortStatus;\r
-  UINT16          PortChangeStatus;\r
+  UINT16          PortStatus;        /// Contains current port status bitmap.\r
+  UINT16          PortChangeStatus;  /// Contains current port status change bitmap.\r
 } EFI_USB_PORT_STATUS;\r
 \r
-//\r
-// Constant value for Port Status & Port Change Status\r
-//\r
+///\r
+/// EFI_USB_PORT_STATUS.PortStatus bit definition \r
+///\r
 #define USB_PORT_STAT_CONNECTION    0x0001\r
 #define USB_PORT_STAT_ENABLE        0x0002\r
 #define USB_PORT_STAT_SUSPEND       0x0004\r
@@ -50,6 +50,9 @@ typedef struct {
 #define USB_PORT_STAT_HIGH_SPEED    0x0400\r
 #define USB_PORT_STAT_OWNER         0x0800\r
 \r
+///\r
+/// EFI_USB_PORT_STATUS.PortChangeStatus bit definition \r
+///\r
 #define USB_PORT_STAT_C_CONNECTION  0x0001\r
 #define USB_PORT_STAT_C_ENABLE      0x0002\r
 #define USB_PORT_STAT_C_SUSPEND     0x0004\r
@@ -57,9 +60,11 @@ typedef struct {
 #define USB_PORT_STAT_C_RESET       0x0010\r
 \r
 \r
-//\r
-// Usb port features\r
-//\r
+///\r
+/// Usb port features value\r
+/// Each value indicates its bit index in the port status and status change bitmaps, \r
+/// if combines these two bitmaps into a 32-bit bitmap.\r
+///\r
 typedef enum {\r
   EfiUsbPortEnable            = 1,\r
   EfiUsbPortSuspend           = 2,\r
@@ -73,14 +78,13 @@ typedef enum {
   EfiUsbPortResetChange       = 20\r
 } EFI_USB_PORT_FEATURE;\r
 \r
-\r
-#define EFI_USB_SPEED_FULL      0x0000  // 12 Mb/s, USB 1.1 OHCI and UHCI HC.\r
-#define EFI_USB_SPEED_LOW       0x0001  // 1 Mb/s, USB 1.1 OHCI and UHCI HC.\r
-#define EFI_USB_SPEED_HIGH      0x0002  // 480 Mb/s, USB 2.0 EHCI HC.\r
+#define EFI_USB_SPEED_FULL      0x0000  /// 12 Mb/s, USB 1.1 OHCI and UHCI HC.\r
+#define EFI_USB_SPEED_LOW       0x0001  /// 1 Mb/s, USB 1.1 OHCI and UHCI HC.\r
+#define EFI_USB_SPEED_HIGH      0x0002  /// 480 Mb/s, USB 2.0 EHCI HC.\r
 \r
 typedef struct {\r
-  UINT8      TranslatorHubAddress;\r
-  UINT8      TranslatorPortNumber;\r
+  UINT8      TranslatorHubAddress; /// device address\r
+  UINT8      TranslatorPortNumber; /// the port number of the hub that device is connected to.\r
 } EFI_USB2_HC_TRANSACTION_TRANSLATOR;\r
 \r
 //\r