On 09/04/2019 12:08, Anthony PERARD wrote: > diff --git a/OvmfPkg/Include/OvmfPlatforms.h b/OvmfPkg/Include/OvmfPlatforms.h > index cc67f40a88..1ce71e18ec 100644 > --- a/OvmfPkg/Include/OvmfPlatforms.h > +++ b/OvmfPkg/Include/OvmfPlatforms.h > @@ -43,4 +43,10 @@ > // > #define ACPI_TIMER_OFFSET 0x8 > > +// > +// When running OVMF on a Xen PVH guest there is no PCI, > +// so -1 is return for the Host Bridge Device ID. > +// > +#define XEN_PVH_PCI_HOST_BRIDGE_DEVICE_ID 0xFFFF
This isn't anything Xen specific - it is a property of how PCI config cycles work. > + > #endif > diff --git a/OvmfPkg/XenPlatformPei/Platform.c > b/OvmfPkg/XenPlatformPei/Platform.c > index 5e6d553ad5..d91cd98bf4 100644 > --- a/OvmfPkg/XenPlatformPei/Platform.c > +++ b/OvmfPkg/XenPlatformPei/Platform.c > @@ -278,6 +278,13 @@ MiscInitialization ( > AcpiEnBit = ICH9_ACPI_CNTL_ACPI_EN; > break; > default: > + if (XenPvhDetected ()) { > + // > + // There is no PCI bus in this case > + // > + PcdSet16S (PcdOvmfHostBridgePciDevId, > XEN_PVH_PCI_HOST_BRIDGE_DEVICE_ID); This is not correct. There may be no PCI bus, and OVMF needs to cope with this case, but there may also be one (especially once we get around to making PCI Passthrough work with PVH guests). That case needs to work too. ~Andrew _______________________________________________ Xen-devel mailing list Xen-devel@lists.xenproject.org https://lists.xenproject.org/mailman/listinfo/xen-devel