- Send NetEventBindsComplete when binding has completed (required for the WDK example ndis protocol driver to work)

svn path=/trunk/; revision=42977
This commit is contained in:
Cameron Gutman 2009-09-01 00:15:30 +00:00
parent 4cb0bbe32f
commit b464adfcbe

View file

@ -1034,6 +1034,7 @@ NdisRegisterProtocol(
PPROTOCOL_BINDING Protocol;
NTSTATUS NtStatus;
UINT MinSize;
PNET_PNP_EVENT PnPEvent;
NDIS_DbgPrint(MAX_TRACE, ("Called.\n"));
@ -1101,6 +1102,23 @@ NdisRegisterProtocol(
ndisBindMiniportsToProtocol(Status, &Protocol->Chars);
/* Should we only send this if ndisBindMiniportsToProtocol succeeds? */
PnPEvent = ProSetupPnPEvent(NetEventBindsComplete, NULL, 0);
if (PnPEvent)
{
if (Protocol->Chars.PnPEventHandler)
{
/* We call this with a NULL binding context because it affects all bindings */
NtStatus = (*Protocol->Chars.PnPEventHandler)(NULL,
PnPEvent);
/* FIXME: We don't support this yet */
ASSERT(NtStatus != NDIS_STATUS_PENDING);
}
ExFreePool(PnPEvent);
}
if (*Status == NDIS_STATUS_SUCCESS) {
ExInterlockedInsertTailList(&ProtocolListHead, &Protocol->ListEntry, &ProtocolListLock);
} else {