Freigeben über


NdisIMGetBindingContext (Compact 2013)

3/26/2014

This function allows an NDIS protocol driver to access the device context area, which was created by an underlying intermediate driver, for a virtual miniport to which the higher level protocol driver is bound.

Syntax

NDIS_HANDLE NdisIMGetBindingContext(
  NDIS_HANDLE NdisBindingHandle
);

Parameters

  • NdisBindingHandle
    [in] The binding handle that the NdisOpenAdapterEx function returned at the NdisBindingHandle parameter that identifies the virtual miniport of the next lower intermediate driver to which the caller is bound.

Return Value

The following table shows the return values for NdisIMGetBindingContext.

Value

Description

NdisIMGetBindingContext

Returns access to the device context area for the given virtual network adapter.

NULL

Returns if no device context area exists for the given virtual network adapter.

Remarks

A protocol driver or intermediate driver can call NdisIMGetBindingContext from its ProtocolBindAdapterEx function to access the device context for a virtual miniport to which it is bound. The device context provides a common context area for all overlying protocol drivers that are bound to the same underlying intermediate driver.

Such a device context area was allocated and defined by the lower level NDIS intermediate driver and passed to NDIS in a call to the NdisIMInitializeDeviceInstanceEx function.

All protocol drivers that call NdisIMGetBindingContext can safely assume that the underlying intermediate driver allocated its context area from nonpaged pool. They should treat the returned context area as read-only, preserving the state set up by the underlying NDIS intermediate driver that defined it.

Requirements

Header

ndis.h

Library

ndis.lib

See Also

Reference

NDIS Functions for Intermediate Drivers
NdisOpenAdapter
MiniportInitialize
ProtocolBindAdapter
NdisIMInitializeDeviceInstanceEx
NdisOpenAdapterEx
ProtocolBindAdapterEx