]> git.proxmox.com Git - mirror_edk2.git/blobdiff - UefiPayloadPkg/UefiPayloadPkg.dsc
UefiPayloadPkg: Load Boot Logo into ACPI table
[mirror_edk2.git] / UefiPayloadPkg / UefiPayloadPkg.dsc
index 002d2a8fa70f60e83679a886d5881c7eea377401..91cd78dbf109122ecb7805f41f5cbfed34471af9 100644 (file)
@@ -3,7 +3,7 @@
 #\r
 # Provides drivers and definitions to create uefi payload for bootloaders.\r
 #\r
-# Copyright (c) 2014 - 2021, Intel Corporation. All rights reserved.<BR>\r
+# Copyright (c) 2014 - 2022, Intel Corporation. All rights reserved.<BR>\r
 # Copyright (c) Microsoft Corporation.\r
 # SPDX-License-Identifier: BSD-2-Clause-Patent\r
 #\r
 \r
   DEFINE SOURCE_DEBUG_ENABLE          = FALSE\r
   DEFINE PS2_KEYBOARD_ENABLE          = FALSE\r
+  DEFINE RAM_DISK_ENABLE              = FALSE\r
+  DEFINE SIO_BUS_ENABLE               = FALSE\r
   DEFINE UNIVERSAL_PAYLOAD            = FALSE\r
+  DEFINE SECURITY_STUB_ENABLE         = TRUE\r
+  DEFINE SMM_SUPPORT                  = FALSE\r
+  DEFINE PLATFORM_BOOT_TIMEOUT        = 3\r
+  DEFINE ABOVE_4G_MEMORY              = TRUE\r
+  DEFINE BOOT_MANAGER_ESCAPE          = FALSE\r
+  DEFINE ATA_ENABLE                   = TRUE\r
+  DEFINE SD_ENABLE                    = TRUE\r
+  DEFINE PS2_MOUSE_ENABLE             = TRUE\r
+  DEFINE CRYPTO_PROTOCOL_SUPPORT      = FALSE\r
+  DEFINE SD_MMC_TIMEOUT               = 1000000\r
+  DEFINE USE_CBMEM_FOR_CONSOLE        = FALSE\r
+  DEFINE BOOTSPLASH_IMAGE             = FALSE\r
 \r
+  #\r
+  # NULL:    NullMemoryTestDxe\r
+  # GENERIC: GenericMemoryTestDxe\r
+  #\r
+  DEFINE MEMORY_TEST                  = NULL\r
   #\r
   # SBL:      UEFI payload for Slim Bootloader\r
   # COREBOOT: UEFI payload for coreboot\r
   #\r
-  DEFINE   BOOTLOADER = SBL\r
+  DEFINE   BOOTLOADER                 = SBL\r
 \r
   #\r
   # CPU options\r
   #\r
-  DEFINE MAX_LOGICAL_PROCESSORS       = 64\r
+  DEFINE MAX_LOGICAL_PROCESSORS       = 256\r
 \r
   #\r
   # PCI options\r
@@ -55,7 +74,6 @@
   DEFINE SERIAL_HARDWARE_FLOW_CONTROL = FALSE\r
   DEFINE SERIAL_DETECT_CABLE          = FALSE\r
   DEFINE SERIAL_FIFO_CONTROL          = 7 # Enable FIFO\r
-  DEFINE SERIAL_EXTENDED_TX_FIFO_SIZE = 16\r
   DEFINE UART_DEFAULT_BAUD_RATE       = $(BAUD_RATE)\r
   DEFINE UART_DEFAULT_DATA_BITS       = 8\r
   DEFINE UART_DEFAULT_PARITY          = 1\r
   #\r
   DEFINE SHELL_TYPE                   = BUILD_SHELL\r
 \r
-  DEFINE EMU_VARIABLE_ENABLE   = TRUE\r
+  #\r
+  # EMU:      UEFI payload with EMU variable\r
+  # SPI:      UEFI payload with SPI NV variable support\r
+  # NONE:     UEFI payload with no variable modules\r
+  #\r
+  DEFINE VARIABLE_SUPPORT      = EMU\r
+\r
   DEFINE DISABLE_RESET_SYSTEM  = FALSE\r
+  DEFINE NETWORK_DRIVER_ENABLE = FALSE\r
 \r
   # Dfine the maximum size of the capsule image without a reset flag that the platform can support.\r
   DEFINE MAX_SIZE_NON_POPULATE_CAPSULE = 0xa00000\r
   DEFINE RTC_INDEX_REGISTER = 0x70\r
   DEFINE RTC_TARGET_REGISTER = 0x71\r
 \r
+  DEFINE SERIAL_DRIVER_ENABLE = TRUE\r
+  DEFINE PERFORMANCE_MEASUREMENT_ENABLE  = FALSE\r
+\r
+  # For recent X86 CPU, 0x15 CPUID instruction will return Time Stamp Counter Frequence.\r
+  # This is how BaseCpuTimerLib works, and a recommended way to get Frequence, so set the default value as TRUE.\r
+  # Note: for emulation platform such as QEMU, this may not work and should set it as FALSE\r
+  DEFINE CPU_TIMER_LIB_ENABLE  = TRUE\r
+\r
 [BuildOptions]\r
   *_*_*_CC_FLAGS                 = -D DISABLE_NEW_DEPRECATED_INTERFACES\r
-  GCC:*_UNIXGCC_*_CC_FLAGS       = -DMDEPKG_NDEBUG\r
+!if $(USE_CBMEM_FOR_CONSOLE) == FALSE\r
   GCC:RELEASE_*_*_CC_FLAGS       = -DMDEPKG_NDEBUG\r
   INTEL:RELEASE_*_*_CC_FLAGS     = /D MDEPKG_NDEBUG\r
   MSFT:RELEASE_*_*_CC_FLAGS      = /D MDEPKG_NDEBUG\r
