NetworkPkg: Fix IPv6 boot failure in diff net segment issue
This patch is used to fix HTTP IPv6 boot failure in diff net segment issue. IPv6 gateway address should be registered before DNS query, otherwise, DNS query will fail. Cc: Ye Ting <ting.ye@intel.com> Cc: Zhang Lubo <lubo.zhang@intel.com> Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Jiaxin Wu <jiaxin.wu@intel.com> Reviewed-by: Zhang Lubo <lubo.zhang@intel.com>
This commit is contained in:
@ -300,6 +300,14 @@ HttpBootDhcp6ExtractUriInfo (
|
|||||||
if (EFI_ERROR (Status)) {
|
if (EFI_ERROR (Status)) {
|
||||||
return Status;
|
return Status;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
//
|
||||||
|
// Register the IPv6 gateway address to the network device.
|
||||||
|
//
|
||||||
|
Status = HttpBootSetIp6Gateway (Private);
|
||||||
|
if (EFI_ERROR (Status)) {
|
||||||
|
return Status;
|
||||||
|
}
|
||||||
|
|
||||||
//
|
//
|
||||||
// Configure the default DNS server if server assigned.
|
// Configure the default DNS server if server assigned.
|
||||||
@ -356,15 +364,7 @@ HttpBootDhcp6ExtractUriInfo (
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
CopyMem (&Private->ServerIp.v6, &IpAddr, sizeof (EFI_IPv6_ADDRESS));
|
CopyMem (&Private->ServerIp.v6, &IpAddr, sizeof (EFI_IPv6_ADDRESS));
|
||||||
|
|
||||||
//
|
|
||||||
// register the IPv6 gateway address to the network device.
|
|
||||||
//
|
|
||||||
Status = HttpBootSetIp6Gateway (Private);
|
|
||||||
if (EFI_ERROR (Status)) {
|
|
||||||
return Status;
|
|
||||||
}
|
|
||||||
|
|
||||||
//
|
//
|
||||||
// Extract the port from URL, and use default HTTP port 80 if not provided.
|
// Extract the port from URL, and use default HTTP port 80 if not provided.
|
||||||
|
Reference in New Issue
Block a user