From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received-SPF: Pass (sender SPF authorized) identity=mailfrom; client-ip=192.55.52.136; helo=mga12.intel.com; envelope-from=jiaxin.wu@intel.com; receiver=edk2-devel@lists.01.org Received: from mga12.intel.com (mga12.intel.com [192.55.52.136]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ml01.01.org (Postfix) with ESMTPS id 056952119AC12 for ; Sun, 13 Jan 2019 22:15:30 -0800 (PST) X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from orsmga007.jf.intel.com ([10.7.209.58]) by fmsmga106.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 13 Jan 2019 22:15:29 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.56,476,1539673200"; d="scan'208";a="106384383" Received: from fmsmsx103.amr.corp.intel.com ([10.18.124.201]) by orsmga007.jf.intel.com with ESMTP; 13 Jan 2019 22:15:29 -0800 Received: from fmsmsx156.amr.corp.intel.com (10.18.116.74) by FMSMSX103.amr.corp.intel.com (10.18.124.201) with Microsoft SMTP Server (TLS) id 14.3.408.0; Sun, 13 Jan 2019 22:15:29 -0800 Received: from shsmsx103.ccr.corp.intel.com (10.239.4.69) by fmsmsx156.amr.corp.intel.com (10.18.116.74) with Microsoft SMTP Server (TLS) id 14.3.408.0; Sun, 13 Jan 2019 22:15:25 -0800 Received: from shsmsx107.ccr.corp.intel.com ([169.254.9.239]) by SHSMSX103.ccr.corp.intel.com ([169.254.4.150]) with mapi id 14.03.0415.000; Mon, 14 Jan 2019 14:12:42 +0800 From: "Wu, Jiaxin" To: Ashish Singhal , "edk2-devel@lists.01.org" CC: "Fu, Siyuan" Thread-Topic: [PATCH] NetworkPkg: Protocol Uninstallation Cleanup Thread-Index: AQHUqRqBCAjv/JJ+TUqK+RCYtKR4FqWpP8gggARzSYCAAJqzsA== Date: Mon, 14 Jan 2019 06:12:42 +0000 Message-ID: <895558F6EA4E3B41AC93A00D163B727416EC48C7@SHSMSX107.ccr.corp.intel.com> References: <2d3d928f7698138685701e6de58c083f65acafa4.1547148192.git.ashishsingha@nvidia.com> <895558F6EA4E3B41AC93A00D163B727416EC3FF3@SHSMSX107.ccr.corp.intel.com> In-Reply-To: Accept-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-titus-metadata-40: eyJDYXRlZ29yeUxhYmVscyI6IiIsIk1ldGFkYXRhIjp7Im5zIjoiaHR0cDpcL1wvd3d3LnRpdHVzLmNvbVwvbnNcL0ludGVsMyIsImlkIjoiNzlhMDExMzUtODUzYS00NWQ1LTlhYzEtZjRmZjQ1NTA2M2JhIiwicHJvcHMiOlt7Im4iOiJDVFBDbGFzc2lmaWNhdGlvbiIsInZhbHMiOlt7InZhbHVlIjoiQ1RQX05UIn1dfV19LCJTdWJqZWN0TGFiZWxzIjpbXSwiVE1DVmVyc2lvbiI6IjE3LjEwLjE4MDQuNDkiLCJUcnVzdGVkTGFiZWxIYXNoIjoiZjNlbGw4XC9UblBtTUtxVUhtMkgrRXRCMmtnNEt5ZnNVaGRoZjFGTGtHUzQwT0dmRlhYZkViU0s2N0tFM2JndysifQ== x-ctpclassification: CTP_NT dlp-product: dlpe-windows dlp-version: 11.0.400.15 dlp-reaction: no-action x-originating-ip: [10.239.127.40] MIME-Version: 1.0 Subject: Re: [PATCH] NetworkPkg: Protocol Uninstallation Cleanup X-BeenThere: edk2-devel@lists.01.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: EDK II Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 14 Jan 2019 06:15:31 -0000 Content-Language: en-US Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable Already pushed. SHA-1: 22b35e8bd1f9aea7bbab3a26e8ab4df339454463 Thanks, Jiaxin > -----Original Message----- > From: Ashish Singhal [mailto:ashishsingha@nvidia.com] > Sent: Monday, January 14, 2019 12:58 PM > To: Wu, Jiaxin ; edk2-devel@lists.01.org > Cc: Fu, Siyuan > Subject: RE: [PATCH] NetworkPkg: Protocol Uninstallation Cleanup >=20 > Thanks Jiaxin. Please let me know if anything else is needed to mainline = it. >=20 > -----Original Message----- > From: Wu, Jiaxin > Sent: Thursday, January 10, 2019 6:01 PM > To: Ashish Singhal ; edk2-devel@lists.01.org > Cc: Fu, Siyuan > Subject: RE: [PATCH] NetworkPkg: Protocol Uninstallation Cleanup >=20 > Looks good to me. >=20 > Reviewed-by: Wu Jiaxin >=20 > Thanks, > Jiaxin >=20 > > -----Original Message----- > > From: Ashish Singhal [mailto:ashishsingha@nvidia.com] > > Sent: Friday, January 11, 2019 3:27 AM > > To: edk2-devel@lists.01.org > > Cc: Fu, Siyuan ; Wu, Jiaxin > > ; Ashish Singhal > > Subject: [PATCH] NetworkPkg: Protocol Uninstallation Cleanup > > > > Use UEFILib provided protocol uninstallation abstraction instead of > > direct API for a proper cleanup. > > > > REF: https://bugzilla.tianocore.org/show_bug.cgi?id=3D1444 > > > > Contributed-under: TianoCore Contribution Agreement 1.1 > > Signed-off-by: Ashish Singhal > > --- > > NetworkPkg/DnsDxe/DnsDriver.c | 30 ++++++++++-----------------= --- > > NetworkPkg/HttpBootDxe/HttpBootDxe.c | 15 +++++---------- > > NetworkPkg/HttpDxe/HttpDriver.c | 15 +++++---------- > > NetworkPkg/IpSecDxe/IpSecDriver.c | 15 +++++---------- > > NetworkPkg/TcpDxe/TcpDriver.c | 15 +++++---------- > > NetworkPkg/UefiPxeBcDxe/PxeBcDriver.c | 15 +++++---------- > > 6 files changed, 35 insertions(+), 70 deletions(-) > > > > diff --git a/NetworkPkg/DnsDxe/DnsDriver.c > > b/NetworkPkg/DnsDxe/DnsDriver.c index 1f9b924..b74f5ba 100644 > > --- a/NetworkPkg/DnsDxe/DnsDriver.c > > +++ b/NetworkPkg/DnsDxe/DnsDriver.c > > @@ -510,28 +510,18 @@ DnsDriverEntryPoint ( > > FreePool (mDriverData); > > > > Error2: > > - gBS->UninstallMultipleProtocolInterfaces ( > > - gDns6DriverBinding.DriverBindingHandle, > > - &gEfiDriverBindingProtocolGuid, > > - &gDns6DriverBinding, > > - &gEfiComponentName2ProtocolGuid, > > - &gDnsComponentName2, > > - &gEfiComponentNameProtocolGuid, > > - &gDnsComponentName, > > - NULL > > - ); > > + EfiLibUninstallDriverBindingComponentName2 ( > > + &gDns6DriverBinding, > > + &gDnsComponentName, > > + &gDnsComponentName2 > > + ); > > > > Error1: > > - gBS->UninstallMultipleProtocolInterfaces ( > > - ImageHandle, > > - &gEfiDriverBindingProtocolGuid, > > - &gDns4DriverBinding, > > - &gEfiComponentName2ProtocolGuid, > > - &gDnsComponentName2, > > - &gEfiComponentNameProtocolGuid, > > - &gDnsComponentName, > > - NULL > > - ); > > + EfiLibUninstallDriverBindingComponentName2 ( > > + &gDns4DriverBinding, > > + &gDnsComponentName, > > + &gDnsComponentName2 > > + ); > > > > return Status; > > } > > diff --git a/NetworkPkg/HttpBootDxe/HttpBootDxe.c > > b/NetworkPkg/HttpBootDxe/HttpBootDxe.c > > index 7ec06f960..0b16f95 100644 > > --- a/NetworkPkg/HttpBootDxe/HttpBootDxe.c > > +++ b/NetworkPkg/HttpBootDxe/HttpBootDxe.c > > @@ -1327,16 +1327,11 @@ HttpBootDxeDriverEntryPoint ( > > &gHttpBootDxeComponentName2 > > ); > > if (EFI_ERROR (Status)) { > > - gBS->UninstallMultipleProtocolInterfaces( > > - ImageHandle, > > - &gEfiDriverBindingProtocolGuid, > > - &gHttpBootIp4DxeDriverBinding, > > - &gEfiComponentName2ProtocolGuid, > > - &gHttpBootDxeComponentName2, > > - &gEfiComponentNameProtocolGuid, > > - &gHttpBootDxeComponentName, > > - NULL > > - ); > > + EfiLibUninstallDriverBindingComponentName2( > > + &gHttpBootIp4DxeDriverBinding, > > + &gHttpBootDxeComponentName, > > + &gHttpBootDxeComponentName2 > > + ); > > } > > return Status; > > } > > diff --git a/NetworkPkg/HttpDxe/HttpDriver.c > > b/NetworkPkg/HttpDxe/HttpDriver.c index 8df984d..979d76d 100644 > > --- a/NetworkPkg/HttpDxe/HttpDriver.c > > +++ b/NetworkPkg/HttpDxe/HttpDriver.c > > @@ -230,16 +230,11 @@ HttpDxeDriverEntryPoint ( > > &gHttpDxeComponentName2 > > ); > > if (EFI_ERROR (Status)) { > > - gBS->UninstallMultipleProtocolInterfaces ( > > - ImageHandle, > > - &gEfiDriverBindingProtocolGuid, > > - &gHttpDxeIp4DriverBinding, > > - &gEfiComponentName2ProtocolGuid, > > - &gHttpDxeComponentName2, > > - &gEfiComponentNameProtocolGuid, > > - &gHttpDxeComponentName, > > - NULL > > - ); > > + EfiLibUninstallDriverBindingComponentName2 ( > > + &gHttpDxeIp4DriverBinding, > > + &gHttpDxeComponentName, > > + &gHttpDxeComponentName2 > > + ); > > } > > return Status; > > } > > diff --git a/NetworkPkg/IpSecDxe/IpSecDriver.c > > b/NetworkPkg/IpSecDxe/IpSecDriver.c > > index f66f89a..3082d99 100644 > > --- a/NetworkPkg/IpSecDxe/IpSecDriver.c > > +++ b/NetworkPkg/IpSecDxe/IpSecDriver.c > > @@ -631,16 +631,11 @@ IpSecDriverEntryPoint ( > > return Status; > > > > ON_UNINSTALL_IPSEC4_DB: > > - gBS->UninstallMultipleProtocolInterfaces ( > > - ImageHandle, > > - &gEfiDriverBindingProtocolGuid, > > - &gIpSec4DriverBinding, > > - &gEfiComponentName2ProtocolGuid, > > - &gIpSecComponentName2, > > - &gEfiComponentNameProtocolGuid, > > - &gIpSecComponentName, > > - NULL > > - ); > > + EfiLibUninstallDriverBindingComponentName2 ( > > + &gIpSec4DriverBinding, > > + &gIpSecComponentName, > > + &gIpSecComponentName2 > > + ); > > > > ON_UNINSTALL_IPSEC: > > gBS->UninstallProtocolInterface ( > > diff --git a/NetworkPkg/TcpDxe/TcpDriver.c > > b/NetworkPkg/TcpDxe/TcpDriver.c index 2d4b16c..00d172b 100644 > > --- a/NetworkPkg/TcpDxe/TcpDriver.c > > +++ b/NetworkPkg/TcpDxe/TcpDriver.c > > @@ -202,16 +202,11 @@ TcpDriverEntryPoint ( > > &gTcpComponentName2 > > ); > > if (EFI_ERROR (Status)) { > > - gBS->UninstallMultipleProtocolInterfaces ( > > - ImageHandle, > > - &gEfiDriverBindingProtocolGuid, > > - &gTcp4DriverBinding, > > - &gEfiComponentName2ProtocolGuid, > > - &gTcpComponentName2, > > - &gEfiComponentNameProtocolGuid, > > - &gTcpComponentName, > > - NULL > > - ); > > + EfiLibUninstallDriverBindingComponentName2 ( > > + &gTcp4DriverBinding, > > + &gTcpComponentName, > > + &gTcpComponentName2 > > + ); > > return Status; > > } > > > > diff --git a/NetworkPkg/UefiPxeBcDxe/PxeBcDriver.c > > b/NetworkPkg/UefiPxeBcDxe/PxeBcDriver.c > > index 0ab640b..f25c27a 100644 > > --- a/NetworkPkg/UefiPxeBcDxe/PxeBcDriver.c > > +++ b/NetworkPkg/UefiPxeBcDxe/PxeBcDriver.c > > @@ -1269,16 +1269,11 @@ PxeBcDriverEntryPoint ( > > &gPxeBcComponentName2 > > ); > > if (EFI_ERROR (Status)) { > > - gBS->UninstallMultipleProtocolInterfaces ( > > - ImageHandle, > > - &gEfiDriverBindingProtocolGuid, > > - &gPxeBcIp4DriverBinding, > > - &gEfiComponentName2ProtocolGuid, > > - &gPxeBcComponentName2, > > - &gEfiComponentNameProtocolGuid, > > - &gPxeBcComponentName, > > - NULL > > - ); > > + EfiLibUninstallDriverBindingComponentName2 ( > > + &gPxeBcIp4DriverBinding, > > + &gPxeBcComponentName, > > + &gPxeBcComponentName2 > > + ); > > } > > > > return Status; > > -- > > 2.7.4 >=20 > -------------------------------------------------------------------------= ---------- > This email message is for the sole use of the intended recipient(s) and m= ay > contain > confidential information. Any unauthorized review, use, disclosure or > distribution > is prohibited. If you are not the intended recipient, please contact the > sender by > reply email and destroy all copies of the original message. > -------------------------------------------------------------------------= ----------