+!endif\r
 \r
 [BuildOptions.common.EDKII.DXE_RUNTIME_DRIVER]\r
   GCC:*_*_*_DLINK_FLAGS      = -z common-page-size=0x1000\r
   CacheMaintenanceLib|MdePkg/Library/BaseCacheMaintenanceLib/BaseCacheMaintenanceLib.inf\r
   SafeIntLib|MdePkg/Library/BaseSafeIntLib/BaseSafeIntLib.inf\r
   DxeHobListLib|UefiPayloadPkg/Library/DxeHobListLib/DxeHobListLib.inf\r
-\r
-!if $(UNIVERSAL_PAYLOAD) == TRUE\r
-  HobLib|UefiPayloadPkg/Library/DxeHobLib/DxeHobLib.inf\r
+!if $(CRYPTO_PROTOCOL_SUPPORT) == TRUE\r
+  BaseCryptLib|CryptoPkg/Library/BaseCryptLibOnProtocolPpi/DxeCryptLib.inf\r
+  TlsLib|CryptoPkg/Library/BaseCryptLibOnProtocolPpi/DxeCryptLib.inf\r
 !else\r
-  HobLib|MdePkg/Library/DxeHobLib/DxeHobLib.inf\r
+  BaseCryptLib|CryptoPkg/Library/BaseCryptLib/BaseCryptLib.inf\r
+  TlsLib|CryptoPkg/Library/TlsLib/TlsLib.inf\r
 !endif\r
+  IntrinsicLib|CryptoPkg/Library/IntrinsicLib/IntrinsicLib.inf\r
+  OpensslLib|CryptoPkg/Library/OpensslLib/OpensslLib.inf\r
+  RngLib|MdePkg/Library/BaseRngLib/BaseRngLib.inf\r
+  HobLib|UefiPayloadPkg/Library/DxeHobLib/DxeHobLib.inf\r
 \r
   #\r
   # UEFI & PI\r
   CapsuleLib|MdeModulePkg/Library/DxeCapsuleLibNull/DxeCapsuleLibNull.inf\r
   SecurityManagementLib|MdeModulePkg/Library/DxeSecurityManagementLib/DxeSecurityManagementLib.inf\r
   UefiBootManagerLib|MdeModulePkg/Library/UefiBootManagerLib/UefiBootManagerLib.inf\r
+  BootLogoLib|MdeModulePkg/Library/BootLogoLib/BootLogoLib.inf\r
   CustomizedDisplayLib|MdeModulePkg/Library/CustomizedDisplayLib/CustomizedDisplayLib.inf\r
   FrameBufferBltLib|MdeModulePkg/Library/FrameBufferBltLib/FrameBufferBltLib.inf\r
 \r
   #\r
   # Platform\r
   #\r
+!if $(CPU_TIMER_LIB_ENABLE) == TRUE && $(UNIVERSAL_PAYLOAD) == TRUE\r
+  TimerLib|UefiCpuPkg/Library/CpuTimerLib/BaseCpuTimerLib.inf\r
+!else\r
   TimerLib|UefiPayloadPkg/Library/AcpiTimerLib/AcpiTimerLib.inf\r
+!endif\r
   ResetSystemLib|UefiPayloadPkg/Library/ResetSystemLib/ResetSystemLib.inf\r
-  SerialPortLib|MdeModulePkg/Library/BaseSerialPortLib16550/BaseSerialPortLib16550.inf\r
-!if $(UNIVERSAL_PAYLOAD) == TRUE\r
-  PlatformHookLib|UefiPayloadPkg/Library/UniversalPayloadPlatformHookLib/PlatformHookLib.inf\r
+!if $(USE_CBMEM_FOR_CONSOLE) == TRUE\r
+  SerialPortLib|UefiPayloadPkg/Library/CbSerialPortLib/CbSerialPortLib.inf\r
+  PlatformHookLib|MdeModulePkg/Library/BasePlatformHookLibNull/BasePlatformHookLibNull.inf\r
 !else\r
+  SerialPortLib|MdeModulePkg/Library/BaseSerialPortLib16550/BaseSerialPortLib16550.inf\r
   PlatformHookLib|UefiPayloadPkg/Library/PlatformHookLib/PlatformHookLib.inf\r
 !endif\r
   PlatformBootManagerLib|UefiPayloadPkg/Library/PlatformBootManagerLib/PlatformBootManagerLib.inf\r
   #\r
   # Misc\r
   #\r
-  DebugPrintErrorLevelLib|MdePkg/Library/BaseDebugPrintErrorLevelLib/BaseDebugPrintErrorLevelLib.inf\r
+  DebugPrintErrorLevelLib|UefiPayloadPkg/Library/DebugPrintErrorLevelLibHob/DebugPrintErrorLevelLibHob.inf\r
   PerformanceLib|MdePkg/Library/BasePerformanceLibNull/BasePerformanceLibNull.inf\r
 !if $(SOURCE_DEBUG_ENABLE) == TRUE\r
   PeCoffExtraActionLib|SourceLevelDebugPkg/Library/PeCoffExtraActionLibDebug/PeCoffExtraActionLibDebug.inf\r
   !endif\r
 !endif\r
 \r
-  DebugLib|MdePkg/Library/BaseDebugLibSerialPort/BaseDebugLibSerialPort.inf\r
+  DebugLib|MdeModulePkg/Library/PeiDxeDebugLibReportStatusCode/PeiDxeDebugLibReportStatusCode.inf\r
   LockBoxLib|MdeModulePkg/Library/LockBoxNullLib/LockBoxNullLib.inf\r
   FileExplorerLib|MdeModulePkg/Library/FileExplorerLib/FileExplorerLib.inf\r
   AuthVariableLib|MdeModulePkg/Library/AuthVariableLibNull/AuthVariableLibNull.inf\r
