syzbot


KCSAN: data-race in _copy_to_iter / fat12_ent_put (7)

Status: moderation: reported on 2025/09/01 20:08
Subsystems: exfat
[Documentation on labels]
Reported-by: syzbot+03122956fefeb0ca4c43@syzkaller.appspotmail.com
First crash: 105d, last: 9d20h
Similar bugs (6)
Kernel Title Rank 🛈 Repro Cause bisect Fix bisect Count Last Reported Patched Status
upstream KCSAN: data-race in _copy_to_iter / fat12_ent_put exfat 6 6 1193d 1223d 0/29 auto-obsoleted due to no activity on 2022/10/14 22:33
upstream KCSAN: data-race in _copy_to_iter / fat12_ent_put (4) exfat 6 5 932d 962d 0/29 auto-obsoleted due to no activity on 2023/07/02 02:14
upstream KCSAN: data-race in _copy_to_iter / fat12_ent_put (5) exfat 6 21 753d 737d 0/29 auto-obsoleted due to no activity on 2023/12/28 22:56
upstream KCSAN: data-race in _copy_to_iter / fat12_ent_put (6) exfat 6 1 655d 655d 0/29 auto-obsoleted due to no activity on 2024/04/04 01:15
upstream KCSAN: data-race in _copy_to_iter / fat12_ent_put (3) exfat 6 3 1006d 1022d 0/29 auto-obsoleted due to no activity on 2023/04/24 07:39
upstream KCSAN: data-race in _copy_to_iter / fat12_ent_put (2) exfat 6 3 1122d 1156d 0/29 auto-obsoleted due to no activity on 2022/12/31 00:12

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

write to 0xffff88811e70980c of 1 bytes by task 6819 on cpu 0:
 fat12_ent_put+0x74/0x170 fs/fat/fatent.c:168
 fat_alloc_clusters+0x4d1/0xa80 fs/fat/fatent.c:503
 fat_alloc_new_dir+0xbb/0x530 fs/fat/dir.c:1156
 vfat_mkdir+0x9b/0x1f0 fs/fat/namei_vfat.c:856
 vfs_mkdir+0x2db/0x3d0 fs/namei.c:5130
 do_mkdirat+0x133/0x3b0 fs/namei.c:5164
 __do_sys_mkdir fs/namei.c:5191 [inline]
 __se_sys_mkdir fs/namei.c:5189 [inline]
 __x64_sys_mkdir+0x42/0x50 fs/namei.c:5189
 x64_sys_call+0x2f32/0x3000 arch/x86/include/generated/asm/syscalls_64.h:84
 do_syscall_x64 arch/x86/entry/syscall_64.c:63 [inline]
 do_syscall_64+0xd8/0x2a0 arch/x86/entry/syscall_64.c:94
 entry_SYSCALL_64_after_hwframe+0x77/0x7f

read to 0xffff88811e709800 of 512 bytes by task 3660 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:302 [inline]
 iterate_and_advance include/linux/iov_iter.h:330 [inline]
 _copy_to_iter+0x130/0xe70 lib/iov_iter.c:197
 copy_page_to_iter+0x18f/0x2d0 lib/iov_iter.c:374
 copy_folio_to_iter include/linux/uio.h:204 [inline]
 filemap_read+0x407/0xa00 mm/filemap.c:2844
 blkdev_read_iter+0x22d/0x2e0 block/fops.c:860
 new_sync_read fs/read_write.c:491 [inline]
 vfs_read+0x64c/0x770 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+0x2889/0x3000 arch/x86/include/generated/asm/syscalls_64.h:1
 do_syscall_x64 arch/x86/entry/syscall_64.c:63 [inline]
 do_syscall_64+0xd8/0x2a0 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: 3660 Comm: udevd Tainted: G        W           syzkaller #0 PREEMPT(voluntary) 
Tainted: [W]=WARN
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 10/25/2025
==================================================================

Crashes (4):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2025/12/06 03:36 upstream d1d36025a617 d6526ea3 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in _copy_to_iter / fat12_ent_put
2025/11/07 22:34 upstream da32d155f4a8 4e1406b4 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in _copy_to_iter / fat12_ent_put
2025/10/09 05:10 upstream cd5a0afbdf80 7e2882b3 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in _copy_to_iter / fat12_ent_put
2025/09/01 20:07 upstream b320789d6883 807a3b61 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in _copy_to_iter / fat12_ent_put
* Struck through repros no longer work on HEAD.