]> git.proxmox.com Git - mirror_edk2.git/commitdiff
EHCI Controllers with a CapLen of 0 are ignored.
authorerictian <erictian@6f19259b-4bc3-4df7-8a09-765794883524>
Fri, 26 Nov 2010 01:49:27 +0000 (01:49 +0000)
committererictian <erictian@6f19259b-4bc3-4df7-8a09-765794883524>
Fri, 26 Nov 2010 01:49:27 +0000 (01:49 +0000)
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@11093 6f19259b-4bc3-4df7-8a09-765794883524

MdeModulePkg/Bus/Pci/EhciDxe/Ehci.c

index 87e4aa079ba89af0d69466d9721d3ca0f259887a..852a15adcb0352e8477d6bac12345d9f46760038 100644 (file)
@@ -1437,6 +1437,14 @@ EhcCreateUsb2Hc (
 \r
   DEBUG ((EFI_D_INFO, "EhcCreateUsb2Hc: capability length %d\n", Ehc->CapLen));\r
 \r
+  //\r
+  // EHCI Controllers with a CapLen of 0 are ignored.\r
+  //\r
+  if (Ehc->CapLen == 0) {\r
+    gBS->FreePool (Ehc);\r
+    return NULL;\r
+  }\r
+\r
   //\r
   // Create AsyncRequest Polling Timer\r
   //\r