+!if $(VARIABLE_SUPPORT) == "EMU"\r
   TpmMeasurementLib|MdeModulePkg/Library/TpmMeasurementLibNull/TpmMeasurementLibNull.inf\r
+!elseif $(VARIABLE_SUPPORT) == "SPI"\r
+  PlatformSecureLib|SecurityPkg/Library/PlatformSecureLibNull/PlatformSecureLibNull.inf\r
+  TpmMeasurementLib|SecurityPkg/Library/DxeTpmMeasurementLib/DxeTpmMeasurementLib.inf\r
+  S3BootScriptLib|MdePkg/Library/BaseS3BootScriptLibNull/BaseS3BootScriptLibNull.inf\r
+  MmUnblockMemoryLib|MdePkg/Library/MmUnblockMemoryLib/MmUnblockMemoryLibNull.inf\r
+!endif\r
   VarCheckLib|MdeModulePkg/Library/VarCheckLib/VarCheckLib.inf\r
   VariablePolicyLib|MdeModulePkg/Library/VariablePolicyLib/VariablePolicyLib.inf\r
   VariablePolicyHelperLib|MdeModulePkg/Library/VariablePolicyHelperLib/VariablePolicyHelperLib.inf\r
+  VariableFlashInfoLib|MdeModulePkg/Library/BaseVariableFlashInfoLib/BaseVariableFlashInfoLib.inf\r
+  VmgExitLib|UefiCpuPkg/Library/VmgExitLibNull/VmgExitLibNull.inf\r
+  ReportStatusCodeLib|MdeModulePkg/Library/DxeReportStatusCodeLib/DxeReportStatusCodeLib.inf\r
+\r
+[LibraryClasses.common]\r
+!if $(BOOTSPLASH_IMAGE)\r
+  SafeIntLib|MdePkg/Library/BaseSafeIntLib/BaseSafeIntLib.inf\r
+  BmpSupportLib|MdeModulePkg/Library/BaseBmpSupportLib/BaseBmpSupportLib.inf\r
+!endif\r
 \r
 [LibraryClasses.common.SEC]\r
   HobLib|UefiPayloadPkg/Library/PayloadEntryHobLib/HobLib.inf\r
   PcdLib|MdePkg/Library/BasePcdLibNull/BasePcdLibNull.inf\r
   DxeHobListLib|UefiPayloadPkg/Library/DxeHobListLibNull/DxeHobListLibNull.inf\r
+  DebugLib|MdePkg/Library/BaseDebugLibSerialPort/BaseDebugLibSerialPort.inf\r
 \r
 [LibraryClasses.common.DXE_CORE]\r
   DxeHobListLib|UefiPayloadPkg/Library/DxeHobListLibNull/DxeHobListLibNull.inf\r
   DebugAgentLib|SourceLevelDebugPkg/Library/DebugAgent/DxeDebugAgentLib.inf\r
 !endif\r
   CpuExceptionHandlerLib|UefiCpuPkg/Library/CpuExceptionHandlerLib/DxeCpuExceptionHandlerLib.inf\r
-  VmgExitLib|UefiCpuPkg/Library/VmgExitLibNull/VmgExitLibNull.inf\r
+!if $(PERFORMANCE_MEASUREMENT_ENABLE)\r
+  PerformanceLib|MdeModulePkg/Library/DxeCorePerformanceLib/DxeCorePerformanceLib.inf\r
+!endif\r
 \r
 [LibraryClasses.common.DXE_DRIVER]\r
   PcdLib|MdePkg/Library/DxePcdLib/DxePcdLib.inf\r
 !endif\r
   CpuExceptionHandlerLib|UefiCpuPkg/Library/CpuExceptionHandlerLib/DxeCpuExceptionHandlerLib.inf\r
   MpInitLib|UefiCpuPkg/Library/MpInitLib/DxeMpInitLib.inf\r
-  VmgExitLib|UefiCpuPkg/Library/VmgExitLibNull/VmgExitLibNull.inf\r
+!if $(PERFORMANCE_MEASUREMENT_ENABLE)\r
+  PerformanceLib|MdeModulePkg/Library/DxePerformanceLib/DxePerformanceLib.inf\r
+!endif\r
 \r
 [LibraryClasses.common.DXE_RUNTIME_DRIVER]\r
   PcdLib|MdePkg/Library/DxePcdLib/DxePcdLib.inf\r
   MemoryAllocationLib|MdePkg/Library/UefiMemoryAllocationLib/UefiMemoryAllocationLib.inf\r
   ReportStatusCodeLib|MdeModulePkg/Library/RuntimeDxeReportStatusCodeLib/RuntimeDxeReportStatusCodeLib.inf\r
   VariablePolicyLib|MdeModulePkg/Library/VariablePolicyLib/VariablePolicyLibRuntimeDxe.inf\r
+!if $(PERFORMANCE_MEASUREMENT_ENABLE)\r
+  PerformanceLib|MdeModulePkg/Library/DxePerformanceLib/DxePerformanceLib.inf\r
+!endif\r
 \r
 [LibraryClasses.common.UEFI_DRIVER,LibraryClasses.common.UEFI_APPLICATION]\r
   PcdLib|MdePkg/Library/DxePcdLib/DxePcdLib.inf\r
   MemoryAllocationLib|MdePkg/Library/UefiMemoryAllocationLib/UefiMemoryAllocationLib.inf\r
   ReportStatusCodeLib|MdeModulePkg/Library/DxeReportStatusCodeLib/DxeReportStatusCodeLib.inf\r
