Re: DeviceIoControl with OVERLAPPED and KMDF
- From: "Ben Voigt [C++ MVP]" <rbv@xxxxxxxxxxxxx>
- Date: Tue, 11 Mar 2008 14:37:46 -0500
Johan Paul wrote:
Ah! Thanks Maxim! This would explain the behavior they are seeing in
user mode - and not reading the documentation carefully enough ;)
*AND* not checking GetLastError.
Now that we have teleconferencing technology, we should use it for some
worthwhile purpose.... like sending lousy programmers to training seminars
in Siberia without punishing the presenters.
Br,
Johan
It returns FALSE and LastError is ERROR_IO_PENDING, this is OK, now
wait for the completion.
--
Maxim Shatskih, Windows DDK MVP
StorageCraft Corporation
ma...@xxxxxxxxxxxxxxxxxxxx://www.storagecraft.com
"Johan Paul" <johan.p...@xxxxxxxxx> wrote in message
news:c67d440c-64a9-48bc-99f0-ec19b5fc723d@xxxxxxxxxxxxxxxxxxxxxxxxxxxxx
Hi Don, Thanks for you reply!
I am still unable to test this myself, but I got a note that if
DeviceIoControl() is called with OVERLAPPED, it will return FALSE. If
OVERLAPPED is NULL, DeviceIoControl() will succeed.
This surprised me. Like you replied, I thought KMDF (or my driver, no
matter if it is KMDF or WDM) should not care about that, since the IO
manager should deal with the dispatch, and send requests to the
driver, right?
BR,
Johan
It should not matter whether it is KMDF or WDM. For a driver
consider all calls to be OVERLAPPED.
--
Don Burn (MVP, Windows DDK)
Windows 2k/XP/2k3 Filesystem and Driver Consulting
Website:http://www.windrvr.com
Blog:http://msmvps.com/blogs/WinDrvr
Remove StopSpam to reply
"Johan Paul" <johan.p...@xxxxxxxxx> wrote in message
news:47366837-2aea-43ad-8097-53a9dddf4627@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
Hi all,
In a driver written with KMDF 1.5, should I need to care if a user
mode application sends a IOCTL with OVERLAPPED structure set or
not in DeviceIoControl() (opened with CreateFile with flag
FILE_FLAG_OVERLAPPED set)? Now I hear that DeviceIoControl() fails
if OVERLAPPED is specified but I am not sure if that should
matter...
BR,
Johan Paul
.
- References:
- DeviceIoControl with OVERLAPPED and KMDF
- From: Johan Paul
- Re: DeviceIoControl with OVERLAPPED and KMDF
- From: Don Burn
- Re: DeviceIoControl with OVERLAPPED and KMDF
- From: Johan Paul
- Re: DeviceIoControl with OVERLAPPED and KMDF
- From: Maxim S. Shatskih
- Re: DeviceIoControl with OVERLAPPED and KMDF
- From: Johan Paul
- DeviceIoControl with OVERLAPPED and KMDF
- Prev by Date: Re: WinUsb Control_Transfer Question
- Next by Date: Re: Is it possible to use SendMessage() from a driver code?
- Previous by thread: Re: DeviceIoControl with OVERLAPPED and KMDF
- Next by thread: Re: DeviceIoControl with OVERLAPPED and KMDF
- Index(es):
Relevant Pages
|
Loading