Hi,
I have a question regarding to the swapBuffer example in the post_read, there are scenario which it can be processed:
//
// They don’t have a MDL and this is not a system buffer
// or a fastio so this is probably some arbitrary user
// buffer. We can not do the processing at DPC level so
// try and get to a safe IRQL so we can do the processing.
//
for this scenario it has to call “FltDoCompletionProcessingWhenSafe”
I want to know what kind of read will go to this scenario, how can I generate this kind of read if I want to test?
Thanks
Mike
> I want to know what kind of read will go to this scenario, how can I
generate this kind of read if I want to test?
Without reading the code (just the comments you quote) I would start with a
non-cached usermode read. You’ll probably not hit it first time and so
you’d need to add explicit code in the pre-call to force the non fastio path
(by looking to see whether the io is fastio and saying
FLT_PREOP_FASTIO_DENIED or whatever it is called).
In real life the fastIO would be denied by a timing windows which would
involve the filesystem denying the fastio in it’s own right.
R
> I want to know what kind of read will go to this scenario, how can I
generate this kind of read if I want to test?
Without reading the code (just the comments you quote) I would start with a
non-cached usermode read. You’ll probably not hit it first time and so
you’d need to add explicit code in the pre-call to force the non fastio path
(by looking to see whether the io is fastio and saying
FLT_PREOP_FASTIO_DENIED or whatever it is called).
In real life the fastIO would be denied by a timing windows which would
involve the filesystem denying the fastio in it’s own right.
R