I/O Manager Routines


Windows Driver Kit: Kernel-Mode Driver Architecture
IoQueueWorkItem

The IoQueueWorkItem routine associates a WorkItem routine with a work item, and it inserts the work item into a queue for later processing by a system worker thread.

VOID
  IoQueueWorkItem(
    IN PIO_WORKITEM  IoWorkItem,
    IN PIO_WORKITEM_ROUTINE  WorkerRoutine,
    IN WORK_QUEUE_TYPE  QueueType,
    IN PVOID  Context
    );

Parameters

IoWorkItem
Pointer to an IO_WORKITEM structure that was allocated by IoAllocateWorkItem.either allocated by or initialized by IoInitializeWorkItem.
WorkerRoutine
Pointer to a WorkItem routine.
QueueType
Specifies a WORK_QUEUE_TYPE value that stipulates the type of system worker thread to handle the work item. Drivers must specify DelayedWorkQueue.
Context
Specifies driver-specific information for the work item. The system passes this value as the Context parameter to WorkItem.

Return Value

None

Comments

For more information about work items, see System Worker Threads.

Requirements

IRQL: <=DISPATCH_LEVEL

Headers: Declared in Wdm.h. Include Wdm.h, Ntddk.h, or Ntifs.h.

See Also

IO_WORKITEM, IoAllocateWorkItem, IoQueueWorkItemEx, WorkItem


Send feedback on this topic
Built on November 19, 2009
Page view tracker