[edk2-devel] [PATCH 2/2] IntelSiliconPkg/VTd: Add PCD flag for select pre-boot DMA protection Driver
Sheng Wei
w.sheng at intel.com
Wed Dec 2 02:20:34 UTC 2020
gIntelSiliconPkgTokenSpaceGuid.PcdVtdDmarPeiEnable is added for select
pre-boot DMA protection driver in PEI phase.
IntelVTdPmrPei driver is used to do the pre-boot DMA protection by PMR.
IntelVTdDmarPei driver is used to do the pre-boot DMA protection by DMAR.
REF: https://bugzilla.tianocore.org/show_bug.cgi?id=3095
Signed-off-by: Sheng Wei <w.sheng at intel.com>
Cc: Ray Ni <ray.ni at intel.com>
Cc: Rangasai V Chaganty <rangasai.v.chaganty at intel.com>
Cc: Jiewen Yao <jiewen.yao at intel.com>
Cc: Jenny Huang <jenny.huang at intel.com>
Cc: Feng Roger <roger.feng at intel.com>
---
Silicon/Intel/IntelSiliconPkg/IntelSiliconPkg.dec | 5 +++++
Silicon/Intel/IntelSiliconPkg/IntelSiliconPkg.dsc | 4 ++++
2 files changed, 9 insertions(+)
diff --git a/Silicon/Intel/IntelSiliconPkg/IntelSiliconPkg.dec b/Silicon/Intel/IntelSiliconPkg/IntelSiliconPkg.dec
index 284820af..2cfed22d 100644
--- a/Silicon/Intel/IntelSiliconPkg/IntelSiliconPkg.dec
+++ b/Silicon/Intel/IntelSiliconPkg/IntelSiliconPkg.dec
@@ -114,3 +114,8 @@
# @Prompt The VTd PEI DMA buffer size for S3.
gIntelSiliconPkgTokenSpaceGuid.PcdVTdPeiDmaBufferSizeS3|0x00200000|UINT32|0x00000004
+ ## Declares the VTd PEI driver to protect DMA.<BR><BR>
+ # TRUE: Use DMAR to protect DMA at PEI phase
+ # FALSE: Use PMR to protect DMA at PEI phase
+ gIntelSiliconPkgTokenSpaceGuid.PcdVtdDmarPeiEnable|FALSE|BOOLEAN|0x00000006
+
diff --git a/Silicon/Intel/IntelSiliconPkg/IntelSiliconPkg.dsc b/Silicon/Intel/IntelSiliconPkg/IntelSiliconPkg.dsc
index 029b9156..6feb5a99 100644
--- a/Silicon/Intel/IntelSiliconPkg/IntelSiliconPkg.dsc
+++ b/Silicon/Intel/IntelSiliconPkg/IntelSiliconPkg.dsc
@@ -80,7 +80,11 @@
IntelSiliconPkg/Feature/PcieSecurity/IntelPciDeviceSecurityDxe/IntelPciDeviceSecurityDxe.inf
IntelSiliconPkg/Feature/PcieSecurity/SamplePlatformDevicePolicyDxe/SamplePlatformDevicePolicyDxe.inf
IntelSiliconPkg/Feature/VTd/IntelVTdDxe/IntelVTdDxe.inf
+!if gIntelSiliconPkgTokenSpaceGuid.PcdVtdDmarPeiEnable == TRUE
+ IntelSiliconPkg/Feature/VTd/IntelVTdDmarPei/IntelVTdDmarPei.inf
+!else
IntelSiliconPkg/Feature/VTd/IntelVTdPmrPei/IntelVTdPmrPei.inf
+!endif
IntelSiliconPkg/Feature/VTd/PlatformVTdSampleDxe/PlatformVTdSampleDxe.inf
IntelSiliconPkg/Feature/VTd/PlatformVTdInfoSamplePei/PlatformVTdInfoSamplePei.inf
IntelSiliconPkg/Feature/Capsule/MicrocodeUpdateDxe/MicrocodeUpdateDxe.inf
--
2.16.2.windows.1
-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#68155): https://edk2.groups.io/g/devel/message/68155
Mute This Topic: https://groups.io/mt/78651227/1813853
Group Owner: devel+owner at edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub [edk2-devel-archive at redhat.com]
-=-=-=-=-=-=-=-=-=-=-=-
More information about the edk2-devel-archive
mailing list