syzbot


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

Status: auto-closed as invalid on 2021/06/18 16:26
Subsystems: kernel
[Documentation on labels]
First crash: 1016d, last: 1016d
Similar bugs (5)
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 (5) kernel 2 509d 517d 0/26 auto-obsoleted due to no activity on 2022/11/08 00:00
upstream KCSAN: data-race in get_cpu_idle_time_us / tick_irq_enter (4) kernel 92 620d 779d 0/26 auto-closed as invalid on 2022/07/20 00:23
upstream KCSAN: data-race in get_cpu_idle_time_us / tick_irq_enter (6) kernel 3 418d 458d 0/26 auto-obsoleted due to no activity on 2023/02/13 18:11
upstream KCSAN: data-race in get_cpu_idle_time_us / tick_irq_enter (2) kernel 37 1212d 1340d 0/26 auto-closed as invalid on 2020/12/05 03:01
upstream KCSAN: data-race in get_cpu_idle_time_us / tick_irq_enter kernel 7 1402d 1499d 0/26 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 0xffff888237c1dd28 of 8 bytes by interrupt on cpu 0:
 update_ts_time_stats kernel/time/tick-sched.c:598 [inline]
 tick_nohz_stop_idle kernel/time/tick-sched.c:612 [inline]
 tick_nohz_irq_enter kernel/time/tick-sched.c:1329 [inline]
 tick_irq_enter+0x102/0x1e0 kernel/time/tick-sched.c:1348
 sysvec_apic_timer_interrupt+0x5c/0x80 arch/x86/kernel/apic/apic.c:1100
 asm_sysvec_apic_timer_interrupt+0x12/0x20 arch/x86/include/asm/idtentry.h:647
 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:108 [inline]
 acpi_idle_do_entry drivers/acpi/processor_idle.c:513 [inline]
 acpi_idle_enter+0x25b/0x2e0 drivers/acpi/processor_idle.c:648
 cpuidle_enter_state+0x2b6/0x750 drivers/cpuidle/cpuidle.c:237
 cpuidle_enter+0x3c/0x60 drivers/cpuidle/cpuidle.c:351
 call_cpuidle kernel/sched/idle.c:158 [inline]
 cpuidle_idle_call kernel/sched/idle.c:239 [inline]
 do_idle+0x1a3/0x240 kernel/sched/idle.c:306
 cpu_startup_entry+0x15/0x20 kernel/sched/idle.c:403
 rest_init+0xc9/0xd0 init/main.c:721
 arch_call_rest_init+0xa/0xb
 start_kernel+0x59e/0x623 init/main.c:1087
 secondary_startup_64_no_verify+0xb0/0xbb

read to 0xffff888237c1dd28 of 8 bytes by task 4660 on cpu 1:
 get_cpu_idle_time_us+0x1e1/0x1f0 kernel/time/tick-sched.c:655
 get_idle_time fs/proc/stat.c:54 [inline]
 show_stat+0x2cf/0xdb0 fs/proc/stat.c:134
 seq_read_iter+0x2ef/0x910 fs/seq_file.c:227
 proc_reg_read_iter+0xd6/0x170 fs/proc/inode.c:296
 call_read_iter include/linux/fs.h:2108 [inline]
 generic_file_splice_read+0x22a/0x310 fs/splice.c:311
 do_splice_to fs/splice.c:796 [inline]
 splice_direct_to_actor+0x2aa/0x650 fs/splice.c:870
 do_splice_direct+0xf5/0x170 fs/splice.c:979
 do_sendfile+0x773/0xda0 fs/read_write.c:1260
 __do_sys_sendfile64 fs/read_write.c:1325 [inline]
 __se_sys_sendfile64 fs/read_write.c:1311 [inline]
 __x64_sys_sendfile64+0xf2/0x130 fs/read_write.c:1311
 do_syscall_64+0x4a/0x90 arch/x86/entry/common.c:47
 entry_SYSCALL_64_after_hwframe+0x44/0xae

Reported by Kernel Concurrency Sanitizer on:
CPU: 1 PID: 4660 Comm: syz-executor.2 Not tainted 5.13.0-rc1-syzkaller #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
2021/05/14 16:23 upstream 315d99318179 8bdd5343 .config console log report info ci2-upstream-kcsan-gce KCSAN: data-race in get_cpu_idle_time_us / tick_irq_enter
* Struck through repros no longer work on HEAD.