diff mbox

[Linaro-uefi] Platforms/AMD/Styx: remove A PRIORI FDF sections for dynamic PCDs

Message ID 1461849379-22688-1-git-send-email-ard.biesheuvel@linaro.org
State New
Headers show

Commit Message

Ard Biesheuvel April 28, 2016, 1:16 p.m. UTC
The default PcdLib resolution supports dynamic PCDs, and to do so, it
depends on dynamic PCD related PPIs and protocols that are produced by
the PEI and DXE versions of Pcd.inf, respectively. However, since these
inherit this default resolution, Pcd.inf depends on protocols it produces
itself, and can only be loaded forcefully using A PRIORI sections in the
FDF.

So instead, make Pcd.inf use the NULL PcdLib instance, so that it can be
dispatches in the normal way.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org>
---
 Platforms/AMD/Styx/HuskyBoard/HuskyBoard.dsc         | 10 ++++++++--
 Platforms/AMD/Styx/HuskyBoard/HuskyBoard.fdf         |  6 ------
 Platforms/AMD/Styx/OverdriveBoard/OverdriveBoard.dsc | 10 ++++++++--
 Platforms/AMD/Styx/OverdriveBoard/OverdriveBoard.fdf |  6 ------
 4 files changed, 16 insertions(+), 16 deletions(-)
diff mbox

Patch

diff --git a/Platforms/AMD/Styx/HuskyBoard/HuskyBoard.dsc b/Platforms/AMD/Styx/HuskyBoard/HuskyBoard.dsc
index bd4e23ddbf98..6b205bdd3631 100644
--- a/Platforms/AMD/Styx/HuskyBoard/HuskyBoard.dsc
+++ b/Platforms/AMD/Styx/HuskyBoard/HuskyBoard.dsc
@@ -548,7 +548,10 @@  DEFINE TRANS_CODE = $(EL3_TO_EL2)
   #
   ArmPlatformPkg/PrePeiCore/PrePeiCoreMPCore.inf
   MdeModulePkg/Core/Pei/PeiMain.inf
-  MdeModulePkg/Universal/PCD/Pei/Pcd.inf
+  MdeModulePkg/Universal/PCD/Pei/Pcd.inf {
+    <LibraryClasses>
+      PcdLib|MdePkg/Library/BasePcdLibNull/BasePcdLibNull.inf
+  }
   ArmPlatformPkg/PlatformPei/PlatformPeim.inf
   AmdModulePkg/Iscp/IscpPei.inf
   OpenPlatformPkg/Platforms/AMD/Styx/Drivers/PlatInitPei/PlatInitPei.inf
@@ -569,7 +572,10 @@  DEFINE TRANS_CODE = $(EL3_TO_EL2)
     <LibraryClasses>
       NULL|MdeModulePkg/Library/DxeCrc32GuidedSectionExtractLib/DxeCrc32GuidedSectionExtractLib.inf
   }
-  MdeModulePkg/Universal/PCD/Dxe/Pcd.inf
+  MdeModulePkg/Universal/PCD/Dxe/Pcd.inf {
+    <LibraryClasses>
+      PcdLib|MdePkg/Library/BasePcdLibNull/BasePcdLibNull.inf
+  }
 
   #
   # Architectural Protocols
diff --git a/Platforms/AMD/Styx/HuskyBoard/HuskyBoard.fdf b/Platforms/AMD/Styx/HuskyBoard/HuskyBoard.fdf
index 9668372c0228..a8003e700fb8 100644
--- a/Platforms/AMD/Styx/HuskyBoard/HuskyBoard.fdf
+++ b/Platforms/AMD/Styx/HuskyBoard/HuskyBoard.fdf
@@ -85,9 +85,6 @@  READ_STATUS        = TRUE
 READ_LOCK_CAP      = TRUE
 READ_LOCK_STATUS   = TRUE
 
-  APRIORI DXE {
-    INF MdeModulePkg/Universal/PCD/Dxe/Pcd.inf
-  }
   INF MdeModulePkg/Core/Dxe/DxeMain.inf
   INF MdeModulePkg/Universal/PCD/Dxe/Pcd.inf
 
