In a virtual Stor miniport, in Windows 2008 RTM, we're occasionally getting an MDL for Write operation that describes a buffer shorter than Srb->DataTransferLength. For example, MmGetMdlByteCount will return 0xECE0, but DataTransferLength is 0xEE00, which is MDL length rounded up to whole sector.
This can happen during installation. I suspect it's caused by WriteFile with FILE_FLAG_WRITE_THROUGH, when a request gets written to the disk immediately, but the lengths is not necessarily multiple of sectors.
Is it calid case which the miniport should handle? I don't see anything in the WDK docs. Should I just zero-pad the transfer up to DataTransferLength?