Summary of Changes Required to Port a Miniport Driver to NDIS 6.20
This topic summarizes the changes that are required to port an NDIS 6.x miniport driver to NDIS 6.20.
NDIS 6.20 retains backward compatibility with earlier NDIS versions. For more information about backward compatibility, see NDIS 6.20 Backward Compatibility.
To update a miniport driver to support the NDIS 6.20 environment, you must modify the NDIS 6.x miniport driver as follows:
Build Environment
Replace the preprocessor definition NDIS60_MINIPORT_DRIVER or NDIS61_MINIPORT_DRIVER with NDIS620_MINIPORT_DRIVER.
Replace obsolete interfaces with NDIS 6.20 versions. For more information about obsolete interfaces, see Obsolete Interfaces in NDIS 6.20.
Update the following interfaces to support more than 64 processors:
- Receive side scaling (RSS)
- Processor information device driver interfaces
- Resource allocation
- Read and write locks
For more information about supporting more than 64 processors, see Support for More than 64 Processors in NDIS 6.20.
Set the NDIS version to 6.20 in the MajorNdisVersion and MinorNdisVersion members of the NDIS_MINIPORT_DRIVER_CHARACTERISTICS structure, which is passed to the NdisMRegisterMiniportDriver function.
Set the miniport driver version in the MajorDriverVersion and MinorDriverVersion members of the NDIS_MINIPORT_DRIVER_CHARACTERISTICS structure to an appropriate driver-specific value.
Define direct OID request entry points in the NDIS_MINIPORT_DRIVER_CHARACTERISTICS structure. Support for the direct OID request interface was optional for NDIS 6.1 drivers but it is mandatory for NDIS 6.20 drivers. For more information about the miniport driver direct OID request interface, see Miniport Adapter OID Requests.
Miniport Adapter Initialization
Use the latest version of the miniport adapter capabilities advertisement interfaces. The following interfaces have updated capabilities:
- Power Management
- Receive side scaling (RSS)
- Hardware assist (VMQ)
Use the updated versions of these structures:
- NDIS_MINIPORT_ADAPTER_GENERAL_ATTRIBUTES
- NDIS_RESTART_GENERAL_ATTRIBUTES
- NDIS_RECEIVE_SCALE_PARAMETERS
- NDIS_MINIPORT_ADAPTER_HARDWARE_ASSIST_ATTRIBUTES
For information about NDIS structure version information, see Specifying NDIS Version Information.
NDIS 6.20 drivers must support receive-side throttle (RST) in processing receive interrupts. The ReceiveThrottleParameters parameters of the MiniportInterruptDPC and MiniportMessageInterruptDPC DPC handler functions point to an NDIS_RECEIVE_THROTTLE_PARAMETERS structure. On entry to the deferred procedure call (DPC) handler, the MaxNblsToIndicate member of the NDIS_RECEIVE_THROTTLE_PARAMETERS structure specifies the maximum number of NET_BUFFER_LIST structures that the miniport driver should indicate in the DPC. For more information about RST, see Receive Side Throttle in NDIS 6.20.
Use the updated version of the NET_BUFFER structure.
Optionally support the virtual machine queue (VMQ) interface. For more information about VMQ, see Virtual Machine Queue (VMQ) in NDIS 6.20.