Starting a NIC (NDIS 5.1)
Note NDIS 5. x has been deprecated and is superseded by NDIS 6. x. For new NDIS driver development, see Network Drivers Starting with Windows Vista. For information about porting NDIS 5. x drivers to NDIS 6. x, see Porting NDIS 5.x Drivers to NDIS 6.0.
NDIS participates in the starting of a NIC as follows:
The PnP manager issues an IRP_MN_START_DEVICE request. This IRP contains information that informs NDIS of the resources that the PnP manager has allocated for the NIC.
NDIS sets an IoCompletion routine and passes the IRP_MN_START_DEVICE request down the device stack to the next lowest driver, which is typically the bus driver. On receiving the IRP_MN_START_DEVICE request, the bus driver performs its start operations on the device and passes the completed IRP_MN_START_DEVICE request back up the device stack.
On receiving the completed IRP_MN_START_DEVICE request (that is, when NDIS's DispatchPnP routine gains control after all lower drivers have finished with the IRP), NDIS calls the miniport driver's MiniportInitialize function.
If the MiniportInitialize function returns NDIS_STATUS_SUCCESS, NDIS schedules an event to call the ProtocolBindAdapter function of all protocol drivers that are supposed to bind to the adapter, as indicated by the binding information in the registry. Note that the miniport driver has no information concerning bindings.
NDIS completes the IRP_MN_START_DEVICE request.