From a2e61f341d26a78751b2f19b5004c6bbfc8b4fa9 Mon Sep 17 00:00:00 2001 From: "Chasel, Chiu" Date: Thu, 11 Oct 2018 21:22:12 +0800 Subject: IntelFsp2Pkg: Support FSP Dispatch mode REF: https://bugzilla.tianocore.org/show_bug.cgi?id=1241 Add support for both API (original mode) and DISPATCH mode: 1. Add FspMode field from reserved byte of Global Data Structure to tell which mode is selected by boot loader. If boot loader invoking FSP-M API this field will remain as default 0 (API mode), otherwise platform FSP should set this field to 1 (Dispatch mode) when initializing Global Data Structure. 2. gFspInApiModePpiGuid will be instaled when FSP running in API mode and modules only for API mode should have this in depex. 3. If it is DISPATCH mode, FSP will return to PEI dispatcher, not directly return to boot loader. 4. DISPATCH mode supports DXE NotifyPhase drivers so FSP will not wait for PEI NotifyPhase callbacks, instead it will install gFspReadyForNotifyPhasePpiGuid PPI for platform to complete late initialization before transferring to DXE. Test: Verified FSP API and DISPATCH modes on 2 internal platforms and both boot successfully. Cc: Jiewen Yao Cc: Desimone Nathaniel L Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Chasel Chiu Reviewed-by: Jiewen Yao --- IntelFsp2Pkg/IntelFsp2Pkg.dec | 12 ++++++++++++ 1 file changed, 12 insertions(+) (limited to 'IntelFsp2Pkg/IntelFsp2Pkg.dec') diff --git a/IntelFsp2Pkg/IntelFsp2Pkg.dec b/IntelFsp2Pkg/IntelFsp2Pkg.dec index b2ee4b6ef5..5b037d65e2 100644 --- a/IntelFsp2Pkg/IntelFsp2Pkg.dec +++ b/IntelFsp2Pkg/IntelFsp2Pkg.dec @@ -43,6 +43,18 @@ ## @libraryclass Provides FSP platform sec related actions. FspSecPlatformLib|Include/Library/FspSecPlatformLib.h +[Ppis] + # + # PPI to indicate FSP is ready to enter notify phase + # This provides flexibility for any late initialization that must be done right before entering notify phase. + # + gFspReadyForNotifyPhasePpiGuid = { 0xcd167c1e, 0x6e0b, 0x42b3, { 0x82, 0xf6, 0xe3, 0xe9, 0x6, 0x19, 0x98, 0x10}} + + # + # PPI as dependency on some modules which only required for API mode + # + gFspInApiModePpiGuid = { 0xa1eeab87, 0xc859, 0x479d, {0x89, 0xb5, 0x14, 0x61, 0xf4, 0x06, 0x1a, 0x3e}} + [Guids] # # GUID defined in package -- cgit v1.2.3