syzbot


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

Status: auto-closed as invalid on 2020/10/22 00:22
Subsystems: cgroups
[Documentation on labels]
First crash: 1348d, last: 1317d
Similar bugs (6)
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) cgroups 1 1060d 1060d 0/26 auto-closed as invalid on 2021/07/05 21:29
upstream KCSAN: data-race in __cgroup_account_cputime / cgroup_rstat_flush_locked cgroups 3 1621d 1641d 0/26 auto-closed as invalid on 2020/01/27 12:36
upstream KCSAN: data-race in __cgroup_account_cputime / cgroup_rstat_flush_locked (6) cgroups 12 714d 718d 0/26 auto-closed as invalid on 2022/06/16 16:40
upstream KCSAN: data-race in __cgroup_account_cputime / cgroup_rstat_flush_locked (7) cgroups 234 317d 415d 0/26 auto-obsoleted due to no activity on 2023/07/19 10:43
upstream KCSAN: data-race in __cgroup_account_cputime / cgroup_rstat_flush_locked (4) cgroups 2 984d 1007d 0/26 auto-closed as invalid on 2021/09/20 09:16
upstream KCSAN: data-race in __cgroup_account_cputime / cgroup_rstat_flush_locked (5) cgroups 6 812d 814d 0/26 auto-closed as invalid on 2022/03/10 20:48

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

write to 0xffffe8ffffc976f8 of 8 bytes by task 29514 on cpu 1:
 cgroup_rstat_cpu_pop_updated kernel/cgroup/rstat.c:131 [inline]
 cgroup_rstat_flush_locked+0x277/0x7c0 kernel/cgroup/rstat.c:154
 cgroup_rstat_flush_hold kernel/cgroup/rstat.c:229 [inline]
 cgroup_base_stat_cputime_show+0x80/0x300 kernel/cgroup/rstat.c:436
 cpu_stat_show+0xab/0x310 kernel/cgroup/cgroup.c:3536
 cgroup_seqfile_show+0xbe/0x150 kernel/cgroup/cgroup.c:3758
 kernfs_seq_show+0x74/0x80 fs/kernfs/file.c:167
 seq_read+0x2ee/0x900 fs/seq_file.c:208
 kernfs_fop_read+0xce/0x2f0 fs/kernfs/file.c:251
 do_loop_readv_writev fs/read_write.c:734 [inline]
 do_iter_read+0x3d2/0x4b0 fs/read_write.c:955
 vfs_readv fs/read_write.c:1073 [inline]
 do_preadv+0x13b/0x230 fs/read_write.c:1165
 __do_sys_preadv fs/read_write.c:1215 [inline]
 __se_sys_preadv fs/read_write.c:1210 [inline]
 __x64_sys_preadv+0x54/0x60 fs/read_write.c:1210
 do_syscall_64+0x39/0x80 arch/x86/entry/common.c:46
 entry_SYSCALL_64_after_hwframe+0x44/0xa9

read to 0xffffe8ffffc976f8 of 8 bytes by task 29508 on cpu 0:
 cgroup_rstat_updated kernel/cgroup/rstat.c:43 [inline]
 cgroup_base_stat_cputime_account_end kernel/cgroup/rstat.c:354 [inline]
 __cgroup_account_cputime+0xc8/0x230 kernel/cgroup/rstat.c:364
 cgroup_account_cputime include/linux/cgroup.h:784 [inline]
 update_curr+0x107/0x3a0 kernel/sched/fair.c:870
 enqueue_entity+0x38/0x480 kernel/sched/fair.c:4202
 enqueue_task_fair+0xbb/0x6a0 kernel/sched/fair.c:5497
 enqueue_task kernel/sched/core.c:1576 [inline]
 activate_task+0x4b/0xc0 kernel/sched/core.c:1595
 ttwu_do_activate kernel/sched/core.c:2510 [inline]
 ttwu_queue kernel/sched/core.c:2700 [inline]
 try_to_wake_up+0x286/0x4a0 kernel/sched/core.c:2978
 io_wqe_activate_free_worker fs/io-wq.c:267 [inline]
 io_wqe_wake_worker+0x11c/0x220 fs/io-wq.c:290
 io_wqe_enqueue+0x2b8/0x340 fs/io-wq.c:831
 io_wq_enqueue+0x3a/0x40 fs/io-wq.c:838
 __io_queue_async_work fs/io_uring.c:1198 [inline]
 io_queue_async_work+0x16b/0x3c0 fs/io_uring.c:1208
 __io_queue_sqe+0x4a3/0x670 fs/io_uring.c:6166
 io_queue_sqe+0x81/0x220 fs/io_uring.c:6229
 io_submit_sqe+0x333/0x550 fs/io_uring.c:6299
 io_submit_sqes+0x8c6/0xfb0 fs/io_uring.c:6496
 __do_sys_io_uring_enter fs/io_uring.c:8322 [inline]
 __se_sys_io_uring_enter+0x1c2/0x720 fs/io_uring.c:8281
 __x64_sys_io_uring_enter+0x74/0x80 fs/io_uring.c:8281
 do_syscall_64+0x39/0x80 arch/x86/entry/common.c:46
 entry_SYSCALL_64_after_hwframe+0x44/0xa9

Reported by Kernel Concurrency Sanitizer on:
CPU: 0 PID: 29508 Comm: syz-executor.4 Not tainted 5.9.0-rc5-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011
==================================================================

Crashes (2):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2020/09/17 00:13 upstream 5925fa68fe82 77507d02 .config console log report info ci2-upstream-kcsan-gce
2020/08/17 09:26 upstream 9123e3a74ec7 5ce13532 .config console log report ci2-upstream-kcsan-gce
* Struck through repros no longer work on HEAD.