summaryrefslogtreecommitdiffstats
path: root/NetworkPkg
diff options
context:
space:
mode:
authorZhang, Lubo <C:/Program Files (x86)/Git/o=Intel/ou=Exchange Administrative Group (FYDIBOHF23SPDLT)/cn=Recipients/cn=Zhang, Lubob8d>2016-05-11 09:37:39 +0800
committerJiaxin Wu <jiaxin.wu@intel.com>2016-05-12 09:35:30 +0800
commit89446d8967361aa6e2eab2b7413d58771591cc32 (patch)
treefdd7f8c6c9c09edfb36417541957ca54d095dd2a /NetworkPkg
parentfca117fd3f598ad931318bceabbd4718fafc1fc7 (diff)
downloadedk2-89446d8967361aa6e2eab2b7413d58771591cc32.tar.gz
edk2-89446d8967361aa6e2eab2b7413d58771591cc32.tar.bz2
edk2-89446d8967361aa6e2eab2b7413d58771591cc32.zip
NetworkPkg: Bug fix of iSCSI to support MPIO
If two attempts added on different NIC and enable MPIO attribute, then change the attempts order. If both two attempts succeed to connect the target,it should abort the later one in the order and uninstall ExtScsiPassThruProtocol Interface, But now it unistall it twice. Cc: Ye Ting <ting.ye@intel.com> Cc: Fu Siyuan <siyuan.fu@intel.com> Cc: Wu Jiaxin <jiaxin.wu@intel.com> Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Zhang Lubo <lubo.zhang@intel.com> Reviewed-By: Ye Ting <ting.ye@intel.com> Reviewed-By: Fu Siyuan <siyuan.fu@intel.com> Reviewed-By: Wu Jiaxin <jiaxin.wu@intel.com>
Diffstat (limited to 'NetworkPkg')
-rw-r--r--NetworkPkg/IScsiDxe/IScsiDriver.c18
1 files changed, 15 insertions, 3 deletions
diff --git a/NetworkPkg/IScsiDxe/IScsiDriver.c b/NetworkPkg/IScsiDxe/IScsiDriver.c
index 12095cb3ff..5a121ce9b3 100644
--- a/NetworkPkg/IScsiDxe/IScsiDriver.c
+++ b/NetworkPkg/IScsiDxe/IScsiDriver.c
@@ -865,10 +865,22 @@ IScsiStart (
IScsiSessionAbort (ExistPrivate->Session);
}
- Status = IScsiCleanDriverData (ExistPrivate);
- if (EFI_ERROR (Status)) {
- goto ON_ERROR;
+ if (ExistPrivate->DevicePath != NULL) {
+ Status = gBS->UninstallProtocolInterface (
+ ExistPrivate->ExtScsiPassThruHandle,
+ &gEfiDevicePathProtocolGuid,
+ ExistPrivate->DevicePath
+ );
+ if (EFI_ERROR (Status)) {
+ goto ON_ERROR;
+ }
+
+ FreePool (ExistPrivate->DevicePath);
}
+
+ gBS->CloseEvent (ExistPrivate->ExitBootServiceEvent);
+ FreePool (ExistPrivate);
+
}
} else {
//