On 13/05/2015 17:43, Stefan Hajnoczi wrote: > A 64 MB buffer was given in the pwrite() call. > > The first and the last 128-page write requests may have partial > pages, but why should the rest not use fully aligned 1024 sector > writes? > > Maybe the buffer is split by the max sectors per request before > the alignment requirements are considered. It would be more > efficient to first split off the unaligned parts.
Sounds like this could be it---then it's very similar to the issue fixed by kernel commit c6e666345e1b (block: split discard into aligned requests, 2012-08-02). Paolo