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

0 views
Skip to first unread message

syzbot

unread,
Jul 30, 2025, 7:00:40 AMJul 30
to syzkaller-upst...@googlegroups.com
Hello,

syzbot found the following issue on:

HEAD commit: 4b290aae788e Merge tag 'sysctl-6.17-rc1' of git://git.kern..
git tree: upstream
console output: https://syzkaller.appspot.com/x/log.txt?x=13b2cca2580000
kernel config: https://syzkaller.appspot.com/x/.config?x=fb0f7e9c3b90e79f
dashboard link: https://syzkaller.appspot.com/bug?extid=9f17d8e392d0bdd62114
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/4dd30bbcf8b1/disk-4b290aae.raw.xz
vmlinux: https://storage.googleapis.com/syzbot-assets/e743bc007946/vmlinux-4b290aae.xz
kernel image: https://storage.googleapis.com/syzbot-assets/36356550c456/bzImage-4b290aae.xz

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

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

write to 0xffff88810cf54f94 of 4 bytes by interrupt on cpu 1:
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+0x377/0x410 block/bio.c:1651
blk_update_request+0x336/0x730 block/blk-mq.c:989
blk_mq_end_request+0x26/0x50 block/blk-mq.c:1151
lo_complete_rq+0x98/0x140 drivers/block/loop.c:304
blk_complete_reqs block/blk-mq.c:1226 [inline]
blk_done_softirq+0x77/0xb0 block/blk-mq.c:1231
handle_softirqs+0xb7/0x290 kernel/softirq.c:579
run_ksoftirqd+0x1c/0x30 kernel/softirq.c:968
smpboot_thread_fn+0x328/0x530 kernel/smpboot.c:160
kthread+0x489/0x510 kernel/kthread.c:464
ret_from_fork+0xdd/0x150 arch/x86/kernel/process.c:148
ret_from_fork_asm+0x1a/0x30 arch/x86/entry/entry_64.S:245

read to 0xffff88810cf54f94 of 4 bytes by task 4791 on cpu 0:
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]
file_write_and_wait_range+0x10e/0x2c0 mm/filemap.c:794
generic_buffers_fsync_noflush+0x45/0x120 fs/buffer.c:609
ext4_fsync_nojournal fs/ext4/fsync.c:88 [inline]
ext4_sync_file+0x1ab/0x690 fs/ext4/fsync.c:147
vfs_fsync_range+0x10a/0x130 fs/sync.c:187
generic_write_sync include/linux/fs.h:3040 [inline]
ext4_buffered_write_iter+0x34f/0x3c0 fs/ext4/file.c:305
ext4_file_write_iter+0x383/0xf00 fs/ext4/file.c:-1
iter_file_splice_write+0x5ef/0x970 fs/splice.c:738
do_splice_from fs/splice.c:935 [inline]
direct_splice_actor+0x156/0x2a0 fs/splice.c:1158
splice_direct_to_actor+0x312/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+0x2bb0/0x2ff0 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: 0x06000021 -> 0x0a000021

Reported by Kernel Concurrency Sanitizer on:
CPU: 0 UID: 0 PID: 4791 Comm: syz.0.222 Not tainted 6.16.0-syzkaller-04405-g4b290aae788e #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 24, 2025, 7:00:20 AM (3 days ago) Sep 24
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