NdisInitializeWorkItem (Windows CE 5.0)
This function initializes a work-queue item with a caller-supplied context and callback routine to be queued for execution when a system worker thread is given control.
VOID NdisInitializeWorkItem(PNDIS_WORK_ITEMWorkItem,NDIS_PROCRoutine,PVOIDContext);
Parameters
WorkItem
[in] Points to the caller-supplied storage to be initialized.Routine
[in] Specifies the entry point of a caller-supplied function that processes this work item when it is dequeued. This callback is declared as follows.VOID (*NDIS_PROC)( IN struct _NDIS_WORK_ITEM * pWorkItem, IN PVOID Context );
Context
[in] Points to a caller-supplied context area that is passed, not interpreted, to the callback as its only parameter. This area should be in resident memory and accessible in any arbitrary thread context in which the callback might be run subsequently. In particular, Context cannot point to the stack.
Return Values
None.
Remarks
NdisInitializeWorkItem initializes Item with pointers to Routine and Context and a NULL list pointer.
In general, only higher-level drivers queue worker thread items.
A NIC miniport that is not deserialized should never call an NdisXXXWorkItem function.
The given Routine is responsible for calling NdisFreeMemory to release the storage for Item.
Requirements
OS Versions: Windows CE .NET 4.0 and later.
Header: Ndis.h.
Link Library: Ndis.lib
See Also
NdisFreeMemory | NdisScheduleWorkItem
Send Feedback on this topic to the authors