]> git.proxmox.com Git - mirror_edk2.git/blobdiff - MdePkg/Include/Protocol/UsbFunctionIo.h
MdePkg: Apply uncrustify changes
[mirror_edk2.git] / MdePkg / Include / Protocol / UsbFunctionIo.h
index 1c003db38731bdd87eba7e424cdc765f8ab8efa9..e360b604808e5676ce0431313afa8c06fe0275a6 100644 (file)
@@ -29,9 +29,9 @@
       0x32d2963a, 0xfe5d, 0x4f30, {0xb6, 0x33, 0x6e, 0x5d, 0xc5, 0x58, 0x3, 0xcc} \\r
     }\r
 \r
-typedef struct _EFI_USBFN_IO_PROTOCOL  EFI_USBFN_IO_PROTOCOL;\r
+typedef struct _EFI_USBFN_IO_PROTOCOL EFI_USBFN_IO_PROTOCOL;\r
 \r
-#define EFI_USBFN_IO_PROTOCOL_REVISION 0x00010001\r
+#define EFI_USBFN_IO_PROTOCOL_REVISION  0x00010001\r
 \r
 typedef enum _EFI_USBFN_PORT_TYPE {\r
   EfiUsbUnknownPort = 0,\r
@@ -42,25 +42,25 @@ typedef enum _EFI_USBFN_PORT_TYPE {
 } EFI_USBFN_PORT_TYPE;\r
 \r
 typedef struct {\r
-  EFI_USB_INTERFACE_DESCRIPTOR         *InterfaceDescriptor;\r
-  EFI_USB_ENDPOINT_DESCRIPTOR          **EndpointDescriptorTable;\r
+  EFI_USB_INTERFACE_DESCRIPTOR    *InterfaceDescriptor;\r
+  EFI_USB_ENDPOINT_DESCRIPTOR     **EndpointDescriptorTable;\r
 } EFI_USB_INTERFACE_INFO;\r
 \r
 typedef struct {\r
-  EFI_USB_CONFIG_DESCRIPTOR            *ConfigDescriptor;\r
-  EFI_USB_INTERFACE_INFO               **InterfaceInfoTable;\r
+  EFI_USB_CONFIG_DESCRIPTOR    *ConfigDescriptor;\r
+  EFI_USB_INTERFACE_INFO       **InterfaceInfoTable;\r
 } EFI_USB_CONFIG_INFO;\r
 \r
 typedef struct {\r
-  EFI_USB_DEVICE_DESCRIPTOR            *DeviceDescriptor;\r
-  EFI_USB_CONFIG_INFO                  **ConfigInfoTable;\r
+  EFI_USB_DEVICE_DESCRIPTOR    *DeviceDescriptor;\r
+  EFI_USB_CONFIG_INFO          **ConfigInfoTable;\r
 } EFI_USB_DEVICE_INFO;\r
 \r
 typedef enum _EFI_USB_ENDPOINT_TYPE {\r
   UsbEndpointControl = 0x00,\r
-  //UsbEndpointIsochronous = 0x01,\r
+  // UsbEndpointIsochronous = 0x01,\r
   UsbEndpointBulk = 0x02,\r
-  //UsbEndpointInterrupt = 0x03\r
+  // UsbEndpointInterrupt = 0x03\r
 } EFI_USB_ENDPOINT_TYPE;\r
 \r
 typedef enum _EFI_USBFN_DEVICE_INFO_ID {\r
@@ -139,11 +139,11 @@ typedef enum _EFI_USBFN_TRANSFER_STATUS {
 } EFI_USBFN_TRANSFER_STATUS;\r
 \r
 typedef struct _EFI_USBFN_TRANSFER_RESULT {\r
-  UINTN                         BytesTransferred;\r
-  EFI_USBFN_TRANSFER_STATUS     TransferStatus;\r
-  UINT8                         EndpointIndex;\r
-  EFI_USBFN_ENDPOINT_DIRECTION  Direction;\r
-  VOID                          *Buffer;\r
+  UINTN                           BytesTransferred;\r
+  EFI_USBFN_TRANSFER_STATUS       TransferStatus;\r
+  UINT8                           EndpointIndex;\r
+  EFI_USBFN_ENDPOINT_DIRECTION    Direction;\r
+  VOID                            *Buffer;\r
 } EFI_USBFN_TRANSFER_RESULT;\r
 \r
 typedef enum _EFI_USB_BUS_SPEED {\r
@@ -184,9 +184,9 @@ typedef enum _EFI_USBFN_POLICY_TYPE {
 **/\r
 typedef\r
 EFI_STATUS\r
-(EFIAPI *EFI_USBFN_IO_DETECT_PORT) (\r
+(EFIAPI *EFI_USBFN_IO_DETECT_PORT)(\r
   IN     EFI_USBFN_IO_PROTOCOL         *This,\r
-     OUT EFI_USBFN_PORT_TYPE           *PortType\r
+  OUT EFI_USBFN_PORT_TYPE           *PortType\r
   );\r
 \r
 /**\r
@@ -214,9 +214,9 @@ EFI_STATUS
 **/\r
 typedef\r
 EFI_STATUS\r
-(EFIAPI *EFI_USBFN_IO_CONFIGURE_ENABLE_ENDPOINTS) (\r
+(EFIAPI *EFI_USBFN_IO_CONFIGURE_ENABLE_ENDPOINTS)(\r
   IN     EFI_USBFN_IO_PROTOCOL         *This,\r
-     OUT EFI_USB_DEVICE_INFO           *DeviceInfo\r
+  OUT EFI_USB_DEVICE_INFO           *DeviceInfo\r
   );\r
 \r
 /**\r
@@ -244,11 +244,11 @@ EFI_STATUS
 **/\r
 typedef\r
 EFI_STATUS\r
-(EFIAPI *EFI_USBFN_IO_GET_ENDPOINT_MAXPACKET_SIZE) (\r
+(EFIAPI *EFI_USBFN_IO_GET_ENDPOINT_MAXPACKET_SIZE)(\r
   IN     EFI_USBFN_IO_PROTOCOL         *This,\r
   IN     EFI_USB_ENDPOINT_TYPE         EndpointType,\r
   IN     EFI_USB_BUS_SPEED             BusSpeed,\r
-     OUT UINT16                        *MaxPacketSize\r
+  OUT UINT16                        *MaxPacketSize\r
   );\r
 \r
 /**\r
@@ -281,12 +281,12 @@ EFI_STATUS
 **/\r
 typedef\r
 EFI_STATUS\r
-(EFIAPI *EFI_USBFN_IO_GET_DEVICE_INFO) (\r
+(EFIAPI *EFI_USBFN_IO_GET_DEVICE_INFO)(\r
   IN     EFI_USBFN_IO_PROTOCOL         *This,\r
   IN     EFI_USBFN_DEVICE_INFO_ID      Id,\r
   IN OUT UINTN                         *BufferSize,\r
-     OUT VOID                          *Buffer OPTIONAL\r
-);\r
+  OUT VOID                          *Buffer OPTIONAL\r
+  );\r
 \r
 /**\r
   Returns the vendor-id and product-id of the device.\r
@@ -302,11 +302,11 @@ EFI_STATUS
 **/\r
 typedef\r
 EFI_STATUS\r
-(EFIAPI *EFI_USBFN_IO_GET_VENDOR_ID_PRODUCT_ID) (\r
+(EFIAPI *EFI_USBFN_IO_GET_VENDOR_ID_PRODUCT_ID)(\r
   IN     EFI_USBFN_IO_PROTOCOL         *This,\r
-     OUT UINT16                        *Vid,\r
-     OUT UINT16                        *Pid\r
-);\r
+  OUT UINT16                        *Vid,\r
+  OUT UINT16                        *Pid\r
+  );\r
 \r
 /**\r
   Aborts the transfer on the specified endpoint.\r
@@ -328,11 +328,11 @@ EFI_STATUS
 **/\r
 typedef\r
 EFI_STATUS\r
-(EFIAPI *EFI_USBFN_IO_ABORT_TRANSFER) (\r
+(EFIAPI *EFI_USBFN_IO_ABORT_TRANSFER)(\r
   IN  EFI_USBFN_IO_PROTOCOL            *This,\r
   IN  UINT8                            EndpointIndex,\r
   IN  EFI_USBFN_ENDPOINT_DIRECTION     Direction\r
-);\r
+  );\r
 \r
 /**\r
   Returns the stall state on the specified endpoint.\r
@@ -355,12 +355,12 @@ EFI_STATUS
 **/\r
 typedef\r
 EFI_STATUS\r
-(EFIAPI *EFI_USBFN_IO_GET_ENDPOINT_STALL_STATE) (\r
+(EFIAPI *EFI_USBFN_IO_GET_ENDPOINT_STALL_STATE)(\r
   IN     EFI_USBFN_IO_PROTOCOL         *This,\r
   IN     UINT8                         EndpointIndex,\r
   IN     EFI_USBFN_ENDPOINT_DIRECTION  Direction,\r
   IN OUT BOOLEAN                       *State\r
-);\r
+  );\r
 \r
 /**\r
   Sets or clears the stall state on the specified endpoint.\r
@@ -384,12 +384,12 @@ EFI_STATUS
 **/\r
 typedef\r
 EFI_STATUS\r
-(EFIAPI *EFI_USBFN_IO_SET_ENDPOINT_STALL_STATE) (\r
+(EFIAPI *EFI_USBFN_IO_SET_ENDPOINT_STALL_STATE)(\r
   IN     EFI_USBFN_IO_PROTOCOL         *This,\r
   IN     UINT8                         EndpointIndex,\r
   IN     EFI_USBFN_ENDPOINT_DIRECTION  Direction,\r
   IN OUT BOOLEAN                       *State\r
-);\r
+  );\r
 \r
 /**\r
   This function is called repeatedly to get information on USB bus states,\r
@@ -419,12 +419,12 @@ EFI_STATUS
 **/\r
 typedef\r
 EFI_STATUS\r
-(EFIAPI *EFI_USBFN_IO_EVENTHANDLER) (\r
+(EFIAPI *EFI_USBFN_IO_EVENTHANDLER)(\r
   IN     EFI_USBFN_IO_PROTOCOL         *This,\r
-     OUT EFI_USBFN_MESSAGE             *Message,\r
+  OUT EFI_USBFN_MESSAGE             *Message,\r
   IN OUT UINTN                         *PayloadSize,\r
-     OUT EFI_USBFN_MESSAGE_PAYLOAD     *Payload\r
-);\r
+  OUT EFI_USBFN_MESSAGE_PAYLOAD     *Payload\r
+  );\r
 \r
 /**\r
   This function handles transferring data to or from the host on the specified\r
@@ -467,13 +467,13 @@ EFI_STATUS
 **/\r
 typedef\r
 EFI_STATUS\r
-(EFIAPI *EFI_USBFN_IO_TRANSFER) (\r
+(EFIAPI *EFI_USBFN_IO_TRANSFER)(\r
   IN     EFI_USBFN_IO_PROTOCOL         *This,\r
   IN     UINT8                         EndpointIndex,\r
   IN     EFI_USBFN_ENDPOINT_DIRECTION  Direction,\r
   IN OUT UINTN                         *BufferSize,\r
   IN OUT VOID                          *Buffer\r
-);\r
+  );\r
 \r
 /**\r
   Returns the maximum supported transfer size.\r
@@ -493,9 +493,9 @@ EFI_STATUS
 **/\r
 typedef\r
 EFI_STATUS\r
-(EFIAPI *EFI_USBFN_IO_GET_MAXTRANSFER_SIZE) (\r
+(EFIAPI *EFI_USBFN_IO_GET_MAXTRANSFER_SIZE)(\r
   IN     EFI_USBFN_IO_PROTOCOL         *This,\r
-     OUT UINTN                         *MaxTransferSize\r
+  OUT UINTN                         *MaxTransferSize\r
   );\r
 \r
 /**\r
@@ -521,10 +521,10 @@ EFI_STATUS
 **/\r
 typedef\r
 EFI_STATUS\r
-(EFIAPI *EFI_USBFN_IO_ALLOCATE_TRANSFER_BUFFER) (\r
+(EFIAPI *EFI_USBFN_IO_ALLOCATE_TRANSFER_BUFFER)(\r
   IN     EFI_USBFN_IO_PROTOCOL         *This,\r
   IN     UINTN                         Size,\r
-     OUT VOID                          **Buffer\r
+  OUT VOID                          **Buffer\r
   );\r
 \r
 /**\r
@@ -544,7 +544,7 @@ EFI_STATUS
 **/\r
 typedef\r
 EFI_STATUS\r
-(EFIAPI *EFI_USBFN_IO_FREE_TRANSFER_BUFFER) (\r
+(EFIAPI *EFI_USBFN_IO_FREE_TRANSFER_BUFFER)(\r
   IN  EFI_USBFN_IO_PROTOCOL         *This,\r
   IN  VOID                          *Buffer\r
   );\r
@@ -563,7 +563,7 @@ EFI_STATUS
 **/\r
 typedef\r
 EFI_STATUS\r
-(EFIAPI *EFI_USBFN_IO_START_CONTROLLER) (\r
+(EFIAPI *EFI_USBFN_IO_START_CONTROLLER)(\r
   IN  EFI_USBFN_IO_PROTOCOL         *This\r
   );\r
 \r
@@ -579,7 +579,7 @@ EFI_STATUS
 **/\r
 typedef\r
 EFI_STATUS\r
-(EFIAPI *EFI_USBFN_IO_STOP_CONTROLLER) (\r
+(EFIAPI *EFI_USBFN_IO_STOP_CONTROLLER)(\r
   IN  EFI_USBFN_IO_PROTOCOL         *This\r
   );\r
 \r
@@ -608,7 +608,7 @@ EFI_STATUS
 **/\r
 typedef\r
 EFI_STATUS\r
-(EFIAPI *EFI_USBFN_IO_SET_ENDPOINT_POLICY) (\r
+(EFIAPI *EFI_USBFN_IO_SET_ENDPOINT_POLICY)(\r
   IN  EFI_USBFN_IO_PROTOCOL         *This,\r
   IN  UINT8                         EndpointIndex,\r
   IN  EFI_USBFN_ENDPOINT_DIRECTION  Direction,\r
@@ -644,7 +644,7 @@ EFI_STATUS
 **/\r
 typedef\r
 EFI_STATUS\r
-(EFIAPI *EFI_USBFN_IO_GET_ENDPOINT_POLICY) (\r
+(EFIAPI *EFI_USBFN_IO_GET_ENDPOINT_POLICY)(\r
   IN     EFI_USBFN_IO_PROTOCOL         *This,\r
   IN     UINT8                         EndpointIndex,\r
   IN     EFI_USBFN_ENDPOINT_DIRECTION  Direction,\r
@@ -658,27 +658,26 @@ EFI_STATUS
 /// controller management for a USB Function port.\r
 ///\r
 struct _EFI_USBFN_IO_PROTOCOL {\r
-  UINT32                                    Revision;\r
-  EFI_USBFN_IO_DETECT_PORT                  DetectPort;\r
-  EFI_USBFN_IO_CONFIGURE_ENABLE_ENDPOINTS   ConfigureEnableEndpoints;\r
-  EFI_USBFN_IO_GET_ENDPOINT_MAXPACKET_SIZE  GetEndpointMaxPacketSize;\r
-  EFI_USBFN_IO_GET_DEVICE_INFO              GetDeviceInfo;\r
-  EFI_USBFN_IO_GET_VENDOR_ID_PRODUCT_ID     GetVendorIdProductId;\r
-  EFI_USBFN_IO_ABORT_TRANSFER               AbortTransfer;\r
-  EFI_USBFN_IO_GET_ENDPOINT_STALL_STATE     GetEndpointStallState;\r
-  EFI_USBFN_IO_SET_ENDPOINT_STALL_STATE     SetEndpointStallState;\r
-  EFI_USBFN_IO_EVENTHANDLER                 EventHandler;\r
-  EFI_USBFN_IO_TRANSFER                     Transfer;\r
-  EFI_USBFN_IO_GET_MAXTRANSFER_SIZE         GetMaxTransferSize;\r
-  EFI_USBFN_IO_ALLOCATE_TRANSFER_BUFFER     AllocateTransferBuffer;\r
-  EFI_USBFN_IO_FREE_TRANSFER_BUFFER         FreeTransferBuffer;\r
-  EFI_USBFN_IO_START_CONTROLLER             StartController;\r
-  EFI_USBFN_IO_STOP_CONTROLLER              StopController;\r
-  EFI_USBFN_IO_SET_ENDPOINT_POLICY          SetEndpointPolicy;\r
-  EFI_USBFN_IO_GET_ENDPOINT_POLICY          GetEndpointPolicy;\r
+  UINT32                                      Revision;\r
+  EFI_USBFN_IO_DETECT_PORT                    DetectPort;\r
+  EFI_USBFN_IO_CONFIGURE_ENABLE_ENDPOINTS     ConfigureEnableEndpoints;\r
+  EFI_USBFN_IO_GET_ENDPOINT_MAXPACKET_SIZE    GetEndpointMaxPacketSize;\r
+  EFI_USBFN_IO_GET_DEVICE_INFO                GetDeviceInfo;\r
+  EFI_USBFN_IO_GET_VENDOR_ID_PRODUCT_ID       GetVendorIdProductId;\r
+  EFI_USBFN_IO_ABORT_TRANSFER                 AbortTransfer;\r
+  EFI_USBFN_IO_GET_ENDPOINT_STALL_STATE       GetEndpointStallState;\r
+  EFI_USBFN_IO_SET_ENDPOINT_STALL_STATE       SetEndpointStallState;\r
+  EFI_USBFN_IO_EVENTHANDLER                   EventHandler;\r
+  EFI_USBFN_IO_TRANSFER                       Transfer;\r
+  EFI_USBFN_IO_GET_MAXTRANSFER_SIZE           GetMaxTransferSize;\r
+  EFI_USBFN_IO_ALLOCATE_TRANSFER_BUFFER       AllocateTransferBuffer;\r
+  EFI_USBFN_IO_FREE_TRANSFER_BUFFER           FreeTransferBuffer;\r
+  EFI_USBFN_IO_START_CONTROLLER               StartController;\r
+  EFI_USBFN_IO_STOP_CONTROLLER                StopController;\r
+  EFI_USBFN_IO_SET_ENDPOINT_POLICY            SetEndpointPolicy;\r
+  EFI_USBFN_IO_GET_ENDPOINT_POLICY            GetEndpointPolicy;\r
 };\r
 \r
-extern EFI_GUID gEfiUsbFunctionIoProtocolGuid;\r
+extern EFI_GUID  gEfiUsbFunctionIoProtocolGuid;\r
 \r
 #endif\r
-\r