syzbot


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

Status: moderation: reported on 2024/09/05 00:33
Subsystems: audit
[Documentation on labels]
Reported-by: syzbot+5a1c043545293521fb95@syzkaller.appspotmail.com
First crash: 30d, last: 30d
Similar bugs (4)
Kernel Title Repro Cause bisect Fix bisect Count Last Reported Patched Status
upstream KCSAN: data-race in memchr / string (3) audit 7 133d 146d 0/28 auto-obsoleted due to no activity on 2024/06/28 09:14
upstream KCSAN: data-race in memchr / string (4) audit 1 84d 84d 0/28 auto-obsoleted due to no activity on 2024/08/16 20:32
upstream KCSAN: data-race in memchr / string v9fs 1 1188d 1188d 0/28 auto-closed as invalid on 2021/08/08 15:57
upstream KCSAN: data-race in memchr / string (2) mm 1 941d 941d 0/28 auto-closed as invalid on 2022/04/12 14:29

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

write to 0xffffffff88b8c649 of 1 bytes by task 29 on cpu 1:
 string_nocheck lib/vsprintf.c:650 [inline]
 string+0x16c/0x210 lib/vsprintf.c:728
 vsnprintf+0xa09/0xe30 lib/vsprintf.c:2824
 vscnprintf+0x42/0x90 lib/vsprintf.c:2930
 printk_sprint+0x30/0x2d0 kernel/printk/printk.c:2165
 vprintk_store+0x570/0x810 kernel/printk/printk.c:2279
 vprintk_emit+0x13a/0x610 kernel/printk/printk.c:2329
 vprintk_default+0x26/0x30 kernel/printk/printk.c:2363
 vprintk+0x75/0x80 kernel/printk/printk_safe.c:45
 _printk+0x7a/0xa0 kernel/printk/printk.c:2373
 kauditd_printk_skb kernel/audit.c:546 [inline]
 kauditd_hold_skb+0x1a3/0x1b0 kernel/audit.c:581
 kauditd_send_queue+0x288/0x2e0 kernel/audit.c:766
 kauditd_thread+0x42a/0x650 kernel/audit.c:890
 kthread+0x1d1/0x210 kernel/kthread.c:389
 ret_from_fork+0x4b/0x60 arch/x86/kernel/process.c:147
 ret_from_fork_asm+0x1a/0x30 arch/x86/entry/entry_64.S:244

read to 0xffffffff88b8c649 of 1 bytes by task 28972 on cpu 0:
 memchr+0x2a/0x50 lib/string.c:791
 count_lines kernel/printk/printk_ringbuffer.c:1797 [inline]
 copy_data kernel/printk/printk_ringbuffer.c:1843 [inline]
 prb_read kernel/printk/printk_ringbuffer.c:1936 [inline]
 _prb_read_valid+0xa26/0xba0 kernel/printk/printk_ringbuffer.c:2113
 prb_read_valid_info+0x67/0x90 kernel/printk/printk_ringbuffer.c:2216
 do_syslog+0x6a3/0x7d0 kernel/printk/printk.c:1802
 __do_sys_syslog kernel/printk/printk.c:1826 [inline]
 __se_sys_syslog kernel/printk/printk.c:1824 [inline]
 __x64_sys_syslog+0x43/0x50 kernel/printk/printk.c:1824
 x64_sys_call+0x1677/0x2d60 arch/x86/include/generated/asm/syscalls_64.h:104
 do_syscall_x64 arch/x86/entry/common.c:52 [inline]
 do_syscall_64+0xc9/0x1c0 arch/x86/entry/common.c:83
 entry_SYSCALL_64_after_hwframe+0x77/0x7f

value changed: 0x69 -> 0x30

Reported by Kernel Concurrency Sanitizer on:
CPU: 0 UID: 0 PID: 28972 Comm: syz.0.9856 Not tainted 6.11.0-rc6-syzkaller-00048-gc7fb1692dc01 #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 08/06/2024
==================================================================

Crashes (1):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2024/09/05 00:32 upstream c7fb1692dc01 dfbe2ed4 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in memchr / string
* Struck through repros no longer work on HEAD.