From 809fa30e7d254305ec5578af19ef19ad07cbc05f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20=C5=BBygowski?= Date: Thu, 25 May 2023 18:11:26 +0200 Subject: [PATCH] Library/DasharoSystemFeaturesUiLib/DasharoSystemFeatures.c: handle interactive NetworkBoot default MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Michał Żygowski --- .../DasharoSystemFeatures.c | 30 ++++++++++++++++++- 1 file changed, 29 insertions(+), 1 deletion(-) diff --git a/Library/DasharoSystemFeaturesUiLib/DasharoSystemFeatures.c b/Library/DasharoSystemFeaturesUiLib/DasharoSystemFeatures.c index 2d1a3f5..07e0b6f 100644 --- a/Library/DasharoSystemFeaturesUiLib/DasharoSystemFeatures.c +++ b/Library/DasharoSystemFeaturesUiLib/DasharoSystemFeatures.c @@ -908,5 +908,33 @@ DasharoSystemFeaturesCallback ( OUT EFI_BROWSER_ACTION_REQUEST *ActionRequest ) { - return EFI_UNSUPPORTED; + EFI_STATUS Status; + + Status = EFI_SUCCESS; + + switch (Action) { + case EFI_BROWSER_ACTION_DEFAULT_STANDARD: + case EFI_BROWSER_ACTION_DEFAULT_MANUFACTURING: + { + switch (QuestionId) { + case 0x1101: + { + if (Value == NULL) + return EFI_INVALID_PARAMETER; + + Value->b = PcdGetBool (PcdDefaultNetworkBootEnable); + break; + } + default: + Status = EFI_UNSUPPORTED; + break; + } + break; + } + default: + Status = EFI_UNSUPPORTED; + break; + } + + return Status; }