WdfDeviceWdmDispatchIrp - NtDoc

Native API online documentation, based on the System Informer (formerly Process Hacker) phnt headers
// wdfdevice.h

NTSTATUS WdfDeviceWdmDispatchIrp(
  [in] WDFDEVICE  Device,
  [in] PIRP       Irp,
  [in] WDFCONTEXT DispatchContext
);
View the official Windows Driver Kit DDI reference

NtDoc

No description available.

Windows Driver Kit DDI reference (nf-wdfdevice-wdfdevicewdmdispatchirp)

WdfDeviceWdmDispatchIrp function

Description

[Applies to KMDF and UMDF]

The WdfDeviceWdmDispatchIrp method returns a dispatched IRP to the framework from EvtDeviceWdmIrpDispatch.

Parameters

Device [in]

A handle to a framework device object.

Irp [in]

A pointer to an IRP structure.

DispatchContext [in]

The dispatch context parameter the driver received in EvtDeviceWdmIrpDispatch callback.

Return value

The WdfDeviceWdmDispatchIrp method returns an NTSTATUS value that the framework or the driver provides as a result of processing the IRP. The driver must use this return value as the return value for the EvtDeviceWdmIrpDispatch callback function that called WdfDeviceWdmDispatchIrp.

A bug check occurs if a KMDF driver supplies an invalid object handle. If a UMDF driver supplies an invalid handle, the driver host process terminates.

Remarks

If your driver provides an EvtDeviceWdmIrpDispatch callback function, you can call WdfDeviceWdmDispatchIrp from within the callback function to return the IRP to the framework for default processing instead of dispatching it to a specific queue.

For more information about specifying queues for IRPs as they arrive, see Dispatching IRPs to I/O Queues.

See also

EvtDeviceWdmIrpDispatch

WdfDeviceWdmDispatchIrpToIoQueue