summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGerd Hoffmann <kraxel@redhat.com>2024-06-19 09:07:56 +0200
committermergify[bot] <37929162+mergify[bot]@users.noreply.github.com>2024-06-27 15:14:56 +0000
commit6862b9d538d96363635677198899e1669e591259 (patch)
treee20b9eb7a08cfd3affede4e91ee3cdbb959b5dbc
parentae09721a65ab3294439f6fa233adaf3b897f702f (diff)
downloadedk2-6862b9d538d96363635677198899e1669e591259.tar.gz
edk2-6862b9d538d96363635677198899e1669e591259.tar.bz2
edk2-6862b9d538d96363635677198899e1669e591259.zip
NetworkPkg/DxeNetLib: adjust PseudoRandom error logging
There is a list of allowed rng algorithms, if /one/ of them is not supported this is not a problem, only /all/ of them failing is an error condition. Downgrade the message for a single unsupported algorithm from ERROR to VERBOSE. Add an error message in case we finish the loop without finding a supported algorithm. Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
-rw-r--r--NetworkPkg/Library/DxeNetLib/DxeNetLib.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/NetworkPkg/Library/DxeNetLib/DxeNetLib.c b/NetworkPkg/Library/DxeNetLib/DxeNetLib.c
index 01c13c08d2..4dfbe91a55 100644
--- a/NetworkPkg/Library/DxeNetLib/DxeNetLib.c
+++ b/NetworkPkg/Library/DxeNetLib/DxeNetLib.c
@@ -951,7 +951,7 @@ PseudoRandom (
//
// Secure Algorithm was not supported on this platform
//
- DEBUG ((DEBUG_ERROR, "Failed to generate random data using secure algorithm %d: %r\n", AlgorithmIndex, Status));
+ DEBUG ((DEBUG_VERBOSE, "Failed to generate random data using secure algorithm %d: %r\n", AlgorithmIndex, Status));
//
// Try the next secure algorithm
@@ -971,6 +971,7 @@ PseudoRandom (
// If we get here, we failed to generate random data using any secure algorithm
// Platform owner should ensure that at least one secure algorithm is supported
//
+ DEBUG ((DEBUG_ERROR, "Failed to generate random data, no supported secure algorithm found\n"));
ASSERT_EFI_ERROR (Status);
return Status;
}