VOID
KeInitializeSpinLock(
IN PKSPIN_LOCK SpinLock
);
KeInitializeSpinLock initializes a variable of type KSPIN_LOCK.
This routine must be called before an initial call to KeAcquireSpinLock or to any other support routine that requires a spin lock as an argument.
Storage for a spin lock object must be resident: in the device extension of a driver-created device object, in the controller extension of a driver-created controller object, or in nonpaged pool allocated by the caller.
Callers of this routine can be running at any IRQL. Usually, a caller is running at IRQL PASSIVE_LEVEL in a DriverEntry routine.
KeAcquireSpinLock, KeAcquireSpinLockAtDpcLevel, KeReleaseSpinLock