+!if $(PERFORMANCE_MEASUREMENT_ENABLE)\r
+  PerformanceLib|MdeModulePkg/Library/DxePerformanceLib/DxePerformanceLib.inf\r
+!endif\r
+\r
+[LibraryClasses.common.SMM_CORE]\r
+!if $(SMM_SUPPORT) == TRUE\r
+  PcdLib|MdePkg/Library/DxePcdLib/DxePcdLib.inf\r
+  SmmServicesTableLib|MdeModulePkg/Library/PiSmmCoreSmmServicesTableLib/PiSmmCoreSmmServicesTableLib.inf\r
+\r
+  MemoryAllocationLib|MdeModulePkg/Library/PiSmmCoreMemoryAllocationLib/PiSmmCoreMemoryAllocationLib.inf\r
+  SmmCorePlatformHookLib|MdeModulePkg/Library/SmmCorePlatformHookLibNull/SmmCorePlatformHookLibNull.inf\r
+  SmmMemLib|MdePkg/Library/SmmMemLib/SmmMemLib.inf\r
+  ReportStatusCodeLib|MdePkg/Library/BaseReportStatusCodeLibNull/BaseReportStatusCodeLibNull.inf\r
+!if $(PERFORMANCE_MEASUREMENT_ENABLE)\r
+  PerformanceLib|MdeModulePkg/Library/SmmCorePerformanceLib/SmmCorePerformanceLib.inf\r
+!endif\r
+!endif\r
+\r
+[LibraryClasses.common.DXE_SMM_DRIVER]\r
+!if $(SMM_SUPPORT) == TRUE\r
+  PcdLib|MdePkg/Library/DxePcdLib/DxePcdLib.inf\r
+\r
+  MemoryAllocationLib|MdePkg/Library/SmmMemoryAllocationLib/SmmMemoryAllocationLib.inf\r
+  SmmServicesTableLib|MdePkg/Library/SmmServicesTableLib/SmmServicesTableLib.inf\r
+  SmmMemLib|MdePkg/Library/SmmMemLib/SmmMemLib.inf\r
+  MmServicesTableLib|MdePkg/Library/MmServicesTableLib/MmServicesTableLib.inf\r
+  DebugLib|MdeModulePkg/Library/PeiDxeDebugLibReportStatusCode/PeiDxeDebugLibReportStatusCode.inf\r
+  SmmCpuPlatformHookLib|UefiCpuPkg/Library/SmmCpuPlatformHookLibNull/SmmCpuPlatformHookLibNull.inf\r
+  SmmCpuFeaturesLib|UefiCpuPkg/Library/SmmCpuFeaturesLib/SmmCpuFeaturesLib.inf\r
+  CpuExceptionHandlerLib|UefiCpuPkg/Library/CpuExceptionHandlerLib/SmmCpuExceptionHandlerLib.inf\r
+  ReportStatusCodeLib|MdePkg/Library/BaseReportStatusCodeLibNull/BaseReportStatusCodeLibNull.inf\r
+  SmmCpuRendezvousLib|UefiCpuPkg/Library/SmmCpuRendezvousLib/SmmCpuRendezvousLib.inf\r
+!if $(PERFORMANCE_MEASUREMENT_ENABLE)\r
+  PerformanceLib|MdeModulePkg/Library/SmmPerformanceLib/SmmPerformanceLib.inf\r
+!endif\r
+!endif\r
+!if $(VARIABLE_SUPPORT) == "SPI"\r
+  SpiFlashLib|UefiPayloadPkg/Library/SpiFlashLib/SpiFlashLib.inf\r
+  FlashDeviceLib|UefiPayloadPkg/Library/FlashDeviceLib/FlashDeviceLib.inf\r
+  BaseCryptLib|CryptoPkg/Library/BaseCryptLib/SmmCryptLib.inf\r
+!endif\r
 \r
 ################################################################################\r
 #\r
   gEfiMdeModulePkgTokenSpaceGuid.PcdInstallAcpiSdtProtocol|TRUE\r
   gEfiMdeModulePkgTokenSpaceGuid.PcdHiiOsRuntimeSupport|FALSE\r
   gEfiMdeModulePkgTokenSpaceGuid.PcdPciDegradeResourceForOptionRom|FALSE\r
+  gUefiCpuPkgTokenSpaceGuid.PcdCpuSmmEnableBspElection|FALSE\r
 \r
 [PcdsFixedAtBuild]\r
+  gEfiMdePkgTokenSpaceGuid.PcdHardwareErrorRecordLevel|1\r
   gEfiMdeModulePkgTokenSpaceGuid.PcdMaxVariableSize|0x10000\r
   gEfiMdeModulePkgTokenSpaceGuid.PcdMaxHardwareErrorVariableSize|0x8000\r
   gEfiMdeModulePkgTokenSpaceGuid.PcdVariableStoreSize|0x10000\r
-  #\r
-  # Make VariableRuntimeDxe work at emulated non-volatile variable mode.\r
-  #\r
-  gEfiMdeModulePkgTokenSpaceGuid.PcdEmuVariableNvModeEnable|TRUE\r
+!if $(VARIABLE_SUPPORT) == "EMU"\r
+  gEfiMdeModulePkgTokenSpaceGuid.PcdEmuVariableNvModeEnable        |TRUE\r
+!else\r
+  gEfiMdeModulePkgTokenSpaceGuid.PcdEmuVariableNvModeEnable        |FALSE\r
+!endif\r
 \r
   gEfiMdeModulePkgTokenSpaceGuid.PcdVpdBaseAddress|0x0\r
   gEfiMdeModulePkgTokenSpaceGuid.PcdStatusCodeUseMemory|FALSE\r
 !if $(SOURCE_DEBUG_ENABLE)\r
   gEfiSourceLevelDebugPkgTokenSpaceGuid.PcdDebugLoadImageMethod|0x2\r
 !endif\r
