From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mx0a-002e3701.pphosted.com (mx0a-002e3701.pphosted.com [148.163.147.86]) by mx.groups.io with SMTP id smtpd.web10.4844.1604372307281312503 for ; Mon, 02 Nov 2020 18:58:27 -0800 Authentication-Results: mx.groups.io; dkim=fail reason="body hash did not verify" header.i=@hpe.com header.s=pps0720 header.b=PKeKs5bT; spf=pass (domain: hpe.com, ip: 148.163.147.86, mailfrom: prvs=0576d3f819=abner.chang@hpe.com) Received: from pps.filterd (m0150241.ppops.net [127.0.0.1]) by mx0a-002e3701.pphosted.com (8.16.0.42/8.16.0.42) with SMTP id 0A32w3p8028772; Tue, 3 Nov 2020 02:58:26 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=hpe.com; h=from : to : cc : subject : date : message-id : in-reply-to : references : mime-version : content-type : content-transfer-encoding; s=pps0720; bh=Q6RcwltQ54K+iytT4afH4ahK+ezctN5YlzFQuONFHxs=; b=PKeKs5bTqclEq1Jzd7D9qOj2ZnS4RKLFtN9y0H3hwcI6OquvDYUEtwVtpdoKt/m50N2P PXQm8x9HzolSdHW9jpKiBB4AxAfPIKz0LKE9nUh82StZPUBB12nduzivRN1KwxGj8L5L WlWf46c1g4rRZ2UqxWd/AwpXRfzVWripDMR3XPR+tDBi4pj45gdPnrPTFFue/IkjU2Zx 7b6UZh3QHVRZK2OKxicFUiQn/auLHzr7kok8NQbbro4tlGeB0Mf4nJHbGMpkwwQukpkK OudKDM1XLe2seEgjFxdZI8Ji6+/xOgt1QKsmTVJf4JKfO8BJmJyUHhcSMrMoqd3qkfnm yg== Received: from g4t3427.houston.hpe.com (g4t3427.houston.hpe.com [15.241.140.73]) by mx0a-002e3701.pphosted.com with ESMTP id 34hhavyfe0-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Tue, 03 Nov 2020 02:58:26 +0000 Received: from g4t3433.houston.hpecorp.net (g4t3433.houston.hpecorp.net [16.208.49.245]) by g4t3427.houston.hpe.com (Postfix) with ESMTP id AF0A657; Tue, 3 Nov 2020 02:58:25 +0000 (UTC) Received: from abner-virtual-machine.asiapacific.hpqcorp.net (abner-virtual-machine.asiapacific.hpqcorp.net [15.119.210.153]) by g4t3433.houston.hpecorp.net (Postfix) with ESMTP id 01B1445; Tue, 3 Nov 2020 02:58:23 +0000 (UTC) From: "Abner Chang" To: devel@edk2.groups.io Cc: Jiaxin Wu , Siyuan Fu , Fan Wang , Jiewen Yao , Dandan Bi , Eric Dong , Nickle Wang Subject: [VFR support REST_STYLE PATCH 3/3] MdeModulePkg/DriverSampleDxe: Add HII sample options Date: Tue, 3 Nov 2020 10:12:48 +0800 Message-Id: <20201103021248.7019-4-abner.chang@hpe.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20201103021248.7019-1-abner.chang@hpe.com> References: <20201103021248.7019-1-abner.chang@hpe.com> MIME-Version: 1.0 X-HPE-SCL: -1 X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:6.0.312,18.0.737 definitions=2020-11-02_16:2020-11-02,2020-11-02 signatures=0 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 phishscore=0 mlxlogscore=999 adultscore=0 suspectscore=1 malwarescore=0 bulkscore=0 spamscore=0 impostorscore=0 lowpriorityscore=0 priorityscore=1501 mlxscore=0 clxscore=1015 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2009150000 definitions=main-2011030019 X-MIME-Autoconverted: from 8bit to quoted-printable by mx0a-002e3701.pphosted.com id 0A32w3p8028772 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Add x-uefi-ns keyword REST_STYLE HII option and non x-uefi keyword REST_STYLE HII option. Signed-off-by: Abner Chang Cc: Jiaxin Wu Cc: Siyuan Fu Cc: Fan Wang Cc: Jiewen Yao Cc: Dandan Bi Cc: Eric Dong Cc: Nickle Wang --- .../Universal/DriverSampleDxe/NVDataStruc.h | 4 ++- .../Universal/DriverSampleDxe/Vfr.vfr | 32 +++++++++++++++++-- .../Universal/DriverSampleDxe/VfrStrings.uni | 11 +++++-- 3 files changed, 40 insertions(+), 7 deletions(-) diff --git a/MdeModulePkg/Universal/DriverSampleDxe/NVDataStruc.h b/MdeMo= dulePkg/Universal/DriverSampleDxe/NVDataStruc.h index 8617617684..761f5e169c 100644 --- a/MdeModulePkg/Universal/DriverSampleDxe/NVDataStruc.h +++ b/MdeModulePkg/Universal/DriverSampleDxe/NVDataStruc.h @@ -1,6 +1,7 @@ /** @file =20 -Copyright (c) 2007 - 2018, Intel Corporation. All rights reserved.
+Copyright (c) 2007 - 2018, Intel Corporation. All rights reserved.
* +(C) Copyright 2020 Hewlett Packard Enterprise Development LP
SPDX-License-Identifier: BSD-2-Clause-Patent =20 Module Name: @@ -92,6 +93,7 @@ typedef struct { UINT16 BitNumeric : 12; MY_BITS_DATA MyBitData; MY_EFI_UNION_DATA MyUnionData; + UINT8 QuestionNonXUefiKeywordRestStyle; } DRIVER_SAMPLE_CONFIGURATION; =20 // diff --git a/MdeModulePkg/Universal/DriverSampleDxe/Vfr.vfr b/MdeModulePk= g/Universal/DriverSampleDxe/Vfr.vfr index 65a65d4d1d..eecb062320 100644 --- a/MdeModulePkg/Universal/DriverSampleDxe/Vfr.vfr +++ b/MdeModulePkg/Universal/DriverSampleDxe/Vfr.vfr @@ -3,6 +3,7 @@ // Sample Setup formset. // // Copyright (c) 2004 - 2018, Intel Corporation. All rights reserved. +// (C) Copyright 2020 Hewlett Packard Enterprise Development LP
// SPDX-License-Identifier: BSD-2-Clause-Patent // //**/ @@ -280,15 +281,40 @@ formset =20 endoneof; =20 + // + // This is an HII option which has REST_STYLE flag and x-UEFI namesp= ace + // UNI string associated. This HII option could be configured by eit= her in-band + // edk2 setup browser or the remote management in out-of-band such a= s Redfish + // service. This HII option is configured through EFI_KEYWORD_HANDLE= R_PROTOCOL. + // oneof varid =3D MyIfrNVData.QuestionAboutTreeHugging, - prompt =3D STRING_TOKEN(STR_ONE_OF_PROMPT_KEYWORD), - help =3D STRING_TOKEN(STR_ONE_OF_HELP), - flags =3D RESET_REQUIRED, + prompt =3D STRING_TOKEN(STR_ONE_OF_PROMPT_X_UEFI), + help =3D STRING_TOKEN(STR_ONE_OF_PROMPT_X_UEFI_HELP), + flags =3D RESET_REQUIRED | REST_STYLE, option text =3D STRING_TOKEN(STR_ONE_OF_TEXT1), value =3D 0, flags= =3D 0; option text =3D STRING_TOKEN(STR_ONE_OF_TEXT2), value =3D 1, flags= =3D DEFAULT; option text =3D STRING_TOKEN(STR_ONE_OF_TEXT3), value =3D 3, flags= =3D 0; endoneof; =20 + // + // This is a HII option which has REST_STYLE flag but without the x-= UEFI namespace + // UNI string associated. This HII option could be configured by eit= her + // setup browser or the remote management in out-of-band such as Red= fish + // service. This HII option is configured through EFI HII Configurat= ion Routing + // Protocol becasue it doesn't have x-UEFI namespace UNI string. + // + numeric varid =3D MyIfrNVData.QuestionNonXUefiKeywordRestStyle, + prompt =3D STRING_TOKEN(STR_ONE_OF_PROMPT_NON_X_UEFI), + help =3D STRING_TOKEN(STR_ONE_OF_PROMPT_NON_X_UEFI_HELP), + flags =3D RESET_REQUIRED | REST_STYLE, + minimum =3D 0, + maximum =3D 0xf0, + step =3D 0, // Stepping of 0 equates to a manual = entering + // of a value, otherwise it will be adj= usted by "+"/"-" + default =3D 0, // defaultstore could be used to spec= ify the default type + // If no defaultstore is specified, it = implies Standard Default + endnumeric; + // // Define a string (EFI_IFR_STRING) // diff --git a/MdeModulePkg/Universal/DriverSampleDxe/VfrStrings.uni b/MdeM= odulePkg/Universal/DriverSampleDxe/VfrStrings.uni index bafa194c63..e67b888783 100644 --- a/MdeModulePkg/Universal/DriverSampleDxe/VfrStrings.uni +++ b/MdeModulePkg/Universal/DriverSampleDxe/VfrStrings.uni @@ -1,6 +1,7 @@ // *++ // // Copyright (c) 2007 - 2018, Intel Corporation. All rights reserved. +# (C) Copyright 2020 Hewlett Packard Enterprise Development LP
// SPDX-License-Identifier: BSD-2-Clause-Patent // // Module Name: @@ -51,9 +52,13 @@ #language fr-FR "Check the input = number, test the efi buffer varstore" #string STR_ONE_OF_PROMPT #language en-US "My one-of prompt= #1" #language fr-FR "Mi uno- de gu=C3= =ADa # 1" -#string STR_ONE_OF_PROMPT_KEYWORD #language en-US "My Keyword Names= pace Test" - #language fr-FR "My Keyword Names= pace Test" - #language x-UEFI-ns "iSCSIBootEna= ble" +#string STR_ONE_OF_PROMPT_X_UEFI #language en-US "x-UEFI HII Optio= n" + #language fr-FR "x-UEFI HII Optio= n" + #language x-UEFI-ns "xUefiHiiOpti= on" +#string STR_ONE_OF_PROMPT_X_UEFI_HELP #language en-US "This is an HII o= ption which has REST_STYLE flag and x-UEFI namespace UNI string associate= d. This HII option could be configured by either in-band edk2 setup brows= er or the remote management in out-of-band such as Redfish service. This = HII option is configured through EFI_KEYWORD_HANDLER_PROTOCOL." +#string STR_ONE_OF_PROMPT_NON_X_UEFI #language en-US "Non x-UEFI H= II Option" + #language fr-FR "Non x-UEFI H= II Option" +#string STR_ONE_OF_PROMPT_NON_X_UEFI_HELP #language en-US "This is a HI= I option which has REST_STYLE flag but without the x-UEFI namespace UNI s= tring associated. This HII option could be configured by either setup bro= wser or the remote management in out-of-band such as Redfish service. Thi= s HII option is configured through EFI HII Configuration Routing Protocol= becasue it doesn't have x-UEFI namespace UNI string." #string STR_CHECK_KEYWORD_SUPPORT #language en-US "Check iSCSI Boot= Enable" #language fr-FR "Check iSCSI Boot= Enable" #string STR_ONE_OF_HELP #language en-US "My one-of help i= s going to be a long string to test out the efficiency of the ability of = the I am tired of typing capabilities" --=20 2.17.1