Re: [PATCH] zonefs: fix synchronous direct writes to sequential files

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 8/9/23 18:08, Shinichiro Kawasaki wrote:
> On Aug 09, 2023 / 12:04, Damien Le Moal wrote:
>> Commit 16d7fd3cfa72 ("zonefs: use iomap for synchronous direct writes")
>> changes zonefs code from a self-built zone append BIO to using iomap for
>> synchronous direct writes. This change relies on iomap submit BIO
>> callback to change the write BIO built by iomap to a zone append BIO.
>> However, this change overlloked the fact that a write BIO may be very
> 
> I found some typos in the commit message. I guess you forgot to run spell
> checker. FYI, here I note the typos found.

Hmmm... I did run checkpatch... Weird. Anyway, thansk, I will send v2 with
corrections.

> 
> s/overlloked/overlooked/
> 
>> large as it is split when issued. The change from a regular write to a
>> zone append operation for the built BIO can result in a block layer
>> warning as zone append BIO are not allowed to be split.
>>
> [...]
>>
>> Manually splitting the zone append BIO using bio_split_rw() can solve
>> this issue but also requires issuing the fragment BIOs sunchronously
> 
> s/sunchronously/synchronously/
> 
>> with submit_bio_wait(), to avoid potential reordering of the zone append
>> BIO fragments, which would lead to data corruption. That is, this
>> solution is not better than using regular write BIOs which are subject
>> to serialization using zone write locking at the IO scheduler level.
>>
>> Given this, fix the issue by removing zone append support and uisng
> 
> s/uisng/using/
> 
>> regular write BIOs for synchronous direct writes. This allows preseving
> 
> s/preserving/preserving/
> 
>> the use of iomap and having iidentical synchronous and asynchronous
> 
> s/iidentical/identical/
> 
>> sequential file write path. Zone append support will be reintroduced
>> later through io_uring commands to ensure that the needed special
>> handling is done correctly.
>>
>> Reported-by: Shin'ichiro Kawasaki <shinichiro.kawasaki@xxxxxxx>
> 
> I confirmed that this patch avoids the issue that I reported [*]. Thanks!
> 
> Tested-by: Shin'ichiro Kawasaki <shinichiro.kawasaki@xxxxxxx>
> 
> [*] https://lore.kernel.org/linux-nvme/20230731114632.1429799-1-shinichiro.kawasaki@xxxxxxx/

-- 
Damien Le Moal
Western Digital Research




[Index of Archives]     [Linux Ext4 Filesystem]     [Union Filesystem]     [Filesystem Testing]     [Ceph Users]     [Ecryptfs]     [NTFS 3]     [AutoFS]     [Kernel Newbies]     [Share Photos]     [Security]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux Cachefs]     [Reiser Filesystem]     [Linux RAID]     [NTFS 3]     [Samba]     [Device Mapper]     [CEPH Development]

  Powered by Linux