From: "Dandan Bi" <dandan.bi@intel.com>
To: "Huang, Long1" <long1.huang@intel.com>,
"devel@edk2.groups.io" <devel@edk2.groups.io>
Cc: "Feng, Bob C" <bob.c.feng@intel.com>,
Liming Gao <gaoliming@byosoft.com.cn>,
"Chen, Christine" <yuwei.chen@intel.com>
Subject: Re: [PATCH] BaseTools/VfrCompile: Correct Bit Field Flags for numeric/one of
Date: Wed, 1 Dec 2021 02:20:55 +0000 [thread overview]
Message-ID: <DM4PR11MB5453AAAD53518EE7DBD5F40AEA689@DM4PR11MB5453.namprd11.prod.outlook.com> (raw)
In-Reply-To: <507a7c3ef092de00a5252327a0de1b0d7733aaf3.1638237205.git.long1.huang@intel.com>
Reviewed-by: Dandan Bi <dandan.bi@intel.com>
Thanks,
Dandan
> -----Original Message-----
> From: Huang, Long1 <long1.huang@intel.com>
> Sent: Tuesday, November 30, 2021 9:55 AM
> To: devel@edk2.groups.io
> Cc: Huang, Long1 <long1.huang@intel.com>; Feng, Bob C
> <bob.c.feng@intel.com>; Liming Gao <gaoliming@byosoft.com.cn>; Chen,
> Christine <yuwei.chen@intel.com>; Bi, Dandan <dandan.bi@intel.com>
> Subject: [PATCH] BaseTools/VfrCompile: Correct Bit Field Flags for
> numeric/one of
>
> REF:https://bugzilla.tianocore.org/show_bug.cgi?id=3752
>
> Add Bit mask to numeric/one of opcode to set correctly Flags for Bit Field.
> VfrSyntax.g: Set "LFlags &= EDKII_IFR_DISPLAY_BIT" before "LFlags |=
> (EDKII_IFR_NUMERIC_SIZE_BIT & (_GET_CURRQEST_VARSIZE()));"
> VfrFormPkg.h: update "if (LFlags & EFI_IFR_DISPLAY)" with "if (LFlags &
> EDKII_IFR_DISPLAY_BIT)" in SetFlagsForBitField()
>
> Cc: Bob Feng <bob.c.feng@intel.com>
> Cc: Liming Gao <gaoliming@byosoft.com.cn>
> Cc: Yuwei Chen <yuwei.chen@intel.com>
> Cc: Dandan Bi <dandan.bi@intel.com>
>
> Signed-off-by: Long1 Huang <long1.huang@intel.com>
> ---
> BaseTools/Source/C/VfrCompile/VfrFormPkg.h | 2 +-
> BaseTools/Source/C/VfrCompile/VfrSyntax.g | 3 +++
> 2 files changed, 4 insertions(+), 1 deletion(-)
>
> diff --git a/BaseTools/Source/C/VfrCompile/VfrFormPkg.h
> b/BaseTools/Source/C/VfrCompile/VfrFormPkg.h
> index 1cea4f0e25..9ef6f07787 100644
> --- a/BaseTools/Source/C/VfrCompile/VfrFormPkg.h
> +++ b/BaseTools/Source/C/VfrCompile/VfrFormPkg.h
> @@ -1455,7 +1455,7 @@ public:
> return Ret; } - if (LFlags & EFI_IFR_DISPLAY) {+ if (LFlags &
> EDKII_IFR_DISPLAY_BIT) { mOneOf->Flags = LFlags; } else { mOneOf-
> >Flags = LFlags | EDKII_IFR_DISPLAY_UINT_DEC_BIT;diff --git
> a/BaseTools/Source/C/VfrCompile/VfrSyntax.g
> b/BaseTools/Source/C/VfrCompile/VfrSyntax.g
> index 3f896c6f1a..55fd067f8a 100644
> --- a/BaseTools/Source/C/VfrCompile/VfrSyntax.g
> +++ b/BaseTools/Source/C/VfrCompile/VfrSyntax.g
> @@ -2930,6 +2930,7 @@ vfrNumericFlags [CIfrNumeric & NObj, UINT32
> LineNum] :
> }
> _PCATCH(NObj.SetFlags (HFlags, LFlags, IsDisplaySpecified),
> LineNum); } else if
> ((_GET_CURRQEST_VARTINFO().mVarStoreId != EFI_VARSTORE_ID_INVALID)
> && (_GET_CURRQEST_VARTINFO().mIsBitVar)) {+
> LFlags &= EDKII_IFR_DISPLAY_BIT; LFlags |=
> (EDKII_IFR_NUMERIC_SIZE_BIT & (_GET_CURRQEST_VARSIZE()));
> _PCATCH(NObj.SetFlagsForBitField (HFlags, LFlags, IsDisplaySpecified),
> LineNum); }@@ -3105,6 +3106,8 @@
> vfrOneofFlagsField [CIfrOneOf & OObj, UINT32 LineNum] :
> }
> _PCATCH(OObj.SetFlags (HFlags, LFlags),
> LineNum); } else if
> (_GET_CURRQEST_VARTINFO().mVarStoreId != EFI_VARSTORE_ID_INVALID)
> {+ LFlags &= EDKII_IFR_DISPLAY_BIT;+
> LFlags |= (EDKII_IFR_NUMERIC_SIZE_BIT & (_GET_CURRQEST_VARSIZE()));
> _PCATCH(OObj.SetFlagsForBitField (HFlags, LFlags),
> LineNum); } >>--
> 2.32.0.windows.1
next prev parent reply other threads:[~2021-12-01 2:20 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-11-30 1:54 [PATCH] BaseTools/VfrCompile: Correct Bit Field Flags for numeric/one of Long1 Huang
2021-12-01 2:20 ` Dandan Bi [this message]
-- strict thread matches above, loose matches on Subject: below --
2021-11-29 2:35 long1.huang
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-list from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=DM4PR11MB5453AAAD53518EE7DBD5F40AEA689@DM4PR11MB5453.namprd11.prod.outlook.com \
--to=devel@edk2.groups.io \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox