From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail.byosoft.com.cn (mail.byosoft.com.cn [58.240.74.242]) by mx.groups.io with SMTP id smtpd.web11.2786.1637734703606015700 for ; Tue, 23 Nov 2021 22:18:24 -0800 Authentication-Results: mx.groups.io; dkim=missing; spf=none, err=permanent DNS error (domain: byosoft.com.cn, ip: 58.240.74.242, mailfrom: gaoliming@byosoft.com.cn) Received: from DESKTOPS6D0PVI ([58.246.60.130]) (envelope-sender ) by 192.168.6.13 with ESMTP for ; Wed, 24 Nov 2021 14:17:27 +0800 X-WM-Sender: gaoliming@byosoft.com.cn X-Originating-IP: 58.246.60.130 X-WM-AuthFlag: YES X-WM-AuthUser: gaoliming@byosoft.com.cn From: "gaoliming" To: , , "'Rebecca Cran'" Cc: "'Hao A Wu'" , "'Ray Ni'" , "'Andrew Fish'" , "'Michael D Kinney'" References: <20211116025328.1604-1-gaoliming@byosoft.com.cn> <680de582-f33a-edd3-afbc-f9aafd05595d@nuviainc.com> In-Reply-To: Subject: =?UTF-8?B?5Zue5aSNOiBlZGsyLXN0YWJsZTIwMjExMSBSZTogW2VkazItZGV2ZWxdIFtQQVRDSF0gTWRlTW9kdWxlUGtnIEF0YUF0YXBpUGFzc1RocnU6IFNraXAgdGhlIHBvdGVudGlhbCBOVUxMIHBvaW50ZXIgYWNjZXNz?= Date: Wed, 24 Nov 2021 14:17:29 +0800 Message-ID: <006301d7e0fa$f595f3d0$e0c1db70$@byosoft.com.cn> MIME-Version: 1.0 X-Mailer: Microsoft Outlook 16.0 Thread-Index: AQGwyYsFxW5y2KPmuIfuGSslWVqoDQHbpzIlAlh+5f6sPsF4UA== Content-Type: text/plain; charset="gb2312" Content-Transfer-Encoding: quoted-printable Content-Language: zh-cn Leif: Thanks for your suggestion. I am OK to merge this patch into stable tag20211. Thanks Liming > -----=D3=CA=BC=FE=D4=AD=BC=FE----- > =B7=A2=BC=FE=C8=CB: devel@edk2.groups.io =B4=FA=B1= =ED Leif Lindholm > =B7=A2=CB=CD=CA=B1=BC=E4: 2021=C4=EA11=D4=C223=C8=D5 21:19 > =CA=D5=BC=FE=C8=CB: Rebecca Cran ; gaoliming@byosof= t.com.cn > =B3=AD=CB=CD: devel@edk2.groups.io; Hao A Wu ; Ray Ni > ; Andrew Fish ; Michael D Kinney > > =D6=F7=CC=E2: edk2-stable202111 Re: [edk2-devel] [PATCH] MdeModulePkg > AtaAtapiPassThru: Skip the potential NULL pointer access >=20 > Since BZ3732 has been triggered by a standard build of a platform in > edk2-platforms, I would request that this fix is brought into the > upcoming stable tag. >=20 > SbsaQemu isn't a "real" platform, so I don't consider that in itself > sufficient reason, but I feel the risk of it affecting other > (including out-of-tree) platforms justifies it. >=20 > Best Regards, >=20 > Leif >=20 > On Tue, Nov 23, 2021 at 06:10:14 -0700, Rebecca Cran wrote: > > Acked-by: Rebecca Cran > > > > > > I've confirmed that this patch fixes the exception I was seeing when running > > the DEBUG build of SbsaQemu. > > > > > > -- > > > > Rebecca Cran > > > > > > On 11/15/21 7:53 PM, gaoliming wrote: > > > BZ: https://bugzilla.tianocore.org/show_bug.cgi?id=3D3732 > > > Recent change c974257821208fc6191779d1ddea918499f165b8 exposes > this potential issue. > > > > > > Signed-off-by: Liming Gao > > > Cc: Hao A Wu > > > Cc: Ray Ni > > > --- > > > MdeModulePkg/Bus/Ata/AtaAtapiPassThru/AhciMode.c | 7 +++++++ > > > 1 file changed, 7 insertions(+) > > > > > > diff --git a/MdeModulePkg/Bus/Ata/AtaAtapiPassThru/AhciMode.c > b/MdeModulePkg/Bus/Ata/AtaAtapiPassThru/AhciMode.c > > > index 7626bac38d..bda900a161 100644 > > > --- a/MdeModulePkg/Bus/Ata/AtaAtapiPassThru/AhciMode.c > > > +++ b/MdeModulePkg/Bus/Ata/AtaAtapiPassThru/AhciMode.c > > > @@ -885,6 +885,13 @@ AhciPrintStatusBlock ( > > > IN UINT32 DebugLevel > > > ) > > > { > > > + // > > > + // Skip NULL pointer > > > + // > > > + if (AtaStatusBlock =3D=3D NULL) { > > > + return; > > > + } > > > + > > > // > > > // Only print status and error since we have all of the rest printed as > > > // a part of command block print. >=20 >=20 >=20 >=20