summaryrefslogtreecommitdiffstats
path: root/MdeModulePkg/Core/Pei/PeiMain.h
diff options
context:
space:
mode:
authorStar Zeng <star.zeng@intel.com>2018-11-15 11:21:46 +0800
committerStar Zeng <star.zeng@intel.com>2018-12-19 12:33:29 +0800
commit111e6c920d156e4160af1956747e6b8614f70f77 (patch)
treee65dac678b56787060b36636f4293665609e3815 /MdeModulePkg/Core/Pei/PeiMain.h
parentaa8c6e2ad388888af6bec9aea1ff252b75dd34dd (diff)
downloadedk2-111e6c920d156e4160af1956747e6b8614f70f77.tar.gz
edk2-111e6c920d156e4160af1956747e6b8614f70f77.tar.bz2
edk2-111e6c920d156e4160af1956747e6b8614f70f77.zip
MdeModulePkg PeiCore: Remove the using of PcdPeiCoreMaxFvSupported
REF: https://bugzilla.tianocore.org/show_bug.cgi?id=1405 Background as below. Problem: As static configuration from the PCDs, the binary PeiCore (for example in FSP binary with dispatch mode) could not predict how many FVs, Files or PPIs for different platforms. Burden: Platform developers need configure the PCDs accordingly for different platforms. To solve the problem and remove the burden, we can update PeiCore to remove the using of PcdPeiCoreMaxFvSupported, PcdPeiCoreMaxPeimPerFv and PcdPeiCoreMaxPpiSupported by extending buffer dynamically for FV, File and PPI management. This patch removes the using of PcdPeiCoreMaxFvSupported in PeiCore. Cc: Jian J Wang <jian.j.wang@intel.com> Cc: Hao Wu <hao.a.wu@intel.com> Cc: Liming Gao <liming.gao@intel.com> Cc: Ruiyu Ni <ruiyu.ni@intel.com> Cc: Michael D Kinney <michael.d.kinney@intel.com> Cc: Nate DeSimone <nathaniel.l.desimone@intel.com> Cc: Chasel Chiu <chasel.chiu@intel.com> Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Star Zeng <star.zeng@intel.com> Reviewed-by: Chasel Chiu <chasel.chiu@intel.com> Reviewed-by: Jian J Wang <jian.j.wang@intel.com>
Diffstat (limited to 'MdeModulePkg/Core/Pei/PeiMain.h')
-rw-r--r--MdeModulePkg/Core/Pei/PeiMain.h15
1 files changed, 13 insertions, 2 deletions
diff --git a/MdeModulePkg/Core/Pei/PeiMain.h b/MdeModulePkg/Core/Pei/PeiMain.h
index 195bdc3425..b103215d81 100644
--- a/MdeModulePkg/Core/Pei/PeiMain.h
+++ b/MdeModulePkg/Core/Pei/PeiMain.h
@@ -107,6 +107,11 @@ typedef struct {
#define PEIM_STATE_REGISTER_FOR_SHADOW 0x02
#define PEIM_STATE_DONE 0x03
+//
+// Number of FV instances to grow by each time we run out of room
+//
+#define FV_GROWTH_STEP 8
+
typedef struct {
EFI_FIRMWARE_VOLUME_HEADER *FvHeader;
EFI_PEI_FIRMWARE_VOLUME_PPI *FvPpi;
@@ -202,16 +207,22 @@ struct _PEI_CORE_INSTANCE {
UINTN FvCount;
///
- /// Pointer to the buffer with the PcdPeiCoreMaxFvSupported number of entries.
+ /// The max count of FVs which contains FFS and could be dispatched by PeiCore.
+ ///
+ UINTN MaxFvCount;
+
+ ///
+ /// Pointer to the buffer with the MaxFvCount number of entries.
/// Each entry is for one FV which contains FFS and could be dispatched by PeiCore.
///
PEI_CORE_FV_HANDLE *Fv;
///
- /// Pointer to the buffer with the PcdPeiCoreMaxFvSupported number of entries.
+ /// Pointer to the buffer with the MaxUnknownFvInfoCount number of entries.
/// Each entry is for one FV which could not be dispatched by PeiCore.
///
PEI_CORE_UNKNOW_FORMAT_FV_INFO *UnknownFvInfo;
+ UINTN MaxUnknownFvInfoCount;
UINTN UnknownFvInfoCount;
///