From mboxrd@z Thu Jan 1 00:00:00 1970 Authentication-Results: mx.groups.io; dkim=missing; spf=pass (domain: redhat.com, ip: 209.132.183.28, mailfrom: lersek@redhat.com) Received: from mx1.redhat.com (mx1.redhat.com [209.132.183.28]) by groups.io with SMTP; Tue, 17 Sep 2019 12:50:32 -0700 Received: from smtp.corp.redhat.com (int-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.11]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 6B97110F2E81; Tue, 17 Sep 2019 19:50:32 +0000 (UTC) Received: from lacos-laptop-7.usersys.redhat.com (ovpn-120-37.rdu2.redhat.com [10.10.120.37]) by smtp.corp.redhat.com (Postfix) with ESMTP id 303D4600C4; Tue, 17 Sep 2019 19:50:30 +0000 (UTC) From: "Laszlo Ersek" To: edk2-devel-groups-io Cc: Chao Zhang , Jian Wang , Jiewen Yao Subject: [PATCH 26/35] SecurityPkg: fix UninstallMultipleProtocolInterfaces() calls Date: Tue, 17 Sep 2019 21:49:26 +0200 Message-Id: <20190917194935.24322-27-lersek@redhat.com> In-Reply-To: <20190917194935.24322-1-lersek@redhat.com> References: <20190917194935.24322-1-lersek@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.11 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.6.2 (mx1.redhat.com [10.5.110.66]); Tue, 17 Sep 2019 19:50:32 +0000 (UTC) Content-Transfer-Encoding: quoted-printable Unlike the InstallMultipleProtocolInterfaces() boot service, which takes an (EFI_HANDLE*) as first parameter, the UninstallMultipleProtocolInterfaces() boot service takes an EFI_HANDLE as first parameter. These are actual bugs. They must have remained hidden until now because they are all in Unload() functions, which are probably exercised infrequently. Fix the UninstallMultipleProtocolInterfaces() calls. Cc: Chao Zhang Cc: Jian Wang Cc: Jiewen Yao Signed-off-by: Laszlo Ersek --- Notes: build-tested only SecurityPkg/Tcg/Tcg2Config/Tcg2ConfigDriver.c = | 2 +- SecurityPkg/Tcg/TcgConfigDxe/TcgConfigDriver.c = | 2 +- SecurityPkg/VariableAuthenticated/SecureBootConfigDxe/SecureBootConfigDr= iver.c | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/SecurityPkg/Tcg/Tcg2Config/Tcg2ConfigDriver.c b/SecurityPkg/= Tcg/Tcg2Config/Tcg2ConfigDriver.c index 54155a338100..9052eced757d 100644 --- a/SecurityPkg/Tcg/Tcg2Config/Tcg2ConfigDriver.c +++ b/SecurityPkg/Tcg/Tcg2Config/Tcg2ConfigDriver.c @@ -443,7 +443,7 @@ Tcg2ConfigDriverUnload ( ASSERT (PrivateData->Signature =3D=3D TCG2_CONFIG_PRIVATE_DATA_SIGNATU= RE); =20 gBS->UninstallMultipleProtocolInterfaces ( - &ImageHandle, + ImageHandle, &gEfiCallerIdGuid, PrivateData, NULL diff --git a/SecurityPkg/Tcg/TcgConfigDxe/TcgConfigDriver.c b/SecurityPkg= /Tcg/TcgConfigDxe/TcgConfigDriver.c index 341879e4c4ba..fb06624fdb8f 100644 --- a/SecurityPkg/Tcg/TcgConfigDxe/TcgConfigDriver.c +++ b/SecurityPkg/Tcg/TcgConfigDxe/TcgConfigDriver.c @@ -138,7 +138,7 @@ TcgConfigDriverUnload ( ASSERT (PrivateData->Signature =3D=3D TCG_CONFIG_PRIVATE_DATA_SIGNATUR= E); =20 gBS->UninstallMultipleProtocolInterfaces ( - &ImageHandle, + ImageHandle, &gEfiCallerIdGuid, PrivateData, NULL diff --git a/SecurityPkg/VariableAuthenticated/SecureBootConfigDxe/Secure= BootConfigDriver.c b/SecurityPkg/VariableAuthenticated/SecureBootConfigDx= e/SecureBootConfigDriver.c index 798ef9cfbc01..6c0294151e6c 100644 --- a/SecurityPkg/VariableAuthenticated/SecureBootConfigDxe/SecureBootCon= figDriver.c +++ b/SecurityPkg/VariableAuthenticated/SecureBootConfigDxe/SecureBootCon= figDriver.c @@ -115,7 +115,7 @@ SecureBootConfigDriverUnload ( ASSERT (PrivateData->Signature =3D=3D SECUREBOOT_CONFIG_PRIVATE_DATA_S= IGNATURE); =20 gBS->UninstallMultipleProtocolInterfaces ( - &ImageHandle, + ImageHandle, &gEfiCallerIdGuid, PrivateData, NULL --=20 2.19.1.3.g30247aa5d201