mirror of https://github.com/acidanthera/audk.git
NetworkPkg/UefiPxeBcDxe: Correct the handle for PXE Base Code Callback Protocol.
According UEFI Spec: The PXE Base Code Callback Protocol must be on the same handle as the PXE Base Code Protocol. But current implementation doesn't follow that. This patch is fix that issue. 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: Fu Siyuan <siyuan.fu@intel.com>
This commit is contained in:
parent
10e6244236
commit
09cddd088c
|
@ -994,7 +994,7 @@ PxeBcInstallCallback (
|
||||||
//
|
//
|
||||||
PxeBc = &Private->PxeBc;
|
PxeBc = &Private->PxeBc;
|
||||||
Status = gBS->HandleProtocol (
|
Status = gBS->HandleProtocol (
|
||||||
Private->Controller,
|
Private->Mode.UsingIpv6 ? Private->Ip6Nic->Controller : Private->Ip4Nic->Controller,
|
||||||
&gEfiPxeBaseCodeCallbackProtocolGuid,
|
&gEfiPxeBaseCodeCallbackProtocolGuid,
|
||||||
(VOID **) &Private->PxeBcCallback
|
(VOID **) &Private->PxeBcCallback
|
||||||
);
|
);
|
||||||
|
@ -1010,7 +1010,7 @@ PxeBcInstallCallback (
|
||||||
// Install a default callback if user didn't offer one.
|
// Install a default callback if user didn't offer one.
|
||||||
//
|
//
|
||||||
Status = gBS->InstallProtocolInterface (
|
Status = gBS->InstallProtocolInterface (
|
||||||
&Private->Controller,
|
Private->Mode.UsingIpv6 ? &Private->Ip6Nic->Controller : &Private->Ip4Nic->Controller,
|
||||||
&gEfiPxeBaseCodeCallbackProtocolGuid,
|
&gEfiPxeBaseCodeCallbackProtocolGuid,
|
||||||
EFI_NATIVE_INTERFACE,
|
EFI_NATIVE_INTERFACE,
|
||||||
&Private->LoadFileCallback
|
&Private->LoadFileCallback
|
||||||
|
@ -1054,7 +1054,7 @@ PxeBcUninstallCallback (
|
||||||
PxeBc->SetParameters (PxeBc, NULL, NULL, NULL, NULL, &NewMakeCallback);
|
PxeBc->SetParameters (PxeBc, NULL, NULL, NULL, NULL, &NewMakeCallback);
|
||||||
|
|
||||||
gBS->UninstallProtocolInterface (
|
gBS->UninstallProtocolInterface (
|
||||||
Private->Controller,
|
Private->Mode.UsingIpv6 ? Private->Ip6Nic->Controller : Private->Ip4Nic->Controller,
|
||||||
&gEfiPxeBaseCodeCallbackProtocolGuid,
|
&gEfiPxeBaseCodeCallbackProtocolGuid,
|
||||||
&Private->LoadFileCallback
|
&Private->LoadFileCallback
|
||||||
);
|
);
|
||||||
|
|
|
@ -1925,7 +1925,7 @@ EfiPxeBcSetParameters (
|
||||||
// Update the previous PxeBcCallback protocol.
|
// Update the previous PxeBcCallback protocol.
|
||||||
//
|
//
|
||||||
Status = gBS->HandleProtocol (
|
Status = gBS->HandleProtocol (
|
||||||
Private->Controller,
|
Mode->UsingIpv6 ? Private->Ip6Nic->Controller : Private->Ip4Nic->Controller,
|
||||||
&gEfiPxeBaseCodeCallbackProtocolGuid,
|
&gEfiPxeBaseCodeCallbackProtocolGuid,
|
||||||
(VOID **) &Private->PxeBcCallback
|
(VOID **) &Private->PxeBcCallback
|
||||||
);
|
);
|
||||||
|
|
Loading…
Reference in New Issue