NdisInitializeListHead (Windows Embedded CE 6.0)
1/6/2010
This function initializes a doubly linked, driver-maintained interlocked queue or doubly linked list.
Syntax
VOID NdisInitializeListHead(
PLIST_ENTRY ListHead
);
Parameters
- ListHead
[in] Pointer to driver-allocated storage for the head of the interlocked queue or list.
Return Value
None.
Remarks
This function can be called from a MiniportInitialize function or from a protocol driver's Initialization of NDIS Protocol Drivers functions if the driver queues requests internally. However, miniport drivers seldom set up internal queues because the NDIS library serializes requests and packets sent to miniports.
Any NDIS driver that maintains an internal queue is responsible for synchronizing driver functions' accesses to queued entries. The NdisInterlockedXXXList functions ensure that only one driver function can access queued entries at any moment, even if the driver is running on a multiprocessor machine, because the queue is protected by a caller-supplied spin lock.
For an interlocked queue, the driver must also provide storage for a spin lock. It must initialize the spin lock with NdisAllocateSpinLock before passing a pointer to that spin lock to any of the NdisInterlockedXXXList functions.
Requirements
Header | ndis.h |
Library | ndis.lib |
Windows Embedded CE | Windows CE .NET 4.0 and later |
See Also
Reference
NDIS Library Functions
MiniportInitialize
NdisAllocateSpinLock
NdisInterlockedInsertHeadList
NdisInterlockedInsertTailList
NdisInterlockedRemoveHeadList