mirror of
https://github.com/acidanthera/audk.git
synced 2025-07-29 16:44:10 +02:00
NetworkPkg/Ip6Dxe: Clean the invalid IPv6 configuration during driver start.
REF: https://bugzilla.tianocore.org/show_bug.cgi?id=1448 *v3: Change the if condition check to only clean the invalid configuration. *v2: Add the warning debug message. This patch is to clean the invalid data and continue to start IP6 driver. Cc: Michael Turner <Michael.Turner@microsoft.com> Cc: Ye Ting <ting.ye@intel.com> Cc: Fu Siyuan <siyuan.fu@intel.com> Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Wu Jiaxin <jiaxin.wu@intel.com> Reviewed-by: Siyuan Fu <siyuan.fu@intel.com>
This commit is contained in:
parent
c417c1b33d
commit
a169a04fd2
@ -587,8 +587,17 @@ Ip6DriverBindingStart (
|
|||||||
DataItem->DataSize,
|
DataItem->DataSize,
|
||||||
DataItem->Data.Ptr
|
DataItem->Data.Ptr
|
||||||
);
|
);
|
||||||
if (EFI_ERROR(Status) && Status != EFI_NOT_READY) {
|
if (Status == EFI_INVALID_PARAMETER || Status == EFI_BAD_BUFFER_SIZE) {
|
||||||
goto UNINSTALL_PROTOCOL;
|
//
|
||||||
|
// Clean the invalid ManualAddress configuration.
|
||||||
|
//
|
||||||
|
Status = Ip6Cfg->SetData (
|
||||||
|
Ip6Cfg,
|
||||||
|
Ip6ConfigDataTypeManualAddress,
|
||||||
|
0,
|
||||||
|
NULL
|
||||||
|
);
|
||||||
|
DEBUG ((EFI_D_WARN, "Ip6DriverBindingStart: Clean the invalid ManualAddress configuration.\n"));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -603,8 +612,17 @@ Ip6DriverBindingStart (
|
|||||||
DataItem->DataSize,
|
DataItem->DataSize,
|
||||||
DataItem->Data.Ptr
|
DataItem->Data.Ptr
|
||||||
);
|
);
|
||||||
if (EFI_ERROR(Status)) {
|
if (Status == EFI_INVALID_PARAMETER || Status == EFI_BAD_BUFFER_SIZE) {
|
||||||
goto UNINSTALL_PROTOCOL;
|
//
|
||||||
|
// Clean the invalid Gateway configuration.
|
||||||
|
//
|
||||||
|
Status = Ip6Cfg->SetData (
|
||||||
|
Ip6Cfg,
|
||||||
|
Ip6ConfigDataTypeGateway,
|
||||||
|
0,
|
||||||
|
NULL
|
||||||
|
);
|
||||||
|
DEBUG ((EFI_D_WARN, "Ip6DriverBindingStart: Clean the invalid Gateway configuration.\n"));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user