* Re: [PATCH] lib/iov_iter: fix to increase non slab folio refcount
[not found] ` <Z-v2ReHKyFIXQlKs@casper.infradead.org>
@ 2025-04-04 8:40 ` Christoph Hellwig
0 siblings, 0 replies; only message in thread
From: Christoph Hellwig @ 2025-04-04 8:40 UTC (permalink / raw)
To: Matthew Wilcox
Cc: Sheng Yong, akpm, vbabka, linux-kernel, linux-mm, Sheng Yong,
linux-nfs, ceph-devel
On Tue, Apr 01, 2025 at 03:20:53PM +0100, Matthew Wilcox wrote:
> On Tue, Apr 01, 2025 at 10:02:55PM +0800, Sheng Yong wrote:
> > When testing EROFS file-backed mount over v9fs on qemu, I encounter
> > a folio UAF and page sanity check reports the following call trace.
> > Fix it by increasing non slab folio refcount correctly.
>
> This report needs to say what the problem _is_, which is that pages may
> be coalesced across a folio boundary.
9p/virtio also really needs to move away from iov_iter_get_pages_alloc
and to iov_iter_extract_pages. That way it properly pins pages for user
memory and doesn't do the pointless page reference for kernel iters that
triggered this. Of course until all callers are gone this fix is
needed, but the caller also needs fixing to use the proper interface.
(Same for ceph and nfs)
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2025-04-04 8:40 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
[not found] <20250401140255.1249264-1-shengyong1@xiaomi.com>
[not found] ` <Z-v2ReHKyFIXQlKs@casper.infradead.org>
2025-04-04 8:40 ` [PATCH] lib/iov_iter: fix to increase non slab folio refcount Christoph Hellwig
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox