MdeMoMdeMdeModulePkg/EhciPei: By default power on all root ports of EHCI host controller for recovery path
Signed-off-by: Tian Feng <feng.tian@intel.com> Reviewed-by: Sun Rui <rui.sun@intel.com> git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@13460 6f19259b-4bc3-4df7-8a09-765794883524
This commit is contained in:
parent
af3a71b85b
commit
23b0b15526
@ -2,7 +2,7 @@
|
|||||||
PEIM to produce gPeiUsb2HostControllerPpiGuid based on gPeiUsbControllerPpiGuid
|
PEIM to produce gPeiUsb2HostControllerPpiGuid based on gPeiUsbControllerPpiGuid
|
||||||
which is used to enable recovery function from USB Drivers.
|
which is used to enable recovery function from USB Drivers.
|
||||||
|
|
||||||
Copyright (c) 2010, Intel Corporation. All rights reserved.<BR>
|
Copyright (c) 2010 - 2012, Intel Corporation. All rights reserved.<BR>
|
||||||
|
|
||||||
This program and the accompanying materials
|
This program and the accompanying materials
|
||||||
are licensed and made available under the terms and conditions
|
are licensed and made available under the terms and conditions
|
||||||
@ -400,6 +400,26 @@ EhcRunHC (
|
|||||||
return Status;
|
return Status;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
Power On All EHCI Ports.
|
||||||
|
|
||||||
|
@param Ehc The EHCI device.
|
||||||
|
|
||||||
|
**/
|
||||||
|
VOID
|
||||||
|
EhcPowerOnAllPorts (
|
||||||
|
IN PEI_USB2_HC_DEV *Ehc
|
||||||
|
)
|
||||||
|
{
|
||||||
|
UINT8 PortNumber;
|
||||||
|
UINT8 Index;
|
||||||
|
|
||||||
|
PortNumber = (UINT8)(Ehc->HcStructParams & HCSP_NPORTS);
|
||||||
|
for (Index = 0; Index < PortNumber; Index++) {
|
||||||
|
EhcSetOpRegBit (Ehc, EHC_PORT_STAT_OFFSET + 4 * Index, PORTSC_POWER);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
Initialize the HC hardware.
|
Initialize the HC hardware.
|
||||||
EHCI spec lists the five things to do to initialize the hardware.
|
EHCI spec lists the five things to do to initialize the hardware.
|
||||||
@ -443,6 +463,9 @@ EhcInitHC (
|
|||||||
if (Ehc->Urb == NULL) {
|
if (Ehc->Urb == NULL) {
|
||||||
return Status;
|
return Status;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
EhcPowerOnAllPorts (Ehc);
|
||||||
|
MicroSecondDelay (EHC_ROOT_PORT_RECOVERY_STALL);
|
||||||
|
|
||||||
Status = EhcInitSched (Ehc);
|
Status = EhcInitSched (Ehc);
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user