summaryrefslogtreecommitdiffstats
path: root/OvmfPkg/Include
diff options
context:
space:
mode:
authorGerd Hoffmann <kraxel@redhat.com>2024-05-24 12:51:17 +0200
committerArd Biesheuvel <workofard@gmail.com>2024-06-13 08:52:48 -0700
commit712797cf19acd292bf203522a79e40e7e13d268b (patch)
treeb0f96dfd80e4ff2a9f8c9d2a7d6204c35301ede0 /OvmfPkg/Include
parenta61bc0accb8a76edba4f073fdc7bafc908df045d (diff)
downloadedk2-712797cf19acd292bf203522a79e40e7e13d268b.tar.gz
edk2-712797cf19acd292bf203522a79e40e7e13d268b.tar.bz2
edk2-712797cf19acd292bf203522a79e40e7e13d268b.zip
OvmfPkg: wire up RngDxe
Add OvmfRng include snippets with the random number generator configuration for OVMF. Include RngDxe, build with BaseRngLib, so the rdrand instruction is used (if available). Also move VirtioRng to the include snippets. Use the new include snippets for OVMF builds. Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
Diffstat (limited to 'OvmfPkg/Include')
-rw-r--r--OvmfPkg/Include/Dsc/OvmfRngComponents.dsc.inc9
-rw-r--r--OvmfPkg/Include/Fdf/OvmfRngDxe.fdf.inc6
2 files changed, 15 insertions, 0 deletions
diff --git a/OvmfPkg/Include/Dsc/OvmfRngComponents.dsc.inc b/OvmfPkg/Include/Dsc/OvmfRngComponents.dsc.inc
new file mode 100644
index 0000000000..68839a0caa
--- /dev/null
+++ b/OvmfPkg/Include/Dsc/OvmfRngComponents.dsc.inc
@@ -0,0 +1,9 @@
+##
+# SPDX-License-Identifier: BSD-2-Clause-Patent
+##
+
+ SecurityPkg/RandomNumberGenerator/RngDxe/RngDxe.inf {
+ <LibraryClasses>
+ RngLib|MdePkg/Library/BaseRngLib/BaseRngLib.inf
+ }
+ OvmfPkg/VirtioRngDxe/VirtioRng.inf
diff --git a/OvmfPkg/Include/Fdf/OvmfRngDxe.fdf.inc b/OvmfPkg/Include/Fdf/OvmfRngDxe.fdf.inc
new file mode 100644
index 0000000000..99cb4a32b1
--- /dev/null
+++ b/OvmfPkg/Include/Fdf/OvmfRngDxe.fdf.inc
@@ -0,0 +1,6 @@
+##
+# SPDX-License-Identifier: BSD-2-Clause-Patent
+##
+
+INF SecurityPkg/RandomNumberGenerator/RngDxe/RngDxe.inf
+INF OvmfPkg/VirtioRngDxe/VirtioRng.inf