]> git.proxmox.com Git - mirror_edk2.git/commitdiff
OvmfPkg/PlatformBootManagerLib: Handle the absence of PCI bus on Xen PVH
authorAnthony PERARD <anthony.perard@citrix.com>
Tue, 13 Aug 2019 11:31:12 +0000 (12:31 +0100)
committerLaszlo Ersek <lersek@redhat.com>
Wed, 21 Aug 2019 16:03:49 +0000 (18:03 +0200)
When running in a Xen PVH guest, there's nothing to do in
PciAcpiInitialization() because there isn't any PCI bus. When the Host
Bridge DID isn't recognised, simply continue. (The value of
PcdOvmfHostBridgePciDevId would be 0 because it isn't set.)

Ref: https://bugzilla.tianocore.org/show_bug.cgi?id=1689
Signed-off-by: Anthony PERARD <anthony.perard@citrix.com>
Reviewed-by: Laszlo Ersek <lersek@redhat.com>
Message-Id: <20190813113119.14804-29-anthony.perard@citrix.com>

OvmfPkg/Library/PlatformBootManagerLib/BdsPlatform.c

index d5d5d20fd8569a2e8a3fb015be9fe58159e12574..1eba304f09d4edc435ea2e6577c23574cf1a3b8b 100644 (file)
@@ -1208,6 +1208,12 @@ PciAcpiInitialization (
       PciWrite8 (PCI_LIB_ADDRESS (0, 0x1f, 0, 0x6b), 0x0b); // H\r
       break;\r
     default:\r
+      if (XenDetected ()) {\r
+        //\r
+        // There is no PCI bus in this case.\r
+        //\r
+        return;\r
+      }\r
       DEBUG ((EFI_D_ERROR, "%a: Unknown Host Bridge Device ID: 0x%04x\n",\r
         __FUNCTION__, mHostBridgeDevId));\r
       ASSERT (FALSE);\r