Implement MiniportRestart to Restart the Adapter (Compact 7)
3/12/2014
The miniport adapter restart capability is a new feature in NDIS 6.0. NDIS calls your miniport driver's MiniportRestart function to return the miniport adapter from the Paused state to the Running state. Typically, your MiniportRestart function performs the following operations:
- Completes any tasks that are required to resume send and receive operations.
- Modifies restart attributes (if NDIS passes restart attributes to MiniportRestart).
- Optionally provides status indications by calling NdisMIndicateStatusEx.
When NDIS passes restart attributes to MiniportRestart, it does so through the RestartAttributes member of NDIS_MINIPORT_RESTART_PARAMETERS, the address of which is passed as the second argument to MiniportRestart. If the RestartAttributes pointer is not NULL, then it points to an NDIS_RESTART_ATTRIBUTES structure. Your driver can modify any member of NDIS_RESTART_ATTRIBUTES. If the RestartAttributes pointer is NULL, then your driver must not modify RestartAttributes or report any attribute changes.
Windows Embedded Compact includes a sample NDIS 6.0 driver that implements MiniportRestart. The sample driver is located at:
%_WINCEROOT%\Public\Common\Oak\Drivers\Netcard\E100bex\60
The source file mp_main.c includes the function MPRestart, which implements MiniportRestart functionality for this driver.