Re: Can I call KeAcquireSpinLockAtDpcLevel at DISPATCH_LEVEL?
- From: "Maxim S. Shatskih" <maxim@xxxxxxxxxxxxxxxx>
- Date: Mon, 11 Jun 2007 00:23:39 +0400
So, if I understand correctly, there is nothing wrong in acquiring a
SpinLock in a DPC (as long as I observe the rules of 25 microseconds,
not aquiring it twice, etc.). Right?
Yes.
One issue that keeps confusing me is: what happens if for some reason
a spinlock is not released in a timely manner (i.e. 250 microseconds
instead of 25 microseconds)? Will the system crash (due to missing
I think the time limit is imposed only by checked build and is much larger -
10ms or so.
Nevertheless, you should make your code paths holding a spinlock as short as
possible, this is a coding culture issue.
--
Maxim Shatskih, Windows DDK MVP
StorageCraft Corporation
maxim@xxxxxxxxxxxxxxxx
http://www.storagecraft.com
.
- References:
- Prev by Date: Re: Can I call KeAcquireSpinLockAtDpcLevel at DISPATCH_LEVEL?
- Next by Date: Re: Mirror Driver - how can I use Driver with User-Mode Application
- Previous by thread: Re: Can I call KeAcquireSpinLockAtDpcLevel at DISPATCH_LEVEL?
- Next by thread: Re: Can I call KeAcquireSpinLockAtDpcLevel at DISPATCH_LEVEL?
- Index(es):