SpinLockSafe rule (wdm)
This rule also specifies that the driver calls KeAcquireSpinLock or KeAcquireSpinLockAtDpcLevel before calling KeReleaseSpinLockFromDpcLevel or KeReleaseSpinLock, and that it calls IoAcquireCancelSpinLock before calling IoReleaseCancelSpinLock.
Static Driver Verifier can report false violations of this rule if the driver includes nested SpinLocks, even if those spin locks are acquired and released correctly.
How to test
|At compile time|
Run Static Driver Verifier and specify the SpinLockSafe rule.Use the following steps to run an analysis of your code:
For more information, see Using Static Driver Verifier to Find Defects in Drivers.