From nobody Mon Feb 9 21:19:48 2026 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of groups.io designates 66.175.222.12 as permitted sender) client-ip=66.175.222.12; envelope-from=bounce+27952+50538+1787277+3901457@groups.io; helo=web01.groups.io; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zoho.com: domain of groups.io designates 66.175.222.12 as permitted sender) smtp.mailfrom=bounce+27952+50538+1787277+3901457@groups.io; dmarc=fail(p=none dis=none) header.from=intel.com ARC-Seal: i=1; a=rsa-sha256; t=1573615811; cv=none; d=zoho.com; s=zohoarc; b=Vwq5YWGXvVJJUGECEHPhSG6eZ72cJxhfYlt52+9en/gud1n15yPn5/por1vpeOU8boS7hTt1W4VS45gxKdcRRji8Vihp3Rmw5Zd13edqS4j4PLJpo0Lvp48eFepzZBwHoXjZFxyz1TENccmX0kABvif+cguCBBxyDi4u5Pp1A14= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zoho.com; s=zohoarc; t=1573615811; h=Cc:Date:From:In-Reply-To:List-Id:List-Unsubscribe:Message-ID:Reply-To:References:Sender:Subject:To; bh=fQxd5WVxeVyVzMOCVe/MzyyCJHpdtXtQDQCoX0yAn7I=; b=UyRL+w/d8Qcj+Y3OX7OhYM2ePclDOWuKFOi9wlmgeZ6WOj5Hi5f2uPj8OtamapelpaEqI2v2vn6o1otuGOIMSWZ+Drn8ICCGs2rwG5kxR1xO+om0NOBSI/3PsjlBriBwJ7te0oMAWQ0Rgk49anml9zu1qMKZNtCXvGVpueSv3wM= ARC-Authentication-Results: i=1; mx.zoho.com; dkim=pass; spf=pass (zoho.com: domain of groups.io designates 66.175.222.12 as permitted sender) smtp.mailfrom=bounce+27952+50538+1787277+3901457@groups.io; dmarc=fail header.from= (p=none dis=none) header.from= Received: from web01.groups.io (web01.groups.io [66.175.222.12]) by mx.zohomail.com with SMTPS id 1573615811446532.3800826138648; Tue, 12 Nov 2019 19:30:11 -0800 (PST) Return-Path: X-Received: by 127.0.0.2 with SMTP id aaaaYY1788612xaaaaaaaaaa; Tue, 12 Nov 2019 19:30:08 -0800 X-Received: from mga11.intel.com (mga11.intel.com []) by mx.groups.io with SMTP id smtpd.web11.2429.1573615788189411290 for ; Tue, 12 Nov 2019 19:30:07 -0800 X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False X-Received: from orsmga005.jf.intel.com ([10.7.209.41]) by fmsmga102.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 12 Nov 2019 19:30:07 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.68,299,1569308400"; d="scan'208";a="379091336" X-Received: from makuback-desk1.amr.corp.intel.com ([10.7.159.162]) by orsmga005.jf.intel.com with ESMTP; 12 Nov 2019 19:30:07 -0800 From: "Kubacki, Michael A" To: devel@edk2.groups.io Cc: Sai Chaganty , Liming Gao Subject: [edk2-devel] [edk2-platforms][PATCH V1 32/49] AdvancedFeaturePkg: Add temporary build workaround Date: Tue, 12 Nov 2019 19:27:58 -0800 Message-Id: <20191113032816.4056-33-michael.a.kubacki@intel.com> In-Reply-To: <20191113032816.4056-1-michael.a.kubacki@intel.com> References: <20191113032816.4056-1-michael.a.kubacki@intel.com> Precedence: Bulk List-Unsubscribe: Sender: devel@edk2.groups.io List-Id: Mailing-List: list devel@edk2.groups.io; contact devel+owner@edk2.groups.io Reply-To: devel@edk2.groups.io,michael.a.kubacki@intel.com X-Gm-Message-State: aaaaaaaaaaaaaaaaaaaaaaaax1787277AA= DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=groups.io; q=dns/txt; s=20140610; t=1573615808; bh=pu/2BYZpt13RRIastltSSfNbwan32puBISsea3WRlaQ=; h=Cc:Date:From:Reply-To:Subject:To; b=tc1p4vRSEIoDbBjZhmGGd5KdnpgZdVmOHGIOyqt6Gejr+hIyYknXvK6jUv9nTEdv+7e qslUcOhzQ+ag+HlvY/haHuYVcgqRMIO/r/03GBmZwo++Bed51VKWgf2rP9EdixhAX49a7 R8EQ/Yox7OQ/hE5G5tSA5m8OHiR+88exi/8= X-ZohoMail-DKIM: pass (identity @groups.io) Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" This change adds a temporary build workaround to allow the advanced feature PCDs to be used in conditional statements in DSC files even if they are not referenced in INF files. Support to allow a FeaturePCD to be used in a conditional statement without being referenced in an INF file has been requested in the following Bugzilla item: https://bugzilla.tianocore.org/show_bug.cgi?id=3D2270 This change can be reverted when that Bugzilla is completed and the change is submitted to edk2. Cc: Sai Chaganty Cc: Liming Gao Signed-off-by: Michael Kubacki --- Features/Intel/AdvancedFeaturePkg/AdvancedFeaturePkg.dsc = | 2 + Features/Intel/AdvancedFeaturePkg/TemporaryBuildWorkaround/TemporaryBuildW= orkaround.dsc | 74 ++++++++++++++++++++ Features/Intel/AdvancedFeaturePkg/TemporaryBuildWorkaround/TemporaryBuildW= orkaround.inf | 57 +++++++++++++++ Features/Intel/AdvancedFeaturePkg/TemporaryBuildWorkaround/TemporaryBuildW= orkaround.c | 31 ++++++++ 4 files changed, 164 insertions(+) diff --git a/Features/Intel/AdvancedFeaturePkg/AdvancedFeaturePkg.dsc b/Fea= tures/Intel/AdvancedFeaturePkg/AdvancedFeaturePkg.dsc index 50c0e81048..23e7c6474a 100644 --- a/Features/Intel/AdvancedFeaturePkg/AdvancedFeaturePkg.dsc +++ b/Features/Intel/AdvancedFeaturePkg/AdvancedFeaturePkg.dsc @@ -30,6 +30,8 @@ PEI_ARCH =3D IA32 DXE_ARCH =3D X64 =20 +!include AdvancedFeaturePkg/TemporaryBuildWorkaround/TemporaryBuildWorkaro= und.dsc + ##########################################################################= ###### # # Advanced Feature Enable section - all advanced features are enabling for= the diff --git a/Features/Intel/AdvancedFeaturePkg/TemporaryBuildWorkaround/Tem= poraryBuildWorkaround.dsc b/Features/Intel/AdvancedFeaturePkg/TemporaryBuil= dWorkaround/TemporaryBuildWorkaround.dsc new file mode 100644 index 0000000000..227ae00908 --- /dev/null +++ b/Features/Intel/AdvancedFeaturePkg/TemporaryBuildWorkaround/TemporaryB= uildWorkaround.dsc @@ -0,0 +1,74 @@ +## @file +# Build description file for a temporary build workaround. +# +# The feature enable PCD for advanced features must be referenced in an INF +# to be referenced in DSC/FDF files. This DSC only exists in the build to +# allow the PCDs to be referenced. This workaround does not affect the fin= al +# flash image or boot in any way. +# +# The request to update BaseTools to allow a PCD to be referenced in DSC/F= DF +# files without requiring the PCD to be referenced in an INF file is track= ed +# here: https://bugzilla.tianocore.org/show_bug.cgi?id=3D2270 +# +# When the BaseTools update is complete, this file can entirely be removed +# from this package. +# +# Copyright (c) 2019, Intel Corporation. All rights reserved.
+# +# SPDX-License-Identifier: BSD-2-Clause-Patent +# +## + +# +# BEGIN:Temporary Build Workaround (resolution: https://bugzilla.tianocore= .org/show_bug.cgi?id=3D2270) +# + +# THIS FILE IS TEMPORARY. PLEASE TRY TO LOOK PAST THE "HACKS" ASSOCIATED W= ITH IT. +# +# With the BaseTools change requested, the changes needed to move to the e= nd state are simply: +# 1. Remove the !include for this file in AdvancedFeatures.dsc +# 2. Remove this directory + +!if $(PLATFORM_NAME) !=3D AdvancedFeaturePkg +# +# AdvancedFeaturePkg initializes all FeaturePCDs to TRUE so they can conve= niently be built in one package. +# Board packages will normally only enable (and therefore reference) a sma= ll subset of advanced features +# relative to the board. If an INF does not reference a package DEC file (= which will be the case if the +# feature is not enabled) then the DSC must set ("define") the PCD for the= conditional statements based +# on the PCD to work. +# +# AdvancedFeaturePkg has no problem as it naturally has a need to set al P= CDs to TRUE for build. +# The section below sets all PCDs to FALSE in the DSC file so if the featu= re is not enabled by a board, +# the build will still be successful. +# +[PcdsFeatureFlag] + gAcpiDebugFeaturePkgTokenSpaceGuid.PcdAcpiDebugFeatureEnable = |FALSE + gIpmiFeaturePkgTokenSpaceGuid.PcdIpmiFeatureEnable = |FALSE + gNetworkFeaturePkgTokenSpaceGuid.PcdNetworkFeatureEnable = |FALSE + gS3FeaturePkgTokenSpaceGuid.PcdS3FeatureEnable = |FALSE + gSmbiosFeaturePkgTokenSpaceGuid.PcdSmbiosFeatureEnable = |FALSE + gUsb3DebugFeaturePkgTokenSpaceGuid.PcdUsb3DebugFeatureEnable = |FALSE + gUserAuthFeaturePkgTokenSpaceGuid.PcdUserAuthenticationFeatureEnable = |FALSE +!endif + +# +# The LibraryClasses required to build TemporaryBuildWorkaround.inf +# (mostly libraries requiring other libraries) +# +[LibraryClasses] + BaseLib|MdePkg/Library/BaseLib/BaseLib.inf + BaseMemoryLib|MdePkg/Library/BaseMemoryLibRepStr/BaseMemoryLibRepStr.inf + DebugLib|MdePkg/Library/BaseDebugLibNull/BaseDebugLibNull.inf + PcdLib|MdePkg/Library/BasePcdLibNull/BasePcdLibNull.inf + PeimEntryPoint|MdePkg/Library/PeimEntryPoint/PeimEntryPoint.inf + PeiServicesLib|MdePkg/Library/PeiServicesLib/PeiServicesLib.inf + PeiServicesTablePointerLib|MdePkg/Library/PeiServicesTablePointerLibIdt/= PeiServicesTablePointerLibIdt.inf + +# +# The driver that references all feature PCDs to satsify current build lim= itations +# +[Components] + AdvancedFeaturePkg/TemporaryBuildWorkaround/TemporaryBuildWorkaround.inf +# +# END:Temporary Build Workaround (resolution: https://bugzilla.tianocore.o= rg/show_bug.cgi?id=3D2270) +# diff --git a/Features/Intel/AdvancedFeaturePkg/TemporaryBuildWorkaround/Tem= poraryBuildWorkaround.inf b/Features/Intel/AdvancedFeaturePkg/TemporaryBuil= dWorkaround/TemporaryBuildWorkaround.inf new file mode 100644 index 0000000000..74176d1989 --- /dev/null +++ b/Features/Intel/AdvancedFeaturePkg/TemporaryBuildWorkaround/TemporaryB= uildWorkaround.inf @@ -0,0 +1,57 @@ +### @file +# Component information file for a temporary build workaround. +# +# The feature enable PCD for this package must be referenced in an INF to = be +# referenced in DSC/FDF files. This driver is only included in the build to +# allow the PCD to be referenced. This driver is not included in the flash +# image and does not affect the boot in any way. +# +# The request to update BaseTools to allow a PCD to be referenced in DSC/F= DF +# files without requiring the PCD to be referenced in an INF file is track= ed +# here: https://bugzilla.tianocore.org/show_bug.cgi?id=3D2270 +# +# When the BaseTools update is complete, this file can entirely be removed +# from this package. +# +# Copyright (c) 2019, Intel Corporation. All rights reserved.
+# +# SPDX-License-Identifier: BSD-2-Clause-Patent +# +### + +[Defines] + INF_VERSION =3D 0x00010017 + BASE_NAME =3D TemporaryBuildWorkaround + FILE_GUID =3D 8846A81E-F552-4917-81F5-80B62E4EFBAC + VERSION_STRING =3D 1.0 + MODULE_TYPE =3D PEIM + ENTRY_POINT =3D TemporaryBuildWorkaroundEntry + +[LibraryClasses] + BaseLib + PeimEntryPoint + +[Packages] + MdePkg/MdePkg.dec + Debugging/AcpiDebugFeaturePkg/AcpiDebugFeaturePkg.dec + Debugging/Usb3DebugFeaturePkg/Usb3DebugFeaturePkg.dec + Network/NetworkFeaturePkg/NetworkFeaturePkg.dec + OutOfBandManagement/IpmiFeaturePkg/IpmiFeaturePkg.dec + PowerManagement/S3FeaturePkg/S3FeaturePkg.dec + SystemInformation/SmbiosFeaturePkg/SmbiosFeaturePkg.dec + UserInterface/UserAuthFeaturePkg/UserAuthFeaturePkg.dec + +[FeaturePcd] + gAcpiDebugFeaturePkgTokenSpaceGuid.PcdAcpiDebugFeatureEnable + gIpmiFeaturePkgTokenSpaceGuid.PcdIpmiFeatureEnable + gNetworkFeaturePkgTokenSpaceGuid.PcdNetworkFeatureEnable + gS3FeaturePkgTokenSpaceGuid.PcdS3FeatureEnable + gSmbiosFeaturePkgTokenSpaceGuid.PcdSmbiosFeatureEnable + gUsb3DebugFeaturePkgTokenSpaceGuid.PcdUsb3DebugFeatureEnable + gUserAuthFeaturePkgTokenSpaceGuid.PcdUserAuthenticationFeatureEnable + +[Sources] + TemporaryBuildWorkaround.c + +[Depex] + TRUE diff --git a/Features/Intel/AdvancedFeaturePkg/TemporaryBuildWorkaround/Tem= poraryBuildWorkaround.c b/Features/Intel/AdvancedFeaturePkg/TemporaryBuildW= orkaround/TemporaryBuildWorkaround.c new file mode 100644 index 0000000000..2cd91b06f0 --- /dev/null +++ b/Features/Intel/AdvancedFeaturePkg/TemporaryBuildWorkaround/TemporaryB= uildWorkaround.c @@ -0,0 +1,31 @@ +/** @file + Source code file for a temporary build workaround. + + The purpose of this workaround is described in the module INF file. + +Copyright (c) 2019, Intel Corporation. All rights reserved.
+SPDX-License-Identifier: BSD-2-Clause-Patent + +**/ + +#include +#include + +/** + An empty entry point function. + + @param FileHandle Handle of the file being invoked. + @param PeiServices Describes the list of possible PEI Services. + + @retval EFI_SUCCESS This function always returns EFI_SUCCESS. + +**/ +EFI_STATUS +EFIAPI +TemporaryBuildWorkaroundEntry ( + IN EFI_PEI_FILE_HANDLE FileHandle, + IN CONST EFI_PEI_SERVICES **PeiServices + ) +{ + return EFI_SUCCESS; +} --=20 2.16.2.windows.1 -=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#50538): https://edk2.groups.io/g/devel/message/50538 Mute This Topic: https://groups.io/mt/55161854/1787277 Group Owner: devel+owner@edk2.groups.io Unsubscribe: https://edk2.groups.io/g/devel/unsub [importer@patchew.org] -=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-