+  gUefiCpuPkgTokenSpaceGuid.PcdCpuSmmStackSize|0x4000\r
+  gEfiMdeModulePkgTokenSpaceGuid.PcdEdkiiFpdtStringRecordEnableOnly| TRUE\r
+!if $(PERFORMANCE_MEASUREMENT_ENABLE)\r
+  gEfiMdePkgTokenSpaceGuid.PcdPerformanceLibraryPropertyMask       | 0x1\r
+!endif\r
+  gEfiMdeModulePkgTokenSpaceGuid.PcdSdMmcGenericTimeoutValue|$(SD_MMC_TIMEOUT)\r
+\r
+  gUefiPayloadPkgTokenSpaceGuid.PcdDispatchModuleAbove4GMemory|$(ABOVE_4G_MEMORY)\r
+  gUefiPayloadPkgTokenSpaceGuid.PcdBootManagerEscape|$(BOOT_MANAGER_ESCAPE)\r
+\r
+  gEfiMdePkgTokenSpaceGuid.PcdMaximumUnicodeStringLength|1800000\r
+\r
+!if $(CRYPTO_PROTOCOL_SUPPORT) == TRUE\r
+  gEfiCryptoPkgTokenSpaceGuid.PcdCryptoServiceFamilyEnable.HmacSha256.Family                        | PCD_CRYPTO_SERVICE_ENABLE_FAMILY\r
+  gEfiCryptoPkgTokenSpaceGuid.PcdCryptoServiceFamilyEnable.Md5.Family                               | PCD_CRYPTO_SERVICE_ENABLE_FAMILY\r
+  gEfiCryptoPkgTokenSpaceGuid.PcdCryptoServiceFamilyEnable.Pkcs.Family                              | PCD_CRYPTO_SERVICE_ENABLE_FAMILY\r
+  gEfiCryptoPkgTokenSpaceGuid.PcdCryptoServiceFamilyEnable.Dh.Family                                | PCD_CRYPTO_SERVICE_ENABLE_FAMILY\r
+  gEfiCryptoPkgTokenSpaceGuid.PcdCryptoServiceFamilyEnable.Random.Family                            | PCD_CRYPTO_SERVICE_ENABLE_FAMILY\r
+  gEfiCryptoPkgTokenSpaceGuid.PcdCryptoServiceFamilyEnable.Rsa.Family                               | PCD_CRYPTO_SERVICE_ENABLE_FAMILY\r
+  gEfiCryptoPkgTokenSpaceGuid.PcdCryptoServiceFamilyEnable.Sha1.Family                              | PCD_CRYPTO_SERVICE_ENABLE_FAMILY\r
+  gEfiCryptoPkgTokenSpaceGuid.PcdCryptoServiceFamilyEnable.Sha256.Family                            | PCD_CRYPTO_SERVICE_ENABLE_FAMILY\r
+  gEfiCryptoPkgTokenSpaceGuid.PcdCryptoServiceFamilyEnable.Sha384.Family                            | PCD_CRYPTO_SERVICE_ENABLE_FAMILY\r
+  gEfiCryptoPkgTokenSpaceGuid.PcdCryptoServiceFamilyEnable.Sha512.Family                            | PCD_CRYPTO_SERVICE_ENABLE_FAMILY\r
+  gEfiCryptoPkgTokenSpaceGuid.PcdCryptoServiceFamilyEnable.X509.Family                              | PCD_CRYPTO_SERVICE_ENABLE_FAMILY\r
+  gEfiCryptoPkgTokenSpaceGuid.PcdCryptoServiceFamilyEnable.Tdes.Family                              | PCD_CRYPTO_SERVICE_ENABLE_FAMILY\r
+  gEfiCryptoPkgTokenSpaceGuid.PcdCryptoServiceFamilyEnable.Aes.Services.GetContextSize              | TRUE\r
+  gEfiCryptoPkgTokenSpaceGuid.PcdCryptoServiceFamilyEnable.Aes.Services.Init                        | TRUE\r
+  gEfiCryptoPkgTokenSpaceGuid.PcdCryptoServiceFamilyEnable.Aes.Services.CbcEncrypt                  | TRUE\r
+  gEfiCryptoPkgTokenSpaceGuid.PcdCryptoServiceFamilyEnable.Aes.Services.CbcDecrypt                  | TRUE\r
+  gEfiCryptoPkgTokenSpaceGuid.PcdCryptoServiceFamilyEnable.Arc4.Family                              | PCD_CRYPTO_SERVICE_ENABLE_FAMILY\r
+  gEfiCryptoPkgTokenSpaceGuid.PcdCryptoServiceFamilyEnable.Sm3.Family                               | PCD_CRYPTO_SERVICE_ENABLE_FAMILY\r
+  gEfiCryptoPkgTokenSpaceGuid.PcdCryptoServiceFamilyEnable.Hkdf.Family                              | PCD_CRYPTO_SERVICE_ENABLE_FAMILY\r
+  gEfiCryptoPkgTokenSpaceGuid.PcdCryptoServiceFamilyEnable.Tls.Family                               | PCD_CRYPTO_SERVICE_ENABLE_FAMILY\r
+  gEfiCryptoPkgTokenSpaceGuid.PcdCryptoServiceFamilyEnable.TlsSet.Family                            | PCD_CRYPTO_SERVICE_ENABLE_FAMILY\r
+  gEfiCryptoPkgTokenSpaceGuid.PcdCryptoServiceFamilyEnable.TlsGet.Family                            | PCD_CRYPTO_SERVICE_ENABLE_FAMILY\r
+!endif\r
+\r
+[PcdsPatchableInModule.X64]\r
+  gPcAtChipsetPkgTokenSpaceGuid.PcdRtcIndexRegister|$(RTC_INDEX_REGISTER)\r
+  gPcAtChipsetPkgTokenSpaceGuid.PcdRtcTargetRegister|$(RTC_TARGET_REGISTER)\r
+!if $(NETWORK_DRIVER_ENABLE) == TRUE\r
+  gEfiNetworkPkgTokenSpaceGuid.PcdAllowHttpConnections|TRUE\r
+!endif\r
 \r
 [PcdsPatchableInModule.common]\r
   gEfiMdeModulePkgTokenSpaceGuid.PcdBootManagerMenuFile|{ 0x21, 0xaa, 0x2c, 0x46, 0x14, 0x76, 0x03, 0x45, 0x83, 0x6e, 0x8a, 0xb6, 0xf4, 0x66, 0x23, 0x31 }\r
   gEfiMdePkgTokenSpaceGuid.PcdReportStatusCodePropertyMask|0x7\r
   gEfiMdePkgTokenSpaceGuid.PcdDebugPrintErrorLevel|0x8000004F\r
