Partager via


NdisIfFreeNetLuidIndex (Compact 2013)

3/26/2014

This function frees a network interface NET_LUID index that was previously allocated by a call to the NdisIfAllocateNetLuidIndex function.

Syntax

NDIS_STATUS
  NdisIfFreeNetLuidIndex(
    IN NET_IFTYPE  IfType,
    IN UINT32  NetLuidIndex
    );

Parameters

  • IfType
    The interface type that the index was allocated for. The caller must provide the same value that it used when it allocated the NET_LUID index with NdisIfAllocateNetLuidIndex. For a list of interface types, see NDIS Interface Types.
  • NetLuidIndex
    The NET_LUID index value that NDIS should free. This index was allocated in a previous call to NdisIfAllocateNetLuidIndex.

Return Value

NdisIfFreeNetLuidIndex returns one of the following values:

Value

Description

NDIS_STATUS_SUCCESS

The operation completed successfully.

DIS_STATUS_INVALID_PARAMETER

NdisIfFreeNetLuidIndex failed because the NetLuidIndex parameter specified an index that was not allocated for the type that the IfType parameter specified.

If the call to NdisIfFreeNetLuidIndex fails, the interface provider should remove any information that it saved in persistent storage that is related to the index. Removing the information will make sure that the provider does not continue to try to free an index that is already freed after the device restarts.

Remarks

NDIS interface providers call the NdisIfFreeNetLuidIndex function to free a NET_LUID index. The interface provider should free the NET_LUID index only if the interface will not be used any longer on the local device.

NdisIfFreeNetLuidIndex returns a previously allocated NET_LUID index to NDIS for possible reallocation to another interface. The caller must pass in the same interface type at IfType that it used when it called the NdisIfAllocateNetLuidIndex function to allocate the NET_LUID index.

The provider should not use the freed NET_LUID index or the associated NET_LUID value in any other NDIS function calls after it calls NdisIfFreeNetLuidIndex.

Requirements

Header

ndis.h

See Also

Reference

NDIS Network Interface Functions
NdisIfAllocateNetLuidIndex

Other Resources

NET_LUID