syzbot


KCSAN: data-race in _copy_to_iter / fat_mirror_bhs (2)

Status: moderation: reported on 2025/08/06 04:56
Subsystems: exfat
[Documentation on labels]
Reported-by: syzbot+956e805354edd7fa192a@syzkaller.appspotmail.com
First crash: 6d15h, last: 6d15h
Similar bugs (1)
Kernel Title Rank 🛈 Repro Cause bisect Fix bisect Count Last Reported Patched Status
upstream KCSAN: data-race in _copy_to_iter / fat_mirror_bhs block 6 1 99d 99d 0/29 auto-obsoleted due to no activity on 2025/06/30 11:05

Sample crash report:
==================================================================
BUG: KCSAN: data-race in _copy_to_iter / fat_mirror_bhs

write to 0xffff88810399c800 of 2048 bytes by task 4818 on cpu 0:
 fat_mirror_bhs+0x1df/0x320 fs/fat/fatent.c:395
 fat_alloc_clusters+0x98b/0xa80 fs/fat/fatent.c:543
 fat_add_cluster fs/fat/inode.c:107 [inline]
 __fat_get_block fs/fat/inode.c:154 [inline]
 fat_get_block+0x258/0x5e0 fs/fat/inode.c:189
 __block_write_begin_int+0x3fd/0xf90 fs/buffer.c:2145
 block_write_begin fs/buffer.c:2256 [inline]
 cont_write_begin+0x5fc/0x970 fs/buffer.c:2594
 fat_write_begin+0x4f/0xe0 fs/fat/inode.c:229
 generic_perform_write+0x181/0x490 mm/filemap.c:4175
 __generic_file_write_iter+0x9e/0x120 mm/filemap.c:4292
 generic_file_write_iter+0x8d/0x2f0 mm/filemap.c:4318
 new_sync_write fs/read_write.c:593 [inline]
 vfs_write+0x49d/0x8e0 fs/read_write.c:686
 ksys_write+0xda/0x1a0 fs/read_write.c:738
 __do_sys_write fs/read_write.c:749 [inline]
 __se_sys_write fs/read_write.c:746 [inline]
 __x64_sys_write+0x40/0x50 fs/read_write.c:746
 x64_sys_call+0x27fe/0x2ff0 arch/x86/include/generated/asm/syscalls_64.h:2
 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

read to 0xffff88810399ce00 of 512 bytes by task 3497 on cpu 1:
 instrument_copy_to_user include/linux/instrumented.h:113 [inline]
 copy_to_user_iter lib/iov_iter.c:24 [inline]
 iterate_ubuf include/linux/iov_iter.h:30 [inline]
 iterate_and_advance2 include/linux/iov_iter.h:300 [inline]
 iterate_and_advance include/linux/iov_iter.h:328 [inline]
 _copy_to_iter+0x12d/0xe30 lib/iov_iter.c:185
 copy_page_to_iter+0x18f/0x2d0 lib/iov_iter.c:362
 copy_folio_to_iter include/linux/uio.h:204 [inline]
 filemap_read+0x407/0xa00 mm/filemap.c:2763
 blkdev_read_iter+0x22d/0x2e0 block/fops.c:849
 new_sync_read fs/read_write.c:491 [inline]
 vfs_read+0x5ca/0x6f0 fs/read_write.c:572
 ksys_read+0xda/0x1a0 fs/read_write.c:715
 __do_sys_read fs/read_write.c:724 [inline]
 __se_sys_read fs/read_write.c:722 [inline]
 __x64_sys_read+0x40/0x50 fs/read_write.c:722
 x64_sys_call+0x27bc/0x2ff0 arch/x86/include/generated/asm/syscalls_64.h:1
 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

Reported by Kernel Concurrency Sanitizer on:
CPU: 1 UID: 0 PID: 3497 Comm: udevd Not tainted 6.16.0-syzkaller-11743-g6bcdbd62bd56 #0 PREEMPT(voluntary) 
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 07/12/2025
==================================================================

Crashes (1):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2025/08/06 04:56 upstream 6bcdbd62bd56 ffe1dd46 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in _copy_to_iter / fat_mirror_bhs
* Struck through repros no longer work on HEAD.