mirror of https://github.com/acidanthera/audk.git
OvmfPkg/PlatformPei: Refactor MiscInitialization for CloudHV
BZ: https://bugzilla.tianocore.org/show_bug.cgi?id=3863 Refactor MiscInitialization for CloudHV to set PCD as other platforms do. Because in the following patch we will split the functions which set PCDs into two, one for PlatformInitLib, one for PlatformPei. Cc: Ard Biesheuvel <ardb+tianocore@kernel.org> Cc: Jordan Justen <jordan.l.justen@intel.com> Cc: Brijesh Singh <brijesh.singh@amd.com> Cc: Erdem Aktas <erdemaktas@google.com> Cc: James Bottomley <jejb@linux.ibm.com> Cc: Jiewen Yao <jiewen.yao@intel.com> Cc: Tom Lendacky <thomas.lendacky@amd.com> Cc: Gerd Hoffmann <kraxel@redhat.com> Cc: Sebastien Boeuf <sebastien.boeuf@intel.com> Acked-by: Gerd Hoffmann <kraxel@redhat.com> Reviewed-by: Jiewen Yao <jiewen.yao@intel.com> Signed-off-by: Min Xu <min.m.xu@intel.com>
This commit is contained in:
parent
5a2574a82e
commit
6d2ce5fd5c
|
@ -380,13 +380,7 @@ MiscInitialization (
|
|||
AcpiEnBit = ICH9_ACPI_CNTL_ACPI_EN;
|
||||
break;
|
||||
case CLOUDHV_DEVICE_ID:
|
||||
DEBUG ((DEBUG_INFO, "%a: Cloud Hypervisor host bridge\n", __FUNCTION__));
|
||||
PcdStatus = PcdSet16S (
|
||||
PcdOvmfHostBridgePciDevId,
|
||||
CLOUDHV_DEVICE_ID
|
||||
);
|
||||
ASSERT_RETURN_ERROR (PcdStatus);
|
||||
return;
|
||||
break;
|
||||
default:
|
||||
DEBUG ((
|
||||
DEBUG_ERROR,
|
||||
|
@ -401,6 +395,11 @@ MiscInitialization (
|
|||
PcdStatus = PcdSet16S (PcdOvmfHostBridgePciDevId, PlatformInfoHob->HostBridgeDevId);
|
||||
ASSERT_RETURN_ERROR (PcdStatus);
|
||||
|
||||
if (PlatformInfoHob->HostBridgeDevId == CLOUDHV_DEVICE_ID) {
|
||||
DEBUG ((DEBUG_INFO, "%a: Cloud Hypervisor is done.\n", __FUNCTION__));
|
||||
return;
|
||||
}
|
||||
|
||||
//
|
||||
// If the appropriate IOspace enable bit is set, assume the ACPI PMBA has
|
||||
// been configured and skip the setup here. This matches the logic in
|
||||
|
|
Loading…
Reference in New Issue