syzbot


KCSAN: data-race in get_cpu_idle_time_us / tick_irq_enter (5)

Status: auto-obsoleted due to no activity on 2022/11/08 00:00
Reported-by: syzbot+@syzkaller.appspotmail.com
First crash: 125d, last: 117d
similar bugs (4):
Kernel Title Repro Cause bisect Fix bisect Count Last Reported Patched Status
upstream KCSAN: data-race in get_cpu_idle_time_us / tick_irq_enter (3) 1 624d 624d 0/24 auto-closed as invalid on 2021/06/18 16:26
upstream KCSAN: data-race in get_cpu_idle_time_us / tick_irq_enter (4) 92 228d 387d 0/24 auto-closed as invalid on 2022/07/20 00:23
upstream KCSAN: data-race in get_cpu_idle_time_us / tick_irq_enter (2) 37 820d 948d 0/24 auto-closed as invalid on 2020/12/05 03:01
upstream KCSAN: data-race in get_cpu_idle_time_us / tick_irq_enter 7 1010d 1108d 0/24 closed as invalid on 2020/06/18 14:24

Sample crash report:
==================================================================
BUG: KCSAN: data-race in get_cpu_idle_time_us / tick_irq_enter

write to 0xffff888237d1e0e8 of 8 bytes by interrupt on cpu 1:
 update_ts_time_stats kernel/time/tick-sched.c:654 [inline]
 tick_nohz_stop_idle kernel/time/tick-sched.c:664 [inline]
 tick_nohz_irq_enter kernel/time/tick-sched.c:1429 [inline]
 tick_irq_enter+0x138/0x210 kernel/time/tick-sched.c:1455
 sysvec_apic_timer_interrupt+0x80/0xb0 arch/x86/kernel/apic/apic.c:1106
 asm_sysvec_apic_timer_interrupt+0x16/0x20 arch/x86/include/asm/idtentry.h:649
 native_safe_halt arch/x86/include/asm/irqflags.h:51 [inline]
 arch_safe_halt arch/x86/include/asm/irqflags.h:89 [inline]
 acpi_safe_halt drivers/acpi/processor_idle.c:112 [inline]
 acpi_idle_do_entry drivers/acpi/processor_idle.c:572 [inline]
 acpi_idle_enter+0x283/0x340 drivers/acpi/processor_idle.c:709
 cpuidle_enter_state+0x2de/0x960 drivers/cpuidle/cpuidle.c:239
 cpuidle_enter+0x3c/0x60 drivers/cpuidle/cpuidle.c:356
 call_cpuidle kernel/sched/idle.c:155 [inline]
 cpuidle_idle_call kernel/sched/idle.c:236 [inline]
 do_idle+0x1a7/0x250 kernel/sched/idle.c:303
 cpu_startup_entry+0x15/0x20 kernel/sched/idle.c:400
 start_secondary+0x78/0x80 arch/x86/kernel/smpboot.c:262
 secondary_startup_64_no_verify+0xcf/0xdb

read to 0xffff888237d1e0e8 of 8 bytes by task 6545 on cpu 0:
 get_cpu_idle_time_us+0x1a8/0x1d0 kernel/time/tick-sched.c:705
 get_idle_time fs/proc/stat.c:54 [inline]
 show_stat+0x96f/0xca0 fs/proc/stat.c:175
 seq_read_iter+0x2c3/0x8e0 fs/seq_file.c:230
 proc_reg_read_iter+0xd4/0x170 fs/proc/inode.c:301
 call_read_iter include/linux/fs.h:2181 [inline]
 io_iter_do_read io_uring/rw.c:643 [inline]
 io_read+0x2ec/0xc90 io_uring/rw.c:765
 io_issue_sqe+0x386/0x900 io_uring/io_uring.c:1577
 io_queue_sqe io_uring/io_uring.c:1755 [inline]
 io_submit_sqe+0x3b6/0xa40 io_uring/io_uring.c:2013
 io_submit_sqes+0x274/0x530 io_uring/io_uring.c:2124
 __do_sys_io_uring_enter io_uring/io_uring.c:3057 [inline]
 __se_sys_io_uring_enter+0x254/0xa50 io_uring/io_uring.c:2987
 __x64_sys_io_uring_enter+0x74/0x80 io_uring/io_uring.c:2987
 do_syscall_x64 arch/x86/entry/common.c:50 [inline]
 do_syscall_64+0x2b/0x70 arch/x86/entry/common.c:80
 entry_SYSCALL_64_after_hwframe+0x63/0xcd

value changed: 0x0000001b3aa6415c -> 0x0000001b3ab615a0

Reported by Kernel Concurrency Sanitizer on:
CPU: 0 PID: 6545 Comm: syz-executor.2 Not tainted 6.0.0-syzkaller-dirty #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 09/22/2022
==================================================================

Crashes (2):
Manager Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets Title
ci2-upstream-kcsan-gce 2022/10/03 23:51 upstream 4fe89d07dcc2 feb56351 .config console log report info [disk image] [vmlinux] KCSAN: data-race in get_cpu_idle_time_us / tick_irq_enter
ci2-upstream-kcsan-gce 2022/09/26 08:40 upstream f76349cf4145 d59ba983 .config console log report info [disk image] [vmlinux] KCSAN: data-race in get_cpu_idle_time_us / tick_irq_enter
* Struck through repros no longer work on HEAD.