共用方式為


ProtocolCloseAdapterComplete (Compact 2013)

3/26/2014

This function is a required driver function that completes processing for an unbinding operation for which NdisCloseAdapter returned NDIS_STATUS_PENDING.

Syntax

VOID ProtocolCloseAdapterComplete(
  NDIS_HANDLE ProtocolBindingContext,
  NDIS_STATUS Status
);

Parameters

  • ProtocolBindingContext
    [in] Specifies the handle to a protocol-allocated context area in which the protocol driver maintains per-binding runtime state. The driver supplied this handle when it called NdisOpenAdapter.
  • Status
    [in] Indicates the final status of the close operation in the underlying driver.

Return Value

None.

Remarks

NDIS delays calling ProtocolCloseAdapterComplete until every request pending on the binding has completed. When ProtocolCloseAdapterComplete is called, the NdisBindingHandle originally returned by NdisOpenAdapter is no longer valid. ProtocolCloseAdapterComplete cannot call any NdisXXX function that requires this handle as a parameter.

ProtocolCloseAdapterComplete releases all resources the driver allocated for per-binding network I/O operations before it returns control.

ProtocolCloseAdapterComplete must call NdisCompleteUnbindAdapter with the UnbindContext handle saved in the ProtocolBindingContext area by ProtocolUnbindAdapter. Consequently, ProtocolCloseAdapterComplete should not release the driver-allocated context area until it has called NdisCompleteUnbindAdapter.

Requirements

Header

ndis.h

Library

Ndislib.lib

See Also

Reference

NDIS 5.x Legacy Functions
NdisCloseAdapter
NdisCompleteUnbindAdapter
NdisFreeBufferPool
NdisFreeMemory
NdisFreePacketPool
NdisOpenAdapter
ProtocolUnbindAdapter