Re: Changing Irp->IoStatus.Status in a completion routine
- From: "Peter Wieland [MSFT]" <peterwie@xxxxxxxxxxxxxxxxxxxx>
- Date: Thu, 14 Feb 2008 15:59:55 -0800
As long as the dispatch routine returns the same status OR STATUS_PENDING.
So if you think you may change the IRP status in your completion routine you should return STATUS_PENDING in your dispatch routine (and mark the IRP pending, etc...)
The verifier will get pissy if the dispatch routine and the IO status block contain different values on completion (except for the pending case)
-p
--
This posting is provided "AS IS" with no warranties, and confers no rights.
"Doron Holan [MSFT]" <doronh@xxxxxxxxxxxxxxxxxxxx> wrote in message news:e7Qnio1bIHA.1376@xxxxxxxxxxxxxxxxxxxxxxx
yes, it is valid to change the status..
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.
"Jeff" <jeff@xxxxxxxxxxxxxxxxx> wrote in message news:OW5TphvbIHA.5984@xxxxxxxxxxxxxxxxxxxxxxxHi again,
I have one more question. Is it ok to change Irp->IoStatus.Status from STATUS_SUCCESS to an error code in a completion routine? I've found lots of information about completion routines, marking Irps pending and returning STATUS_CONTINUE_COMPLETION or STATUS_MORE_PROCESSING_REQUIRED but so far nothing that tells me if I can legally change the Irp->IoStatus.Status value.
If we can do this, do we need to do anything else like complete the request again, or changing the status value ok.
TIA,
Jeff.
- Follow-Ups:
- References:
- Changing Irp->IoStatus.Status in a completion routine
- From: Jeff
- Re: Changing Irp->IoStatus.Status in a completion routine
- From: Doron Holan [MSFT]
- Changing Irp->IoStatus.Status in a completion routine
- Prev by Date: Hardware Cursor
- Next by Date: Up2Date Driver Development Book...
- Previous by thread: Re: Changing Irp->IoStatus.Status in a completion routine
- Next by thread: Re: Changing Irp->IoStatus.Status in a completion routine
- Index(es):
Relevant Pages
|