[moderation] [fs?] [mm?] KCSAN: data-race in __xa_clear_mark / filemap_write_and_wait_range (2)

2 views
Skip to first unread message

syzbot

unread,
Jul 28, 2025, 1:26:40 AM7/28/25
to syzkaller-upst...@googlegroups.com
Hello,

syzbot found the following issue on:

HEAD commit: b711733e89a3 Merge tag 'timers-urgent-2025-07-27' of git:/..
git tree: upstream
console output: https://syzkaller.appspot.com/x/log.txt?x=15d06782580000
kernel config: https://syzkaller.appspot.com/x/.config?x=c0dd0a92e88efc24
dashboard link: https://syzkaller.appspot.com/bug?extid=c3077ef8b6850eb395b2
compiler: Debian clang version 20.1.7 (++20250616065708+6146a88f6049-1~exp1~20250616065826.132), Debian LLD 20.1.7
CC: [ak...@linux-foundation.org linux-...@vger.kernel.org linux-...@vger.kernel.org linu...@kvack.org wi...@infradead.org]

Unfortunately, I don't have any reproducer for this issue yet.

Downloadable assets:
disk image: https://storage.googleapis.com/syzbot-assets/f245f96ef445/disk-b711733e.raw.xz
vmlinux: https://storage.googleapis.com/syzbot-assets/79a659d1cf48/vmlinux-b711733e.xz
kernel image: https://storage.googleapis.com/syzbot-assets/cd0f24590073/bzImage-b711733e.xz

IMPORTANT: if you fix the issue, please add the following tag to the commit:
Reported-by: syzbot+c3077e...@syzkaller.appspotmail.com

==================================================================
BUG: KCSAN: data-race in __xa_clear_mark / filemap_write_and_wait_range

write to 0xffff888115b669a4 of 4 bytes by interrupt on cpu 0:
xa_mark_clear lib/xarray.c:77 [inline]
xas_clear_mark lib/xarray.c:932 [inline]
__xa_clear_mark+0x1c6/0x1e0 lib/xarray.c:2097
__folio_end_writeback+0x177/0x470 mm/page-writeback.c:3024
folio_end_writeback+0x71/0x3d0 mm/filemap.c:1660
ext4_finish_bio+0x459/0x8c0 fs/ext4/page-io.c:144
ext4_end_bio+0x22a/0x330 fs/ext4/page-io.c:-1
bio_endio+0x374/0x410 block/bio.c:1645
blk_update_request+0x336/0x730 block/blk-mq.c:987
blk_mq_end_request+0x26/0x50 block/blk-mq.c:1149
lo_complete_rq+0x98/0x140 drivers/block/loop.c:304
blk_complete_reqs block/blk-mq.c:1224 [inline]
blk_done_softirq+0x77/0xb0 block/blk-mq.c:1229
handle_softirqs+0xb7/0x290 kernel/softirq.c:579
run_ksoftirqd+0x1c/0x30 kernel/softirq.c:968
smpboot_thread_fn+0x32b/0x530 kernel/smpboot.c:164
kthread+0x486/0x510 kernel/kthread.c:464
ret_from_fork+0xda/0x150 arch/x86/kernel/process.c:148
ret_from_fork_asm+0x1a/0x30 arch/x86/entry/entry_64.S:245

read to 0xffff888115b669a4 of 4 bytes by task 10319 on cpu 1:
xa_marked include/linux/xarray.h:424 [inline]
mapping_tagged include/linux/fs.h:542 [inline]
filemap_fdatawrite_wbc mm/filemap.c:382 [inline]
__filemap_fdatawrite_range mm/filemap.c:419 [inline]
filemap_write_and_wait_range+0xfc/0x340 mm/filemap.c:691
filemap_invalidate_pages+0xa4/0x1a0 mm/filemap.c:2815
kiocb_invalidate_pages+0x6e/0x80 mm/filemap.c:2834
__iomap_dio_rw+0x5d4/0x1250 fs/iomap/direct-io.c:703
iomap_dio_rw+0x40/0x90 fs/iomap/direct-io.c:823
ext4_dio_write_iter fs/ext4/file.c:580 [inline]
ext4_file_write_iter+0xad9/0xf00 fs/ext4/file.c:721
iter_file_splice_write+0x5ef/0x970 fs/splice.c:738
do_splice_from fs/splice.c:935 [inline]
direct_splice_actor+0x153/0x2a0 fs/splice.c:1158
splice_direct_to_actor+0x30f/0x680 fs/splice.c:1102
do_splice_direct_actor fs/splice.c:1201 [inline]
do_splice_direct+0xda/0x150 fs/splice.c:1227
do_sendfile+0x380/0x650 fs/read_write.c:1370
__do_sys_sendfile64 fs/read_write.c:1431 [inline]
__se_sys_sendfile64 fs/read_write.c:1417 [inline]
__x64_sys_sendfile64+0x105/0x150 fs/read_write.c:1417
x64_sys_call+0xb39/0x2fb0 arch/x86/include/generated/asm/syscalls_64.h:41
do_syscall_x64 arch/x86/entry/syscall_64.c:63 [inline]
do_syscall_64+0xd2/0x200 arch/x86/entry/syscall_64.c:94
entry_SYSCALL_64_after_hwframe+0x77/0x7f

value changed: 0x0e000021 -> 0x04000021

Reported by Kernel Concurrency Sanitizer on:
CPU: 1 UID: 0 PID: 10319 Comm: syz.6.1925 Not tainted 6.16.0-rc7-syzkaller-00142-gb711733e89a3 #0 PREEMPT(voluntary)
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 05/07/2025
==================================================================


---
This report is generated by a bot. It may contain errors.
See https://goo.gl/tpsmEJ for more information about syzbot.
syzbot engineers can be reached at syzk...@googlegroups.com.

syzbot will keep track of this issue. See:
https://goo.gl/tpsmEJ#status for how to communicate with syzbot.

If the report is already addressed, let syzbot know by replying with:
#syz fix: exact-commit-title

If you want to overwrite report's subsystems, reply with:
#syz set subsystems: new-subsystem
(See the list of subsystem names on the web dashboard)

If the report is a duplicate of another one, reply with:
#syz dup: exact-subject-of-another-report

If you want to undo deduplication, reply with:
#syz undup

syzbot

unread,
Sep 22, 2025, 1:26:19 AM9/22/25
to syzkaller-upst...@googlegroups.com
Auto-closing this bug as obsolete.
Crashes did not happen for a while, no reproducer and no activity.
Reply all
Reply to author
Forward
0 new messages