public inbox for devel@edk2.groups.io
 help / color / mirror / Atom feed
* [PATCH] Platform/Intel: Add fspapi build parameter
@ 2019-05-28  7:52 Chiu, Chasel
  2019-05-29  0:45 ` Nate DeSimone
  0 siblings, 1 reply; 2+ messages in thread
From: Chiu, Chasel @ 2019-05-28  7:52 UTC (permalink / raw)
  To: devel; +Cc: Agyeman Prince, Nate DeSimone, Michael Kubacki

REF: https://bugzilla.tianocore.org/show_bug.cgi?id=1824

Going forward FSP Dispatch mode will be default in
KabylakeOpenBoardPkg and requires fspapi build parameter
to switch back to FSP API mode.
When --fspapi given to build python script it will set
gIntelFsp2WrapperTokenSpaceGuid.PcdFspModeSelection to
1, otherwise the PCD will be the default value defined
by each *BoardPkg.

Test: verified the PCD PcdFspModeSelection can be
      overridden by new build parameter.

Cc: Agyeman Prince <prince.agyeman@intel.com>
Cc: Nate DeSimone <nathaniel.l.desimone@intel.com>
Cc: Michael Kubacki <michael.a.kubacki@intel.com>
Signed-off-by: Chasel Chiu <chasel.chiu@intel.com>
---
 Platform/Intel/build_bios.py | 13 ++++++++++++-
 1 file changed, 12 insertions(+), 1 deletion(-)

diff --git a/Platform/Intel/build_bios.py b/Platform/Intel/build_bios.py
index 9effefc0c7..9f8d78f6e8 100644
--- a/Platform/Intel/build_bios.py
+++ b/Platform/Intel/build_bios.py
@@ -359,6 +359,11 @@ def build(config):
         command.append("-D")
         command.append("MAX_SOCKET=" + config["MAX_SOCKET"])
 
+    if config.get("API_MODE_FSP_WRAPPER_BUILD", "FALSE") == "TRUE":
+        #Override PCD to enable API mode FSP wrapper.
+        command.append("--pcd")
+        command.append("gIntelFsp2WrapperTokenSpaceGuid.PcdFspModeSelection=1")
+
     shell = True
     if os.name == "posix":
         shell = False
@@ -840,6 +845,9 @@ def get_cmd_config_arguments(arguments):
     if arguments.fsp is True:
         result["FSP_WRAPPER_BUILD"] = "TRUE"
 
+    if arguments.fspapi is True:
+        result["API_MODE_FSP_WRAPPER_BUILD"] = "TRUE"
+
     return result
 
 
@@ -910,9 +918,12 @@ def get_cmd_arguments(build_config):
     parser.add_argument("--performance", help="performance build enabled",
                         action='store_true', dest="performance")
 
-    parser.add_argument("--fsp", help="fsp build enabled",
+    parser.add_argument("--fsp", help="fsp wrapper build enabled",
                         action='store_true', dest="fsp")
 
+    parser.add_argument("--fspapi", help="API mode fsp wrapper build enabled",
+                        action='store_true', dest="fspapi")
+
     return parser.parse_args()
 
 
-- 
2.13.3.windows.1


^ permalink raw reply related	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2019-05-29  0:45 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2019-05-28  7:52 [PATCH] Platform/Intel: Add fspapi build parameter Chiu, Chasel
2019-05-29  0:45 ` Nate DeSimone

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox