回复: [edk2-devel] [PATCH v2 1/1] OvmfPkg/VmgExitLib: Fix uninitialized variable warning with XCODE5

gaoliming gaoliming at byosoft.com.cn
Fri Feb 11 01:13:42 UTC 2022


Ard:
 I am OK to merge this issue for this stable tag. It is a clear bug fix. 

Thanks
Liming
> -----邮件原件-----
> 发件人: Ard Biesheuvel <ardb at kernel.org>
> 发送时间: 2022年2月10日 17:18
> 收件人: edk2-devel-groups-io <devel at edk2.groups.io>; Rebecca Cran
> <quic_rcran at quicinc.com>; Liming Gao (Byosoft address)
> <gaoliming at byosoft.com.cn>
> 抄送: James Bottomley <jejb at linux.ibm.com>; Min Xu
> <min.m.xu at intel.com>; Jiewen Yao <jiewen.yao at intel.com>; Tom Lendacky
> <thomas.lendacky at amd.com>; Jordan Justen <jordan.l.justen at intel.com>;
> Ard Biesheuvel <ardb+tianocore at kernel.org>; Erdem Aktas
> <erdemaktas at google.com>; Michael Roth <Michael.Roth at amd.com>; Gerd
> Hoffmann <kraxel at redhat.com>; Brijesh Singh <brijesh.singh at amd.com>
> 主题: Re: [edk2-devel] [PATCH v2 1/1] OvmfPkg/VmgExitLib: Fix uninitialized
> variable warning with XCODE5
> 
> On Thu, 10 Feb 2022 at 10:17, Ard Biesheuvel <ardb at kernel.org> wrote:
> >
> > (+ Liming)
> >
> 
> ... for real this time.
> 
> > On Fri, 4 Feb 2022 at 21:28, Rebecca Cran <quic_rcran at quicinc.com>
> wrote:
> > >
> > > XCODE5 reported the following warning:
> > >
> > > OvmfPkg/Library/VmgExitLib/VmgExitVcHandler.c:1895:12: note:
> > > uninitialized use occurs here
> > >            Compacted
> > >            ^^^^^^^^^
> > >
> > > Initialize the 'Compacted' variable to fix the warning.
> > >
> > > Signed-off-by: Rebecca Cran <quic_rcran at quicinc.com>
> > > ---
> > >  OvmfPkg/Library/VmgExitLib/VmgExitVcHandler.c | 1 +
> > >  1 file changed, 1 insertion(+)
> > >
> > > diff --git a/OvmfPkg/Library/VmgExitLib/VmgExitVcHandler.c
> b/OvmfPkg/Library/VmgExitLib/VmgExitVcHandler.c
> > > index a40a31f7c275..ccb1300690fa 100644
> > > --- a/OvmfPkg/Library/VmgExitLib/VmgExitVcHandler.c
> > > +++ b/OvmfPkg/Library/VmgExitLib/VmgExitVcHandler.c
> > > @@ -1872,6 +1872,7 @@ GetCpuidFw (
> > >      UINT32                 XSaveSize;
> > >
> > >      XssMsr.Uint64 = 0;
> > > +    Compacted     = 0;
> >
> > This should be FALSE not 0. I will fix this up before merging.
> >
> > Liming: is it ok if I merge this today?
> >
> >
> > >      if (EcxIn == 1) {
> > >        /*
> > >         * The PPR and APM aren't clear on what size should be
> encoded in
> > > --
> > > 2.34.1
> > >
> > >
> > >
> > > 
> > >
> > >




-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#86599): https://edk2.groups.io/g/devel/message/86599
Mute This Topic: https://groups.io/mt/89060527/1813853
Group Owner: devel+owner at edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub [edk2-devel-archive at redhat.com]
-=-=-=-=-=-=-=-=-=-=-=-






More information about the edk2-devel-archive mailing list