[edk2] [RFC 1/2] Example: The PCDs configuring for multiple SKUs with current SKU usage

Star Zeng posted 2 patches 7 years, 6 months ago
[edk2] [RFC 1/2] Example: The PCDs configuring for multiple SKUs with current SKU usage
Posted by Star Zeng 7 years, 6 months ago
---
 Nt32Pkg/Nt32Pkg.dec |   9 ++++
 Nt32Pkg/Nt32Pkg.dsc | 125 ++++++++++++++++++++++++++++++++++++++++++++++++++++
 2 files changed, 134 insertions(+)

diff --git a/Nt32Pkg/Nt32Pkg.dec b/Nt32Pkg/Nt32Pkg.dec
index 06da067bc1d9..7b330359c5d2 100644
--- a/Nt32Pkg/Nt32Pkg.dec
+++ b/Nt32Pkg/Nt32Pkg.dec
@@ -93,4 +93,13 @@ [PcdsDynamic, PcdsDynamicEx]
   gEfiNt32PkgTokenSpaceGuid.PcdWinNtMemorySize|L"64!64"|VOID*|0x00001005
   gEfiNt32PkgTokenSpaceGuid.PcdWinNtConsole|L"Bus Driver Console Window"|VOID*|0x0000100a
   gEfiNt32PkgTokenSpaceGuid.PcdWinNtGop|L"UGA Window 1!UGA Window 2"|VOID*|0x0000100d
+  gXXXPkgTokenSpaceGuid.PcdCpuConfig1|FALSE|BOOLEAN|0x00000001
+  gXXXPkgTokenSpaceGuid.PcdCpuConfig2|FALSE|BOOLEAN|0x00000002
+  gXXXPkgTokenSpaceGuid.PcdCpuConfig3|FALSE|BOOLEAN|0x00000003
+  gXXXPkgTokenSpaceGuid.PcdCsConfig1|FALSE|BOOLEAN|0x00000004
+  gXXXPkgTokenSpaceGuid.PcdCsConfig2|FALSE|BOOLEAN|0x00000005
+  gXXXPkgTokenSpaceGuid.PcdCsConfig3|FALSE|BOOLEAN|0x00000006
+  gXXXPkgTokenSpaceGuid.PcdFruConfig1|FALSE|BOOLEAN|0x00000007
+  gXXXPkgTokenSpaceGuid.PcdFruConfig2|FALSE|BOOLEAN|0x00000008
+  gXXXPkgTokenSpaceGuid.PcdFruConfig3|FALSE|BOOLEAN|0x00000009
 
diff --git a/Nt32Pkg/Nt32Pkg.dsc b/Nt32Pkg/Nt32Pkg.dsc
index fa3446be062f..573875fe4b95 100644
--- a/Nt32Pkg/Nt32Pkg.dsc
+++ b/Nt32Pkg/Nt32Pkg.dsc
@@ -86,6 +86,16 @@ [Defines]
 ################################################################################
 [SkuIds]
   0|DEFAULT              # The entry: 0|DEFAULT is reserved and always required.
+  1 | Sku1 # CpuA + CsA + FruA
+  2 | Sku2 # CpuA + CsA + FruB
+  3 | Sku3 # CpuA + CsB + FruA
+  4 | Sku4 # CpuA + CsB + FruB
+  5 | Sku5 # CpuB + CsA + FruA
+  6 | Sku6 # CpuB + CsA + FruB
+  7 | Sku7 # CpuB + CsB + FruA
+  8 | Sku8 # CpuB + CsB + FruB
+  9 | Sku9 # CpuA + CsB
+  10 | Sku10 # CpuB + CsB
 
 ################################################################################
 #
@@ -327,6 +337,121 @@ [PcdsDynamicHii.common.DEFAULT]
   gEfiMdePkgTokenSpaceGuid.PcdPlatformBootTimeOut|L"Timeout"|gEfiGlobalVariableGuid|0x0|10
   gEfiMdePkgTokenSpaceGuid.PcdHardwareErrorRecordLevel|L"HwErrRecSupport"|gEfiGlobalVariableGuid|0x0|1
 
