TianoCore EDK2 master
|
Go to the source code of this file.
Functions | |
EFI_STATUS | PeiUsbEnumeration (IN EFI_PEI_SERVICES **PeiServices, IN PEI_USB_HOST_CONTROLLER_PPI *UsbHcPpi, IN PEI_USB2_HOST_CONTROLLER_PPI *Usb2HcPpi) |
EFI_STATUS | PeiConfigureUsbDevice (IN EFI_PEI_SERVICES **PeiServices, IN PEI_USB_DEVICE *PeiUsbDevice, IN UINT8 Port, IN OUT UINT8 *DeviceAddress) |
EFI_STATUS | PeiUsbGetAllConfiguration (IN EFI_PEI_SERVICES **PeiServices, IN PEI_USB_DEVICE *PeiUsbDevice) |
EFI_STATUS | GetExpectedDescriptor (IN UINT8 *Buffer, IN UINTN Length, IN UINT8 DescType, IN UINT8 DescLength, OUT UINTN *ParsedBytes) |
EFI_STATUS EFIAPI | PeimInitializeUsb (IN EFI_PEI_FILE_HANDLE FileHandle, IN CONST EFI_PEI_SERVICES **PeiServices) |
EFI_STATUS | PeiHubEnumeration (IN EFI_PEI_SERVICES **PeiServices, IN PEI_USB_DEVICE *PeiUsbDevice, IN UINT8 *CurrentAddress) |
VOID | ResetRootPort (IN EFI_PEI_SERVICES **PeiServices, IN PEI_USB_HOST_CONTROLLER_PPI *UsbHcPpi, IN PEI_USB2_HOST_CONTROLLER_PPI *Usb2HcPpi, IN UINT8 PortNum, IN UINT8 RetryIndex) |
Variables | |
PEI_USB_IO_PPI | mUsbIoPpi |
EFI_PEI_PPI_DESCRIPTOR | mUsbIoPpiList |
The module to produce Usb Bus PPI.
Copyright (c) 2006 - 2018, Intel Corporation. All rights reserved.
SPDX-License-Identifier: BSD-2-Clause-Patent
Definition in file UsbPeim.c.
EFI_STATUS GetExpectedDescriptor | ( | IN UINT8 * | Buffer, |
IN UINTN | Length, | ||
IN UINT8 | DescType, | ||
IN UINT8 | DescLength, | ||
OUT UINTN * | ParsedBytes | ||
) |
Get the start position of next wanted descriptor.
Buffer | Buffer containing data to parse. |
Length | Buffer length. |
DescType | Descriptor type. |
DescLength | Descriptor length. |
ParsedBytes | Bytes has been parsed. |
EFI_SUCCESS | Get wanted descriptor successfully. |
EFI_DEVICE_ERROR | Error occurred. |
EFI_STATUS PeiConfigureUsbDevice | ( | IN EFI_PEI_SERVICES ** | PeiServices, |
IN PEI_USB_DEVICE * | PeiUsbDevice, | ||
IN UINT8 | Port, | ||
IN OUT UINT8 * | DeviceAddress | ||
) |
Configure new detected usb device.
PeiServices | Describes the list of possible PEI Services. |
PeiUsbDevice | The pointer of PEI_USB_DEVICE instance. |
Port | The port to be configured. |
DeviceAddress | The device address to be configured. |
EFI_SUCCESS | The new detected usb device is configured successfully. |
EFI_OUT_OF_RESOURCES | Can't allocate memory resource. |
Others | Other failure occurs. |
EFI_STATUS PeiHubEnumeration | ( | IN EFI_PEI_SERVICES ** | PeiServices, |
IN PEI_USB_DEVICE * | PeiUsbDevice, | ||
IN UINT8 * | CurrentAddress | ||
) |
The Hub Enumeration just scans the hub ports one time. It also doesn't support hot-plug.
PeiServices | Describes the list of possible PEI Services. |
PeiUsbDevice | The pointer of PEI_USB_DEVICE instance. |
CurrentAddress | The DeviceAddress of usb device. |
EFI_SUCCESS | The usb hub is enumerated successfully. |
EFI_OUT_OF_RESOURCES | Can't allocate memory resource. |
Others | Other failure occurs. |
EFI_STATUS EFIAPI PeimInitializeUsb | ( | IN EFI_PEI_FILE_HANDLE | FileHandle, |
IN CONST EFI_PEI_SERVICES ** | PeiServices | ||
) |
The entrypoint of the module, it will enumerate all HCs.
FileHandle | Handle of the file being invoked. |
PeiServices | Describes the list of possible PEI Services. |
EFI_SUCCESS | Usb initialization is done successfully. |
EFI_OUT_OF_RESOURCES | Can't allocate memory resource. |
EFI_UNSUPPORTED | Can't find required PPI. |
EFI_STATUS PeiUsbEnumeration | ( | IN EFI_PEI_SERVICES ** | PeiServices, |
IN PEI_USB_HOST_CONTROLLER_PPI * | UsbHcPpi, | ||
IN PEI_USB2_HOST_CONTROLLER_PPI * | Usb2HcPpi | ||
) |
The enumeration routine to detect device change.
PeiServices | Describes the list of possible PEI Services. |
UsbHcPpi | The pointer of PEI_USB_HOST_CONTROLLER_PPI instance. |
Usb2HcPpi | The pointer of PEI_USB2_HOST_CONTROLLER_PPI instance. |
EFI_SUCCESS | The usb is enumerated successfully. |
EFI_OUT_OF_RESOURCES | Can't allocate memory resource. |
Others | Other failure occurs. |
EFI_STATUS PeiUsbGetAllConfiguration | ( | IN EFI_PEI_SERVICES ** | PeiServices, |
IN PEI_USB_DEVICE * | PeiUsbDevice | ||
) |
Get all configurations from a detected usb device.
PeiServices | Describes the list of possible PEI Services. |
PeiUsbDevice | The pointer of PEI_USB_DEVICE instance. |
EFI_SUCCESS | The new detected usb device is configured successfully. |
EFI_OUT_OF_RESOURCES | Can't allocate memory resource. |
Others | Other failure occurs. |
VOID ResetRootPort | ( | IN EFI_PEI_SERVICES ** | PeiServices, |
IN PEI_USB_HOST_CONTROLLER_PPI * | UsbHcPpi, | ||
IN PEI_USB2_HOST_CONTROLLER_PPI * | Usb2HcPpi, | ||
IN UINT8 | PortNum, | ||
IN UINT8 | RetryIndex | ||
) |
Send reset signal over the given root hub port.
PeiServices | Describes the list of possible PEI Services. |
UsbHcPpi | The pointer of PEI_USB_HOST_CONTROLLER_PPI instance. |
Usb2HcPpi | The pointer of PEI_USB2_HOST_CONTROLLER_PPI instance. |
PortNum | The port to be reset. |
RetryIndex | The retry times. |
PEI_USB_IO_PPI mUsbIoPpi |
EFI_PEI_PPI_DESCRIPTOR mUsbIoPpiList |