1. Add DPC protocol and DpcLib library in MdeModulePkg.

2. Add DpcDxe module and DxeDpcLib module in MdeModulePkg
3. Port network stack module to use DPC.
4. Use MIN, and MAX defined in MdePkg to replace NET_MIN and NET_MAX.

git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@4307 6f19259b-4bc3-4df7-8a09-765794883524
This commit is contained in:
vanjeff
2007-11-20 05:42:23 +00:00
parent 04e12c2147
commit 36ee91ca36
48 changed files with 1835 additions and 543 deletions

View File

@@ -294,6 +294,11 @@ SIGNAL_TOKEN:
Token->Status = Status;
gBS->SignalEvent (Token->Event);
//
// Dispatch the DPC queued by the NotifyFunction of Token->Event.
//
NetLibDispatchDpc ();
return EFI_SUCCESS;
}
@@ -562,12 +567,6 @@ MnpMatchPacket (
ConfigData = &Instance->ConfigData;
if (ConfigData->EnablePromiscuousReceive) {
//
// Always match if this instance is configured to be promiscuous.
//
return TRUE;
}
//
// Check the protocol type.
//
@@ -575,6 +574,13 @@ MnpMatchPacket (
return FALSE;
}
if (ConfigData->EnablePromiscuousReceive) {
//
// Always match if this instance is configured to be promiscuous.
//
return TRUE;
}
//
// The protocol type is matched, check receive filter, include unicast and broadcast.
//
@@ -987,6 +993,11 @@ MnpReceivePacket (
//
MnpDeliverPacket (MnpServiceData);
//
// Dispatch the DPC queued by the NotifyFunction of rx token's events.
//
NetLibDispatchDpc ();
EXIT:
ASSERT (Nbuf->TotalSize == MnpServiceData->BufferLength);
@@ -1087,4 +1098,6 @@ MnpSystemPoll (
// Try to receive packets from Snp.
//
MnpReceivePacket (MnpServiceData);
NetLibDispatchDpc ();
}