From: Christoph Hellwig <hch@infradead.org>
To: Matthew Wilcox <willy@infradead.org>
Cc: Christoph Hellwig <hch@infradead.org>,
Joanne Koong <joannelkoong@gmail.com>,
brauner@kernel.org, djwong@kernel.org, bfoster@redhat.com,
linux-fsdevel@vger.kernel.org
Subject: Re: [PATCH v4 1/1] iomap: fix invalid folio access after folio_end_read()
Date: Mon, 26 Jan 2026 06:59:51 -0800 [thread overview]
Message-ID: <aXeBZx7A3sWuFmIm@infradead.org> (raw)
In-Reply-To: <aXeAY8K12KKf9d4_@casper.infradead.org>
On Mon, Jan 26, 2026 at 02:55:31PM +0000, Matthew Wilcox wrote:
> > Can you drop this cleanup for now? I think it's actually useful,
> > but it should be in a separate patch, and creates a conflict with
> > my iomap PI series.
> >
> > The actual fix looks great and simplified the code nicely!
>
> I don't think it's just a cleanup -- I think it's a bug fix. But, yes,
> it should be a separate patch because it's a separate bug. That bug
> can be hit if the folio passed to iomap_read_folio() covers more than
> one extent, the first call to iomap_iter() succeeds, and then the second
> one fails. Now we have a folio with a positive read_pending that will
> never become zero, so we'll never unlock the folio.
Oh, I missed it added a condition for the read_folio case. Another
reason to split the fix from the (otherwise nice) refactoring. And
fixing it directly in read_folio also helps with the conflict avoidance.
next prev parent reply other threads:[~2026-01-26 14:59 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-01-23 23:56 [PATCH v4 0/1] iomap: fix invalid folio access after folio_end_read() Joanne Koong
2026-01-23 23:56 ` [PATCH v4 1/1] " Joanne Koong
2026-01-26 5:46 ` Christoph Hellwig
2026-01-26 14:55 ` Matthew Wilcox
2026-01-26 14:59 ` Christoph Hellwig [this message]
2026-01-26 21:36 ` Joanne Koong
2026-01-26 21:42 ` Matthew Wilcox
2026-01-26 22:10 ` Joanne Koong
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=aXeBZx7A3sWuFmIm@infradead.org \
--to=hch@infradead.org \
--cc=bfoster@redhat.com \
--cc=brauner@kernel.org \
--cc=djwong@kernel.org \
--cc=joannelkoong@gmail.com \
--cc=linux-fsdevel@vger.kernel.org \
--cc=willy@infradead.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox