]> git.proxmox.com Git - mirror_edk2.git/commitdiff
MdeModulePkg/Ip4Dxe: Uninstall protocols when error happen in Driver Binding Start.
authorJiaxin Wu <Jiaxin.wu@intel.com>
Fri, 25 Jan 2019 00:54:00 +0000 (08:54 +0800)
committerJiaxin Wu <Jiaxin.wu@intel.com>
Tue, 12 Feb 2019 00:25:31 +0000 (08:25 +0800)
REF: https://bugzilla.tianocore.org/show_bug.cgi?id=1447

This patch is to uninstall Ip4ServiceBindingProtocol and Ip4Config2Protocol when
error happen in Driver Binding Start.

Cc: Michael Turner <Michael.Turner@microsoft.com>
Cc: Ye Ting <ting.ye@intel.com>
Cc: Fu Siyuan <siyuan.fu@intel.com>
Contributed-under: TianoCore Contribution Agreement 1.1
Signed-off-by: Wu Jiaxin <jiaxin.wu@intel.com>
Signed-off-by: Michael Turner <Michael.Turner@microsoft.com>
Reviewed-By: Ye Ting <ting.ye@intel.com>
MdeModulePkg/Universal/Network/Ip4Dxe/Ip4Driver.c

index 0f2558141459a59b1ad1fc7e617076fee95c0467..87ec968e7b1ffabd887a7e109369b3c58078d310 100644 (file)
@@ -1,7 +1,7 @@
 /** @file\r
   The driver binding and service binding protocol for IP4 driver.\r
 \r
-Copyright (c) 2005 - 2018, Intel Corporation. All rights reserved.<BR>\r
+Copyright (c) 2005 - 2019, Intel Corporation. All rights reserved.<BR>\r
 (C) Copyright 2015 Hewlett-Packard Development Company, L.P.<BR>\r
 \r
 This program and the accompanying materials\r
@@ -664,10 +664,13 @@ Ip4DriverBindingStart (
   return Status;\r
 \r
 UNINSTALL_PROTOCOL:\r
-  gBS->UninstallProtocolInterface (\r
+  gBS->UninstallMultipleProtocolInterfaces (\r
          ControllerHandle,\r
          &gEfiIp4ServiceBindingProtocolGuid,\r
-         &IpSb->ServiceBinding\r
+         &IpSb->ServiceBinding,\r
+         &gEfiIp4Config2ProtocolGuid,\r
+         Ip4Cfg2,\r
+         NULL\r
          );\r
 \r
 FREE_SERVICE:\r