Porting Protocol Driver OID Request Handling to CoNDIS 6.0

In NDIS 6.0, the NdisCoOidRequest function replaces the NDIS 5.x NdisCoRequest function, and the NDIS_OID_REQUEST structure replaces the NDIS_REQUEST structure.

To send an OID request to an underlying driver, a call manager or client calls NdisCoOidRequest and specifies a NULL address family. If NdisCoOidRequest returns NDIS_STATUS_PENDING, NDIS subsequently calls the ProtocolCoOidRequestComplete(formerly ProtocolCoRequestComplete) function to complete the request.

To send an OID request to another protocol driver in NDIS 6.0, a call manager or client specifies a valid address family when it calls NdisCoOidRequest. In this case, NDIS calls the other protocol driver's ProtocolCoOidRequest function (formerly ProtocolCoRequest). If ProtocolCoOidRequest returns NDIS_STATUS_PENDING, the protocol driver that received the request must later call the NdisCoOidRequestComplete function (formerly NdisCoRequestComplete) to complete the operation. NDIS subsequently calls the ProtocolCoOidRequestComplete(formerly ProtocolCoRequestComplete) function to complete the request.

NDIS 6.0 protocol drivers can call NdisCancelOidRequest to cancel an OID request to a miniport driver. Protocol drivers cannot cancel requests that they send to other protocol drivers. In NDIS 6.0, drivers should not call the NdisReset function, and NDIS 6.0 protocol drivers cannot reset the underlying miniport driver.

To improve computer performance, NDIS 6.0 protocol drivers should avoid OID requests when possible. For example, during bind operations, much of the information that was formerly available only through OID requests is available in the NDIS_BIND_PARAMETERS structure. To determine link status, use the status indications from underlying drivers instead of OID queries.

The NDIS_OID_REQUEST structure differs from NDIS_REQUEST in that NDIS_OID_REQUEST can specify a time-out and a request identifier.

For more information about OID requests in a protocol driver, see CoNDIS Protocol Driver OID Requests.