Good, looking forward to hearing how this turned out for you.
Regarding your doubts, I’m hoping someone with more experience could
clear up a few other things. I have a couple of questions myself
regarding this…
Writing to a file from user land should be more expensive than writing
to one from our own IRP. Is this true? I mean, if implemented
correctly, the kernel mode way to write logs to a file should be a
beter approach than sending the logs to user land, and then again
writing them to the disk.
I was thinking a kernel thread has a higher priority than a usermode
thread, therefor, if a lot of little writes are happening - this would
block usermode threads, giving the appearance that the system is hanging
or slowing(single processor). Whereas, if a usermode thread is doing a
lot of little writes, this might be slower, but it wouldn’t give the
same appearance because the ‘slow’ thread is more so isolated and
wouldn’t affect the rest of the win32 sub system or kernel code. Thus
creating an illusion.
I’m also wondering if you declared your log buffer as paged or non-paged
and if that could affect your driver’s performance. If the log was paged
mem and flushed to disk, then accessed again that would cause a fault,
then when saving the data to a log file, that would result in a third
disk access. LOL, I think I need to re-read those chapters on the CM…
M