]> git.proxmox.com Git - mirror_edk2.git/blobdiff - Omap35xxPkg/PciEmulation/PciEmulation.c
Update USB init code to do a softreset.
[mirror_edk2.git] / Omap35xxPkg / PciEmulation / PciEmulation.c
index bdba40353f52c59336aa430b00bf33f4a56ae2e4..3e49f8a1bc93042f14415ca3f8863b2d14980950 100644 (file)
@@ -62,6 +62,12 @@ ConfigureUSBHost (
   EFI_STATUS Status;
   UINT8      Data = 0;
 
   EFI_STATUS Status;
   UINT8      Data = 0;
 
+  // Do a softreset 
+  MmioOr32 (UHH_SYSCONFIG, UHH_SYSCONFIG_SOFTRESET);
+  // When the bit clears reset is complete
+  while ((MmioRead32 (UHH_SYSCONFIG) & UHH_SYSCONFIG_SOFTRESET) == UHH_SYSCONFIG_SOFTRESET);
+
+
   // Take USB host out of force-standby mode
   MmioWrite32 (UHH_SYSCONFIG, UHH_SYSCONFIG_MIDLEMODE_NO_STANDBY
                              | UHH_SYSCONFIG_CLOCKACTIVITY_ON
   // Take USB host out of force-standby mode
   MmioWrite32 (UHH_SYSCONFIG, UHH_SYSCONFIG_MIDLEMODE_NO_STANDBY
                              | UHH_SYSCONFIG_CLOCKACTIVITY_ON