TianoCore EDK2 master
|
#include "EhcPeim.h"
Go to the source code of this file.
Functions | |
EFI_STATUS | EhcCreateHelpQ (IN PEI_USB2_HC_DEV *Ehc) |
EFI_STATUS | EhcInitSched (IN PEI_USB2_HC_DEV *Ehc) |
VOID | EhcFreeSched (IN PEI_USB2_HC_DEV *Ehc) |
VOID | EhcLinkQhToAsync (IN PEI_USB2_HC_DEV *Ehc, IN PEI_EHC_QH *Qh) |
VOID | EhcUnlinkQhFromAsync (IN PEI_USB2_HC_DEV *Ehc, IN PEI_EHC_QH *Qh) |
BOOLEAN | EhcCheckUrbResult (IN PEI_USB2_HC_DEV *Ehc, IN PEI_URB *Urb) |
EFI_STATUS | EhcExecTransfer (IN PEI_USB2_HC_DEV *Ehc, IN PEI_URB *Urb, IN UINTN TimeOut) |
PEIM to produce gPeiUsb2HostControllerPpiGuid based on gPeiUsbControllerPpiGuid which is used to enable recovery function from USB Drivers.
Copyright (c) 2010 - 2018, Intel Corporation. All rights reserved.
Copyright (c) Microsoft Corporation.
SPDX-License-Identifier: BSD-2-Clause-Patent
Definition in file EhciSched.c.
BOOLEAN EhcCheckUrbResult | ( | IN PEI_USB2_HC_DEV * | Ehc, |
IN PEI_URB * | Urb | ||
) |
Check the URB's execution result and update the URB's result accordingly.
Ehc | The EHCI device. |
Urb | The URB to check result. |
TRUE | URB transfer is finialized. |
FALSE | URB transfer is not finialized. |
Definition at line 304 of file EhciSched.c.
EFI_STATUS EhcCreateHelpQ | ( | IN PEI_USB2_HC_DEV * | Ehc | ) |
Create helper QTD/QH for the EHCI device.
Ehc | The EHCI device. |
EFI_OUT_OF_RESOURCES | Failed to allocate resource for helper QTD/QH. |
EFI_SUCCESS | Helper QH/QTD are created. |
Definition at line 24 of file EhciSched.c.
EFI_STATUS EhcExecTransfer | ( | IN PEI_USB2_HC_DEV * | Ehc, |
IN PEI_URB * | Urb, | ||
IN UINTN | TimeOut | ||
) |
Execute the transfer by polling the URB. This is a synchronous operation.
Ehc | The EHCI device. |
Urb | The URB to execute. |
TimeOut | The time to wait before abort, in millisecond. |
EFI_DEVICE_ERROR | The transfer failed due to transfer error. |
EFI_TIMEOUT | The transfer failed due to time out. |
EFI_SUCCESS | The transfer finished OK. |
Definition at line 417 of file EhciSched.c.
VOID EhcFreeSched | ( | IN PEI_USB2_HC_DEV * | Ehc | ) |
Free the schedule data. It may be partially initialized.
Ehc | The EHCI device. |
Definition at line 188 of file EhciSched.c.
EFI_STATUS EhcInitSched | ( | IN PEI_USB2_HC_DEV * | Ehc | ) |
Initialize the schedule data structure such as frame list.
Ehc | The EHCI device to init schedule data for. |
EFI_OUT_OF_RESOURCES | Failed to allocate resource to init schedule data. |
EFI_SUCCESS | The schedule data is initialized. |
Definition at line 100 of file EhciSched.c.
VOID EhcLinkQhToAsync | ( | IN PEI_USB2_HC_DEV * | Ehc, |
IN PEI_EHC_QH * | Qh | ||
) |
Link the queue head to the asynchronous schedule list. UEFI only supports one CTRL/BULK transfer at a time due to its interfaces. This simplifies the AsynList management: A reclamation header is always linked to the AsyncListAddr, the only active QH is appended to it.
Ehc | The EHCI device. |
Qh | The queue head to link. |
Definition at line 233 of file EhciSched.c.
VOID EhcUnlinkQhFromAsync | ( | IN PEI_USB2_HC_DEV * | Ehc, |
IN PEI_EHC_QH * | Qh | ||
) |
Unlink a queue head from the asynchronous schedule list. Need to synchronize with hardware.
Ehc | The EHCI device. |
Qh | The queue head to unlink. |
Definition at line 263 of file EhciSched.c.