@@ -246,9 +243,6 @@  READ_STATUS        = TRUE
 READ_LOCK_CAP      = TRUE
 READ_LOCK_STATUS   = TRUE
 
-  APRIORI PEI {
-    INF  MdeModulePkg/Universal/PCD/Pei/Pcd.inf
-  }
   INF ArmPlatformPkg/PrePeiCore/PrePeiCoreMPCore.inf
   INF MdeModulePkg/Core/Pei/PeiMain.inf
   INF ArmPlatformPkg/PlatformPei/PlatformPeim.inf
diff --git a/Platforms/AMD/Styx/OverdriveBoard/OverdriveBoard.dsc b/Platforms/AMD/Styx/OverdriveBoard/OverdriveBoard.dsc
index ae33f79f6f76..ceb1e60c621b 100644
--- a/Platforms/AMD/Styx/OverdriveBoard/OverdriveBoard.dsc
+++ b/Platforms/AMD/Styx/OverdriveBoard/OverdriveBoard.dsc
@@ -558,7 +558,10 @@  DEFINE TRANS_CODE = $(EL3_TO_EL2)
   #
   ArmPlatformPkg/PrePeiCore/PrePeiCoreMPCore.inf
   MdeModulePkg/Core/Pei/PeiMain.inf
-  MdeModulePkg/Universal/PCD/Pei/Pcd.inf
+  MdeModulePkg/Universal/PCD/Pei/Pcd.inf {
+    <LibraryClasses>
+      PcdLib|MdePkg/Library/BasePcdLibNull/BasePcdLibNull.inf
+  }
   ArmPlatformPkg/PlatformPei/PlatformPeim.inf
   AmdModulePkg/Iscp/IscpPei.inf
   OpenPlatformPkg/Platforms/AMD/Styx/Drivers/PlatInitPei/PlatInitPei.inf
@@ -579,7 +582,10 @@  DEFINE TRANS_CODE = $(EL3_TO_EL2)
     <LibraryClasses>
       NULL|MdeModulePkg/Library/DxeCrc32GuidedSectionExtractLib/DxeCrc32GuidedSectionExtractLib.inf
   }
-  MdeModulePkg/Universal/PCD/Dxe/Pcd.inf
+  MdeModulePkg/Universal/PCD/Dxe/Pcd.inf {
+    <LibraryClasses>
+      PcdLib|MdePkg/Library/BasePcdLibNull/BasePcdLibNull.inf
+  }
 
   #
   # Architectural Protocols
diff --git a/Platforms/AMD/Styx/OverdriveBoard/OverdriveBoard.fdf b/Platforms/AMD/Styx/OverdriveBoard/OverdriveBoard.fdf
index 7677718b76da..9583cbf1d32a 100644
--- a/Platforms/AMD/Styx/OverdriveBoard/OverdriveBoard.fdf
+++ b/Platforms/AMD/Styx/OverdriveBoard/OverdriveBoard.fdf
@@ -85,9 +85,6 @@  READ_STATUS        = TRUE
 READ_LOCK_CAP      = TRUE
 READ_LOCK_STATUS   = TRUE
 
-  APRIORI DXE {
-    INF MdeModulePkg/Universal/PCD/Dxe/Pcd.inf
-  }
   INF MdeModulePkg/Core/Dxe/DxeMain.inf
   INF MdeModulePkg/Universal/PCD/Dxe/Pcd.inf
 
@@ -239,9 +236,6 @@  READ_STATUS        = TRUE
 READ_LOCK_CAP      = TRUE
 READ_LOCK_STATUS   = TRUE
 
-  APRIORI PEI {
-    INF  MdeModulePkg/Universal/PCD/Pei/Pcd.inf
-  }
   INF ArmPlatformPkg/PrePeiCore/PrePeiCoreMPCore.inf
   INF MdeModulePkg/Core/Pei/PeiMain.inf
   INF ArmPlatformPkg/PlatformPei/PlatformPeim.inf