From 4c495e5e3d387b26e1f22d708ff707eee6898c17 Mon Sep 17 00:00:00 2001 From: Michael D Kinney Date: Mon, 8 Nov 2021 19:13:08 -0800 Subject: [PATCH] OvmfPkg/Bhyve/PlatformPei: Fix VS2019 X64 NOOPT build issue REF: https://bugzilla.tianocore.org/show_bug.cgi?id=3724 Add typecast to fix build error with VS2019 X64 NOOPT converting a UINT64 value to UINT32 value. Cc: Rebecca Cran Cc: Peter Grehan Signed-off-by: Michael D Kinney Reviewed-by: Rebecca Cran Acked-by: Peter Grehan --- OvmfPkg/Bhyve/PlatformPei/Platform.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/OvmfPkg/Bhyve/PlatformPei/Platform.c b/OvmfPkg/Bhyve/PlatformPei/Platform.c index d980e3fcb0..c23b906733 100644 --- a/OvmfPkg/Bhyve/PlatformPei/Platform.c +++ b/OvmfPkg/Bhyve/PlatformPei/Platform.c @@ -191,7 +191,7 @@ MemMapInitialization ( ASSERT (PciExBarBase <= MAX_UINT32 - SIZE_256MB); PciBase = (UINT32)(PciExBarBase + SIZE_256MB); } else { - PciBase = PcdGet64 (PcdPciMmio32Base); + PciBase = (UINT32)PcdGet64 (PcdPciMmio32Base); if (PciBase == 0) PciBase = (TopOfLowRam < BASE_2GB) ? BASE_2GB : TopOfLowRam; }