From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mga14.intel.com (mga14.intel.com [192.55.52.115]) by mx.groups.io with SMTP id smtpd.web08.80988.1629444108583559485 for ; Fri, 20 Aug 2021 00:21:48 -0700 Authentication-Results: mx.groups.io; dkim=missing; spf=pass (domain: intel.com, ip: 192.55.52.115, mailfrom: dun.tan@intel.com) X-IronPort-AV: E=McAfee;i="6200,9189,10081"; a="216455779" X-IronPort-AV: E=Sophos;i="5.84,336,1620716400"; d="scan'208";a="216455779" Received: from fmsmga003.fm.intel.com ([10.253.24.29]) by fmsmga103.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 20 Aug 2021 00:21:47 -0700 X-IronPort-AV: E=Sophos;i="5.84,336,1620716400"; d="scan'208";a="523107245" Received: from duntan-mobl.ccr.corp.intel.com ([10.238.1.156]) by fmsmga003-auth.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 20 Aug 2021 00:21:45 -0700 From: "duntan" To: devel@edk2.groups.io Cc: Guo Dong , Ray Ni , Maurice Ma , Benjamin You , DunTan Subject: [Patch V2] UefiPayloadPkg: Fix the build error when enable Core ci for UefiPayloadPkg Date: Fri, 20 Aug 2021 15:20:40 +0800 Message-Id: <20210820072040.346-1-dun.tan@intel.com> X-Mailer: git-send-email 2.31.1.windows.1 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit V1: Add quotes when using $(ARCH) in .dsc and .fdf file. The quotes are added due to the way by which Core ci parse the .dsc file. Add UINTN in Hob.c to fix cast from pointer to integer of different size error. V2: Delete lines which reference ShellBinPkg.The pkg doesn't exist in edk2. Cc: Guo Dong Cc: Ray Ni Cc: Maurice Ma Cc: Benjamin You Signed-off-by: DunTan --- UefiPayloadPkg/Library/PayloadEntryHobLib/Hob.c | 6 +++--- UefiPayloadPkg/UefiPayloadPkg.dsc | 2 +- UefiPayloadPkg/UefiPayloadPkg.fdf | 16 ---------------- 3 files changed, 4 insertions(+), 20 deletions(-) diff --git a/UefiPayloadPkg/Library/PayloadEntryHobLib/Hob.c b/UefiPayloadPkg/Library/PayloadEntryHobLib/Hob.c index 768c3db770..dd25ac2682 100644 --- a/UefiPayloadPkg/Library/PayloadEntryHobLib/Hob.c +++ b/UefiPayloadPkg/Library/PayloadEntryHobLib/Hob.c @@ -77,9 +77,9 @@ HobConstructor ( Hob->Version = EFI_HOB_HANDOFF_TABLE_VERSION; Hob->BootMode = BOOT_WITH_FULL_CONFIGURATION; - Hob->EfiMemoryTop = (EFI_PHYSICAL_ADDRESS) EfiMemoryTop; - Hob->EfiMemoryBottom = (EFI_PHYSICAL_ADDRESS) EfiMemoryBottom; - Hob->EfiFreeMemoryTop = (EFI_PHYSICAL_ADDRESS) EfiFreeMemoryTop; + Hob->EfiMemoryTop = (EFI_PHYSICAL_ADDRESS) (UINTN) EfiMemoryTop; + Hob->EfiMemoryBottom = (EFI_PHYSICAL_ADDRESS) (UINTN) EfiMemoryBottom; + Hob->EfiFreeMemoryTop = (EFI_PHYSICAL_ADDRESS) (UINTN) EfiFreeMemoryTop; Hob->EfiFreeMemoryBottom = (EFI_PHYSICAL_ADDRESS) (UINTN) (HobEnd+1); Hob->EfiEndOfHobList = (EFI_PHYSICAL_ADDRESS) (UINTN) HobEnd; diff --git a/UefiPayloadPkg/UefiPayloadPkg.dsc b/UefiPayloadPkg/UefiPayloadPkg.dsc index b4a30be381..856d5ea786 100644 --- a/UefiPayloadPkg/UefiPayloadPkg.dsc +++ b/UefiPayloadPkg/UefiPayloadPkg.dsc @@ -415,7 +415,7 @@ # ################################################################################ -!if "IA32" in $(ARCH) +!if "IA32" in "$(ARCH)" [Components.IA32] !if $(UNIVERSAL_PAYLOAD) == TRUE UefiPayloadPkg/UefiPayloadEntry/UniversalPayloadEntry.inf diff --git a/UefiPayloadPkg/UefiPayloadPkg.fdf b/UefiPayloadPkg/UefiPayloadPkg.fdf index b2cfb6b405..5871d71dbb 100644 --- a/UefiPayloadPkg/UefiPayloadPkg.fdf +++ b/UefiPayloadPkg/UefiPayloadPkg.fdf @@ -201,22 +201,6 @@ INF ShellPkg/DynamicCommand/DpDynamicCommand/DpDynamicCommand.inf INF ShellPkg/Application/Shell/Shell.inf !endif -!if $(SHELL_TYPE) == MIN_BIN -!if $(ARCH) == IA32 -INF RuleOverride = BINARY USE = IA32 ShellBinPkg/MinUefiShell/MinUefiShell.inf -!else -INF RuleOverride = BINARY USE = X64 ShellBinPkg/MinUefiShell/MinUefiShell.inf -!endif -!endif - -!if $(SHELL_TYPE) == UEFI_BIN -!if $(ARCH) == IA32 -INF RuleOverride = BINARY USE = IA32 ShellBinPkg/UefiShell/UefiShell.inf -!else -INF RuleOverride = BINARY USE = X64 ShellBinPkg/UefiShell/UefiShell.inf -!endif -!endif - ################################################################################ # -- 2.31.1.windows.1