[edk2] [RFC 2/2] Example: The PCDs configuring for multiple SKUs with sub SKU support

Star Zeng posted 2 patches 7 years, 6 months ago
[edk2] [RFC 2/2] Example: The PCDs configuring for multiple SKUs with sub SKU support
Posted by Star Zeng 7 years, 6 months ago
---
 Nt32Pkg/Nt32Pkg.dsc | 116 ++++++++--------------------------------------------
 1 file changed, 16 insertions(+), 100 deletions(-)

diff --git a/Nt32Pkg/Nt32Pkg.dsc b/Nt32Pkg/Nt32Pkg.dsc
index 573875fe4b95..7b468c18ad7a 100644
--- a/Nt32Pkg/Nt32Pkg.dsc
+++ b/Nt32Pkg/Nt32Pkg.dsc
@@ -86,16 +86,15 @@ [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
+  CpuSku | CpuSkuA | DEFAULT
+  CpuSku | CpuSkuB | CpuSkuA
+  CsSku | CsSkuA | DEFAULT
+  CsSku | CsSkuB | CsSkuA
+  FruSku | FruSkuA | DEFAULT
+  FruSku | FruSkuB | FruSkuA
+
+  Combo1 | (CpuSku , CsSku, FruSku)
+  Combo2 | (CpuSku , CsSkuB)
 
 ################################################################################
 #
@@ -348,109 +347,26 @@ [PcdsDynamicDefault.Common.DEFAULT]
   gXXXPkgTokenSpaceGuid.PcdFruConfig2|FALSE
   gXXXPkgTokenSpaceGuid.PcdFruConfig3|FALSE
 
-[PcdsDynamicDefault.Common.Sku1]
+[PcdsDynamicDefault.Common.CpuA]
   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
+[PcdsDynamicDefault.Common.CpuB]
   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
+[PcdsDynamicDefault.Common.CsA]
   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
+[PcdsDynamicDefault.Common.CsB]
   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
+[PcdsDynamicDefault.Common.FruA]
   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
+[PcdsDynamicDefault.Common.FruB]
+  gXXXPkgTokenSpaceGuid.PcdFruConfig3|TRUE
 
 ###################################################################################################
 #
-- 
2.7.0.windows.1

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