On Mon, Mar 12, 2018 at 11:21:55PM +0800, Eryu Guan wrote: > i_disksize update should be protected by i_data_sem, by either taking > the lock explicitly or by using ext4_update_i_disksize() helper. But the > i_disksize updates in ext4_direct_IO_write() are not protected at all, > which may be racing with i_disksize updates in writeback path in > delalloc buffer write path. > > This is found by code inspection, and I didn't hit any i_disksize > corruption due to this bug. Thanks to Jan Kara for catching this bug and > suggesting the fix! > > Reported-by: Jan Kara <jack@xxxxxxx> > Suggested-by: Jan Kara <jack@xxxxxxx> > Signed-off-by: Eryu Guan <guaneryu@xxxxxxxxx> Applied, thanks. - Ted