-!if $(SOURCE_DEBUG_ENABLE)\r
-  gEfiMdePkgTokenSpaceGuid.PcdDebugPropertyMask|0x17\r
+!if $(USE_CBMEM_FOR_CONSOLE) == FALSE\r
+  !if $(SOURCE_DEBUG_ENABLE)\r
+    gEfiMdePkgTokenSpaceGuid.PcdDebugPropertyMask|0x17\r
+  !else\r
+    gEfiMdePkgTokenSpaceGuid.PcdDebugPropertyMask|0x2F\r
+  !endif\r
 !else\r
-  gEfiMdePkgTokenSpaceGuid.PcdDebugPropertyMask|0x2F\r
+  !if $(TARGET) == DEBUG\r
+    gEfiMdePkgTokenSpaceGuid.PcdDebugPropertyMask|0x07\r
+  !else\r
+    gEfiMdePkgTokenSpaceGuid.PcdDebugPropertyMask|0x03\r
+  !endif\r
 !endif\r
   gEfiMdeModulePkgTokenSpaceGuid.PcdMaxSizeNonPopulateCapsule|$(MAX_SIZE_NON_POPULATE_CAPSULE)\r
-  gPcAtChipsetPkgTokenSpaceGuid.PcdRtcIndexRegister|$(RTC_INDEX_REGISTER)\r
-  gPcAtChipsetPkgTokenSpaceGuid.PcdRtcTargetRegister|$(RTC_TARGET_REGISTER)\r
   #\r
   # The following parameters are set by Library/PlatformHookLib\r
   #\r
   gEfiMdeModulePkgTokenSpaceGuid.PcdSerialUseHardwareFlowControl|$(SERIAL_HARDWARE_FLOW_CONTROL)\r
   gEfiMdeModulePkgTokenSpaceGuid.PcdSerialDetectCable|$(SERIAL_DETECT_CABLE)\r
   gEfiMdeModulePkgTokenSpaceGuid.PcdSerialFifoControl|$(SERIAL_FIFO_CONTROL)\r
-  gEfiMdeModulePkgTokenSpaceGuid.PcdSerialExtendedTxFifoSize|$(SERIAL_EXTENDED_TX_FIFO_SIZE)\r
 \r
   gEfiMdeModulePkgTokenSpaceGuid.PcdPciSerialParameters|$(PCI_SERIAL_PARAMETERS)\r
 \r
   gUefiCpuPkgTokenSpaceGuid.PcdCpuMaxLogicalProcessorNumber|$(MAX_LOGICAL_PROCESSORS)\r
   gUefiCpuPkgTokenSpaceGuid.PcdCpuNumberOfReservedVariableMtrrs|0\r
+  gUefiPayloadPkgTokenSpaceGuid.PcdBootloaderParameter|0\r
 \r
 ################################################################################\r
 #\r
   gUefiCpuPkgTokenSpaceGuid.PcdCpuApLoopMode\r
   gUefiCpuPkgTokenSpaceGuid.PcdCpuMicrocodePatchAddress\r
   gUefiCpuPkgTokenSpaceGuid.PcdCpuMicrocodePatchRegionSize\r
-!if $(TARGET) == DEBUG\r
+!if ($(TARGET) == DEBUG || $(USE_CBMEM_FOR_CONSOLE) == TRUE)\r
   gEfiMdeModulePkgTokenSpaceGuid.PcdStatusCodeUseSerial|TRUE\r
 !else\r
   gEfiMdeModulePkgTokenSpaceGuid.PcdStatusCodeUseSerial|FALSE\r
   gEfiMdeModulePkgTokenSpaceGuid.PcdFlashNvStorageVariableBase64|0\r
   gEfiMdeModulePkgTokenSpaceGuid.PcdFlashNvStorageFtwWorkingBase|0\r
   gEfiMdeModulePkgTokenSpaceGuid.PcdFlashNvStorageFtwSpareBase|0\r
-  gEfiMdePkgTokenSpaceGuid.PcdPlatformBootTimeOut|3\r
+  gEfiMdePkgTokenSpaceGuid.PcdPlatformBootTimeOut|$(PLATFORM_BOOT_TIMEOUT)\r
+!if $(VARIABLE_SUPPORT) == "SPI"\r
+  gEfiMdeModulePkgTokenSpaceGuid.PcdFlashNvStorageVariableSize  |0\r
+  gEfiMdeModulePkgTokenSpaceGuid.PcdFlashNvStorageFtwWorkingSize|0\r
+  gEfiMdeModulePkgTokenSpaceGuid.PcdFlashNvStorageFtwSpareSize  |0\r
+  gEfiMdeModulePkgTokenSpaceGuid.PcdFlashNvStorageVariableBase  |0\r
+!endif\r
+  # Disable SMM S3 script\r
+  gEfiMdeModulePkgTokenSpaceGuid.PcdAcpiS3Enable|FALSE\r
 \r
   ## This PCD defines the video horizontal resolution.\r
   #  This PCD could be set to 0 then video resolution could be at highest resolution.\r
 #\r
 ################################################################################\r
 \r
-!if "IA32" in $(ARCH)\r
+!if "IA32" in "$(ARCH)"\r
   [Components.IA32]\r
   !if $(UNIVERSAL_PAYLOAD) == TRUE\r
     UefiPayloadPkg/UefiPayloadEntry/UniversalPayloadEntry.inf\r
   !endif\r
 !endif\r
 \r
