NetworkPkg/IScsiDxe: Correct the DnsMode value according the target info.

When the platform gets the target info from DHCP (option 17) and the ISCSI
server is expressed as IP address, the value of DnsMode should be false,
otherwise, the failure will happen in certain case.

please refer to https://bugzilla.tianocore.org/show_bug.chi?id=823 for
the detailed steps.

Cc: Ye Ting <ting.ye@intel.com>
Cc: Fu Siyuan <siyuan.fu@intel.com>
Cc: Karunakar P <karunakarp@amiindia.co.in>
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Wu Jiaxin <jiaxin.wu@intel.com>
Tested-by: Karunakar P <karunakarp@amiindia.co.in>
Reviewed-by: Ye Ting <ting.ye@intel.com>
Reviewed-by: Fu Siyuan <siyuan.fu@intel.com>
This commit is contained in:
Jiaxin Wu 2017-12-22 10:15:36 +08:00
parent 2af1059064
commit db0cd7ecab
1 changed files with 1 additions and 0 deletions

View File

@ -134,6 +134,7 @@ IScsiDhcpExtractRootPath (
CopyMem (&ConfigNvData->TargetUrl, Field->Str, Field->Len);
ConfigNvData->TargetUrl[Field->Len + 1] = '\0';
} else {
ConfigNvData->DnsMode = FALSE;
ZeroMem(ConfigNvData->TargetUrl, sizeof (ConfigNvData->TargetUrl));
Status = IScsiAsciiStrToIp (Field->Str, IpMode, &Ip);
CopyMem (&ConfigNvData->TargetIp, &Ip, sizeof (EFI_IP_ADDRESS));