diff options
author | Ilias Apalodimas <ilias.apalodimas@linaro.org> | 2020-04-16 21:40:54 +0300 |
---|---|---|
committer | Ilias Apalodimas <ilias.apalodimas@linaro.org> | 2020-04-29 11:29:42 +0300 |
commit | ffbcda2d2a2220aefbf3c9ab424f06c1220dd785 (patch) | |
tree | c419e7990c6a1eef9bf681a3b58059c27e7b850a | |
parent | ed1c7d900e080a418c6746201a4b0d77de307c6a (diff) |
MdeModulePkg: move PcdFlashNvStorageVariableBase(64) to Pcd4upstream
With the latest OP-TEE patches we can compile StandAloneMM as a single
binary and run it in a secure partition. By doing so we can leverage the
OP-TEE APIs and store EFI variables in an RPMB.
This opens up possibilities for different firmware implementations to
securely store EFI variables (i.e U-Boot) using OP-TEE.
Since RPMB is not byte-addressable, the RPMB driver allocates memory,
which is passed in EDK2 upper layers and syncs the memory/hardware on
read/write operations.
The driver allocates memory in runtime, but Dynamic PCDs are not
available in that context. Patchable PCDs are used to update the
PcdFlashNvStorageVariableBase.
So let's switch the to Pcd instead of FixedPcd and allow the driver to
patch the PcdFlashNvStorageVariableBase.
Signed-off-by: Ilias Apalodimas <ilias.apalodimas@linaro.org>
-rw-r--r-- | MdeModulePkg/Universal/Variable/RuntimeDxe/VariableStandaloneMm.inf | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/MdeModulePkg/Universal/Variable/RuntimeDxe/VariableStandaloneMm.inf b/MdeModulePkg/Universal/Variable/RuntimeDxe/VariableStandaloneMm.inf index 6e17f6cdf5..0f6530f1aa 100644 --- a/MdeModulePkg/Universal/Variable/RuntimeDxe/VariableStandaloneMm.inf +++ b/MdeModulePkg/Universal/Variable/RuntimeDxe/VariableStandaloneMm.inf @@ -115,10 +115,12 @@ ## SOMETIMES_PRODUCES ## Variable:L"VarErrorFlag"
gEdkiiVarErrorFlagGuid
-[FixedPcd]
- gEfiMdeModulePkgTokenSpaceGuid.PcdFlashNvStorageVariableSize ## CONSUMES
+[Pcd]
gEfiMdeModulePkgTokenSpaceGuid.PcdFlashNvStorageVariableBase ## SOMETIMES_CONSUMES
gEfiMdeModulePkgTokenSpaceGuid.PcdFlashNvStorageVariableBase64 ## CONSUMES
+
+[FixedPcd]
+ gEfiMdeModulePkgTokenSpaceGuid.PcdFlashNvStorageVariableSize ## CONSUMES
gEfiMdeModulePkgTokenSpaceGuid.PcdMaxVariableSize ## CONSUMES
gEfiMdeModulePkgTokenSpaceGuid.PcdMaxAuthVariableSize ## CONSUMES
gEfiMdeModulePkgTokenSpaceGuid.PcdMaxVolatileVariableSize ## CONSUMES
|