On 12/11/19 7:21 PM, Matthew Wilcox wrote: > On Wed, Dec 11, 2019 at 07:03:40PM -0700, Jens Axboe wrote: >> Tested and cleaned a bit, and added truncate protection through >> inode_dio_begin()/inode_dio_end(). >> >> https://git.kernel.dk/cgit/linux-block/commit/?h=buffered-uncached&id=6dac80bc340dabdcbfb4230b9331e52510acca87 >> >> This is much faster than the previous page cache dance, and I _think_ >> we're ok as long as we block truncate and hole punching. > > What about races between UNCACHED and regular buffered IO? Seems like > we might end up sending overlapping writes to the device? The UNCACHED out-of-page-cache IO is just for reads, it's not writes. The write part is still using the same approach as earlier, though now I bet it looks kinda slow compared to the read side... -- Jens Axboe