direct io and IRP_MJ_WRITE

Hello,
I have dispatch function for both read and write
major functions. When I set my device flag to direct
io. Read works fine. (I copy a string into an address
returned by MmGetSystemAddressForMDLSafe).

However my IRP_MJ_WRITE does not work. The system
crashes reporting KMODE_EXCEPTION not handled.

my code actually does nothing. It just sets
information to 0 completes the irp with a
STATUS_SUCCESS.

Using Buffered Io causes no problems.

Rajeev


For live cricket scores download Yahoo! Score Tracker
at: http://in.sports.yahoo.com/cricket/tracker.html