+#\r
+# UEFI network modules\r
+#\r
+!if $(NETWORK_DRIVER_ENABLE) == TRUE\r
+[Defines]\r
+  DEFINE PLATFORMX64_ENABLE = TRUE\r
+  !include NetworkPkg/Network.dsc.inc\r
+!endif\r
+\r
 [Components.X64]\r
   #\r
   # DXE Core\r
   #\r
   # Components that produce the architectural protocols\r
   #\r
+!if $(SECURITY_STUB_ENABLE) == TRUE\r
   MdeModulePkg/Universal/SecurityStubDxe/SecurityStubDxe.inf\r
+!endif\r
   UefiCpuPkg/CpuDxe/CpuDxe.inf\r
   MdeModulePkg/Universal/BdsDxe/BdsDxe.inf\r
+!if $(BOOTSPLASH_IMAGE)\r
+  MdeModulePkg/Logo/LogoDxe.inf\r
+!endif\r
   MdeModulePkg/Application/UiApp/UiApp.inf {\r
     <LibraryClasses>\r
       NULL|MdeModulePkg/Library/DeviceManagerUiLib/DeviceManagerUiLib.inf\r
       NULL|MdeModulePkg/Library/BootManagerUiLib/BootManagerUiLib.inf\r
       NULL|MdeModulePkg/Library/BootMaintenanceManagerUiLib/BootMaintenanceManagerUiLib.inf\r
   }\r
-\r
+  MdeModulePkg/Application/BootManagerMenuApp/BootManagerMenuApp.inf {\r
+    <LibraryClasses>\r
+      NULL|UefiPayloadPkg/Library/PlatformBootManagerLib/PlatformBootManagerLib.inf\r
+  }\r
   PcAtChipsetPkg/HpetTimerDxe/HpetTimerDxe.inf\r
   MdeModulePkg/Universal/Metronome/Metronome.inf\r
   MdeModulePkg/Universal/WatchdogTimerDxe/WatchdogTimer.inf\r
   MdeModulePkg/Universal/StatusCodeHandler/RuntimeDxe/StatusCodeHandlerRuntimeDxe.inf\r
   UefiCpuPkg/CpuIo2Dxe/CpuIo2Dxe.inf\r
   MdeModulePkg/Universal/DevicePathDxe/DevicePathDxe.inf\r
+!if $(MEMORY_TEST) == "GENERIC"\r
+  MdeModulePkg/Universal/MemoryTest/GenericMemoryTestDxe/GenericMemoryTestDxe.inf\r
+!elseif $(MEMORY_TEST) == "NULL"\r
   MdeModulePkg/Universal/MemoryTest/NullMemoryTestDxe/NullMemoryTestDxe.inf\r
+!endif\r
   MdeModulePkg/Universal/HiiDatabaseDxe/HiiDatabaseDxe.inf\r
   MdeModulePkg/Universal/SetupBrowserDxe/SetupBrowserDxe.inf\r
   MdeModulePkg/Universal/DisplayEngineDxe/DisplayEngineDxe.inf\r
+  MdeModulePkg/Universal/PlatformDriOverrideDxe/PlatformDriOverrideDxe.inf\r
+  MdeModulePkg/Universal/EbcDxe/EbcDxe.inf\r
 \r
   UefiPayloadPkg/BlSupportDxe/BlSupportDxe.inf\r
 \r
   # ACPI Support\r
   #\r
   MdeModulePkg/Universal/Acpi/AcpiTableDxe/AcpiTableDxe.inf\r
+!if $(BOOTSPLASH_IMAGE)\r
+  MdeModulePkg/Universal/Acpi/AcpiPlatformDxe/AcpiPlatformDxe.inf\r
+  MdeModulePkg/Universal/Acpi/BootGraphicsResourceTableDxe/BootGraphicsResourceTableDxe.inf\r
+!endif\r
 \r
   #\r
   # PCI Support\r
   MdeModulePkg/Universal/Disk/PartitionDxe/PartitionDxe.inf\r
   MdeModulePkg/Universal/Disk/UnicodeCollation/EnglishDxe/EnglishDxe.inf\r
   FatPkg/EnhancedFatDxe/Fat.inf\r
+!if $(ATA_ENABLE) == TRUE\r
   MdeModulePkg/Bus/Pci/SataControllerDxe/SataControllerDxe.inf\r
   MdeModulePkg/Bus/Ata/AtaBusDxe/AtaBusDxe.inf\r
+!endif\r
   MdeModulePkg/Bus/Ata/AtaAtapiPassThru/AtaAtapiPassThru.inf\r
   MdeModulePkg/Bus/Scsi/ScsiBusDxe/ScsiBusDxe.inf\r
   MdeModulePkg/Bus/Scsi/ScsiDiskDxe/ScsiDiskDxe.inf\r
   MdeModulePkg/Bus/Pci/NvmExpressDxe/NvmExpressDxe.inf\r
 \r
+!if $(RAM_DISK_ENABLE) == TRUE\r
+  MdeModulePkg/Universal/Disk/RamDiskDxe/RamDiskDxe.inf\r
+!endif\r
   #\r
   # SD/eMMC Support\r
   #\r
+!if $(SD_ENABLE) == TRUE\r
   MdeModulePkg/Bus/Pci/SdMmcPciHcDxe/SdMmcPciHcDxe.inf\r
   MdeModulePkg/Bus/Sd/EmmcDxe/EmmcDxe.inf\r
   MdeModulePkg/Bus/Sd/SdDxe/SdDxe.inf\r
+!endif\r
 \r
   #\r
   # Usb Support\r
   MdeModulePkg/Bus/Usb/UsbBusDxe/UsbBusDxe.inf\r
   MdeModulePkg/Bus/Usb/UsbKbDxe/UsbKbDxe.inf\r
   MdeModulePkg/Bus/Usb/UsbMassStorageDxe/UsbMassStorageDxe.inf\r
