driver - Windows Kernel-Level global Critical Section -


i'm writing user-space buffer kernel-level driver (from iocontrol functionality) , need make sure user-land program/service won't overwrite buffer or read before driver has finished writing it.

is there way (and if so, preferred way) enter kind of 'global critical section' within kernel-mode driver on windows allowing driver obtain exclusivity processing system-wide short time driver can have guaranteed exclusive access buffer in user-space?

taking account reply in comments, 1 way achieve maintain kernel-mode threads affinitized each system processor , raise irql dpc @ time when write buffer. thread scheduling not allowed @ dpc irql user-mode application won't able take control.

note: answer question, agree comments saying not supposed that. should redesign driver works under assumption user-mode buffer can change @ moment.


Comments

Popular posts from this blog

django - How can I change user group without delete record -

java - Need to add SOAP security token -

java - EclipseLink JPA Object is not a known entity type -