On Wed, Sep 15, 2021 at 9:29 AM Jens Axboe <axboe@xxxxxxxxx> wrote: > > I've run this through vectored read/write with io_uring on the commonly > problematic cases (dm and low depth SCSI device) which trigger these > conditions often, and it seems to pass muster. I've also hacked in > faked randomly short reads and that helped find on issue with double > accounting. But it did validate the state handling otherwise. Ok, so I can't see anything obviously wrong with this, or anything I can object to. It's still fairly complicated, and I don't love how hard it is to follow some of it, but I do believe it's better. IOW, I don't have any objections. Al was saying he was looking at the io_uring code, so maybe he'll find something. Do you have these test-cases as some kind of test-suite so that this all stays correct? Linus