回复: [edk2-devel] [PATCH V2 1/1] [edk2-stable202205]OvmfPkg/OvmfPkgX64: Use different CcProbeLib when SMM is on or off

gaoliming gaoliming at byosoft.com.cn
Wed May 18 06:45:36 UTC 2022


Jiewen:
  I agree to merge it for this stable tag. 

Thanks
Liming
> -----邮件原件-----
> 发件人: devel at edk2.groups.io <devel at edk2.groups.io> 代表 Yao, Jiewen
> 发送时间: 2022年5月18日 11:43
> 收件人: Xu, Min M <min.m.xu at intel.com>; devel at edk2.groups.io
> 抄送: Andrew Fish <afish at apple.com>; Leif Lindholm
> <quic_llindhol at quicinc.com>; Kinney, Michael D
> <michael.d.kinney at intel.com>; Dann Frazier <dann.frazier at canonical.com>;
> Aktas, Erdem <erdemaktas at google.com>; James Bottomley
> <jejb at linux.ibm.com>; Tom Lendacky <thomas.lendacky at amd.com>; Gao,
> Liming <gaoliming at byosoft.com.cn>
> 主题: Re: [edk2-devel] [PATCH V2 1/1]
> [edk2-stable202205]OvmfPkg/OvmfPkgX64: Use different CcProbeLib when
> SMM is on or off
> 
> Hi Steward Team
> I request this be in stable202205. It is a regression issue since
stable202202.
> 
> Reviewed-by: Jiewen Yao <jiewen.yao at intel.com>
> 
> Thank you
> Yao Jiewen
> 
> 
> > -----Original Message-----
> > From: Xu, Min M <min.m.xu at intel.com>
> > Sent: Wednesday, May 18, 2022 11:37 AM
> > To: devel at edk2.groups.io
> > Cc: Xu, Min M <min.m.xu at intel.com>; Andrew Fish <afish at apple.com>;
> Leif
> > Lindholm <quic_llindhol at quicinc.com>; Kinney, Michael D
> > <michael.d.kinney at intel.com>; Dann Frazier
> <dann.frazier at canonical.com>;
> > Aktas, Erdem <erdemaktas at google.com>; James Bottomley
> > <jejb at linux.ibm.com>; Yao, Jiewen <jiewen.yao at intel.com>; Tom Lendacky
> > <thomas.lendacky at amd.com>; Gao, Liming <gaoliming at byosoft.com.cn>;
> Yao,
> > Jiewen <jiewen.yao at intel.com>
> > Subject: [PATCH V2 1/1] [edk2-stable202205]OvmfPkg/OvmfPkgX64: Use
> > different CcProbeLib when SMM is on or off
> >
> > BZ: https://bugzilla.tianocore.org/show_bug.cgi?id=3930
> >
> > CcProbeLib is designed to check the vm guest type. The
> OvmfPkg/CcProbeLib
> > reads the OvmfWorkArea (0x80B000) to get the vm guest type which is
> > written by each guest (SEV or TDX guest). But in SMM drivers the access
> > to OvmfWorkArea is illegal. PiSmmCpuDxeSmm.inf is an example. It uses
> > IoLib which in OvmfPkgX64 BaseIoLibIntrinsicSev.inf is included. The
> > IoLib probes if the working guest is td guest by calling CcProbe().
> >
> > So CcProbeLibNull will be included when SMM_REQUIRE is set. Currently
> > only TDVF uses CcProbe to check the guest type, and TDVF doesn't
> > support SMM, so this fix has no side-effect.
> >
> > Cc: Andrew Fish <afish at apple.com>
> > Cc: Leif Lindholm <quic_llindhol at quicinc.com>
> > Cc: Michael D Kinney <michael.d.kinney at intel.com>
> > Cc: Dann Frazier <dann.frazier at canonical.com>
> > Cc: Erdem Aktas <erdemaktas at google.com>
> > Cc: James Bottomley <jejb at linux.ibm.com>
> > Cc: Jiewen Yao <jiewen.yao at intel.com>
> > Cc: Tom Lendacky <thomas.lendacky at amd.com>
> > Cc: Liming Gao <gaoliming at byosoft.com.cn>
> > Tested-by: dann frazier <dann.frazier at canonical.com>
> > Acked-by: Jiewen Yao <Jiewen.yao at intel.com>
> > Signed-off-by: Min Xu <min.m.xu at intel.com>
> > ---
> >  OvmfPkg/OvmfPkgX64.dsc | 4 +++-
> >  1 file changed, 3 insertions(+), 1 deletion(-)
> >
> > diff --git a/OvmfPkg/OvmfPkgX64.dsc b/OvmfPkg/OvmfPkgX64.dsc
> > index 71526bba3183..db7f4def7a24 100644
> > --- a/OvmfPkg/OvmfPkgX64.dsc
> > +++ b/OvmfPkg/OvmfPkgX64.dsc
> > @@ -171,7 +171,6 @@
> >    PciCapLib|OvmfPkg/Library/BasePciCapLib/BasePciCapLib.inf
> >
> >
> PciCapPciSegmentLib|OvmfPkg/Library/BasePciCapPciSegmentLib/BasePciC
> apP
> > ciSegmentLib.inf
> >
> PciCapPciIoLib|OvmfPkg/Library/UefiPciCapPciIoLib/UefiPciCapPciIoLib.inf
> > -  CcProbeLib|OvmfPkg/Library/CcProbeLib/CcProbeLib.inf
> >    IoLib|MdePkg/Library/BaseIoLibIntrinsic/BaseIoLibIntrinsicSev.inf
> >
> >
> OemHookStatusCodeLib|MdeModulePkg/Library/OemHookStatusCodeLibNul
> l/
> > OemHookStatusCodeLibNull.inf
> >    SerialPortLib|PcAtChipsetPkg/Library/SerialIoLib/SerialIoLib.inf
> > @@ -198,6 +197,9 @@
> >
> >  !if $(SMM_REQUIRE) == FALSE
> >    LockBoxLib|OvmfPkg/Library/LockBoxLib/LockBoxBaseLib.inf
> > +  CcProbeLib|OvmfPkg/Library/CcProbeLib/CcProbeLib.inf
> > +!else
> > +  CcProbeLib|MdePkg/Library/CcProbeLibNull/CcProbeLibNull.inf
> >  !endif
> >
> >
> CustomizedDisplayLib|MdeModulePkg/Library/CustomizedDisplayLib/Custom
> ize
> > dDisplayLib.inf
> >
> >
> FrameBufferBltLib|MdeModulePkg/Library/FrameBufferBltLib/FrameBufferBl
> tLi
> > b.inf
> > --
> > 2.29.2.windows.2
> 
> 
> 
> 
> 





-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#89883): https://edk2.groups.io/g/devel/message/89883
Mute This Topic: https://groups.io/mt/91181023/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