mirror of https://github.com/acidanthera/audk.git
1. Fixed issue when calculating timeout value in timeout function in MNP module.
2. Added and refine some comments. 3. Enable UefiPxeBc Module to accept all broadcast packets for UDP Read&Write interface. git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@6781 6f19259b-4bc3-4df7-8a09-765794883524
This commit is contained in:
parent
0e4d589e91
commit
48bd50c5a1
|
@ -1042,9 +1042,12 @@ MnpCheckPacketTimeout (
|
|||
|
||||
RxDataWrap = NET_LIST_USER_STRUCT (RxEntry, MNP_RXDATA_WRAP, WrapEntry);
|
||||
|
||||
if (RxDataWrap->TimeoutTick >= MNP_TIMEOUT_CHECK_INTERVAL) {
|
||||
//
|
||||
// TimeoutTick unit is ms, MNP_TIMEOUT_CHECK_INTERVAL unit is 100ns.
|
||||
//
|
||||
if (RxDataWrap->TimeoutTick >= (MNP_TIMEOUT_CHECK_INTERVAL / 10)) {
|
||||
|
||||
RxDataWrap->TimeoutTick -= MNP_TIMEOUT_CHECK_INTERVAL;
|
||||
RxDataWrap->TimeoutTick -= (MNP_TIMEOUT_CHECK_INTERVAL / 10);
|
||||
} else {
|
||||
//
|
||||
// Drop the timeout packet.
|
||||
|
|
|
@ -451,13 +451,16 @@ Udp4CheckTimeout (
|
|||
//
|
||||
Wrap = NET_LIST_USER_STRUCT (WrapEntry, UDP4_RXDATA_WRAP, Link);
|
||||
|
||||
if (Wrap->TimeoutTick <= UDP4_TIMEOUT_INTERVAL / 10) {
|
||||
//
|
||||
// TimeoutTick unit is ms, MNP_TIMEOUT_CHECK_INTERVAL unit is 100ns.
|
||||
//
|
||||
if (Wrap->TimeoutTick <= (UDP4_TIMEOUT_INTERVAL / 10)) {
|
||||
//
|
||||
// Remove this RxData if it timeouts.
|
||||
//
|
||||
Udp4RecycleRxDataWrap (NULL, (VOID *) Wrap);
|
||||
} else {
|
||||
Wrap->TimeoutTick -= UDP4_TIMEOUT_INTERVAL / 10;
|
||||
Wrap->TimeoutTick -= (UDP4_TIMEOUT_INTERVAL / 10);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -318,7 +318,7 @@ PxeBcDriverBindingStart (
|
|||
goto ON_ERROR;
|
||||
}
|
||||
ZeroMem (&Private->Udp4CfgData, sizeof (EFI_UDP4_CONFIG_DATA));
|
||||
Private->Udp4CfgData.AcceptBroadcast = FALSE;
|
||||
Private->Udp4CfgData.AcceptBroadcast = TRUE;
|
||||
Private->Udp4CfgData.AcceptPromiscuous = FALSE;
|
||||
Private->Udp4CfgData.AcceptAnyPort = TRUE;
|
||||
Private->Udp4CfgData.AllowDuplicatePort = TRUE;
|
||||
|
|
Loading…
Reference in New Issue