]> git.proxmox.com Git - mirror_edk2.git/commit - MdeModulePkg/Universal/PCD/Pei/Pcd.inf
MdeModulePkg: Update PCD driver to support the optimized PcdDataBase
authorLiming Gao <liming.gao@intel.com>
Fri, 22 Dec 2017 05:41:54 +0000 (13:41 +0800)
committerLiming Gao <liming.gao@intel.com>
Mon, 25 Dec 2017 03:05:57 +0000 (11:05 +0800)
commit7c73626513238176bdd16dca14fcf3f9e10bcc81
tree9a75f70d555811e298a00fbc0db906ec0e8ce6af
parent219247e16462d72e3b22db4e21bfaec256cc5fbb
MdeModulePkg: Update PCD driver to support the optimized PcdDataBase

https://bugzilla.tianocore.org/show_bug.cgi?id=546
BaseTools will generate the optimized PCD database to save the image size
at build time for multiple SKUs. The optimized PCD database layout will be like
below, the PCD database will be composed of the full default SKU data
(PCD_DATABASE_INIT) and the non-default SKU delta data(PCD_DATABASE_SKU_DELTA).
PCD driver will build HOB to store the full default SKU data, and patch HOB
data based on non-default SKU delta data for the SKU set by SetSku(),
it can save memory resource at boot time.

//
// PCD database layout:
// +---------------------------------+
// | PCD_DATABASE_INIT (DEFAULT SKU) |
// +---------------------------------+
// | PCD_DATABASE_SKU_DELTA (SKU A)  |
// +---------------------------------+
// | PCD_DATABASE_SKU_DELTA (SKU B)  |
// +---------------------------------+
// | ......                          |
// +---------------------------------+
//

BaseTools, PCD database and driver updates are needed for this proposal.
For single SKU (default) case, this proposal is expected to have no impact.
For multi-SKU case, PCD database format will be changed.
So, PcdDataBase Version is also updated from 6 to 7.

Contributed-under: TianoCore Contribution Agreement 1.1
Signed-off-by: Liming Gao <liming.gao@intel.com>
Reviewed-by: Star Zeng <star.zeng@intel.com>
MdeModulePkg/Include/Guid/PcdDataBaseSignatureGuid.h
MdeModulePkg/Universal/PCD/Dxe/Pcd.c
MdeModulePkg/Universal/PCD/Dxe/Service.c
MdeModulePkg/Universal/PCD/Dxe/Service.h
MdeModulePkg/Universal/PCD/Pei/Pcd.c
MdeModulePkg/Universal/PCD/Pei/Pcd.inf
MdeModulePkg/Universal/PCD/Pei/Service.c
MdeModulePkg/Universal/PCD/Pei/Service.h