In a driver i forgot calling IoCompleteRequest for read/write from user
mode. still everyting worked fine. how did this happen. who completed
the irp.


...Mani

Re: IoCompleteRequest query by Doron

Doron
Mon Apr 25 02:41:28 CDT 2005

did you forget to call IoCompleteRequest from your completion routine? If
you return any value != STATUS_MORE_PROCESSING_REQUIRED (SMPR) from your
completion routine, the IRP is completed for you. If you return SMPR you
must call IoCompleteRequest.

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.


"Bajamani" <bajamani@hotmail.com> wrote in message
news:1114409461.234740.238370@g14g2000cwa.googlegroups.com...
> In a driver i forgot calling IoCompleteRequest for read/write from user
> mode. still everyting worked fine. how did this happen. who completed
> the irp.
>
>
> ...Mani
>



Re: IoCompleteRequest query by Bajamani

Bajamani
Mon Apr 25 03:57:52 CDT 2005

No. It was from dispatch routine.


Re: IoCompleteRequest query by Doron

Doron
Mon Apr 25 10:47:11 CDT 2005

did you call IoSkipCurrentIrpStackLocation & IoCallDriver? if not, then it
was luck and you should not rely on this working at any other time

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.


"Bajamani" <bajamani@hotmail.com> wrote in message
news:1114419472.498726.278770@z14g2000cwz.googlegroups.com...
> No. It was from dispatch routine.
>



Re: IoCompleteRequest query by Bajamani

Bajamani
Mon Apr 25 23:09:14 CDT 2005

Thank you Doron.

i didn't call IoSkipCurrentIrpStackLocation & IoCallDriver. this is a
simple driver. my usermode app sends a read request to the driver which
it must complete.

IoMarkPending doc says:
Unless an IRP's dispatch routine completes the IRP (by calling
IoCompleteRequest) or passes the IRP on to lower drivers, it must call
IoMarkIrpPending with the IRP. Otherwise, the I/O manager attempts to
complete the IRP as soon as the dispatch routine returns control.

i thought the last sentence from the above paragraph worked for me. is
it ?

...Mani


Re: IoCompleteRequest query by Doron

Doron
Tue Apr 26 02:31:01 CDT 2005

no, that is not true. if you are not sending the request to another devobj,
you must eventually call IoCompleteRequest

--
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.


"Bajamani" <bajamani@hotmail.com> wrote in message
news:1114488554.480839.298490@z14g2000cwz.googlegroups.com...
> Thank you Doron.
>
> i didn't call IoSkipCurrentIrpStackLocation & IoCallDriver. this is a
> simple driver. my usermode app sends a read request to the driver which
> it must complete.
>
> IoMarkPending doc says:
> Unless an IRP's dispatch routine completes the IRP (by calling
> IoCompleteRequest) or passes the IRP on to lower drivers, it must call
> IoMarkIrpPending with the IRP. Otherwise, the I/O manager attempts to
> complete the IRP as soon as the dispatch routine returns control.
>
> i thought the last sentence from the above paragraph worked for me. is
> it ?
>
> ...Mani
>



Re: IoCompleteRequest query by Bajamani

Bajamani
Tue Apr 26 03:33:29 CDT 2005

Thank you Doron. that's done.
So should we expect the DOCs to say so.

...Mani