Expand Minimize

WDF_REQUEST_REUSE_PARAMS_SET_NEW_IRP function

[Applies to KMDF and UMDF]

The WDF_REQUEST_REUSE_PARAMS_SET_NEW_IRP function sets a new IRP in a driver's WDF_REQUEST_REUSE_PARAMS structure.

Syntax


VOID WDF_REQUEST_REUSE_PARAMS_SET_NEW_IRP(
  _Inout_  PWDF_REQUEST_REUSE_PARAMS Params,
  _In_     PIRP NewIrp
);

Parameters

Params [in, out]

A pointer to a caller-supplied WDF_REQUEST_REUSE_PARAMS structure.

NewIrp [in]

A pointer to a caller-supplied IRP structure.

Return value

None

Remarks

If a driver's call to WdfRequestReuse specifies a new IRP structure, the driver must first call WDF_REQUEST_REUSE_PARAMS_INIT and then call WDF_REQUEST_REUSE_PARAMS_SET_NEW_IRP to initialize a WDF_REQUEST_REUSE_PARAMS structure.

The WDF_REQUEST_REUSE_PARAMS_SET_NEW_IRP function sets the structure's NewIrp member to the specified IRP pointer. It also sets the WDF_REQUEST_REUSE_SET_NEW_IRP flag in the structure's Flag member.

Examples

The following code example initializes a WDF_REQUEST_REUSE_PARAMS structure, provides a new IRP structure for the I/O request, and then calls WdfRequestReuse.


WDF_REQUEST_REUSE_PARAMS  params;
NTSTATUS  status;
PIRP  myIrp;
...
WDF_REQUEST_REUSE_PARAMS_INIT(
                              &params,
                              WDF_REQUEST_REUSE_NO_FLAGS,
                              STATUS_SUCCESS
                              );
WDF_REQUEST_REUSE_PARAMS_SET_NEW_IRP(
                                     &params,
                                     myIrp
                                     );
status = WdfRequestReuse(
                         Request,
                         &params
                         );
...

Requirements

Minimum KMDF version

1.0

Minimum UMDF version

2.0

Header

Wdfrequest.h (include Wdf.h)

See also

WdfRequestReuse
WDF_REQUEST_REUSE_PARAMS
WDF_REQUEST_REUSE_PARAMS_INIT

 

 

Send comments about this topic to Microsoft

Show:
© 2014 Microsoft