syzbot


KCSAN: data-race in __cgroup_account_cputime / cgroup_rstat_flush_locked (5)

Status: auto-closed as invalid on 2022/03/10 20:48
Reported-by: syzbot+@syzkaller.appspotmail.com
First crash: 297d, last: 295d
similar bugs (5):
Kernel Title Repro Cause bisect Fix bisect Count Last Reported Patched Status
upstream KCSAN: data-race in __cgroup_account_cputime / cgroup_rstat_flush_locked (3) 1 543d 543d 0/24 auto-closed as invalid on 2021/07/05 21:29
upstream KCSAN: data-race in __cgroup_account_cputime / cgroup_rstat_flush_locked 3 1104d 1124d 0/24 auto-closed as invalid on 2020/01/27 12:36
upstream KCSAN: data-race in __cgroup_account_cputime / cgroup_rstat_flush_locked (6) 12 198d 201d 0/24 auto-closed as invalid on 2022/06/16 16:40
upstream KCSAN: data-race in __cgroup_account_cputime / cgroup_rstat_flush_locked (2) 2 800d 831d 0/24 auto-closed as invalid on 2020/10/22 00:22
upstream KCSAN: data-race in __cgroup_account_cputime / cgroup_rstat_flush_locked (4) 2 467d 490d 0/24 auto-closed as invalid on 2021/09/20 09:16

Sample crash report:
==================================================================
BUG: KCSAN: data-race in __cgroup_account_cputime / cgroup_rstat_flush_locked

write to 0xffffe8ffffd9cb50 of 8 bytes by task 4314 on cpu 1:
 __cgroup_account_cputime+0x67/0xc0 kernel/cgroup/rstat.c:371
 cgroup_account_cputime include/linux/cgroup.h:797 [inline]
 update_curr+0xf6/0x280 kernel/sched/fair.c:877
 enqueue_entity+0x38/0x5a0 kernel/sched/fair.c:4272
 enqueue_task_fair+0xd9/0x420 kernel/sched/fair.c:5620
 enqueue_task kernel/sched/core.c:2010 [inline]
 activate_task kernel/sched/core.c:2035 [inline]
 wake_up_new_task+0x208/0x310 kernel/sched/core.c:4515
 kernel_clone+0x277/0x6a0 kernel/fork.c:2579
 __do_sys_clone kernel/fork.c:2672 [inline]
 __se_sys_clone kernel/fork.c:2656 [inline]
 __x64_sys_clone+0xc6/0xf0 kernel/fork.c:2656
 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 0xffffe8ffffd9cb50 of 8 bytes by task 1825 on cpu 0:
 cgroup_base_stat_flush kernel/cgroup/rstat.c:328 [inline]
 cgroup_rstat_flush_locked+0x2e8/0x7e0 kernel/cgroup/rstat.c:161
 cgroup_rstat_flush_irqsafe+0x24/0x40 kernel/cgroup/rstat.c:215
 __mem_cgroup_flush_stats mm/memcontrol.c:652 [inline]
 mem_cgroup_flush_stats+0x96/0xf0 mm/memcontrol.c:660
 shrink_node+0x2f9/0x1190 mm/vmscan.c:3198
 shrink_zones+0x2d1/0x5e0 mm/vmscan.c:3530
 do_try_to_free_pages+0x181/0x720 mm/vmscan.c:3588
 try_to_free_mem_cgroup_pages+0x1cb/0x420 mm/vmscan.c:3902
 reclaim_high mm/memcontrol.c:2300 [inline]
 mem_cgroup_handle_over_high+0x15b/0x480 mm/memcontrol.c:2484
 tracehook_notify_resume include/linux/tracehook.h:197 [inline]
 exit_to_user_mode_loop kernel/entry/common.c:175 [inline]
 exit_to_user_mode_prepare+0x139/0x190 kernel/entry/common.c:207
 __syscall_exit_to_user_mode_work kernel/entry/common.c:289 [inline]
 syscall_exit_to_user_mode+0x20/0x40 kernel/entry/common.c:300
 do_syscall_64+0x50/0xd0 arch/x86/entry/common.c:86
 entry_SYSCALL_64_after_hwframe+0x44/0xae

value changed: 0x000000007c873cfa -> 0x000000007c874f36

Reported by Kernel Concurrency Sanitizer on:
CPU: 0 PID: 1825 Comm: syz-executor.1 Not tainted 5.17.0-rc2-syzkaller-00064-gc36c04c2e132 #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011
==================================================================

Crashes (6):
Manager Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Title
ci2-upstream-kcsan-gce 2022/02/03 20:40 upstream c36c04c2e132 30646bfe .config log report info KCSAN: data-race in __cgroup_account_cputime / cgroup_rstat_flush_locked
ci2-upstream-kcsan-gce 2022/02/03 08:53 upstream 88808fbbead4 4ebb2798 .config log report info KCSAN: data-race in __cgroup_account_cputime / cgroup_rstat_flush_locked
ci2-upstream-kcsan-gce 2022/02/03 08:19 upstream 88808fbbead4 4ebb2798 .config log report info KCSAN: data-race in __cgroup_account_cputime / cgroup_rstat_flush_locked
ci2-upstream-kcsan-gce 2022/02/02 22:23 upstream 27bb0b18c208 4ebb2798 .config log report info KCSAN: data-race in __cgroup_account_cputime / cgroup_rstat_flush_locked
ci2-upstream-kcsan-gce 2022/02/02 02:10 upstream 9f7fb8de5d9b 4ebb2798 .config log report info KCSAN: data-race in __cgroup_account_cputime / cgroup_rstat_flush_locked
ci2-upstream-kcsan-gce 2022/02/01 21:39 upstream 9f7fb8de5d9b c1c1631d .config log report info KCSAN: data-race in __cgroup_account_cputime / cgroup_rstat_flush_locked
* Struck through repros no longer work on HEAD.