From 203d30bedd01e953a2f5962877c87da7a1d6fcc3 Mon Sep 17 00:00:00 2001 From: Oliver Steffen Date: Mon, 4 Nov 2024 19:00:11 +0100 Subject: [PATCH] OvmfPkg: Rerun dispatcher after initializing virtio-rng RH-Author: Oliver Steffen RH-MergeRequest: 105: OvmfPkg: Rerun dispatcher after initializing virtio-rng RH-Jira: RHEL-63094 RH-Acked-by: Gerd Hoffmann RH-Commit: [1/1] 87d0a3f9392d3b7788193148ee74f6edfe719a3e Since the pixiefail CVE fix the network stack requires a hardware random number generator. This can currently be a modern CPU supporting the RDRAND instruction or a virtio-rng device. The latter is initialized during the BDS phase. To ensure all depending (network) modules are also started, we need to run the dispatcher once more after the device was initialized. Without this, network boot is not available under certain hardware configurations. Fixes: 4c4ceb2ceb ("NetworkPkg: SECURITY PATCH CVE-2023-45237") Analysed-by: Stefano Garzarella Suggested-by: Gerd Hoffmann Signed-off-by: Oliver Steffen --- OvmfPkg/Library/PlatformBootManagerLib/BdsPlatform.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/OvmfPkg/Library/PlatformBootManagerLib/BdsPlatform.c b/OvmfPkg/Library/PlatformBootManagerLib/BdsPlatform.c index 87d1ac3142..1f1298eb0b 100644 --- a/OvmfPkg/Library/PlatformBootManagerLib/BdsPlatform.c +++ b/OvmfPkg/Library/PlatformBootManagerLib/BdsPlatform.c @@ -675,6 +675,8 @@ ConnectVirtioPciRng ( if (EFI_ERROR (Status)) { goto Error; } + + gDS->Dispatch (); } return EFI_SUCCESS; -- 2.45.1