DriverEntry of NDIS Miniport Drivers function
The DriverEntry function is required and is the first function that the system calls in any NDIS miniport driver.
- Argument1 [in]
A pointer to a system-supplied parameter. For Windows 2000 and later drivers, this points to a driver object, which is opaque to any NDIS driver that exports only MiniportXxx functions.
- Argument2 [in]
A pointer to a second system-supplied parameter. For Windows 2000 and later drivers, this points to a registry path, which is opaque to any NDIS driver that exports only MiniportXxx functions.
NDIS miniport drivers fill in an NDIS_MINIPORT_DRIVER_CHARACTERISTICS structure with the appropriate version numbers and the entry points for driver-supplied MiniportXxx functions and then call NdisMRegisterMiniportDriver.
Intermediate drivers share most of the DriverEntry requirements of miniport drivers. For more information about the DriverEntry function for intermediate drivers, see DriverEntry of NDIS Intermediate Drivers.
DriverEntry can allocate the NDIS_MINIPORT_DRIVER_CHARACTERISTICS structure on the stack because the NDIS library copies the relevant information to its own storage. DriverEntry should clear the memory for this structure with NdisZeroMemory before setting any driver-supplied values in its members. The MajorNdisVersion and MinorNdisVersion members must contain the major and minor versions of NDIS that that driver supports. In each XxxHandler member of the characteristics structure, DriverEntry must set the entry point of a driver-supplied MiniportXxx function, or the member must be NULL.
Drivers that call NdisMRegisterMiniportDriver must be prepared for NDIS to call their MiniportInitializeEx functions any time after DriverEntry returns. Such a driver must have sufficient installation and configuration information stored in the registry or available from calls to an NdisXxx bus-type-specific configuration function to set up any NIC-specific resources the driver will need to carry out network I/O operations.
|Supported in NDIS 5.1, and NDIS 6.0 and later. For NDIS 5.1 drivers, see DriverEntry of NDIS Miniport Drivers (NDIS 5.1).|
- Initializing a Miniport Driver