Re: [GIT PULL 14/14 for v6.17] vfs iomap

From: Sasha Levin
Date: Sun Jul 27 2025 - 09:10:23 EST


Hey Christian,

On Fri, Jul 25, 2025 at 01:27:20PM +0200, Christian Brauner wrote:
Hey Linus,

/* Summary */
This contains the iomap updates for this cycle:

- Refactor the iomap writeback code and split the generic and ioend/bio
based writeback code. There are two methods that define the split
between the generic writeback code, and the implemementation of it,
and all knowledge of ioends and bios now sits below that layer.

- This series adds fuse iomap support for buffered writes and dirty
folio writeback. This is needed so that granular uptodate and dirty
tracking can be used in fuse when large folios are enabled. This has
two big advantages. For writes, instead of the entire folio needing to
be read into the page cache, only the relevant portions need to be.
For writeback, only the dirty portions need to be written back instead
of the entire folio.

While testing with the linus-next tree, it appears that LKFT can trigger
the following warning, but only on arm64 tests (both on real HW as well
as qemu):

[ 333.129662] WARNING: CPU: 1 PID: 2580 at fs/fuse/file.c:2158 fuse_iomap_writeback_range+0x478/0x558 fuse
[ 333.132010] Modules linked in: btrfs blake2b_generic xor xor_neon raid6_pq zstd_compress sm3_ce sha3_ce sha512_ce fuse drm backlight ip_tables x_tables
[ 333.133982] CPU: 1 UID: 0 PID: 2580 Comm: msync04 Tainted: G W 6.16.0-rc7 #1 PREEMPT
[ 333.134997] Tainted: [W]=WARN
[ 333.135497] Hardware name: linux,dummy-virt (DT)
[ 333.136114] pstate: 03402009 (nzcv daif +PAN -UAO +TCO +DIT -SSBS BTYPE=--)
WARNING! No debugging info in module fuse, rebuild with DEBUG_KERNEL and DEBUG_INFO
[ 333.137090] pc : fuse_iomap_writeback_range+0x478/0x558 fuse
[ 333.138009] lr : iomap_writeback_folio (fs/iomap/buffered-io.c:1586 fs/iomap/buffered-io.c:1710)
[ 333.138510] sp : ffff80008be8f8c0
[ 333.138653] x29: ffff80008be8f8c0 x28: fff00000c5198c00 x27: 0000000000000000
[ 333.138975] x26: fff00000d32b8c00 x25: 0000000000000000 x24: 0000000000000000
[ 333.139309] x23: 0000000000000000 x22: fffffc1fc039ba40 x21: 0000000000001000
[ 333.139600] x20: ffff80008be8f9f0 x19: 0000000000000000 x18: 0000000000000000
[ 333.139917] x17: 0000000000000000 x16: ffffbb40f61c3a48 x15: 0000000000000000
[ 333.142199] x14: ffffbb40f6924788 x13: 0000ffff8e8effff x12: 0000000000000000
[ 333.142739] x11: 1ffe0000199a9241 x10: fff00000ccd4920c x9 : ffffbb40f50bba18
[ 333.143466] x8 : ffff80008be8f778 x7 : ffffbb40ee180b68 x6 : ffffbb40f76c9000
[ 333.143718] x5 : 0000000000000000 x4 : 000000000000000a x3 : 0000000000001000
[ 333.143957] x2 : fff00000c0b6e600 x1 : 000000000000ffff x0 : 0bfffe000000400b
[ 333.144993] Call trace:
WARNING! No debugging info in module fuse, rebuild with DEBUG_KERNEL and DEBUG_INFO
[ 333.145466] fuse_iomap_writeback_range+0x478/0x558 fuse (P)
[ 333.146136] iomap_writeback_folio (fs/iomap/buffered-io.c:1586 fs/iomap/buffered-io.c:1710)
[ 333.146444] iomap_writepages (fs/iomap/buffered-io.c:1762)
WARNING! No debugging info in module fuse, rebuild with DEBUG_KERNEL and DEBUG_INFO
[ 333.146590] fuse_writepages+0xa0/0xe8 fuse
[ 333.146774] do_writepages (mm/page-writeback.c:2636)
[ 333.146915] filemap_fdatawrite_wbc (mm/filemap.c:386 mm/filemap.c:376)
[ 333.147788] __filemap_fdatawrite_range (mm/filemap.c:420)
[ 333.148440] file_write_and_wait_range (mm/filemap.c:794)
WARNING! No debugging info in module fuse, rebuild with DEBUG_KERNEL and DEBUG_INFO
[ 333.149054] fuse_fsync+0x6c/0x138 fuse
[ 333.149578] vfs_fsync_range (fs/sync.c:188)
[ 333.149892] __arm64_sys_msync (mm/msync.c:96 mm/msync.c:32 mm/msync.c:32)
[ 333.150095] invoke_syscall.constprop.0 (arch/arm64/include/asm/syscall.h:61 arch/arm64/kernel/syscall.c:54)
[ 333.150330] do_el0_svc (include/linux/thread_info.h:135 (discriminator 2) arch/arm64/kernel/syscall.c:140 (discriminator 2) arch/arm64/kernel/syscall.c:151 (discriminator 2))
[ 333.150461] el0_svc (arch/arm64/include/asm/irqflags.h:82 (discriminator 1) arch/arm64/include/asm/irqflags.h:123 (discriminator 1) arch/arm64/include/asm/irqflags.h:136 (discriminator 1) arch/arm64/kernel/entry-common.c:165 (discriminator 1) arch/arm64/kernel/entry-common.c:178 (discriminator 1) arch/arm64/kernel/entry-common.c:768 (discriminator 1))
[ 333.150583] el0t_64_sync_handler (arch/arm64/kernel/entry-common.c:787)
[ 333.150729] el0t_64_sync (arch/arm64/kernel/entry.S:600)
[ 333.150862] ---[ end trace 0000000000000000 ]---

I think that this is because the arm64 tests run on
CONFIG_PAGE_SIZE_64KB=y build, but I'm not sure why we don't see it with
4KB pages at all.

An example link to a failing test that has the full log and more
information: https://qa-reports.linaro.org/lkft/sashal-linus-next/build/v6.13-rc7-44385-g8a03a07bad83/testrun/29269158/suite/log-parser-test/test/exception-warning-cpu-pid-at-fsfusefile-fuse_iomap_writeback_range/details/

--
Thanks,
Sasha