diff options
author | Jiaxin Wu <jiaxin.wu@intel.com> | 2017-10-16 14:53:09 +0800 |
---|---|---|
committer | Jiaxin Wu <jiaxin.wu@intel.com> | 2017-10-26 16:19:45 +0800 |
commit | 067ca8382201a7a8d7c44b03f117482e5a2306e6 (patch) | |
tree | c619ebc712d6c19417c647994411dab585aa3b2e | |
parent | 452676ffd895651683dcf19535e65294ff1d00d0 (diff) | |
download | edk2-067ca8382201a7a8d7c44b03f117482e5a2306e6.zip edk2-067ca8382201a7a8d7c44b03f117482e5a2306e6.tar.gz edk2-067ca8382201a7a8d7c44b03f117482e5a2306e6.tar.bz2 |
NetworkPkg/IScsiDxe: Fix the incorrect/needless DHCP process.
The existing attempt should not trigger the DHCP process if it
doesn't associates with the current NIC. That's incorrect when
displaying the initiator info in attempt page.
Cc: Karunakar P <karunakarp@amiindia.co.in>
Cc: Ye Ting <ting.ye@intel.com>
Cc: Fu Siyuan <siyuan.fu@intel.com>
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Wu Jiaxin <jiaxin.wu@intel.com>
Reviewed-by: Karunakar p <karunakarp@amiindia.co.in>
-rw-r--r-- | NetworkPkg/IScsiDxe/IScsiMisc.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/NetworkPkg/IScsiDxe/IScsiMisc.c b/NetworkPkg/IScsiDxe/IScsiMisc.c index efd05cf..0a0a3f5 100644 --- a/NetworkPkg/IScsiDxe/IScsiMisc.c +++ b/NetworkPkg/IScsiDxe/IScsiMisc.c @@ -1994,9 +1994,12 @@ IScsiGetConfigData ( continue;
}
- } else if (AttemptTmp->SessionConfigData.InitiatorInfoFromDhcp && !AttemptTmp->ValidPath) {
+ } else if (AttemptTmp->SessionConfigData.InitiatorInfoFromDhcp &&
+ !AttemptTmp->ValidPath &&
+ AttemptTmp->NicIndex == mPrivate->CurrentNic) {
//
- // Get DHCP information for already added, but failed, attempt.
+ // If the attempt associates with the current NIC, we can
+ // get DHCP information for already added, but failed, attempt.
//
AttemptTmp->DhcpSuccess = FALSE;
if (!mPrivate->Ipv6Flag && (AttemptTmp->SessionConfigData.IpMode == IP_MODE_IP4)) {
|