From 9673d0ef04e43a90f19c8d2baf3866ac2bef2072 Mon Sep 17 00:00:00 2001 From: Oliver Smith-Denny Date: Fri, 13 Sep 2024 08:49:35 -0700 Subject: [PATCH] Update to New StackCheckLib edk2 PR https://github.com/tianocore/edk2/pull/5957 removed BaseStackCheckLib and added StackCheckLibNull (amongst others). This PR updates all dscs/dsc.incs to remove the old BaseStackCheckLib and if appropriate, add StackCheckLibNull to LibraryClasses.common.SEC or to specific SEC libs. For all other component types, MdeLibs.dsc.inc links them to StackCheckLibNull. This does all dscs at once as it is formulaic and fixes build breaks. Continuous-integration-options: PatchCheck.ignore-multi-package Signed-off-by: Oliver Smith-Denny --- Drivers/ASIX/Asix.dsc | 12 ------------ .../DisplayLink/DisplayLinkPkg/DisplayLinkPkg.dsc | 6 ------ Drivers/OptionRomPkg/OptionRomPkg.dsc | 3 --- Features/Ext4Pkg/Ext4Pkg.dsc | 5 ----- Features/ManageabilityPkg/Include/Manageability.dsc | 1 - Platform/AMD/AmdMinBoardPkg/AmdMinBoardPkg.dsc | 3 +++ Platform/AMD/OverdriveBoard/OverdriveBoard.dsc | 6 +++--- .../AMD/VanGoghBoard/ChachaniBoardPkg/Project.dsc | 5 +++-- Platform/ARM/Morello/MorelloPlatform.dsc.inc | 3 +++ Platform/ARM/SgiPkg/SgiPlatform.dsc.inc | 3 +++ Platform/ARM/VExpressPkg/ArmVExpress.dsc.inc | 7 +++---- Platform/ARM/VExpressPkg/PlatformStandaloneMm.dsc | 2 -- .../BeagleBoard/BeagleBoardPkg/BeagleBoardPkg.dsc | 10 ++++------ .../Bosc/XiangshanSeriesPkg/NanhuDev/NanhuDev.dsc | 3 +++ Platform/Intel/MinPlatformPkg/MinPlatformPkg.dsc | 2 ++ Platform/Intel/QuarkPlatformPkg/Quark.dsc | 3 ++- Platform/Intel/QuarkPlatformPkg/QuarkMin.dsc | 3 ++- .../BoardX58Ich10/OpenBoardPkg.dsc | 1 + Platform/LeMaker/CelloBoard/CelloBoard.dsc | 6 +++--- Platform/Loongson/LoongArchQemuPkg/Loongson.dsc | 6 +++--- Platform/Qemu/SbsaQemu/SbsaQemu.dsc | 6 +++--- Platform/RISC-V/PlatformPkg/RiscVPlatformPkg.dsc | 3 +++ Platform/RaspberryPi/RPi3/RPi3.dsc | 6 +++--- Platform/RaspberryPi/RPi4/RPi4.dsc | 6 +++--- .../U5SeriesPkg/FreedomU500VC707Board/U500.dsc | 5 ++++- .../FreedomU540HiFiveUnleashedBoard/U540.dsc | 3 +++ Platform/Socionext/DeveloperBox/DeveloperBox.dsc.inc | 6 ++++-- .../SynQuacerEvalBoard/SynQuacerEvalBoard.dsc | 5 +++-- .../Overdrive1000Board/Overdrive1000Board.dsc | 6 +++--- Platform/Sophgo/SG2042_EVB_Board/SG2042.dsc | 5 ++++- .../PlatformStandaloneMmRpmb.dsc | 1 - Silicon/Ampere/AmpereAltraPkg/AmpereAltraPkg.dsc.inc | 9 +++------ Silicon/Hisilicon/Hisilicon.dsc.inc | 6 +++--- Silicon/Marvell/Armada7k8k/Armada7k8k.dsc.inc | 7 +++---- Silicon/Marvell/OdysseyPkg/OdysseyPkg.dsc.inc | 8 +++----- Silicon/NXP/NxpQoriqLs.dsc.inc | 4 +++- Silicon/Openmoko/Openmoko.dsc | 1 - .../PhytiumCommonPkg/PhytiumCommonPkg.dsc.inc | 9 +++------ Silicon/Synopsys/DesignWare/DesignWare.dsc | 1 - Silicon/TexasInstruments/Omap35xxPkg/Omap35xxPkg.dsc | 3 --- 40 files changed, 89 insertions(+), 101 deletions(-) diff --git a/Drivers/ASIX/Asix.dsc b/Drivers/ASIX/Asix.dsc index 279ab37ef19..0e82b4f765d 100644 --- a/Drivers/ASIX/Asix.dsc +++ b/Drivers/ASIX/Asix.dsc @@ -46,18 +46,6 @@ UefiApplicationEntryPoint|MdePkg/Library/UefiApplicationEntryPoint/UefiApplicationEntryPoint.inf UefiRuntimeLib|MdePkg/Library/UefiRuntimeLib/UefiRuntimeLib.inf -[LibraryClasses.ARM] - NULL|MdePkg/Library/BaseStackCheckLib/BaseStackCheckLib.inf - -################################################################################ -# -# Pcd Section - list of all EDK II PCD Entries defined by this Platform -# -################################################################################ -[PcdsFeatureFlag] - -[PcdsFixedAtBuild] - ################################################################################ # # Components Section - list of all EDK II Modules needed by this Platform diff --git a/Drivers/DisplayLink/DisplayLinkPkg/DisplayLinkPkg.dsc b/Drivers/DisplayLink/DisplayLinkPkg/DisplayLinkPkg.dsc index b6c53be9592..4bd566a0baa 100644 --- a/Drivers/DisplayLink/DisplayLinkPkg/DisplayLinkPkg.dsc +++ b/Drivers/DisplayLink/DisplayLinkPkg/DisplayLinkPkg.dsc @@ -36,12 +36,6 @@ [LibraryClasses.common.UEFI_DRIVER] MemoryAllocationLib|MdePkg/Library/UefiMemoryAllocationLib/UefiMemoryAllocationLib.inf -[LibraryClasses.AARCH64] - NULL|MdePkg/Library/BaseStackCheckLib/BaseStackCheckLib.inf - -[LibraryClasses.ARM] - NULL|MdePkg/Library/BaseStackCheckLib/BaseStackCheckLib.inf - [PcdsFixedAtBuild] !ifdef $(DEBUG_ENABLE_OUTPUT) gEfiMdePkgTokenSpaceGuid.PcdDebugPropertyMask|0x3f diff --git a/Drivers/OptionRomPkg/OptionRomPkg.dsc b/Drivers/OptionRomPkg/OptionRomPkg.dsc index 8b5a374d3a3..ab8afabd206 100644 --- a/Drivers/OptionRomPkg/OptionRomPkg.dsc +++ b/Drivers/OptionRomPkg/OptionRomPkg.dsc @@ -58,9 +58,6 @@ UefiApplicationEntryPoint|MdePkg/Library/UefiApplicationEntryPoint/UefiApplicationEntryPoint.inf UefiRuntimeLib|MdePkg/Library/UefiRuntimeLib/UefiRuntimeLib.inf -[LibraryClasses.ARM] - NULL|MdePkg/Library/BaseStackCheckLib/BaseStackCheckLib.inf - ################################################################################ # # Pcd Section - list of all EDK II PCD Entries defined by this Platform diff --git a/Features/Ext4Pkg/Ext4Pkg.dsc b/Features/Ext4Pkg/Ext4Pkg.dsc index 621c63eaf92..57f279a4d91 100644 --- a/Features/Ext4Pkg/Ext4Pkg.dsc +++ b/Features/Ext4Pkg/Ext4Pkg.dsc @@ -47,11 +47,6 @@ OrderedCollectionLib|MdePkg/Library/BaseOrderedCollectionRedBlackTreeLib/BaseOrderedCollectionRedBlackTreeLib.inf BaseUcs2Utf8Lib|RedfishPkg/Library/BaseUcs2Utf8Lib/BaseUcs2Utf8Lib.inf - # - # Required for stack protector support - # - NULL|MdePkg/Library/BaseStackCheckLib/BaseStackCheckLib.inf - ################################################################################################### # # Components Section - list of the modules and components that will be processed by compilation diff --git a/Features/ManageabilityPkg/Include/Manageability.dsc b/Features/ManageabilityPkg/Include/Manageability.dsc index 4121bd303ad..ef9c7e2e4a2 100644 --- a/Features/ManageabilityPkg/Include/Manageability.dsc +++ b/Features/ManageabilityPkg/Include/Manageability.dsc @@ -14,7 +14,6 @@ PldmProtocolLib|ManageabilityPkg/Library/PldmProtocolLibrary/Dxe/PldmProtocolLib.inf [LibraryClasses.ARM, LibraryClasses.AARCH64] - NULL|MdePkg/Library/BaseStackCheckLib/BaseStackCheckLib.inf ArmSoftFloatLib|ArmPkg/Library/ArmSoftFloatLib/ArmSoftFloatLib.inf ArmLib|ArmPkg/Library/ArmLib/ArmBaseLib.inf BaseMemoryLib|MdePkg/Library/BaseMemoryLib/BaseMemoryLib.inf diff --git a/Platform/AMD/AmdMinBoardPkg/AmdMinBoardPkg.dsc b/Platform/AMD/AmdMinBoardPkg/AmdMinBoardPkg.dsc index dd161fd73d0..d7a4f7650cd 100644 --- a/Platform/AMD/AmdMinBoardPkg/AmdMinBoardPkg.dsc +++ b/Platform/AMD/AmdMinBoardPkg/AmdMinBoardPkg.dsc @@ -41,6 +41,9 @@ [LibraryClasses.common.SEC] PlatformSecLib|AmdMinBoardPkg/Library/PlatformSecLib/PlatformSecLib.inf + + # This has SEC modules with standard entry points, so we can generically link StackCheckLib + NULL|MdePkg/Library/StackCheckLibNull/StackCheckLibNull.inf [LibraryClasses.common.PEIM] BoardInitLib|AmdMinBoardPkg/Library/PeiBoardInitPreMemLib/PeiBoardInitPreMemLib.inf diff --git a/Platform/AMD/OverdriveBoard/OverdriveBoard.dsc b/Platform/AMD/OverdriveBoard/OverdriveBoard.dsc index e10aed7ae87..671f0a5b1ba 100644 --- a/Platform/AMD/OverdriveBoard/OverdriveBoard.dsc +++ b/Platform/AMD/OverdriveBoard/OverdriveBoard.dsc @@ -172,6 +172,9 @@ DEFINE X64EMU_ENABLE = FALSE ArmGicArchLib|ArmPkg/Library/ArmGicArchSecLib/ArmGicArchSecLib.inf + # ARM platforms have SEC modules with standard entry points, so we can generically link StackCheckLib + NULL|MdePkg/Library/StackCheckLibNull/StackCheckLibNull.inf + [LibraryClasses.common.PEIM, LibraryClasses.common.SEC] MemoryInitPeiLib|Silicon/AMD/Styx/Library/MemoryInitPei/MemoryInitPeiLib.inf BaseMemoryLib|MdePkg/Library/BaseMemoryLib/BaseMemoryLib.inf @@ -232,9 +235,6 @@ DEFINE X64EMU_ENABLE = FALSE PerformanceLib|MdeModulePkg/Library/DxePerformanceLib/DxePerformanceLib.inf MemoryAllocationLib|MdePkg/Library/UefiMemoryAllocationLib/UefiMemoryAllocationLib.inf -[LibraryClasses.AARCH64] - NULL|MdePkg/Library/BaseStackCheckLib/BaseStackCheckLib.inf - ################################################################################################### # BuildOptions Section - Define the module specific tool chain flags that should be used as # the default flags for a module. These flags are appended to any diff --git a/Platform/AMD/VanGoghBoard/ChachaniBoardPkg/Project.dsc b/Platform/AMD/VanGoghBoard/ChachaniBoardPkg/Project.dsc index f553181c36a..38d90886228 100644 --- a/Platform/AMD/VanGoghBoard/ChachaniBoardPkg/Project.dsc +++ b/Platform/AMD/VanGoghBoard/ChachaniBoardPkg/Project.dsc @@ -371,8 +371,8 @@ [LibraryClasses.common] RegisterFilterLib|MdePkg/Library/RegisterFilterLibNull/RegisterFilterLibNull.inf - CcExitLib|UefiCpuPkg/Library/CcExitLibNull/CcExitLibNull.inf - AmdSvsmLib|UefiCpuPkg/Library/AmdSvsmLibNull/AmdSvsmLibNull.inf + CcExitLib|UefiCpuPkg/Library/CcExitLibNull/CcExitLibNull.inf + AmdSvsmLib|UefiCpuPkg/Library/AmdSvsmLibNull/AmdSvsmLibNull.inf [PcdsFixedAtBuild] gEfiAmdAgesaPkgTokenSpaceGuid.PcdFchOemBeforePciRestoreSwSmi|0xEA @@ -527,6 +527,7 @@ PeiServicesTablePointerLib|MdePkg/Library/PeiServicesTablePointerLibIdt/PeiServicesTablePointerLibIdt.inf PeiServicesLib|MdePkg/Library/PeiServicesLib/PeiServicesLib.inf PlatformSecLib|ChachaniBoardPkg/Library/PlatformSecLib/PlatformSecLib.inf + NULL|MdePkg/Library/StackCheckLibNull/StackCheckLibNull.inf } !if $(CAPSULE_ENABLE) == TRUE diff --git a/Platform/ARM/Morello/MorelloPlatform.dsc.inc b/Platform/ARM/Morello/MorelloPlatform.dsc.inc index 2ecc937d292..18b736108d9 100644 --- a/Platform/ARM/Morello/MorelloPlatform.dsc.inc +++ b/Platform/ARM/Morello/MorelloPlatform.dsc.inc @@ -25,6 +25,9 @@ PeiServicesLib|MdePkg/Library/PeiServicesLib/PeiServicesLib.inf PeiServicesTablePointerLib|ArmPkg/Library/PeiServicesTablePointerLib/PeiServicesTablePointerLib.inf + # ARM platforms have SEC modules with standard entry points, so we can generically link StackCheckLib + NULL|MdePkg/Library/StackCheckLibNull/StackCheckLibNull.inf + [LibraryClasses.common.PEI_CORE, LibraryClasses.common.PEIM] BaseMemoryLib|MdePkg/Library/BaseMemoryLib/BaseMemoryLib.inf HobLib|MdePkg/Library/PeiHobLib/PeiHobLib.inf diff --git a/Platform/ARM/SgiPkg/SgiPlatform.dsc.inc b/Platform/ARM/SgiPkg/SgiPlatform.dsc.inc index 1bf9457fe99..a639f94839c 100644 --- a/Platform/ARM/SgiPkg/SgiPlatform.dsc.inc +++ b/Platform/ARM/SgiPkg/SgiPlatform.dsc.inc @@ -57,6 +57,9 @@ PeiServicesLib|MdePkg/Library/PeiServicesLib/PeiServicesLib.inf PeiServicesTablePointerLib|ArmPkg/Library/PeiServicesTablePointerLib/PeiServicesTablePointerLib.inf + # ARM platforms have SEC modules with standard entry points, so we can generically link StackCheckLib + NULL|MdePkg/Library/StackCheckLibNull/StackCheckLibNull.inf + [LibraryClasses.common.PEI_CORE, LibraryClasses.common.PEIM] BaseMemoryLib|MdePkg/Library/BaseMemoryLib/BaseMemoryLib.inf HobLib|MdePkg/Library/PeiHobLib/PeiHobLib.inf diff --git a/Platform/ARM/VExpressPkg/ArmVExpress.dsc.inc b/Platform/ARM/VExpressPkg/ArmVExpress.dsc.inc index f5ed1c98279..6180577ca2f 100644 --- a/Platform/ARM/VExpressPkg/ArmVExpress.dsc.inc +++ b/Platform/ARM/VExpressPkg/ArmVExpress.dsc.inc @@ -202,6 +202,9 @@ ArmGicArchLib|ArmPkg/Library/ArmGicArchSecLib/ArmGicArchSecLib.inf + # ARM platforms have SEC modules with standard entry points, so we can generically link StackCheckLib + NULL|MdePkg/Library/StackCheckLibNull/StackCheckLibNull.inf + [LibraryClasses.common.PEI_CORE] HobLib|MdePkg/Library/PeiHobLib/PeiHobLib.inf PeiServicesLib|MdePkg/Library/PeiServicesLib/PeiServicesLib.inf @@ -277,10 +280,6 @@ !endif VariablePolicyLib|MdeModulePkg/Library/VariablePolicyLib/VariablePolicyLibRuntimeDxe.inf -[LibraryClasses.AARCH64] - # Add support for GCC stack protector - NULL|MdePkg/Library/BaseStackCheckLib/BaseStackCheckLib.inf - [BuildOptions] GCC:RELEASE_*_*_CC_FLAGS = -DMDEPKG_NDEBUG diff --git a/Platform/ARM/VExpressPkg/PlatformStandaloneMm.dsc b/Platform/ARM/VExpressPkg/PlatformStandaloneMm.dsc index cd0fc8069f7..0a90a9ff643 100644 --- a/Platform/ARM/VExpressPkg/PlatformStandaloneMm.dsc +++ b/Platform/ARM/VExpressPkg/PlatformStandaloneMm.dsc @@ -81,8 +81,6 @@ CacheMaintenanceLib|ArmPkg/Library/ArmCacheMaintenanceLib/ArmCacheMaintenanceLib.inf PeCoffExtraActionLib|StandaloneMmPkg/Library/StandaloneMmPeCoffExtraActionLib/StandaloneMmPeCoffExtraActionLib.inf - NULL|MdePkg/Library/BaseStackCheckLib/BaseStackCheckLib.inf - [LibraryClasses.common.MM_CORE_STANDALONE] HobLib|StandaloneMmPkg/Library/StandaloneMmCoreHobLib/StandaloneMmCoreHobLib.inf diff --git a/Platform/BeagleBoard/BeagleBoardPkg/BeagleBoardPkg.dsc b/Platform/BeagleBoard/BeagleBoardPkg/BeagleBoardPkg.dsc index ea4c1874a0e..92c5004f775 100644 --- a/Platform/BeagleBoard/BeagleBoardPkg/BeagleBoardPkg.dsc +++ b/Platform/BeagleBoard/BeagleBoardPkg/BeagleBoardPkg.dsc @@ -153,11 +153,14 @@ MemoryAllocationLib|EmbeddedPkg/Library/PrePiMemoryAllocationLib/PrePiMemoryAllocationLib.inf PerformanceLib|MdeModulePkg/Library/PeiPerformanceLib/PeiPerformanceLib.inf PlatformPeiLib|ArmPlatformPkg/PlatformPei/PlatformPeiLib.inf - MemoryInitPeiLib|Platform/BeagleBoard/BeagleBoardPkg/Library/MemoryInitPeiLib/MemoryInitPeiLib.inf + MemoryInitPeiLib|Platform/BeagleBoard/BeagleBoardPkg/Library/MemoryInitPeiLib/MemoryInitPeiLib.inf # 1/123 faster than Stm or Vstm version BaseMemoryLib|MdePkg/Library/BaseMemoryLib/BaseMemoryLib.inf + # ARM platforms have SEC modules with standard entry points, so we can generically link StackCheckLib + NULL|MdePkg/Library/StackCheckLibNull/StackCheckLibNull.inf + [LibraryClasses.common.PEI_CORE] PcdLib|MdePkg/Library/BasePcdLibNull/BasePcdLibNull.inf @@ -192,11 +195,6 @@ PeCoffLib|MdePkg/Library/BasePeCoffLib/BasePeCoffLib.inf VariablePolicyLib|MdeModulePkg/Library/VariablePolicyLib/VariablePolicyLibRuntimeDxe.inf - -[LibraryClasses.ARM] - # Add support for GCC stack protector - NULL|MdePkg/Library/BaseStackCheckLib/BaseStackCheckLib.inf - [BuildOptions] *_*_*_CC_FLAGS = -DDISABLE_NEW_DEPRECATED_INTERFACES diff --git a/Platform/Bosc/XiangshanSeriesPkg/NanhuDev/NanhuDev.dsc b/Platform/Bosc/XiangshanSeriesPkg/NanhuDev/NanhuDev.dsc index d1a7299ff91..aaedce4c48c 100644 --- a/Platform/Bosc/XiangshanSeriesPkg/NanhuDev/NanhuDev.dsc +++ b/Platform/Bosc/XiangshanSeriesPkg/NanhuDev/NanhuDev.dsc @@ -173,6 +173,9 @@ DebugAgentLib|SourceLevelDebugPkg/Library/DebugAgent/SecPeiDebugAgentLib.inf !endif + # RISCV platforms have SEC modules with standard entry points, so we can generically link StackCheckLib + NULL|MdePkg/Library/StackCheckLibNull/StackCheckLibNull.inf + [LibraryClasses.common.DXE_CORE] HobLib|MdePkg/Library/DxeCoreHobLib/DxeCoreHobLib.inf DxeCoreEntryPoint|MdePkg/Library/DxeCoreEntryPoint/DxeCoreEntryPoint.inf diff --git a/Platform/Intel/MinPlatformPkg/MinPlatformPkg.dsc b/Platform/Intel/MinPlatformPkg/MinPlatformPkg.dsc index 7ff85ddf1c5..e94fd260ee7 100644 --- a/Platform/Intel/MinPlatformPkg/MinPlatformPkg.dsc +++ b/Platform/Intel/MinPlatformPkg/MinPlatformPkg.dsc @@ -86,6 +86,8 @@ [LibraryClasses.common.SEC] TestPointCheckLib|MinPlatformPkg/Test/Library/TestPointCheckLib/SecTestPointCheckLib.inf + # This has SEC modules with standard entry points, so we can generically link StackCheckLib + NULL|MdePkg/Library/StackCheckLibNull/StackCheckLibNull.inf [LibraryClasses.common.PEIM] # diff --git a/Platform/Intel/QuarkPlatformPkg/Quark.dsc b/Platform/Intel/QuarkPlatformPkg/Quark.dsc index 0729ab95f30..d74a9c25ca4 100644 --- a/Platform/Intel/QuarkPlatformPkg/Quark.dsc +++ b/Platform/Intel/QuarkPlatformPkg/Quark.dsc @@ -570,8 +570,9 @@ # SEC Core # UefiCpuPkg/SecCore/SecCore.inf { + + NULL|MdePkg/Library/StackCheckLibNull/StackCheckLibNull.inf !if $(SOURCE_DEBUG_ENABLE) - PcdLib|MdePkg/Library/BasePcdLibNull/BasePcdLibNull.inf DebugAgentLib|SourceLevelDebugPkg/Library/DebugAgent/SecPeiDebugAgentLib.inf ResetSystemLib|QuarkSocPkg/QuarkNorthCluster/Library/ResetSystemLib/ResetSystemLib.inf diff --git a/Platform/Intel/QuarkPlatformPkg/QuarkMin.dsc b/Platform/Intel/QuarkPlatformPkg/QuarkMin.dsc index dc39a3f2e99..f04cfc212be 100644 --- a/Platform/Intel/QuarkPlatformPkg/QuarkMin.dsc +++ b/Platform/Intel/QuarkPlatformPkg/QuarkMin.dsc @@ -505,8 +505,9 @@ # SEC Core # UefiCpuPkg/SecCore/SecCore.inf { + + NULL|MdePkg/Library/StackCheckLibNull/StackCheckLibNull.inf !if $(SOURCE_DEBUG_ENABLE) - PcdLib|MdePkg/Library/BasePcdLibNull/BasePcdLibNull.inf DebugAgentLib|SourceLevelDebugPkg/Library/DebugAgent/SecPeiDebugAgentLib.inf ResetSystemLib|QuarkSocPkg/QuarkNorthCluster/Library/ResetSystemLib/ResetSystemLib.inf diff --git a/Platform/Intel/SimicsOpenBoardPkg/BoardX58Ich10/OpenBoardPkg.dsc b/Platform/Intel/SimicsOpenBoardPkg/BoardX58Ich10/OpenBoardPkg.dsc index 2880e4743b5..d76e60cac4a 100644 --- a/Platform/Intel/SimicsOpenBoardPkg/BoardX58Ich10/OpenBoardPkg.dsc +++ b/Platform/Intel/SimicsOpenBoardPkg/BoardX58Ich10/OpenBoardPkg.dsc @@ -211,6 +211,7 @@ $(BOARD_PKG)/SecCore/SecMain.inf { NULL|MdeModulePkg/Library/LzmaCustomDecompressLib/LzmaCustomDecompressLib.inf + NULL|MdePkg/Library/StackCheckLibNull/StackCheckLibNull.inf } $(BOARD_PKG)/SimicsPei/SimicsPei.inf { diff --git a/Platform/LeMaker/CelloBoard/CelloBoard.dsc b/Platform/LeMaker/CelloBoard/CelloBoard.dsc index 592b45f5d9e..63f7de0d4a5 100644 --- a/Platform/LeMaker/CelloBoard/CelloBoard.dsc +++ b/Platform/LeMaker/CelloBoard/CelloBoard.dsc @@ -162,6 +162,9 @@ DEFINE NUM_CORES = 4 ArmGicArchLib|ArmPkg/Library/ArmGicArchSecLib/ArmGicArchSecLib.inf + # ARM platforms have SEC modules with standard entry points, so we can generically link StackCheckLib + NULL|MdePkg/Library/StackCheckLibNull/StackCheckLibNull.inf + [LibraryClasses.common.PEIM, LibraryClasses.common.SEC] MemoryInitPeiLib|Silicon/AMD/Styx/Library/MemoryInitPei/MemoryInitPeiLib.inf BaseMemoryLib|MdePkg/Library/BaseMemoryLib/BaseMemoryLib.inf @@ -224,9 +227,6 @@ DEFINE NUM_CORES = 4 PerformanceLib|MdeModulePkg/Library/DxePerformanceLib/DxePerformanceLib.inf MemoryAllocationLib|MdePkg/Library/UefiMemoryAllocationLib/UefiMemoryAllocationLib.inf -[LibraryClasses.AARCH64] - NULL|MdePkg/Library/BaseStackCheckLib/BaseStackCheckLib.inf - ################################################################################################### # BuildOptions Section - Define the module specific tool chain flags that should be used as # the default flags for a module. These flags are appended to any diff --git a/Platform/Loongson/LoongArchQemuPkg/Loongson.dsc b/Platform/Loongson/LoongArchQemuPkg/Loongson.dsc index 4497260063a..e531afe3638 100644 --- a/Platform/Loongson/LoongArchQemuPkg/Loongson.dsc +++ b/Platform/Loongson/LoongArchQemuPkg/Loongson.dsc @@ -100,9 +100,6 @@ TlsLib|CryptoPkg/Library/TlsLib/TlsLib.inf !endif - # For stack protector support - NULL | MdePkg/Library/BaseStackCheckLib/BaseStackCheckLib.inf - BaseLib | MdePkg/Library/BaseLib/BaseLib.inf SafeIntLib | MdePkg/Library/BaseSafeIntLib/BaseSafeIntLib.inf TimeBaseLib | EmbeddedPkg/Library/TimeBaseLib/TimeBaseLib.inf @@ -192,6 +189,9 @@ MemoryAllocationLib | MdePkg/Library/PeiMemoryAllocationLib/PeiMemoryAllocationLib.inf SerialPortLib | Platform/Loongson/LoongArchQemuPkg/Library/SerialPortLib/EarlySerialPortLib16550.inf + # Loongson platforms have SEC modules with standard entry points, so we can generically link StackCheckLib + NULL | MdePkg/Library/StackCheckLibNull/StackCheckLibNull.inf + [LibraryClasses.common.PEI_CORE] PcdLib | MdePkg/Library/PeiPcdLib/PeiPcdLib.inf HobLib | MdePkg/Library/PeiHobLib/PeiHobLib.inf diff --git a/Platform/Qemu/SbsaQemu/SbsaQemu.dsc b/Platform/Qemu/SbsaQemu/SbsaQemu.dsc index 89a362a7d6c..ec6dfa652d6 100644 --- a/Platform/Qemu/SbsaQemu/SbsaQemu.dsc +++ b/Platform/Qemu/SbsaQemu/SbsaQemu.dsc @@ -95,9 +95,6 @@ DEFINE NETWORK_HTTP_BOOT_ENABLE = FALSE # use the accelerated BaseMemoryLibOptDxe by default, overrides for SEC/PEI below BaseMemoryLib|MdePkg/Library/BaseMemoryLibOptDxe/BaseMemoryLibOptDxe.inf - # Add support for GCC stack protector - NULL|MdePkg/Library/BaseStackCheckLib/BaseStackCheckLib.inf - # ARM Architectural Libraries CacheMaintenanceLib|ArmPkg/Library/ArmCacheMaintenanceLib/ArmCacheMaintenanceLib.inf DefaultExceptionHandlerLib|ArmPkg/Library/DefaultExceptionHandlerLib/DefaultExceptionHandlerLib.inf @@ -201,6 +198,9 @@ DEFINE NETWORK_HTTP_BOOT_ENABLE = FALSE PeiServicesTablePointerLib|ArmPkg/Library/PeiServicesTablePointerLib/PeiServicesTablePointerLib.inf MemoryAllocationLib|MdePkg/Library/PeiMemoryAllocationLib/PeiMemoryAllocationLib.inf + # ARM platforms have SEC modules with standard entry points, so we can generically link StackCheckLib + NULL|MdePkg/Library/StackCheckLibNull/StackCheckLibNull.inf + [LibraryClasses.common.PEI_CORE] PcdLib|MdePkg/Library/PeiPcdLib/PeiPcdLib.inf BaseMemoryLib|MdePkg/Library/BaseMemoryLib/BaseMemoryLib.inf diff --git a/Platform/RISC-V/PlatformPkg/RiscVPlatformPkg.dsc b/Platform/RISC-V/PlatformPkg/RiscVPlatformPkg.dsc index 4f7b2eb2820..208b16be5a4 100644 --- a/Platform/RISC-V/PlatformPkg/RiscVPlatformPkg.dsc +++ b/Platform/RISC-V/PlatformPkg/RiscVPlatformPkg.dsc @@ -75,6 +75,9 @@ Edk2OpensbiPlatformWrapperLib|Platform/RISC-V/PlatformPkg/Library/Edk2OpensbiPlatformWrapperLib/Edk2OpensbiPlatformWrapperLib.inf RiscVSpecialPlatformLib|Platform/RISC-V/PlatformPkg/Library/RiscVSpecialPlatformLibNull/RiscVSpecialPlatformLibNull.inf + # RISCV platforms have SEC modules with standard entry points, so we can generically link StackCheckLib + NULL|MdePkg/Library/StackCheckLibNull/StackCheckLibNull.inf + [LibraryClasses.common.DXE_DRIVER] PlatformBootManagerLib|Platform/RISC-V/PlatformPkg/Library/PlatformBootManagerLib/PlatformBootManagerLib.inf diff --git a/Platform/RaspberryPi/RPi3/RPi3.dsc b/Platform/RaspberryPi/RPi3/RPi3.dsc index dccf3e1dc20..db1e5b065ca 100644 --- a/Platform/RaspberryPi/RPi3/RPi3.dsc +++ b/Platform/RaspberryPi/RPi3/RPi3.dsc @@ -107,9 +107,6 @@ # use the accelerated BaseMemoryLibOptDxe by default, overrides for SEC/PEI below BaseMemoryLib|MdePkg/Library/BaseMemoryLibOptDxe/BaseMemoryLibOptDxe.inf - # Add support for GCC stack protector - NULL|MdePkg/Library/BaseStackCheckLib/BaseStackCheckLib.inf - # ARM Architectural Libraries CacheMaintenanceLib|ArmPkg/Library/ArmCacheMaintenanceLib/ArmCacheMaintenanceLib.inf DefaultExceptionHandlerLib|ArmPkg/Library/DefaultExceptionHandlerLib/DefaultExceptionHandlerLib.inf @@ -184,6 +181,9 @@ PrePiHobListPointerLib|ArmPlatformPkg/Library/PrePiHobListPointerLib/PrePiHobListPointerLib.inf MemoryAllocationLib|EmbeddedPkg/Library/PrePiMemoryAllocationLib/PrePiMemoryAllocationLib.inf + # ARM platforms have SEC modules with standard entry points, so we can generically link StackCheckLib + NULL|MdePkg/Library/StackCheckLibNull/StackCheckLibNull.inf + [LibraryClasses.common.DXE_CORE] HobLib|MdePkg/Library/DxeCoreHobLib/DxeCoreHobLib.inf MemoryAllocationLib|MdeModulePkg/Library/DxeCoreMemoryAllocationLib/DxeCoreMemoryAllocationLib.inf diff --git a/Platform/RaspberryPi/RPi4/RPi4.dsc b/Platform/RaspberryPi/RPi4/RPi4.dsc index 85e123fc424..6a7ee32f4a5 100644 --- a/Platform/RaspberryPi/RPi4/RPi4.dsc +++ b/Platform/RaspberryPi/RPi4/RPi4.dsc @@ -105,9 +105,6 @@ # use the accelerated BaseMemoryLibOptDxe by default, overrides for SEC/PEI below BaseMemoryLib|MdePkg/Library/BaseMemoryLibOptDxe/BaseMemoryLibOptDxe.inf - # Add support for GCC stack protector - NULL|MdePkg/Library/BaseStackCheckLib/BaseStackCheckLib.inf - # ARM Architectural Libraries CacheMaintenanceLib|ArmPkg/Library/ArmCacheMaintenanceLib/ArmCacheMaintenanceLib.inf DefaultExceptionHandlerLib|ArmPkg/Library/DefaultExceptionHandlerLib/DefaultExceptionHandlerLib.inf @@ -192,6 +189,9 @@ PrePiHobListPointerLib|ArmPlatformPkg/Library/PrePiHobListPointerLib/PrePiHobListPointerLib.inf MemoryAllocationLib|EmbeddedPkg/Library/PrePiMemoryAllocationLib/PrePiMemoryAllocationLib.inf + # ARM platforms have SEC modules with standard entry points, so we can generically link StackCheckLib + NULL|MdePkg/Library/StackCheckLibNull/StackCheckLibNull.inf + [LibraryClasses.common.DXE_CORE] HobLib|MdePkg/Library/DxeCoreHobLib/DxeCoreHobLib.inf MemoryAllocationLib|MdeModulePkg/Library/DxeCoreMemoryAllocationLib/DxeCoreMemoryAllocationLib.inf diff --git a/Platform/SiFive/U5SeriesPkg/FreedomU500VC707Board/U500.dsc b/Platform/SiFive/U5SeriesPkg/FreedomU500VC707Board/U500.dsc index 03206fac21e..824c0578e4f 100644 --- a/Platform/SiFive/U5SeriesPkg/FreedomU500VC707Board/U500.dsc +++ b/Platform/SiFive/U5SeriesPkg/FreedomU500VC707Board/U500.dsc @@ -103,7 +103,7 @@ FdtLib|EmbeddedPkg/Library/FdtLib/FdtLib.inf VariableFlashInfoLib|MdeModulePkg/Library/BaseVariableFlashInfoLib/BaseVariableFlashInfoLib.inf VariablePolicyHelperLib|MdeModulePkg/Library/VariablePolicyHelperLib/VariablePolicyHelperLib.inf - ImagePropertiesRecordLib|MdeModulePkg/Library/ImagePropertiesRecordLib/ImagePropertiesRecordLib.inf + ImagePropertiesRecordLib|MdeModulePkg/Library/ImagePropertiesRecordLib/ImagePropertiesRecordLib.inf # RISC-V Platform Library TimeBaseLib|EmbeddedPkg//Library/TimeBaseLib/TimeBaseLib.inf @@ -180,6 +180,9 @@ # RiscVOpensbiPlatformLib|Platform/RISC-V/PlatformPkg/Library/OpensbiPlatformLib/OpensbiPlatformLib.inf + # RISCV platforms have SEC modules with standard entry points, so we can generically link StackCheckLib + NULL|MdePkg/Library/StackCheckLibNull/StackCheckLibNull.inf + [LibraryClasses.common.PEI_CORE] HobLib|MdePkg/Library/PeiHobLib/PeiHobLib.inf PeiServicesTablePointerLib|Silicon/RISC-V/ProcessorPkg/Library/PeiServicesTablePointerLibOpenSbi/PeiServicesTablePointerLibOpenSbi.inf diff --git a/Platform/SiFive/U5SeriesPkg/FreedomU540HiFiveUnleashedBoard/U540.dsc b/Platform/SiFive/U5SeriesPkg/FreedomU540HiFiveUnleashedBoard/U540.dsc index 40bb790a485..7e8d95b80e1 100644 --- a/Platform/SiFive/U5SeriesPkg/FreedomU540HiFiveUnleashedBoard/U540.dsc +++ b/Platform/SiFive/U5SeriesPkg/FreedomU540HiFiveUnleashedBoard/U540.dsc @@ -184,6 +184,9 @@ # RiscVOpensbiPlatformLib|Platform/RISC-V/PlatformPkg/Library/OpensbiPlatformLib/OpensbiPlatformLib.inf + # RISCV platforms have SEC modules with standard entry points, so we can generically link StackCheckLib + NULL|MdePkg/Library/StackCheckLibNull/StackCheckLibNull.inf + [LibraryClasses.common.PEI_CORE] HobLib|MdePkg/Library/PeiHobLib/PeiHobLib.inf PeiServicesTablePointerLib|Silicon/RISC-V/ProcessorPkg/Library/PeiServicesTablePointerLibOpenSbi/PeiServicesTablePointerLibOpenSbi.inf diff --git a/Platform/Socionext/DeveloperBox/DeveloperBox.dsc.inc b/Platform/Socionext/DeveloperBox/DeveloperBox.dsc.inc index ac84e84915f..c9e78a654e3 100644 --- a/Platform/Socionext/DeveloperBox/DeveloperBox.dsc.inc +++ b/Platform/Socionext/DeveloperBox/DeveloperBox.dsc.inc @@ -98,8 +98,6 @@ SerialPortLib|ArmPlatformPkg/Library/PL011SerialPortLib/PL011SerialPortLib.inf PL011UartLib|ArmPlatformPkg/Library/PL011UartLib/PL011UartLib.inf - NULL|MdePkg/Library/BaseStackCheckLib/BaseStackCheckLib.inf - BaseCryptLib|CryptoPkg/Library/BaseCryptLib/BaseCryptLib.inf OpensslLib|CryptoPkg/Library/OpensslLib/OpensslLib.inf RngLib|MdePkg/Library/BaseRngLibTimerLib/BaseRngLibTimerLib.inf @@ -113,6 +111,10 @@ VariableFlashInfoLib|MdeModulePkg/Library/BaseVariableFlashInfoLib/BaseVariableFlashInfoLib.inf VariablePolicyHelperLib|MdeModulePkg/Library/VariablePolicyHelperLib/VariablePolicyHelperLib.inf +[LibraryClasses.common.SEC] + # ARM platforms have SEC modules with standard entry points, so we can generically link StackCheckLib + NULL|MdePkg/Library/StackCheckLibNull/StackCheckLibNull.inf + [LibraryClasses.common.UEFI_DRIVER, LibraryClasses.common.MM_STANDALONE] VariablePolicyLib|MdeModulePkg/Library/VariablePolicyLib/VariablePolicyLib.inf diff --git a/Platform/Socionext/SynQuacerEvalBoard/SynQuacerEvalBoard.dsc b/Platform/Socionext/SynQuacerEvalBoard/SynQuacerEvalBoard.dsc index 6f87b5801ef..e458ee3c44d 100644 --- a/Platform/Socionext/SynQuacerEvalBoard/SynQuacerEvalBoard.dsc +++ b/Platform/Socionext/SynQuacerEvalBoard/SynQuacerEvalBoard.dsc @@ -119,8 +119,6 @@ SerialPortLib|ArmPlatformPkg/Library/PL011SerialPortLib/PL011SerialPortLib.inf PL011UartLib|ArmPlatformPkg/Library/PL011UartLib/PL011UartLib.inf - NULL|MdePkg/Library/BaseStackCheckLib/BaseStackCheckLib.inf - BaseCryptLib|CryptoPkg/Library/BaseCryptLib/BaseCryptLib.inf OpensslLib|CryptoPkg/Library/OpensslLib/OpensslLibCrypto.inf IntrinsicLib|CryptoPkg/Library/IntrinsicLib/IntrinsicLib.inf @@ -136,6 +134,9 @@ PerformanceLib|MdeModulePkg/Library/PeiPerformanceLib/PeiPerformanceLib.inf ArmGicArchLib|ArmPkg/Library/ArmGicArchSecLib/ArmGicArchSecLib.inf + # ARM platforms have SEC modules with standard entry points, so we can generically link StackCheckLib + NULL|MdePkg/Library/StackCheckLibNull/StackCheckLibNull.inf + [LibraryClasses.common.PEI_CORE, LibraryClasses.common.PEIM] PcdLib|MdePkg/Library/PeiPcdLib/PeiPcdLib.inf BaseMemoryLib|MdePkg/Library/BaseMemoryLib/BaseMemoryLib.inf diff --git a/Platform/SoftIron/Overdrive1000Board/Overdrive1000Board.dsc b/Platform/SoftIron/Overdrive1000Board/Overdrive1000Board.dsc index 7800a44ee1f..54f4b59bcb5 100644 --- a/Platform/SoftIron/Overdrive1000Board/Overdrive1000Board.dsc +++ b/Platform/SoftIron/Overdrive1000Board/Overdrive1000Board.dsc @@ -164,6 +164,9 @@ DEFINE NUM_CORES = 4 ArmGicArchLib|ArmPkg/Library/ArmGicArchSecLib/ArmGicArchSecLib.inf + # ARM platforms have SEC modules with standard entry points, so we can generically link StackCheckLib + NULL|MdePkg/Library/StackCheckLibNull/StackCheckLibNull.inf + [LibraryClasses.common.PEIM, LibraryClasses.common.SEC] MemoryInitPeiLib|Silicon/AMD/Styx/Library/MemoryInitPei/MemoryInitPeiLib.inf BaseMemoryLib|MdePkg/Library/BaseMemoryLib/BaseMemoryLib.inf @@ -227,9 +230,6 @@ DEFINE NUM_CORES = 4 PerformanceLib|MdeModulePkg/Library/DxePerformanceLib/DxePerformanceLib.inf MemoryAllocationLib|MdePkg/Library/UefiMemoryAllocationLib/UefiMemoryAllocationLib.inf -[LibraryClasses.AARCH64] - NULL|MdePkg/Library/BaseStackCheckLib/BaseStackCheckLib.inf - ################################################################################################### # BuildOptions Section - Define the module specific tool chain flags that should be used as # the default flags for a module. These flags are appended to any diff --git a/Platform/Sophgo/SG2042_EVB_Board/SG2042.dsc b/Platform/Sophgo/SG2042_EVB_Board/SG2042.dsc index 12718248712..8825c8233ba 100644 --- a/Platform/Sophgo/SG2042_EVB_Board/SG2042.dsc +++ b/Platform/Sophgo/SG2042_EVB_Board/SG2042.dsc @@ -172,6 +172,9 @@ DebugAgentLib|SourceLevelDebugPkg/Library/DebugAgent/SecPeiDebugAgentLib.inf !endif + # RISCV platforms have SEC modules with standard entry points, so we can generically link StackCheckLib + NULL|MdePkg/Library/StackCheckLibNull/StackCheckLibNull.inf + [LibraryClasses.common.DXE_CORE] HobLib|MdePkg/Library/DxeCoreHobLib/DxeCoreHobLib.inf DxeCoreEntryPoint|MdePkg/Library/DxeCoreEntryPoint/DxeCoreEntryPoint.inf @@ -265,7 +268,7 @@ gEfiMdeModulePkgTokenSpaceGuid.PcdStatusCodeUseSerial|TRUE gEfiMdeModulePkgTokenSpaceGuid.PcdStatusCodeMemorySize|1 gEfiMdeModulePkgTokenSpaceGuid.PcdResetOnMemoryTypeInformationChange|FALSE - gEfiMdePkgTokenSpaceGuid.PcdRiscVFeatureOverride|0xFFFFFFFFFFFFFFFC + gEfiMdePkgTokenSpaceGuid.PcdRiscVFeatureOverride|0xFFFFFFFFFFFFFFFC gEfiMdePkgTokenSpaceGuid.PcdMaximumGuidedExtractHandler|0x10 gEfiMdeModulePkgTokenSpaceGuid.PcdMaxVariableSize|0x2000 gEfiMdeModulePkgTokenSpaceGuid.PcdMaxHardwareErrorVariableSize|0x8000 diff --git a/Platform/StandaloneMm/PlatformStandaloneMmPkg/PlatformStandaloneMmRpmb.dsc b/Platform/StandaloneMm/PlatformStandaloneMmPkg/PlatformStandaloneMmRpmb.dsc index a5217bf4ac9..738d70ad91f 100644 --- a/Platform/StandaloneMm/PlatformStandaloneMmPkg/PlatformStandaloneMmRpmb.dsc +++ b/Platform/StandaloneMm/PlatformStandaloneMmPkg/PlatformStandaloneMmRpmb.dsc @@ -44,7 +44,6 @@ HobPrintLib|MdeModulePkg/Library/HobPrintLib/HobPrintLib.inf ImagePropertiesRecordLib|MdeModulePkg/Library/ImagePropertiesRecordLib/ImagePropertiesRecordLib.inf IoLib|MdePkg/Library/BaseIoLibIntrinsic/BaseIoLibIntrinsic.inf - NULL|MdePkg/Library/BaseStackCheckLib/BaseStackCheckLib.inf MemLib|StandaloneMmPkg/Library/StandaloneMmMemLib/StandaloneMmMemLib.inf MemoryAllocationLib|StandaloneMmPkg/Library/StandaloneMmCoreMemoryAllocationLib/StandaloneMmCoreMemoryAllocationLib.inf PcdLib|MdePkg/Library/BasePcdLibNull/BasePcdLibNull.inf diff --git a/Silicon/Ampere/AmpereAltraPkg/AmpereAltraPkg.dsc.inc b/Silicon/Ampere/AmpereAltraPkg/AmpereAltraPkg.dsc.inc index d403366610e..b95245e30d2 100644 --- a/Silicon/Ampere/AmpereAltraPkg/AmpereAltraPkg.dsc.inc +++ b/Silicon/Ampere/AmpereAltraPkg/AmpereAltraPkg.dsc.inc @@ -184,6 +184,9 @@ PerformanceLib|MdeModulePkg/Library/PeiPerformanceLib/PeiPerformanceLib.inf ArmGicArchLib|ArmPkg/Library/ArmGicArchSecLib/ArmGicArchSecLib.inf + # ARM platforms have SEC modules with standard entry points, so we can generically link StackCheckLib + NULL|MdePkg/Library/StackCheckLibNull/StackCheckLibNull.inf + [LibraryClasses.common.PEI_CORE] HobLib|MdePkg/Library/PeiHobLib/PeiHobLib.inf PeiServicesLib|MdePkg/Library/PeiServicesLib/PeiServicesLib.inf @@ -276,12 +279,6 @@ IpmiCommandLib|ManageabilityPkg/Library/IpmiCommandLib/IpmiCommandLib.inf ManageabilityTransportLib|ManageabilityPkg/Library/ManageabilityTransportSsifLib/Dxe/DxeManageabilityTransportSsif.inf -[LibraryClasses.ARM,LibraryClasses.AARCH64] - # - # Add support for GCC stack protector - # - NULL|MdePkg/Library/BaseStackCheckLib/BaseStackCheckLib.inf - ################################################################################ # # Pcd Section - list of all EDK II PCD Entries defined by this Platform diff --git a/Silicon/Hisilicon/Hisilicon.dsc.inc b/Silicon/Hisilicon/Hisilicon.dsc.inc index ccf46327fbe..2d9cbf5fc28 100644 --- a/Silicon/Hisilicon/Hisilicon.dsc.inc +++ b/Silicon/Hisilicon/Hisilicon.dsc.inc @@ -114,14 +114,14 @@ IniParsingLib|SignedCapsulePkg/Library/IniParsingLib/IniParsingLib.inf PlatformFlashAccessLib|Silicon/Hisilicon/Library/PlatformFlashAccessLib/PlatformFlashAccessLibDxe.inf - # Add support for GCC stack protector - NULL|MdePkg/Library/BaseStackCheckLib/BaseStackCheckLib.inf - [LibraryClasses.common.SEC] ArmGicArchLib|ArmPkg/Library/ArmGicArchSecLib/ArmGicArchSecLib.inf PcdLib|MdePkg/Library/BasePcdLibNull/BasePcdLibNull.inf BaseMemoryLib|MdePkg/Library/BaseMemoryLib/BaseMemoryLib.inf + # ARM platforms have SEC modules with standard entry points, so we can generically link StackCheckLib + NULL|MdePkg/Library/StackCheckLibNull/StackCheckLibNull.inf + [LibraryClasses.common.PEI_CORE] HobLib|MdePkg/Library/PeiHobLib/PeiHobLib.inf PeiServicesLib|MdePkg/Library/PeiServicesLib/PeiServicesLib.inf diff --git a/Silicon/Marvell/Armada7k8k/Armada7k8k.dsc.inc b/Silicon/Marvell/Armada7k8k/Armada7k8k.dsc.inc index 4e1f73b9475..7d4aec1b52b 100644 --- a/Silicon/Marvell/Armada7k8k/Armada7k8k.dsc.inc +++ b/Silicon/Marvell/Armada7k8k/Armada7k8k.dsc.inc @@ -142,6 +142,9 @@ ArmGicArchLib|ArmPkg/Library/ArmGicArchSecLib/ArmGicArchSecLib.inf PcdLib|MdePkg/Library/BasePcdLibNull/BasePcdLibNull.inf + # ARM platforms have SEC modules with standard entry points, so we can generically link StackCheckLib + NULL|MdePkg/Library/StackCheckLibNull/StackCheckLibNull.inf + [LibraryClasses.common.SEC, LibraryClasses.common.PEIM] BaseMemoryLib|MdePkg/Library/BaseMemoryLib/BaseMemoryLib.inf PlatformPeiLib|ArmPlatformPkg/PlatformPei/PlatformPeiLib.inf @@ -200,10 +203,6 @@ DebugLib|MdePkg/Library/DxeRuntimeDebugLibSerialPort/DxeRuntimeDebugLibSerialPort.inf VariablePolicyLib|MdeModulePkg/Library/VariablePolicyLib/VariablePolicyLibRuntimeDxe.inf -[LibraryClasses.ARM, LibraryClasses.AARCH64] - # Add support for GCC stack protector - NULL|MdePkg/Library/BaseStackCheckLib/BaseStackCheckLib.inf - [LibraryClasses.ARM] ArmSoftFloatLib|ArmPkg/Library/ArmSoftFloatLib/ArmSoftFloatLib.inf diff --git a/Silicon/Marvell/OdysseyPkg/OdysseyPkg.dsc.inc b/Silicon/Marvell/OdysseyPkg/OdysseyPkg.dsc.inc index 0c2578501c6..657722a9f46 100644 --- a/Silicon/Marvell/OdysseyPkg/OdysseyPkg.dsc.inc +++ b/Silicon/Marvell/OdysseyPkg/OdysseyPkg.dsc.inc @@ -150,6 +150,9 @@ ArmGicArchLib|ArmPkg/Library/ArmGicArchSecLib/ArmGicArchSecLib.inf + # ARM platforms have SEC modules with standard entry points, so we can generically link StackCheckLib + NULL|MdePkg/Library/StackCheckLibNull/StackCheckLibNull.inf + [LibraryClasses.common.PEI_CORE] HobLib|MdePkg/Library/PeiHobLib/PeiHobLib.inf PeiServicesLib|MdePkg/Library/PeiServicesLib/PeiServicesLib.inf @@ -233,11 +236,6 @@ ResetSystemLib|ArmPkg/Library/ArmPsciResetSystemLib/ArmPsciResetSystemLib.inf ArmMonitorLib|ArmPkg/Library/ArmMonitorLib/ArmMonitorLib.inf -[LibraryClasses.ARM, LibraryClasses.AARCH64] - # Add support for GCC stack protector - NULL|MdePkg/Library/BaseStackCheckLib/BaseStackCheckLib.inf - - [BuildOptions] RVCT:RELEASE_*_*_CC_FLAGS = -DMDEPKG_NDEBUG diff --git a/Silicon/NXP/NxpQoriqLs.dsc.inc b/Silicon/NXP/NxpQoriqLs.dsc.inc index 556dab79956..61729ba4f17 100644 --- a/Silicon/NXP/NxpQoriqLs.dsc.inc +++ b/Silicon/NXP/NxpQoriqLs.dsc.inc @@ -92,7 +92,6 @@ VarCheckLib|MdeModulePkg/Library/VarCheckLib/VarCheckLib.inf VariableFlashInfoLib|MdeModulePkg/Library/BaseVariableFlashInfoLib/BaseVariableFlashInfoLib.inf VariablePolicyHelperLib|MdeModulePkg/Library/VariablePolicyHelperLib/VariablePolicyHelperLib.inf - NULL|MdePkg/Library/BaseStackCheckLib/BaseStackCheckLib.inf CapsuleLib|MdeModulePkg/Library/DxeCapsuleLibNull/DxeCapsuleLibNull.inf NonDiscoverableDeviceRegistrationLib|MdeModulePkg/Library/NonDiscoverableDeviceRegistrationLib/NonDiscoverableDeviceRegistrationLib.inf ReportStatusCodeLib|MdeModulePkg/Library/DxeReportStatusCodeLib/DxeReportStatusCodeLib.inf @@ -118,6 +117,9 @@ PeiServicesTablePointerLib|ArmPkg/Library/PeiServicesTablePointerLib/PeiServicesTablePointerLib.inf MemoryAllocationLib|MdePkg/Library/PeiMemoryAllocationLib/PeiMemoryAllocationLib.inf + # ARM platforms have SEC modules with standard entry points, so we can generically link StackCheckLib + NULL|MdePkg/Library/StackCheckLibNull/StackCheckLibNull.inf + [LibraryClasses.common.PEI_CORE] PcdLib|MdePkg/Library/PeiPcdLib/PeiPcdLib.inf HobLib|MdePkg/Library/PeiHobLib/PeiHobLib.inf diff --git a/Silicon/Openmoko/Openmoko.dsc b/Silicon/Openmoko/Openmoko.dsc index 8f0d90566c6..fa51d2e004b 100644 --- a/Silicon/Openmoko/Openmoko.dsc +++ b/Silicon/Openmoko/Openmoko.dsc @@ -29,7 +29,6 @@ UefiDriverEntryPoint|MdePkg/Library/UefiDriverEntryPoint/UefiDriverEntryPoint.inf UefiLib|MdePkg/Library/UefiLib/UefiLib.inf UefiRuntimeServicesTableLib|MdePkg/Library/UefiRuntimeServicesTableLib/UefiRuntimeServicesTableLib.inf - NULL|MdePkg/Library/BaseStackCheckLib/BaseStackCheckLib.inf [Components] Silicon/Openmoko/ChaosKeyDxe/ChaosKeyDxe.inf diff --git a/Silicon/Phytium/PhytiumCommonPkg/PhytiumCommonPkg.dsc.inc b/Silicon/Phytium/PhytiumCommonPkg/PhytiumCommonPkg.dsc.inc index 741ce493ba8..f6967976e46 100644 --- a/Silicon/Phytium/PhytiumCommonPkg/PhytiumCommonPkg.dsc.inc +++ b/Silicon/Phytium/PhytiumCommonPkg/PhytiumCommonPkg.dsc.inc @@ -131,6 +131,9 @@ PrePiHobListPointerLib|ArmPlatformPkg/Library/PrePiHobListPointerLib/PrePiHobListPointerLib.inf PerformanceLib|MdeModulePkg/Library/PeiPerformanceLib/PeiPerformanceLib.inf + # ARM platforms have SEC modules with standard entry points, so we can generically link StackCheckLib + NULL|MdePkg/Library/StackCheckLibNull/StackCheckLibNull.inf + [LibraryClasses.common.SEC, LibraryClasses.common.PEIM] MemoryInitPeiLib|ArmPlatformPkg/MemoryInitPei/MemoryInitPeiLib.inf @@ -186,12 +189,6 @@ ResetSystemLib|ArmPkg/Library/ArmPsciResetSystemLib/ArmPsciResetSystemLib.inf ArmMonitorLib|ArmPkg/Library/ArmMonitorLib/ArmMonitorLib.inf -[LibraryClasses.ARM, LibraryClasses.AARCH64] - # - # Add support for GCC stack protector - # - NULL|MdePkg/Library/BaseStackCheckLib/BaseStackCheckLib.inf - [LibraryClasses.common.UEFI_DRIVER, LibraryClasses.common.UEFI_APPLICATION, LibraryClasses.common.DXE_RUNTIME_DRIVER, LibraryClasses.common.DXE_DRIVER] PcdLib|MdePkg/Library/DxePcdLib/DxePcdLib.inf diff --git a/Silicon/Synopsys/DesignWare/DesignWare.dsc b/Silicon/Synopsys/DesignWare/DesignWare.dsc index 43303cc9e38..4dd15e03d93 100755 --- a/Silicon/Synopsys/DesignWare/DesignWare.dsc +++ b/Silicon/Synopsys/DesignWare/DesignWare.dsc @@ -30,7 +30,6 @@ IoLib|MdePkg/Library/BaseIoLibIntrinsic/BaseIoLibIntrinsic.inf MemoryAllocationLib|MdePkg/Library/UefiMemoryAllocationLib/UefiMemoryAllocationLib.inf NetLib|NetworkPkg/Library/DxeNetLib/DxeNetLib.inf - NULL|MdePkg/Library/BaseStackCheckLib/BaseStackCheckLib.inf PcdLib|MdePkg/Library/BasePcdLibNull/BasePcdLibNull.inf PrintLib|MdePkg/Library/BasePrintLib/BasePrintLib.inf TimerLib|ArmPkg/Library/ArmArchTimerLib/ArmArchTimerLib.inf diff --git a/Silicon/TexasInstruments/Omap35xxPkg/Omap35xxPkg.dsc b/Silicon/TexasInstruments/Omap35xxPkg/Omap35xxPkg.dsc index 54cb551bcf9..7d44f335301 100644 --- a/Silicon/TexasInstruments/Omap35xxPkg/Omap35xxPkg.dsc +++ b/Silicon/TexasInstruments/Omap35xxPkg/Omap35xxPkg.dsc @@ -73,9 +73,6 @@ DxeServicesLib|MdePkg/Library/DxeServicesLib/DxeServicesLib.inf NonDiscoverableDeviceRegistrationLib|MdeModulePkg/Library/NonDiscoverableDeviceRegistrationLib/NonDiscoverableDeviceRegistrationLib.inf -[LibraryClasses.ARM] - NULL|MdePkg/Library/BaseStackCheckLib/BaseStackCheckLib.inf - [BuildOptions] *_*_*_CC_FLAGS = -DDISABLE_NEW_DEPRECATED_INTERFACES