NDIS_SWITCH_GROW_NET_BUFFER_LIST_DESTINATIONS callback function

The GrowNetBufferListDestinations function adds space for additional Hyper-V extensible switch destination ports to a packet that is specified by a NET_BUFFER_LIST structure.

Syntax

NDIS_SWITCH_GROW_NET_BUFFER_LIST_DESTINATIONS NdisSwitchGrowNetBufferListDestinations;

NDIS_STATUS NdisSwitchGrowNetBufferListDestinations(
  NDIS_SWITCH_CONTEXT NdisSwitchContext,
  PNET_BUFFER_LIST NetBufferList,
  UINT32 NumberOfNewDestinations,
  PNDIS_SWITCH_FORWARDING_DESTINATION_ARRAY *Destinations
)
{...}

Parameters

NdisSwitchContext

An NDIS_SWITCH_CONTEXT value that contains the handle of the extensible switch module to which the Hyper-V extensible switch extension is attached. When the extension calls NdisFGetOptionalSwitchHandlers, this handle is returned through the NdisSwitchContext parameter.

NetBufferList

A pointer to a linked list of NET_BUFFER_LIST structures.

Note  This structure must contain an extensible switch forwarding context. If the extension created or cloned the packet, it must have previously allocated this structure by calling the AllocateNetBufferListForwardingContext function. For more information about the extensible switch forwarding context, see Hyper-V Extensible Switch Forwarding Context.
 

NumberOfNewDestinations

A UINT32 value that specifies the number of new destination ports to be added for the packet.

*Destinations

Return Value

If the call succeeds, the function returns NDIS_STATUS_SUCCESS. Otherwise, it returns an NDIS_STATUS_Xxx error code that is defined in Ndis.h.

Remarks

The extensible switch extension calls the GrowNetBufferListDestinations function to add space for destination ports for a packet. Port destinations are specified through an NDIS_SWITCH_FORWARDING_DESTINATION_ARRAY structure.

For more information on how to add destination ports to a packet, see Adding Extensible Switch Destination Port Data to a Packet.

Note  If the NetBufferList parameter contains a pointer to a linked-list of multiple NET_BUFFER_LIST structures, space for additional destination ports is only added to the first NET_BUFFER_LIST structure in the list.
 

Requirements

   
Minimum supported client Supported in NDIS 6.30 and later.
Target Platform Desktop
Header ndis.h (include Ndis.h)
IRQL "<= DISPATCH_LEVEL"

See Also

AllocateNetBufferListForwardingContext

NDIS_SWITCH_FORWARDING_DESTINATION_ARRAY

NDIS_SWITCH_PORT_DESTINATION

NET_BUFFER

NET_BUFFER_LIST

NdisFGetOptionalSwitchHandlers

UpdateNetBufferListDestinations