syzbot


KCSAN: data-race in memchr / string (2)

Status: auto-closed as invalid on 2022/04/12 14:29
Subsystems: mm
[Documentation on labels]
First crash: 793d, last: 793d
Similar bugs (1)
Kernel Title Repro Cause bisect Fix bisect Count Last Reported Patched Status
upstream KCSAN: data-race in memchr / string v9fs 1 1040d 1040d 0/26 auto-closed as invalid on 2021/08/08 15:57

Sample crash report:
==================================================================
BUG: KCSAN: data-race in memchr / string

write to 0xffffffff86da64f4 of 1 bytes by task 24703 on cpu 0:
 string_nocheck lib/vsprintf.c:642 [inline]
 string+0xa1/0x210 lib/vsprintf.c:720
 format_flags lib/vsprintf.c:1972 [inline]
 flags_string+0x27d/0x800 lib/vsprintf.c:2081
 pointer+0x1a5/0x830 lib/vsprintf.c:2448
 vsnprintf+0x8a1/0xed0 lib/vsprintf.c:2799
 vscnprintf+0x29/0x80 lib/vsprintf.c:2898
 printk_sprint kernel/printk/printk.c:2076 [inline]
 vprintk_store+0x638/0xbb0 kernel/printk/printk.c:2186
 vprintk_emit+0xac/0x3c0 kernel/printk/printk.c:2229
 vprintk_default+0x22/0x30 kernel/printk/printk.c:2256
 vprintk+0x7f/0x90 kernel/printk/printk_safe.c:50
 _printk+0x76/0x97 kernel/printk/printk.c:2266
 dump_header+0x93/0x410 mm/oom_kill.c:457
 out_of_memory+0x65c/0x8c0 mm/oom_kill.c:1109
 mem_cgroup_out_of_memory mm/memcontrol.c:1617 [inline]
 memory_max_write+0x32c/0x3d0 mm/memcontrol.c:6313
 cgroup_file_write+0x161/0x300 kernel/cgroup/cgroup.c:3882
 kernfs_fop_write_iter+0x1d3/0x2d0 fs/kernfs/file.c:296
 call_write_iter include/linux/fs.h:2074 [inline]
 new_sync_write fs/read_write.c:503 [inline]
 vfs_write+0x7f5/0x950 fs/read_write.c:590
 ksys_write+0xd9/0x190 fs/read_write.c:643
 __do_sys_write fs/read_write.c:655 [inline]
 __se_sys_write fs/read_write.c:652 [inline]
 __x64_sys_write+0x3e/0x50 fs/read_write.c:652
 do_syscall_x64 arch/x86/entry/common.c:50 [inline]
 do_syscall_64+0x44/0xd0 arch/x86/entry/common.c:80
 entry_SYSCALL_64_after_hwframe+0x44/0xae

read to 0xffffffff86da64f4 of 1 bytes by task 24704 on cpu 1:
 memchr+0x34/0x50 lib/string.c:896
 count_lines kernel/printk/printk_ringbuffer.c:1675 [inline]
 copy_data kernel/printk/printk_ringbuffer.c:1721 [inline]
 prb_read kernel/printk/printk_ringbuffer.c:1814 [inline]
 _prb_read_valid+0x7bf/0x950 kernel/printk/printk_ringbuffer.c:1880
 prb_read_valid_info+0x69/0x90 kernel/printk/printk_ringbuffer.c:1963
 find_first_fitting_seq+0x8c/0x320 kernel/printk/printk.c:1450
 syslog_print_all kernel/printk/printk.c:1590 [inline]
 do_syslog+0x807/0x1050 kernel/printk/printk.c:1669
 __do_sys_syslog kernel/printk/printk.c:1747 [inline]
 __se_sys_syslog kernel/printk/printk.c:1745 [inline]
 __x64_sys_syslog+0x3f/0x50 kernel/printk/printk.c:1745
 do_syscall_x64 arch/x86/entry/common.c:50 [inline]
 do_syscall_64+0x44/0xd0 arch/x86/entry/common.c:80
 entry_SYSCALL_64_after_hwframe+0x44/0xae

value changed: 0x73 -> 0x50

Reported by Kernel Concurrency Sanitizer on:
CPU: 1 PID: 24704 Comm: syz-executor.0 Not tainted 5.17.0-rc7-syzkaller-00020-gea4424be1688-dirty #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011
==================================================================

Crashes (1):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2022/03/08 14:27 upstream ea4424be1688 7bdd8b2c .config console log report info ci2-upstream-kcsan-gce KCSAN: data-race in memchr / string
* Struck through repros no longer work on HEAD.