syzbot


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

Status: moderation: reported on 2025/09/07 18:11
Subsystems: block
[Documentation on labels]
Reported-by: syzbot+7a4ccac88a3cc49e3b8b@syzkaller.appspotmail.com
First crash: 48d, last: 6d11h
Similar bugs (1)
Kernel Title Rank 🛈 Repro Cause bisect Fix bisect Count Last Reported Patched Status
upstream KCSAN: data-race in _copy_to_iter / memcpy_and_pad block 6 2 156d 157d 0/29 auto-obsoleted due to no activity on 2025/07/17 19:38

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

write to 0xffff88811e0ea488 of 10 bytes by task 19042 on cpu 1:
 memcpy_and_pad+0x48/0x80 lib/string_helpers.c:1007
 ext4_sample_last_mounted fs/ext4/file.c:879 [inline]
 ext4_file_open+0x53d/0x600 fs/ext4/file.c:901
 do_dentry_open+0x649/0xa20 fs/open.c:965
 vfs_open+0x37/0x1e0 fs/open.c:1097
 do_open fs/namei.c:3975 [inline]
 path_openat+0x1c5e/0x2170 fs/namei.c:4134
 do_filp_open+0x109/0x230 fs/namei.c:4161
 do_sys_openat2+0xa6/0x110 fs/open.c:1437
 do_sys_open fs/open.c:1452 [inline]
 __do_sys_creat fs/open.c:1530 [inline]
 __se_sys_creat fs/open.c:1524 [inline]
 __x64_sys_creat+0x65/0x90 fs/open.c:1524
 x64_sys_call+0x2da3/0x3000 arch/x86/include/generated/asm/syscalls_64.h:86
 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 0xffff88811e0ea400 of 1024 bytes by task 5487 on cpu 0:
 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: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:2799
 blkdev_read_iter+0x22d/0x2e0 block/fops.c:859
 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+0x27c0/0x3000 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: 0 UID: 0 PID: 5487 Comm: udevd Not tainted syzkaller #0 PREEMPT(voluntary) 
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 10/02/2025
==================================================================

Crashes (4):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2025/10/19 18:54 upstream d9043c79ba68 1c8c8cd8 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in _copy_to_iter / memcpy_and_pad
2025/09/22 13:46 upstream 07e27ad16399 0ac7291c .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in _copy_to_iter / memcpy_and_pad
2025/09/08 07:16 upstream 76eeb9b8de98 d291dd2d .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in _copy_to_iter / memcpy_and_pad
2025/09/07 18:10 upstream 6ab41fca2e80 d291dd2d .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in _copy_to_iter / memcpy_and_pad
* Struck through repros no longer work on HEAD.