Compartilhar via


NdisQueryBindInstanceName (Compact 2013)

3/26/2014

This function retrieves the friendly name of a physical network adapter or a virtual adapter that the calling protocol driver will bind to.

Syntax

NDIS_STATUS
  NdisQueryBindInstanceName(
    OUT PNDIS_STRING  pAdapterInstanceName,
    IN NDIS_HANDLE  BindingContext
    );

Parameters

  • pAdapterInstanceName
    A pointer to a caller-supplied NDIS_STRING type that receives a counted Unicode string. This string specifies the friendly name of the interface to which the binding refers. This interface is either a physical network adapter or a virtual adapter
  • BindingContext
    A handle that identifies the NDIS context area for the bind operation. NDIS passed this handle to the BindContext parameter of the ProtocolBindAdapterEx function.

Return Value

NdisQueryBindInstanceName returns NDIS_STATUS_SUCCESS if memory for the string at pAdapterInstanceName was successfully allocated; otherwise, it returns NDIS_STATUS_RESOURCES.

Remarks

A protocol driver uses NdisQueryBindInstanceName to retrieve the friendly name of a physical network adapter or a virtual adapter to which the protocol driver will be bound. The protocol driver specifies the binding context that NDIS provided in the ProtocolBindAdapterEx function.

Protocol drivers can use NdisQueryBindInstanceName to obtain the friendly name before they bind to the adapter.

NdisQueryBindInstanceName allocates memory for the string that specifies the friendly name. After the caller finishes using this memory, the caller must call the NdisFreeMemory function to release the memory.

Friendly names are intended to help the user quickly and accurately identify a physical network adapter or virtual adapter-for example, "PCI Ethernet Adapter" and "Virtual Private Networking Adapter" are considered friendly names.

Requirements

Header

ndis.h

See Also

Reference

NDIS Functions for Protocol Drivers
NdisFreeMemory
ProtocolBindAdapterEx