syzbot


KCSAN: data-race in __flush_work / wq_worker_running (2)

Status: auto-obsoleted due to no activity on 2023/02/13 19:04
Subsystems: mm
[Documentation on labels]
First crash: 513d, last: 486d
Similar bugs (1)
Kernel Title Repro Cause bisect Fix bisect Count Last Reported Patched Status
upstream KCSAN: data-race in __flush_work / wq_worker_running net 3 610d 623d 0/26 auto-closed as invalid on 2022/10/06 07:44

Sample crash report:
==================================================================
BUG: KCSAN: data-race in __flush_work / wq_worker_running

read-write to 0xffff888237d2abe0 of 4 bytes by task 3236 on cpu 1:
 wq_worker_running+0x96/0xe0 kernel/workqueue.c:880
 schedule_timeout+0xc1/0x290 kernel/time/timer.c:2167
 synchronize_rcu_expedited_wait_once kernel/rcu/tree_exp.h:571 [inline]
 synchronize_rcu_expedited_wait+0x22a/0xc40 kernel/rcu/tree_exp.h:622
 rcu_exp_wait_wake kernel/rcu/tree_exp.h:688 [inline]
 rcu_exp_sel_wait_wake+0x355/0x730 kernel/rcu/tree_exp.h:722
 wait_rcu_exp_gp+0x1a/0x20 kernel/rcu/tree_exp.h:512
 process_one_work+0x3d3/0x720 kernel/workqueue.c:2289
 worker_thread+0x618/0xa70 kernel/workqueue.c:2436
 kthread+0x1a9/0x1e0 kernel/kthread.c:376
 ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:308

read to 0xffff888237d2abe0 of 4 bytes by task 15091 on cpu 0:
 __need_more_worker kernel/workqueue.c:785 [inline]
 insert_work kernel/workqueue.c:1365 [inline]
 insert_wq_barrier kernel/workqueue.c:2716 [inline]
 start_flush_work kernel/workqueue.c:3034 [inline]
 __flush_work+0x416/0x520 kernel/workqueue.c:3072
 flush_work+0x13/0x20 kernel/workqueue.c:3094
 __lru_add_drain_all+0x37b/0x3c0 mm/swap.c:931
 lru_add_drain_all+0xc/0x10 mm/swap.c:939
 invalidate_bdev+0x56/0x80 block/bdev.c:86
 ext4_put_super+0x510/0x810 fs/ext4/super.c:1273
 generic_shutdown_super+0xd5/0x240 fs/super.c:492
 kill_block_super+0x4a/0x90 fs/super.c:1386
 deactivate_locked_super+0x6a/0xb0 fs/super.c:332
 deactivate_super+0x85/0x90 fs/super.c:363
 cleanup_mnt+0x267/0x2d0 fs/namespace.c:1291
 __cleanup_mnt+0x15/0x20 fs/namespace.c:1298
 task_work_run+0xde/0x110 kernel/task_work.c:179
 resume_user_mode_work include/linux/resume_user_mode.h:49 [inline]
 exit_to_user_mode_loop+0x124/0x130 kernel/entry/common.c:171
 exit_to_user_mode_prepare kernel/entry/common.c:203 [inline]
 __syscall_exit_to_user_mode_work kernel/entry/common.c:285 [inline]
 syscall_exit_to_user_mode+0x6a/0x90 kernel/entry/common.c:296
 do_syscall_64+0x37/0x70 arch/x86/entry/common.c:86
 entry_SYSCALL_64_after_hwframe+0x63/0xcd

value changed: 0x00000000 -> 0x00000001

Reported by Kernel Concurrency Sanitizer on:
CPU: 0 PID: 15091 Comm: syz-executor.3 Tainted: G        W          6.2.0-rc2-syzkaller-00010-g69b41ac87e4a-dirty #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 10/26/2022
==================================================================
EXT4-fs (loop3): unmounting filesystem 00000000-0000-0000-0000-000000000000.
EXT4-fs (loop3): unmounting filesystem 00000000-0000-0000-0000-000000000000.
EXT4-fs (loop3): unmounting filesystem 00000000-0000-0000-0000-000000000000.
EXT4-fs (loop3): unmounting filesystem 00000000-0000-0000-0000-000000000000.
EXT4-fs (loop3): unmounting filesystem 00000000-0000-0000-0000-000000000000.
EXT4-fs (loop3): unmounting filesystem 00000000-0000-0000-0000-000000000000.
EXT4-fs (loop3): unmounting filesystem 00000000-0000-0000-0000-000000000000.

Crashes (2):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2023/01/03 10:50 upstream 69b41ac87e4a f0036e18 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in __flush_work / wq_worker_running
2022/12/07 09:41 upstream 8ed710da2873 d88f3abb .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in __flush_work / wq_worker_running
* Struck through repros no longer work on HEAD.