Summary of Changes Required to Port a Protocol Driver to NDIS 6.0

Summary of Changes Required to Port a Protocol Driver to NDIS 6.0

This topic provides a summary of the changes that are required to port an NDIS 5.x protocol driver to NDIS 6.0. Porting earlier drivers is similar to porting NDIS 5.x drivers. To run in the NDIS 6.0 environment, NDIS 5.x protocol drivers must be modified as follows:

Build Environment

Replace the preprocessor definition NDIS51 with NDIS60.

Driver Initialization
  • Set the NDIS version to 6.0 in the MajorNdisVersion and MinorNdisVersion members of the NDIS_PROTOCOL_DRIVER_CHARACTERISTICS structure (formerly NDIS_PROTOCOL_CHARACTERISTICS) that is passed to the NdisRegisterProtocolDriver function.

  • Set the protocol driver version in the MajorDriverVersion and MinorDriverVersion members of the NDIS_PROTOCOL_DRIVER_CHARACTERISTICS structure to an appropriate driver-specific value.

  • Define new entry points and replace obsolete entry points in the NDIS_PROTOCOL_DRIVER_CHARACTERISTICS structure. For example, the ProtocolBindAdapterEx function replaces the ProtocolBindAdapter function.

  • If the protocol driver uses optional handlers, add the entry point for the ProtocolSetOptions function to the NDIS_PROTOCOL_DRIVER_CHARACTERISTICS structure. To register optional handlers, ProtocolSetOptions calls the NdisSetOptionalHandlers function.

  • In the DriverEntry routine, replace the call to the NdisRegisterProtocol function with a call to the NdisRegisterProtocolDriver function. If an error occurs after a successful call to NdisRegisterProtocolDriver, the driver must call the NdisDeregisterProtocolDriver function before DriverEntry returns.

Driver Unload
Protocol Bind and Unbind Operations
Send and Receive Data Paths
  • Send and receive data paths should support multipacket operations.

  • Rewrite the send and receive code paths to use NET_BUFFER structures and NET_BUFFER_LIST structures instead of NDIS_PACKET structures.

OID Requests
Status Indications
Plug and Play Events
Binding States

 

 

Send comments about this topic to Microsoft

Show:
© 2016 Microsoft