TDI_ACTION

When a kernel-mode client makes a TDI_ACTION request, it asks the underlying TDI transport driver to make transport-specific extensions available to that client.

IRP

The transport calls IoGetCurrentIrpStackLocation with the given Irpto get a pointer to its own stack location in the IRP, shown in the following list as IrpSp. The pointer to the IRP is shown in the following list as Irp. IRP members relevant to this request include the following:

Irp->IoStatus.Status

Specifies the final status of the action request. The transport sets this member before it completes the IRP, possibly to one of the following:

STATUS_SUCCESS

STATUS_PENDING

STATUS_INVALID_CONNECTION

STATUS_INVALID_PARAMETER

STATUS_INVALID_HANDLE

STATUS_BUFFER_TOO_SMALL

STATUS_INSUFFICIENT_RESOURCES

STATUS_NOT_SUPPORTED

STATUS_NOT_IMPLEMENTED

Irp->IoStatus.Information

Specifies how many bytes of data were transferred for this request. The transport sets this member of the I/O status block before it completes the IRP.

IrpSp->MajorFunction

Specifies IRP_MJ_INTERNAL_DEVICE_CONTROL. The transport can ignore this member if it exports a TdiDispatchInternalDeviceControl routine that handles only TDI_XXX requests.

IrpSp->MinorFunction

Specifies TDI_ACTION.

IrpSp->FileObject

Pointer to an open file object representing an address, connection endpoint, or control channel. The transport uses the FsContext and, possibly, FsContext2 fields to access the state it maintains about this address, connection, or control channel.

Irp->MdlAddress

Pointer to an MDL, possibly the initial MDL in a chain, mapping a buffer containing the client-supplied action parameter block. The initial part of this buffer always contains a system-defined TDI_ACTION_HEADER structure, followed by whatever transport-defined contents are required to carry out the action request.

Comments

The successful completion of any client's action request makes the transport-provided extension applicable to that client but not to any other TDI clients or drivers. The set of possible actions is defined by the transport at the discretion of the TDI transport driver writer.

Such a client makes an action request for transport-defined extensions related to an address, a connection, or a control channel. The client supplies a buffer containing all information concerning the requested action in the parameter block mapped at MdlAddress.

Every action parameter block begins with a TDI_ACTION_HEADER containing a transport identifier and an action code. On receipt of such a request, the transport uses the value of TransportIdin this header to validate the request. The ActionCodemember specifies the transport-defined operation to carry out and determines the transport-required contents for the remainder of the parameter block.

TdiBuildActionis the macro a client uses to fill in this IRP.

Note   The TDI feature is deprecated and will be removed in future versions of Microsoft Windows. Depending on how you use TDI, use either the Winsock Kernel (WSK) or Windows Filtering Platform (WFP). For more information about WFP and WSK, see Windows Filtering Platform and Winsock Kernel. For a Windows Core Networking blog entry about WSK and TDI, see Introduction to Winsock Kernel (WSK).

 

See Also

TDI_ACTION_HEADER, TdiBuildAction, TdiDispatchInternalDeviceControl

Requirements

Header

TdiKrnl.h (include TdiKrnl.h)

 

 

Send comments about this topic to Microsoft