NdisMWanSendComplete

VOID
    NdisMWanSendComplete(
        IN NDIS_HANDLE  MiniportAdapterHandle,
        IN PNDIS_WAN_PACKET  Packet,
        IN NDIS_STATUS  Status
        );

NdisMWanSendComplete returns the packet and final status of a completed send request for which the miniport previously returned NDIS_STATUS_PENDING.

Parameters

MiniportAdapterHandle
Specifies the handle originally input to MiniportInitialize.
Packet
Points to the protocol-supplied packet originally passed in to the MiniportWanSend function.
Status
Specifies the NDIS_STATUS_XXX code describing the outcome of the completed send operation, either NDIS_STATUS_SUCCESS or a miniport-determined error status value.

Comments

Whenever the MiniportWanSend function returns NDIS_STATUS_PENDING for an incoming packet, the miniport must eventually call NdisMWanSendComplete with a pointer to that packet. When MiniportWanSend returns any NDIS_STATUS_XXX except NDIS_STATUS_PENDING for a given packet, that packet is considered completed as soon as MiniportWanSend returns control.

Calling NdisMWanSendComplete does not necessarily imply that the packet has been transmitted over the network, although usually it has before a miniport calls this function. However, a miniport might call NdisMWanSendComplete as soon as it has successfully programmed its NIC for the transmit operation, particularly if its NIC is a so-called intelligent network card.

NdisMWanSendComplete forwards the completed packet to the ProtocolSendComplete function of the driver that initiated the original send operation. Then, the protocol regains ownership of the packet and all buffers that it allocated for the send.

Callers of NdisMWanSendComplete run at IRQL DISPATCH_LEVEL.

See Also

MiniportInitialize, MiniportWanSend, NdisSend, ProtocolSendComplete