maybe this is a common question, but what is the best
practice of notifying a User Mode Application that
holds a Handle to the Driver by CreateFile? By notifying
i mean if a certain event occurs inside the driver i want
to pass a piece of memory to my user mode application
that holds a CreateFile Handle and was communicating
only the direction of DeviceIOControl and "synchronously"?
There is no "request" for anything from the UserMode
application. The Driver should inform the User Mode
Application. What is best practice for that. It is a
Software-Only Driver e.g. it has no physical device
attached. Should i work with some kind of shared
memory and events wait-handles? Any recommendation,...?
Regards
Kerem
--
--
-----------------------
Beste Grüsse / Best regards / Votre bien devoue
Kerem Gümrükcü
Microsoft Live Space: http://kerem-g.spaces.live.com/
Latest Open-Source Projects: http://entwicklung.junetz.de
-----------------------
"This reply is provided as is, without warranty express or implied."
"Kerem Gümrükcü" <kare...@hotmail.com> wrote in message
news:uehwNdKD...@TK2MSFTNGP06.phx.gbl...
IoReportTargetDeviceChange/TARGET_DEVICE_CUSTOM_NOTIFICATION
"Kerem Gümrükcü" <kare...@hotmail.com> wrote in message
news:uehwNdKD...@TK2MSFTNGP06.phx.gbl...
d
--
Please do not send e-mail directly to this alias. this alias is for
newsgroup purposes only.
This posting is provided "AS IS" with no warranties, and confers no rights.
"Kerem Gümrükcü" <kare...@hotmail.com> wrote in message
news:uehwNdKD...@TK2MSFTNGP06.phx.gbl...
And if the app dies, the ioctl will be canceled automatically
and your (?) driver will receive cancel request on the
ioctl, and then cleanup.
Nevertheless... that a usermode app can hold a driver and prevent
deletion of surprise-removed device, etc. is annoying.
Fortunately, there are many 3rd party "close handle"
hacks to work around this.
( can MS include this ability in "Windows 7", please? )
--PA
The usermode app should use RegisterDeviceNotification, to release the
handle of removed device. And in any case, a properly written driver doesn't
suffer from hanging handles. The secret is to delete symboolic links and
device interfaces on surprise removal.
d
--
Please do not send e-mail directly to this alias. this alias is for
newsgroup purposes only.
This posting is provided "AS IS" with no warranties, and confers no rights.
"Pavel A." <pav...@NOfastmailNO.fm> wrote in message
news:uMVEOoUD...@TK2MSFTNGP02.phx.gbl...
This "should" often is not realistic.
The app may be written in a scripting language that simply
has no support for receiving Windows notification.
Or you know... it can be a quick and dirty app written just to test something.
There should be some officially supported way to close pending handles,
because users actually need it, the "find and kill" utilites exist and seem
to work.
(Conceptually this is like how the windows manager (?) hides not responding
app window and substitutes it to something surrogate. So the app continues to
hang or do whatever it does, but it's window can be moved away.)
Maybe this is even already implemented...
how chkdsk can forcibly unmout a disk with open files on it?
Regards,
--PA