+  MdeModulePkg/Bus/Usb/UsbMouseDxe/UsbMouseDxe.inf\r
 \r
   #\r
   # ISA Support\r
   #\r
+!if $(SERIAL_DRIVER_ENABLE) == TRUE\r
   MdeModulePkg/Universal/SerialDxe/SerialDxe.inf\r
-!if $(PS2_KEYBOARD_ENABLE) == TRUE\r
+!endif\r
+!if $(SIO_BUS_ENABLE) == TRUE\r
   OvmfPkg/SioBusDxe/SioBusDxe.inf\r
+!endif\r
+!if $(PS2_KEYBOARD_ENABLE) == TRUE\r
   MdeModulePkg/Bus/Isa/Ps2KeyboardDxe/Ps2KeyboardDxe.inf\r
 !endif\r
+!if $(PS2_MOUSE_ENABLE) == TRUE\r
+  MdeModulePkg/Bus/Isa/Ps2MouseDxe/Ps2MouseDxe.inf\r
+!endif\r
 \r
   #\r
   # Console Support\r
   MdeModulePkg/Universal/Console/TerminalDxe/TerminalDxe.inf\r
 !endif\r
   UefiPayloadPkg/GraphicsOutputDxe/GraphicsOutputDxe.inf\r
+!if $(PERFORMANCE_MEASUREMENT_ENABLE)\r
+  MdeModulePkg/Universal/Acpi/FirmwarePerformanceDataTableDxe/FirmwarePerformanceDxe.inf\r
+!endif\r
+  #\r
+  # SMM Support\r
+  #\r
+!if $(SMM_SUPPORT) == TRUE\r
+  UefiPayloadPkg/SmmAccessDxe/SmmAccessDxe.inf\r
+  UefiPayloadPkg/SmmControlRuntimeDxe/SmmControlRuntimeDxe.inf\r
+  UefiPayloadPkg/BlSupportSmm/BlSupportSmm.inf\r
+  MdeModulePkg/Core/PiSmmCore/PiSmmIpl.inf\r
+  MdeModulePkg/Core/PiSmmCore/PiSmmCore.inf\r
+  UefiPayloadPkg/PchSmiDispatchSmm/PchSmiDispatchSmm.inf\r
+  UefiCpuPkg/PiSmmCpuDxeSmm/PiSmmCpuDxeSmm.inf\r
+  UefiCpuPkg/CpuIo2Smm/CpuIo2Smm.inf\r
+!if $(PERFORMANCE_MEASUREMENT_ENABLE)\r
+  MdeModulePkg/Universal/Acpi/FirmwarePerformanceDataTableSmm/FirmwarePerformanceSmm.inf\r
+!endif\r
+!endif\r
+\r
+!if $(VARIABLE_SUPPORT) == "EMU"\r
+  MdeModulePkg/Universal/Variable/RuntimeDxe/VariableRuntimeDxe.inf\r
+!elseif $(VARIABLE_SUPPORT) == "SPI"\r
+  MdeModulePkg/Universal/Variable/RuntimeDxe/VariableSmm.inf {\r
+    <LibraryClasses>\r
+      NULL|MdeModulePkg/Library/VarCheckUefiLib/VarCheckUefiLib.inf\r
+      NULL|MdeModulePkg/Library/VarCheckHiiLib/VarCheckHiiLib.inf\r
+      NULL|MdeModulePkg/Library/VarCheckPcdLib/VarCheckPcdLib.inf\r
+      NULL|MdeModulePkg/Library/VarCheckPolicyLib/VarCheckPolicyLib.inf\r
+  }\r
+\r
+  UefiPayloadPkg/FvbRuntimeDxe/FvbSmm.inf\r
+  MdeModulePkg/Universal/FaultTolerantWriteDxe/FaultTolerantWriteSmm.inf\r
+  MdeModulePkg/Universal/Variable/RuntimeDxe/VariableSmmRuntimeDxe.inf\r
+!endif\r
+\r
+  #\r
+  # Misc\r
+  #\r
+!if $(CRYPTO_PROTOCOL_SUPPORT) == TRUE\r
+  CryptoPkg/Driver/CryptoDxe.inf {\r
+    <LibraryClasses>\r
+      BaseCryptLib|CryptoPkg/Library/BaseCryptLib/BaseCryptLib.inf\r
+      TlsLib|CryptoPkg/Library/TlsLib/TlsLib.inf\r
+  }\r
+!endif\r
 \r
   #------------------------------\r
   #  Build the shell\r
       #  This should be FALSE for compiling the dynamic command.\r
       gEfiShellPkgTokenSpaceGuid.PcdShellLibAutoInitialize|FALSE\r
   }\r
+!if $(PERFORMANCE_MEASUREMENT_ENABLE) == TRUE\r
   ShellPkg/DynamicCommand/DpDynamicCommand/DpDynamicCommand.inf {\r
     <PcdsFixedAtBuild>\r
       ## This flag is used to control initialization of the shell library\r
       #  This should be FALSE for compiling the dynamic command.\r
       gEfiShellPkgTokenSpaceGuid.PcdShellLibAutoInitialize|FALSE\r
   }\r
+!endif\r
   ShellPkg/Application/Shell/Shell.inf {\r
     <PcdsFixedAtBuild>\r
       ## This flag is used to control initialization of the shell library\r
     #------------------------------\r
 \r
     <LibraryClasses>\r
-      DebugLib|MdePkg/Library/UefiDebugLibConOut/UefiDebugLibConOut.inf\r
       DevicePathLib|MdePkg/Library/UefiDevicePathLib/UefiDevicePathLib.inf\r
       HandleParsingLib|ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.inf\r
       OrderedCollectionLib|MdePkg/Library/BaseOrderedCollectionRedBlackTreeLib/BaseOrderedCollectionRedBlackTreeLib.inf\r