NdisFSetAttributes function (ndis.h)

A filter driver calls the NdisFSetAttributes function to specify a filter module context area.

Syntax

NDIS_STATUS NdisFSetAttributes(
  [in] NDIS_HANDLE                  NdisFilterHandle,
  [in] __drv_aliasesMem NDIS_HANDLE FilterModuleContext,
  [in] PNDIS_FILTER_ATTRIBUTES      FilterAttributes
);

Parameters

[in] NdisFilterHandle

The NDIS handle that identifies this filter module. NDIS passed the handle to the filter driver in a call to the FilterAttach function.

[in] FilterModuleContext

The caller-allocated context area for this filter module.

[in] FilterAttributes

A pointer to a filter driver allocated NDIS_FILTER_ATTRIBUTES structure.

Return value

NdisFSetAttributes returns one of the following status values:

Return code Description
NDIS_STATUS_SUCCESS
NdisFSetAttributes returns NDIS_STATUS_SUCCESS if it set the filter driver attributes.
NDIS_STATUS_RESOURCES
NdisFSetAttributes failed because of insufficient resources.
NDIS_STATUS_FAILURE
NdisFSetAttributes returns NDIS_STATUS_FAILURE if none of the preceding values applies.

Remarks

A filter driver calls NdisFSetAttributes from its FilterAttach function and passes the handle that NDIS passed to FilterAttach at the NdisFilterHandle parameter. The FilterModuleContext parameter of NdisFSetAttributes specifies the context area for this filter module. NDIS passes the context area back to the filter driver in calls to functions such as FilterSendNetBufferLists.

Requirements

Requirement Value
Minimum supported client Supported in NDIS 6.0 and later.
Target Platform Desktop
Header ndis.h (include Ndis.h)
Library Ndis.lib
IRQL PASSIVE_LEVEL
DDI compliance rules Irql_Filter_Driver_Function(ndis)

See also

FilterAttach

FilterSendNetBufferLists

NDIS_FILTER_ATTRIBUTES