Share via


ProtocolCmDeactivateVcComplete (NDIS 5.1) function

Note   NDIS 5. x has been deprecated and is superseded by NDIS 6. x. For new NDIS driver development, see Network Drivers Starting with Windows Vista. For information about porting NDIS 5. x drivers to NDIS 6. x, see Porting NDIS 5.x Drivers to NDIS 6.0.

The ProtocolCmDeactivateVcComplete function is a required function. ProtocolCmDeactivateVcComplete completes the processing of a call manager-initiated request that the underlying miniport driver (and NDIS) deactivate a VC for which NdisCmDeactivateVc previously returned NDIS_STATUS_PENDING.

Syntax

VOID ProtocolCmDeactivateVcComplete(
  _In_ NDIS_STATUS Status,
  _In_ NDIS_HANDLE CallMgrVcContext
);

Parameters

  • Status [in]
    Specifies the final status of the deactivation.

  • CallMgrVcContext [in]
    Specifies the handle to a call manager-allocated context area in which the call manager maintains its per-VC state. The call manager supplied this handle to NDIS from its ProtocolCoCreateVc function.

Return value

None

Remarks

NDIS usually calls ProtocolCmDeactivateVcComplete in the context of the call manager's closing down a call on behalf of a connection-oriented client. The call manager typically calls NdisCmDeactivateVc from its ProtocolCmCloseCall function. Whenever NdisCmDeactivateVc returns NDIS_STATUS_PENDING, NDIS subsequently calls its ProtocolCmDeactivateVcComplete function.

That is, when the underlying connection-oriented miniport driver has deactivated the VC, NDIS calls ProtocolCmDeactivateVcComplete. The final status of the deactivation is found in Status. Possible values for the final status include, but are not limited to:

  • NDIS_STATUS_SUCCESS
    Indicates that the VC was deactivated successfully.

  • NDIS_STATUS_NOT_ACCEPTED
    Indicates that an activation is pending on this VC. The call manager should attempt to deactivate the VC at a later time.

  • NDIS_STATUS_CLOSING
    Indicates that a deactivation is currently pending on this VC. The call manager need not call NdisCmDeactivateVc again as only one call to NdisCmDeactivateVc is required to deactivate a VC.

ProtocolCmDeactivateVcComplete performs whatever postprocessing is necessary to complete the deactivation of a virtual connection, such as setting flags in its state area to indicate that the connection is inactive or releasing dynamically allocated resources used while the VC is active.

Completion of the deactivation means that all call parameters for the VC used on activation are no longer valid. Any further use of the VC is prohibited except to reactivate it with a new set of call parameters.

Call managers should release any resources that were allocated for the VC activation and return control as quickly as possible. If the call manager previously returned NDIS_STATUS_PENDING from its ProtocolCmCloseCall function and all operations to close the call have been completed, ProtocolCmDeactivateVcComplete should now call NdisCmCloseCallComplete.

Requirements

Target platform

Desktop

Version

See ProtocolCmDeactivateVcComplete.

Header

Ndis.h (include Ndis.h)

IRQL

<= DISPATCH_LEVEL

See also

MiniportCoDeactivateVc

NdisCmCloseCallComplete

NdisCmDeactivateVc

ProtocolCmCloseCall

 

 

Send comments about this topic to Microsoft