IoQueueWorkItemEx function (wdm.h)
The IoQueueWorkItemEx routine associates a WorkItemEx routine with a work item, and it inserts the work item into a queue for later processing by a system worker thread.
Syntax
void IoQueueWorkItemEx(
[in] __drv_aliasesMem PIO_WORKITEM IoWorkItem,
[in] PIO_WORKITEM_ROUTINE_EX WorkerRoutine,
[in] WORK_QUEUE_TYPE QueueType,
[in, optional] __drv_aliasesMem PVOID Context
);
Parameters
[in] IoWorkItem
Pointer to an IO_WORKITEM structure that was allocated by IoAllocateWorkItem or initialized by IoInitializeWorkItem.
[in] WorkerRoutine
Pointer to a WorkItemEx routine.
[in] QueueType
Specifies a WORK_QUEUE_TYPE value that stipulates the type of system worker thread to handle the work item. Drivers must specify DelayedWorkQueue.
[in, optional] Context
Specifies driver-specific information for the work item. The system passes this value as the Context parameter to WorkItemEx.
Return value
None
Remarks
The IoQueueWorkItemEx routine differs from IoQueueWorkItem in that the WorkerRoutine parameter is a pointer to a WorkItemEx callback routine, which provides the driver with a pointer to the IO_WORKITEM structure for the work item.
For more information about work items, see System Worker Threads.
Requirements
Requirement | Value |
---|---|
Minimum supported client | Available in Windows Vista and later versions of Windows. |
Target Platform | Universal |
Header | wdm.h (include Wdm.h, Ntddk.h, Ntifs.h) |
Library | NtosKrnl.lib |
DLL | NtosKrnl.exe |
IRQL | <= DISPATCH_LEVEL |