iPXE
UsbIo.h
Go to the documentation of this file.
1 /** @file
2  EFI Usb I/O Protocol as defined in UEFI specification.
3  This protocol is used by code, typically drivers, running in the EFI
4  boot services environment to access USB devices like USB keyboards,
5  mice and mass storage devices. In particular, functions for managing devices
6  on USB buses are defined here.
7 
8  Copyright (c) 2006 - 2018, Intel Corporation. All rights reserved.<BR>
9  SPDX-License-Identifier: BSD-2-Clause-Patent
10 
11 **/
12 
13 #ifndef __USB_IO_H__
14 #define __USB_IO_H__
15 
16 FILE_LICENCE ( BSD2_PATENT );
17 
19 
20 //
21 // Global ID for the USB I/O Protocol
22 //
23 #define EFI_USB_IO_PROTOCOL_GUID \
24  { \
25  0x2B2F68D6, 0x0CD2, 0x44cf, {0x8E, 0x8B, 0xBB, 0xA2, 0x0B, 0x1B, 0x5B, 0x75 } \
26  }
27 
29 
30 //
31 // Related Definition for EFI USB I/O protocol
32 //
33 
34 //
35 // USB standard descriptors and reqeust
36 //
42 
43 ///
44 /// USB data transfer direction
45 ///
46 typedef enum {
51 
52 //
53 // USB Transfer Results
54 //
55 #define EFI_USB_NOERROR 0x00
56 #define EFI_USB_ERR_NOTEXECUTE 0x01
57 #define EFI_USB_ERR_STALL 0x02
58 #define EFI_USB_ERR_BUFFER 0x04
59 #define EFI_USB_ERR_BABBLE 0x08
60 #define EFI_USB_ERR_NAK 0x10
61 #define EFI_USB_ERR_CRC 0x20
62 #define EFI_USB_ERR_TIMEOUT 0x40
63 #define EFI_USB_ERR_BITSTUFF 0x80
64 #define EFI_USB_ERR_SYSTEM 0x100
65 
66 /**
67  Async USB transfer callback routine.
68 
69  @param Data Data received or sent via the USB Asynchronous Transfer, if the
70  transfer completed successfully.
71  @param DataLength The length of Data received or sent via the Asynchronous
72  Transfer, if transfer successfully completes.
73  @param Context Data passed from UsbAsyncInterruptTransfer() request.
74  @param Status Indicates the result of the asynchronous transfer.
75 
76  @retval EFI_SUCCESS The asynchronous USB transfer request has been successfully executed.
77  @retval EFI_DEVICE_ERROR The asynchronous USB transfer request failed.
78 
79 **/
80 typedef
83  IN VOID *Data,
85  IN VOID *Context,
87  );
88 
89 //
90 // Prototype for EFI USB I/O protocol
91 //
92 
93 /**
94  This function is used to manage a USB device with a control transfer pipe. A control transfer is
95  typically used to perform device initialization and configuration.
96 
97  @param This A pointer to the EFI_USB_IO_PROTOCOL instance.
98  @param Request A pointer to the USB device request that will be sent to the USB
99  device.
100  @param Direction Indicates the data direction.
101  @param Timeout Indicating the transfer should be completed within this time frame.
102  The units are in milliseconds.
103  @param Data A pointer to the buffer of data that will be transmitted to USB
104  device or received from USB device.
105  @param DataLength The size, in bytes, of the data buffer specified by Data.
106  @param Status A pointer to the result of the USB transfer.
107 
108  @retval EFI_SUCCESS The control transfer has been successfully executed.
109  @retval EFI_DEVICE_ERROR The transfer failed. The transfer status is returned in Status.
110  @retval EFI_INVALID_PARAMETER One or more parameters are invalid.
111  @retval EFI_OUT_OF_RESOURCES The request could not be completed due to a lack of resources.
112  @retval EFI_TIMEOUT The control transfer fails due to timeout.
113 
114 **/
115 typedef
118  IN EFI_USB_IO_PROTOCOL *This,
119  IN EFI_USB_DEVICE_REQUEST *Request,
120  IN EFI_USB_DATA_DIRECTION Direction,
121  IN UINT32 Timeout,
122  IN OUT VOID *Data OPTIONAL,
124  OUT UINT32 *Status
125  );
126 
127 /**
128  This function is used to manage a USB device with the bulk transfer pipe. Bulk Transfers are
129  typically used to transfer large amounts of data to/from USB devices.
130 
131  @param This A pointer to the EFI_USB_IO_PROTOCOL instance.
132  @param DeviceEndpoint The destination USB device endpoint to which the
133  device request is being sent. DeviceEndpoint must
134  be between 0x01 and 0x0F or between 0x81 and 0x8F,
135  otherwise EFI_INVALID_PARAMETER is returned. If
136  the endpoint is not a BULK endpoint, EFI_INVALID_PARAMETER
137  is returned. The MSB of this parameter indicates
138  the endpoint direction. The number "1" stands for
139  an IN endpoint, and "0" stands for an OUT endpoint.
140  @param Data A pointer to the buffer of data that will be transmitted to USB
141  device or received from USB device.
142  @param DataLength The size, in bytes, of the data buffer specified by Data.
143  On input, the size, in bytes, of the data buffer specified by Data.
144  On output, the number of bytes that were actually transferred.
145  @param Timeout Indicating the transfer should be completed within this time frame.
146  The units are in milliseconds. If Timeout is 0, then the
147  caller must wait for the function to be completed until
148  EFI_SUCCESS or EFI_DEVICE_ERROR is returned.
149  @param Status This parameter indicates the USB transfer status.
150 
151  @retval EFI_SUCCESS The bulk transfer has been successfully executed.
152  @retval EFI_DEVICE_ERROR The transfer failed. The transfer status is returned in Status.
153  @retval EFI_INVALID_PARAMETER One or more parameters are invalid.
154  @retval EFI_OUT_OF_RESOURCES The request could not be submitted due to a lack of resources.
155  @retval EFI_TIMEOUT The control transfer fails due to timeout.
156 
157 **/
158 typedef
161  IN EFI_USB_IO_PROTOCOL *This,
162  IN UINT8 DeviceEndpoint,
163  IN OUT VOID *Data,
165  IN UINTN Timeout,
166  OUT UINT32 *Status
167  );
168 
169 /**
170  This function is used to manage a USB device with an interrupt transfer pipe. An Asynchronous
171  Interrupt Transfer is typically used to query a device's status at a fixed rate. For example,
172  keyboard, mouse, and hub devices use this type of transfer to query their interrupt endpoints at
173  a fixed rate.
174 
175  @param This A pointer to the EFI_USB_IO_PROTOCOL instance.
176  @param DeviceEndpoint The destination USB device endpoint to which the
177  device request is being sent. DeviceEndpoint must
178  be between 0x01 and 0x0F or between 0x81 and 0x8F,
179  otherwise EFI_INVALID_PARAMETER is returned. If
180  the endpoint is not a BULK endpoint, EFI_INVALID_PARAMETER
181  is returned. The MSB of this parameter indicates
182  the endpoint direction. The number "1" stands for
183  an IN endpoint, and "0" stands for an OUT endpoint.
184  @param IsNewTransfer If TRUE, a new transfer will be submitted to USB controller. If
185  FALSE, the interrupt transfer is deleted from the device's interrupt
186  transfer queue.
187  @param PollingInterval Indicates the periodic rate, in milliseconds, that the transfer is to be
188  executed.This parameter is required when IsNewTransfer is TRUE. The
189  value must be between 1 to 255, otherwise EFI_INVALID_PARAMETER is returned.
190  The units are in milliseconds.
191  @param DataLength Specifies the length, in bytes, of the data to be received from the
192  USB device. This parameter is only required when IsNewTransfer is TRUE.
193  @param InterruptCallback The Callback function. This function is called if the asynchronous
194  interrupt transfer is completed. This parameter is required
195  when IsNewTransfer is TRUE.
196  @param Context Data passed to the InterruptCallback function. This is an optional
197  parameter and may be NULL.
198 
199  @retval EFI_SUCCESS The asynchronous USB transfer request transfer has been successfully executed.
200  @retval EFI_DEVICE_ERROR The asynchronous USB transfer request failed.
201 
202 **/
203 typedef
206  IN EFI_USB_IO_PROTOCOL *This,
207  IN UINT8 DeviceEndpoint,
208  IN BOOLEAN IsNewTransfer,
209  IN UINTN PollingInterval OPTIONAL,
211  IN EFI_ASYNC_USB_TRANSFER_CALLBACK InterruptCallBack OPTIONAL,
212  IN VOID *Context OPTIONAL
213  );
214 
215 /**
216  This function is used to manage a USB device with an interrupt transfer pipe.
217 
218  @param This A pointer to the EFI_USB_IO_PROTOCOL instance.
219  @param DeviceEndpoint The destination USB device endpoint to which the
220  device request is being sent. DeviceEndpoint must
221  be between 0x01 and 0x0F or between 0x81 and 0x8F,
222  otherwise EFI_INVALID_PARAMETER is returned. If
223  the endpoint is not a BULK endpoint, EFI_INVALID_PARAMETER
224  is returned. The MSB of this parameter indicates
225  the endpoint direction. The number "1" stands for
226  an IN endpoint, and "0" stands for an OUT endpoint.
227  @param Data A pointer to the buffer of data that will be transmitted to USB
228  device or received from USB device.
229  @param DataLength On input, then size, in bytes, of the buffer Data. On output, the
230  amount of data actually transferred.
231  @param Timeout The time out, in seconds, for this transfer. If Timeout is 0,
232  then the caller must wait for the function to be completed
233  until EFI_SUCCESS or EFI_DEVICE_ERROR is returned. If the
234  transfer is not completed in this time frame, then EFI_TIMEOUT is returned.
235  @param Status This parameter indicates the USB transfer status.
236 
237  @retval EFI_SUCCESS The sync interrupt transfer has been successfully executed.
238  @retval EFI_INVALID_PARAMETER One or more parameters are invalid.
239  @retval EFI_DEVICE_ERROR The sync interrupt transfer request failed.
240  @retval EFI_OUT_OF_RESOURCES The request could not be submitted due to a lack of resources.
241  @retval EFI_TIMEOUT The transfer fails due to timeout.
242 **/
243 typedef
246  IN EFI_USB_IO_PROTOCOL *This,
247  IN UINT8 DeviceEndpoint,
248  IN OUT VOID *Data,
250  IN UINTN Timeout,
251  OUT UINT32 *Status
252  );
253 
254 /**
255  This function is used to manage a USB device with an isochronous transfer pipe. An Isochronous
256  transfer is typically used to transfer streaming data.
257 
258  @param This A pointer to the EFI_USB_IO_PROTOCOL instance.
259  @param DeviceEndpoint The destination USB device endpoint to which the
260  device request is being sent. DeviceEndpoint must
261  be between 0x01 and 0x0F or between 0x81 and 0x8F,
262  otherwise EFI_INVALID_PARAMETER is returned. If
263  the endpoint is not a BULK endpoint, EFI_INVALID_PARAMETER
264  is returned. The MSB of this parameter indicates
265  the endpoint direction. The number "1" stands for
266  an IN endpoint, and "0" stands for an OUT endpoint.
267  @param Data A pointer to the buffer of data that will be transmitted to USB
268  device or received from USB device.
269  @param DataLength The size, in bytes, of the data buffer specified by Data.
270  @param Status This parameter indicates the USB transfer status.
271 
272  @retval EFI_SUCCESS The isochronous transfer has been successfully executed.
273  @retval EFI_INVALID_PARAMETER The parameter DeviceEndpoint is not valid.
274  @retval EFI_DEVICE_ERROR The transfer failed due to the reason other than timeout, The error status
275  is returned in Status.
276  @retval EFI_OUT_OF_RESOURCES The request could not be submitted due to a lack of resources.
277  @retval EFI_TIMEOUT The transfer fails due to timeout.
278 **/
279 typedef
282  IN EFI_USB_IO_PROTOCOL *This,
283  IN UINT8 DeviceEndpoint,
284  IN OUT VOID *Data,
286  OUT UINT32 *Status
287  );
288 
289 /**
290  This function is used to manage a USB device with an isochronous transfer pipe. An Isochronous
291  transfer is typically used to transfer streaming data.
292 
293  @param This A pointer to the EFI_USB_IO_PROTOCOL instance.
294  @param DeviceEndpoint The destination USB device endpoint to which the
295  device request is being sent. DeviceEndpoint must
296  be between 0x01 and 0x0F or between 0x81 and 0x8F,
297  otherwise EFI_INVALID_PARAMETER is returned. If
298  the endpoint is not a BULK endpoint, EFI_INVALID_PARAMETER
299  is returned. The MSB of this parameter indicates
300  the endpoint direction. The number "1" stands for
301  an IN endpoint, and "0" stands for an OUT endpoint.
302  @param Data A pointer to the buffer of data that will be transmitted to USB
303  device or received from USB device.
304  @param DataLength The size, in bytes, of the data buffer specified by Data.
305  This is an optional parameter and may be NULL.
306  @param IsochronousCallback The IsochronousCallback() function.This function is
307  called if the requested isochronous transfer is completed.
308  @param Context Data passed to the IsochronousCallback() function.
309 
310  @retval EFI_SUCCESS The asynchronous isochronous transfer has been successfully submitted
311  to the system.
312  @retval EFI_INVALID_PARAMETER The parameter DeviceEndpoint is not valid.
313  @retval EFI_OUT_OF_RESOURCES The request could not be submitted due to a lack of resources.
314 
315 **/
316 typedef
319  IN EFI_USB_IO_PROTOCOL *This,
320  IN UINT8 DeviceEndpoint,
321  IN OUT VOID *Data,
323  IN EFI_ASYNC_USB_TRANSFER_CALLBACK IsochronousCallBack,
324  IN VOID *Context OPTIONAL
325  );
326 
327 /**
328  Resets and reconfigures the USB controller. This function will work for all USB devices except
329  USB Hub Controllers.
330 
331  @param This A pointer to the EFI_USB_IO_PROTOCOL instance.
332 
333  @retval EFI_SUCCESS The USB controller was reset.
334  @retval EFI_INVALID_PARAMETER If the controller specified by This is a USB hub.
335  @retval EFI_DEVICE_ERROR An error occurred during the reconfiguration process.
336 
337 **/
338 typedef
341  IN EFI_USB_IO_PROTOCOL *This
342  );
343 
344 /**
345  Retrieves the USB Device Descriptor.
346 
347  @param This A pointer to the EFI_USB_IO_PROTOCOL instance.
348  @param DeviceDescriptor A pointer to the caller allocated USB Device Descriptor.
349 
350  @retval EFI_SUCCESS The device descriptor was retrieved successfully.
351  @retval EFI_INVALID_PARAMETER DeviceDescriptor is NULL.
352  @retval EFI_NOT_FOUND The device descriptor was not found. The device may not be configured.
353 
354 **/
355 typedef
358  IN EFI_USB_IO_PROTOCOL *This,
359  OUT EFI_USB_DEVICE_DESCRIPTOR *DeviceDescriptor
360  );
361 
362 /**
363  Retrieves the USB Device Descriptor.
364 
365  @param This A pointer to the EFI_USB_IO_PROTOCOL instance.
366  @param ConfigurationDescriptor A pointer to the caller allocated USB Active Configuration
367  Descriptor.
368  @retval EFI_SUCCESS The active configuration descriptor was retrieved successfully.
369  @retval EFI_INVALID_PARAMETER ConfigurationDescriptor is NULL.
370  @retval EFI_NOT_FOUND An active configuration descriptor cannot be found. The device may not
371  be configured.
372 
373 **/
374 typedef
377  IN EFI_USB_IO_PROTOCOL *This,
378  OUT EFI_USB_CONFIG_DESCRIPTOR *ConfigurationDescriptor
379  );
380 
381 /**
382  Retrieves the Interface Descriptor for a USB Device Controller. As stated earlier, an interface
383  within a USB device is equivalently to a USB Controller within the current configuration.
384 
385  @param This A pointer to the EFI_USB_IO_PROTOCOL instance.
386  @param InterfaceDescriptor A pointer to the caller allocated USB Interface Descriptor within
387  the configuration setting.
388  @retval EFI_SUCCESS The interface descriptor retrieved successfully.
389  @retval EFI_INVALID_PARAMETER InterfaceDescriptor is NULL.
390  @retval EFI_NOT_FOUND The interface descriptor cannot be found. The device may not be
391  correctly configured.
392 
393 **/
394 typedef
397  IN EFI_USB_IO_PROTOCOL *This,
398  OUT EFI_USB_INTERFACE_DESCRIPTOR *InterfaceDescriptor
399  );
400 
401 /**
402  Retrieves an Endpoint Descriptor within a USB Controller.
403 
404  @param This A pointer to the EFI_USB_IO_PROTOCOL instance.
405  @param EndpointIndex Indicates which endpoint descriptor to retrieve.
406  @param EndpointDescriptor A pointer to the caller allocated USB Endpoint Descriptor of
407  a USB controller.
408 
409  @retval EFI_SUCCESS The endpoint descriptor was retrieved successfully.
410  @retval EFI_INVALID_PARAMETER One or more parameters are invalid.
411  @retval EFI_NOT_FOUND The endpoint descriptor cannot be found. The device may not be
412  correctly configured.
413 
414 **/
415 typedef
418  IN EFI_USB_IO_PROTOCOL *This,
419  IN UINT8 EndpointIndex,
420  OUT EFI_USB_ENDPOINT_DESCRIPTOR *EndpointDescriptor
421  );
422 
423 /**
424  Retrieves a string stored in a USB Device.
425 
426  @param This A pointer to the EFI_USB_IO_PROTOCOL instance.
427  @param LangID The Language ID for the string being retrieved.
428  @param StringID The ID of the string being retrieved.
429  @param String A pointer to a buffer allocated by this function with
430  AllocatePool() to store the string.If this function
431  returns EFI_SUCCESS, it stores the string the caller
432  wants to get. The caller should release the string
433  buffer with FreePool() after the string is not used any more.
434 
435  @retval EFI_SUCCESS The string was retrieved successfully.
436  @retval EFI_NOT_FOUND The string specified by LangID and StringID was not found.
437  @retval EFI_OUT_OF_RESOURCES There are not enough resources to allocate the return buffer String.
438 
439 **/
440 typedef
443  IN EFI_USB_IO_PROTOCOL *This,
444  IN UINT16 LangID,
445  IN UINT8 StringID,
446  OUT CHAR16 **String
447  );
448 
449 /**
450  Retrieves all the language ID codes that the USB device supports.
451 
452  @param This A pointer to the EFI_USB_IO_PROTOCOL instance.
453  @param LangIDTable Language ID for the string the caller wants to get.
454  This is a 16-bit ID defined by Microsoft. This
455  buffer pointer is allocated and maintained by
456  the USB Bus Driver, the caller should not modify
457  its contents.
458  @param TableSize The size, in bytes, of the table LangIDTable.
459 
460  @retval EFI_SUCCESS The support languages were retrieved successfully.
461 
462 **/
463 typedef
466  IN EFI_USB_IO_PROTOCOL *This,
467  OUT UINT16 **LangIDTable,
468  OUT UINT16 *TableSize
469  );
470 
471 ///
472 /// The EFI_USB_IO_PROTOCOL provides four basic transfers types described
473 /// in the USB 1.1 Specification. These include control transfer, interrupt
474 /// transfer, bulk transfer and isochronous transfer. The EFI_USB_IO_PROTOCOL
475 /// also provides some basic USB device/controller management and configuration
476 /// interfaces. A USB device driver uses the services of this protocol to manage USB devices.
477 ///
479  //
480  // IO transfer
481  //
488 
489  //
490  // Common device request
491  //
498 
499  //
500  // Reset controller's parent port
501  //
503 };
504 
506 
507 #endif
#define OPTIONAL
Passing the datum to the function is optional, and a NULL is passed if the value is not supplied.
Definition: Base.h:292
EFI_STATUS(EFIAPI * EFI_USB_IO_PORT_RESET)(IN EFI_USB_IO_PROTOCOL *This)
Resets and reconfigures the USB controller.
Definition: UsbIo.h:340
EFI_USB_IO_PORT_RESET UsbPortReset
Definition: UsbIo.h:502
EFI_USB_IO_ASYNC_ISOCHRONOUS_TRANSFER UsbAsyncIsochronousTransfer
Definition: UsbIo.h:487
USB_ENDPOINT_DESCRIPTOR EFI_USB_ENDPOINT_DESCRIPTOR
Definition: UsbIo.h:41
USB_DEVICE_DESCRIPTOR EFI_USB_DEVICE_DESCRIPTOR
Definition: UsbIo.h:38
128 bit buffer containing a unique identifier value.
Definition: Base.h:215
EFI_STATUS(EFIAPI * EFI_USB_IO_ISOCHRONOUS_TRANSFER)(IN EFI_USB_IO_PROTOCOL *This, IN UINT8 DeviceEndpoint, IN OUT VOID *Data, IN UINTN DataLength, OUT UINT32 *Status)
This function is used to manage a USB device with an isochronous transfer pipe.
Definition: UsbIo.h:281
PXENV_STATUS_t Status
PXE status code.
Definition: pxe_api.h:57
unsigned char BOOLEAN
EFI_USB_IO_ASYNC_INTERRUPT_TRANSFER UsbAsyncInterruptTransfer
Definition: UsbIo.h:484
EFI_USB_IO_GET_ENDPOINT_DESCRIPTOR UsbGetEndpointDescriptor
Definition: UsbIo.h:495
Standard Interface Descriptor USB 2.0 spec, Section 9.6.5.
Definition: Usb.h:140
unsigned int UINT32
Definition: ProcessorBind.h:98
Support for USB 2.0 standard.
The EFI_USB_IO_PROTOCOL provides four basic transfers types described in the USB 1....
Definition: UsbIo.h:478
unsigned short CHAR16
EFI_STATUS(EFIAPI * EFI_USB_IO_GET_CONFIG_DESCRIPTOR)(IN EFI_USB_IO_PROTOCOL *This, OUT EFI_USB_CONFIG_DESCRIPTOR *ConfigurationDescriptor)
Retrieves the USB Device Descriptor.
Definition: UsbIo.h:376
USB_INTERFACE_DESCRIPTOR EFI_USB_INTERFACE_DESCRIPTOR
Definition: UsbIo.h:40
EFI_USB_DATA_DIRECTION
USB data transfer direction.
Definition: UsbIo.h:46
EFI_STATUS(EFIAPI * EFI_USB_IO_GET_SUPPORTED_LANGUAGE)(IN EFI_USB_IO_PROTOCOL *This, OUT UINT16 **LangIDTable, OUT UINT16 *TableSize)
Retrieves all the language ID codes that the USB device supports.
Definition: UsbIo.h:465
unsigned char UINT8
EFI_STATUS(EFIAPI * EFI_USB_IO_SYNC_INTERRUPT_TRANSFER)(IN EFI_USB_IO_PROTOCOL *This, IN UINT8 DeviceEndpoint, IN OUT VOID *Data, IN OUT UINTN *DataLength, IN UINTN Timeout, OUT UINT32 *Status)
This function is used to manage a USB device with an interrupt transfer pipe.
Definition: UsbIo.h:245
EFI_STATUS(EFIAPI * EFI_USB_IO_CONTROL_TRANSFER)(IN EFI_USB_IO_PROTOCOL *This, IN EFI_USB_DEVICE_REQUEST *Request, IN EFI_USB_DATA_DIRECTION Direction, IN UINT32 Timeout, IN OUT VOID *Data OPTIONAL, IN UINTN DataLength OPTIONAL, OUT UINT32 *Status)
This function is used to manage a USB device with a control transfer pipe.
Definition: UsbIo.h:117
EFI_STATUS(EFIAPI * EFI_USB_IO_GET_INTERFACE_DESCRIPTOR)(IN EFI_USB_IO_PROTOCOL *This, OUT EFI_USB_INTERFACE_DESCRIPTOR *InterfaceDescriptor)
Retrieves the Interface Descriptor for a USB Device Controller.
Definition: UsbIo.h:396
FILE_LICENCE(BSD2_PATENT)
#define OUT
Definition: mlx_utils.h:29
Format of Setup Data for USB Device Requests USB 2.0 spec, Section 9.3.
Definition: Usb.h:92
EFI_USB_IO_ISOCHRONOUS_TRANSFER UsbIsochronousTransfer
Definition: UsbIo.h:486
EFI_STATUS(EFIAPI * EFI_USB_IO_ASYNC_INTERRUPT_TRANSFER)(IN EFI_USB_IO_PROTOCOL *This, IN UINT8 DeviceEndpoint, IN BOOLEAN IsNewTransfer, IN UINTN PollingInterval OPTIONAL, IN UINTN DataLength OPTIONAL, IN EFI_ASYNC_USB_TRANSFER_CALLBACK InterruptCallBack OPTIONAL, IN VOID *Context OPTIONAL)
This function is used to manage a USB device with an interrupt transfer pipe.
Definition: UsbIo.h:205
EFI_GUID gEfiUsbIoProtocolGuid
unsigned short UINT16
EFI_USB_IO_SYNC_INTERRUPT_TRANSFER UsbSyncInterruptTransfer
Definition: UsbIo.h:485
EFI_STATUS(EFIAPI * EFI_USB_IO_GET_DEVICE_DESCRIPTOR)(IN EFI_USB_IO_PROTOCOL *This, OUT EFI_USB_DEVICE_DESCRIPTOR *DeviceDescriptor)
Retrieves the USB Device Descriptor.
Definition: UsbIo.h:357
EFI_STATUS(EFIAPI * EFI_USB_IO_GET_STRING_DESCRIPTOR)(IN EFI_USB_IO_PROTOCOL *This, IN UINT16 LangID, IN UINT8 StringID, OUT CHAR16 **String)
Retrieves a string stored in a USB Device.
Definition: UsbIo.h:442
#define EFIAPI
UINT64 UINTN
Unsigned value of native width.
Standard Endpoint Descriptor USB 2.0 spec, Section 9.6.6.
Definition: Usb.h:156
EFI_STATUS(EFIAPI * EFI_USB_IO_GET_ENDPOINT_DESCRIPTOR)(IN EFI_USB_IO_PROTOCOL *This, IN UINT8 EndpointIndex, OUT EFI_USB_ENDPOINT_DESCRIPTOR *EndpointDescriptor)
Retrieves an Endpoint Descriptor within a USB Controller.
Definition: UsbIo.h:417
#define VOID
Undeclared type.
Definition: Base.h:271
EFI_USB_IO_CONTROL_TRANSFER UsbControlTransfer
Definition: UsbIo.h:482
EFI_USB_IO_BULK_TRANSFER UsbBulkTransfer
Definition: UsbIo.h:483
#define IN
Definition: mlx_utils.h:28
USB_DEVICE_REQUEST EFI_USB_DEVICE_REQUEST
Definition: UsbIo.h:37
EFI_STATUS(EFIAPI * EFI_USB_IO_BULK_TRANSFER)(IN EFI_USB_IO_PROTOCOL *This, IN UINT8 DeviceEndpoint, IN OUT VOID *Data, IN OUT UINTN *DataLength, IN UINTN Timeout, OUT UINT32 *Status)
This function is used to manage a USB device with the bulk transfer pipe.
Definition: UsbIo.h:160
EFI_USB_IO_GET_STRING_DESCRIPTOR UsbGetStringDescriptor
Definition: UsbIo.h:496
EFI_USB_IO_GET_DEVICE_DESCRIPTOR UsbGetDeviceDescriptor
Definition: UsbIo.h:492
RETURN_STATUS EFI_STATUS
Function return status for EFI API.
Definition: UefiBaseType.h:31
USB_CONFIG_DESCRIPTOR EFI_USB_CONFIG_DESCRIPTOR
Definition: UsbIo.h:39
Standard Configuration Descriptor USB 2.0 spec, Section 9.6.3.
Definition: Usb.h:125
EFI_STATUS(EFIAPI * EFI_USB_IO_ASYNC_ISOCHRONOUS_TRANSFER)(IN EFI_USB_IO_PROTOCOL *This, IN UINT8 DeviceEndpoint, IN OUT VOID *Data, IN UINTN DataLength, IN EFI_ASYNC_USB_TRANSFER_CALLBACK IsochronousCallBack, IN VOID *Context OPTIONAL)
This function is used to manage a USB device with an isochronous transfer pipe.
Definition: UsbIo.h:318
volatile unsigned int DataLength
Definition: 3c90x.h:52
EFI_USB_IO_GET_SUPPORTED_LANGUAGE UsbGetSupportedLanguages
Definition: UsbIo.h:497
EFI_USB_IO_GET_INTERFACE_DESCRIPTOR UsbGetInterfaceDescriptor
Definition: UsbIo.h:494
Standard Device Descriptor USB 2.0 spec, Section 9.6.1.
Definition: Usb.h:104
EFI_STATUS(EFIAPI * EFI_ASYNC_USB_TRANSFER_CALLBACK)(IN VOID *Data, IN UINTN DataLength, IN VOID *Context, IN UINT32 Status)
Async USB transfer callback routine.
Definition: UsbIo.h:82
EFI_USB_IO_GET_CONFIG_DESCRIPTOR UsbGetConfigDescriptor
Definition: UsbIo.h:493