+[PcdsDynamicDefault.Common.DEFAULT]
+  gXXXPkgTokenSpaceGuid.PcdCpuConfig1|FALSE
+  gXXXPkgTokenSpaceGuid.PcdCpuConfig2|FALSE
+  gXXXPkgTokenSpaceGuid.PcdCpuConfig3|FALSE
+  gXXXPkgTokenSpaceGuid.PcdCsConfig1|FALSE
+  gXXXPkgTokenSpaceGuid.PcdCsConfig2|FALSE
+  gXXXPkgTokenSpaceGuid.PcdCsConfig3|FALSE
+  gXXXPkgTokenSpaceGuid.PcdFruConfig1|FALSE
+  gXXXPkgTokenSpaceGuid.PcdFruConfig2|FALSE
+  gXXXPkgTokenSpaceGuid.PcdFruConfig3|FALSE
+
+[PcdsDynamicDefault.Common.Sku1]
+  gXXXPkgTokenSpaceGuid.PcdCpuConfig1|TRUE
+  gXXXPkgTokenSpaceGuid.PcdCpuConfig2|TRUE
+  # gXXXPkgTokenSpaceGuid.PcdCpuConfig3|FALSE
+  gXXXPkgTokenSpaceGuid.PcdCsConfig1|TRUE
+  gXXXPkgTokenSpaceGuid.PcdCsConfig2|TRUE
+  # gXXXPkgTokenSpaceGuid.PcdCsConfig3|FALSE
+  gXXXPkgTokenSpaceGuid.PcdFruConfig1|TRUE
+  gXXXPkgTokenSpaceGuid.PcdFruConfig2|TRUE
+  # gXXXPkgTokenSpaceGuid.PcdFruConfig3|FALSE
+
+[PcdsDynamicDefault.Common.Sku2]
+  gXXXPkgTokenSpaceGuid.PcdCpuConfig1|TRUE
+  gXXXPkgTokenSpaceGuid.PcdCpuConfig2|TRUE
+  # gXXXPkgTokenSpaceGuid.PcdCpuConfig3|FALSE
+  gXXXPkgTokenSpaceGuid.PcdCsConfig1|TRUE
+  gXXXPkgTokenSpaceGuid.PcdCsConfig2|TRUE
+  # gXXXPkgTokenSpaceGuid.PcdCsConfig3|FALSE
+  gXXXPkgTokenSpaceGuid.PcdFruConfig1|TRUE
+  gXXXPkgTokenSpaceGuid.PcdFruConfig2|TRUE
+  gXXXPkgTokenSpaceGuid.PcdFruConfig3|TRUE
+
+[PcdsDynamicDefault.Common.Sku3]
+  gXXXPkgTokenSpaceGuid.PcdCpuConfig1|TRUE
+  gXXXPkgTokenSpaceGuid.PcdCpuConfig2|TRUE
+  # gXXXPkgTokenSpaceGuid.PcdCpuConfig3|FALSE
+  gXXXPkgTokenSpaceGuid.PcdCsConfig1|TRUE
+  gXXXPkgTokenSpaceGuid.PcdCsConfig2|TRUE
+  gXXXPkgTokenSpaceGuid.PcdCsConfig3|TRUE
+  gXXXPkgTokenSpaceGuid.PcdFruConfig1|TRUE
+  gXXXPkgTokenSpaceGuid.PcdFruConfig2|TRUE
+  # gXXXPkgTokenSpaceGuid.PcdFruConfig3|FALSE
+
+[PcdsDynamicDefault.Common.Sku4]
+  gXXXPkgTokenSpaceGuid.PcdCpuConfig1|TRUE
+  gXXXPkgTokenSpaceGuid.PcdCpuConfig2|TRUE
+  # gXXXPkgTokenSpaceGuid.PcdCpuConfig3|FALSE
+  gXXXPkgTokenSpaceGuid.PcdCsConfig1|TRUE
+  gXXXPkgTokenSpaceGuid.PcdCsConfig2|TRUE
+  gXXXPkgTokenSpaceGuid.PcdCsConfig3|TRUE
+  gXXXPkgTokenSpaceGuid.PcdFruConfig1|TRUE
+  gXXXPkgTokenSpaceGuid.PcdFruConfig2|TRUE
+  gXXXPkgTokenSpaceGuid.PcdFruConfig3|TRUE
+
+[PcdsDynamicDefault.Common.Sku5]
+  gXXXPkgTokenSpaceGuid.PcdCpuConfig1|TRUE
+  gXXXPkgTokenSpaceGuid.PcdCpuConfig2|TRUE
+  gXXXPkgTokenSpaceGuid.PcdCpuConfig3|TRUE
+  gXXXPkgTokenSpaceGuid.PcdCsConfig1|TRUE
+  gXXXPkgTokenSpaceGuid.PcdCsConfig2|TRUE
+  # gXXXPkgTokenSpaceGuid.PcdCsConfig3|FALSE
+  gXXXPkgTokenSpaceGuid.PcdFruConfig1|TRUE
+  gXXXPkgTokenSpaceGuid.PcdFruConfig2|TRUE
+  # gXXXPkgTokenSpaceGuid.PcdFruConfig3|FALSE
+
+[PcdsDynamicDefault.Common.Sku6]
+  gXXXPkgTokenSpaceGuid.PcdCpuConfig1|TRUE
+  gXXXPkgTokenSpaceGuid.PcdCpuConfig2|TRUE
+  gXXXPkgTokenSpaceGuid.PcdCpuConfig3|TRUE
+  gXXXPkgTokenSpaceGuid.PcdCsConfig1|TRUE
+  gXXXPkgTokenSpaceGuid.PcdCsConfig2|TRUE
+  # gXXXPkgTokenSpaceGuid.PcdCsConfig3|FALSE
+  gXXXPkgTokenSpaceGuid.PcdFruConfig1|TRUE
+  gXXXPkgTokenSpaceGuid.PcdFruConfig2|TRUE
+  gXXXPkgTokenSpaceGuid.PcdFruConfig3|TRUE
+
+[PcdsDynamicDefault.Common.Sku7]
+  gXXXPkgTokenSpaceGuid.PcdCpuConfig1|TRUE
+  gXXXPkgTokenSpaceGuid.PcdCpuConfig2|TRUE
+  gXXXPkgTokenSpaceGuid.PcdCpuConfig3|TRUE
+  gXXXPkgTokenSpaceGuid.PcdCsConfig1|TRUE
+  gXXXPkgTokenSpaceGuid.PcdCsConfig2|TRUE
+  gXXXPkgTokenSpaceGuid.PcdCsConfig3|TRUE
+  gXXXPkgTokenSpaceGuid.PcdFruConfig1|TRUE
+  gXXXPkgTokenSpaceGuid.PcdFruConfig2|TRUE
+  # gXXXPkgTokenSpaceGuid.PcdFruConfig3|FALSE
+
+[PcdsDynamicDefault.Common.Sku8]
+  gXXXPkgTokenSpaceGuid.PcdCpuConfig1|TRUE
+  gXXXPkgTokenSpaceGuid.PcdCpuConfig2|TRUE
+  gXXXPkgTokenSpaceGuid.PcdCpuConfig3|TRUE
+  gXXXPkgTokenSpaceGuid.PcdCsConfig1|TRUE
+  gXXXPkgTokenSpaceGuid.PcdCsConfig2|TRUE
+  gXXXPkgTokenSpaceGuid.PcdCsConfig3|TRUE
+  gXXXPkgTokenSpaceGuid.PcdFruConfig1|TRUE
+  gXXXPkgTokenSpaceGuid.PcdFruConfig2|TRUE
+  gXXXPkgTokenSpaceGuid.PcdFruConfig3|TRUE
+
+[PcdsDynamicDefault.Common.Sku9]
+  gXXXPkgTokenSpaceGuid.PcdCpuConfig1|TRUE
+  gXXXPkgTokenSpaceGuid.PcdCpuConfig2|TRUE
+  # gXXXPkgTokenSpaceGuid.PcdCpuConfig3|FALSE
+  gXXXPkgTokenSpaceGuid.PcdCsConfig1|TRUE
+  gXXXPkgTokenSpaceGuid.PcdCsConfig2|TRUE
+  gXXXPkgTokenSpaceGuid.PcdCsConfig3|TRUE
+
+[PcdsDynamicDefault.Common.Sku10]
+  gXXXPkgTokenSpaceGuid.PcdCpuConfig1|TRUE
+  gXXXPkgTokenSpaceGuid.PcdCpuConfig2|TRUE
+  gXXXPkgTokenSpaceGuid.PcdCpuConfig3|TRUE
+  gXXXPkgTokenSpaceGuid.PcdCsConfig1|TRUE
+  gXXXPkgTokenSpaceGuid.PcdCsConfig2|TRUE
+  gXXXPkgTokenSpaceGuid.PcdCsConfig3|TRUE
+
 ###################################################################################################
 #
 # Components Section - list of the modules and components that will be processed by compilation
-- 
2.7.0.windows.1

_______________________________________________
edk2-devel mailing list
edk2-devel@lists.01.org
https://lists.01.org/mailman/listinfo/edk2-devel