Re: [PATCH 2/2] block: take i_rwsem for the direct I/O write fallback
Christoph Hellwig <[email protected]> Tue, 4 Aug 2026 16:04:45 +0200
| Newsgroups | org.kernel.vger.linux-block,org.kernel.vger.linux-kernel |
|---|---|
| Message-ID | <[email protected]> |
On Sun, Aug 02, 2026 at 08:11:41PM +0300, Tal Zussman wrote:
> > } else {
> > /*
> > * Take i_rwsem and invalidate_lock to avoid racing with
> >
>
> I seem to have stumbled into a Sashiko rabbit hole of issues with IOCB_NOWAIT
> and IOCB_ATOMIC here... [1].
> I'll wait a day or two and send an update along with some additional fixes
> I've spotted.
I think IOCB_ATOMIC vs fallback to buffered I/O is a generally
unsolved issue. I know ext4 just has a warning, but I'm not
sure how to avoid creating the problem in the first place.