syzbot


KCSAN: data-race in fprop_new_period / fprop_reflect_period_percpu (7)

Status: auto-closed as invalid on 2022/07/28 18:16
Reported-by: syzbot+@syzkaller.appspotmail.com
First crash: 241d, last: 162d
similar bugs (6):
Kernel Title Repro Cause bisect Fix bisect Count Last Reported Patched Status
upstream KCSAN: data-race in fprop_new_period / fprop_reflect_period_percpu (2) 2 744d 725d 0/24 auto-closed as invalid on 2020/12/23 11:14
upstream KCSAN: data-race in fprop_new_period / fprop_reflect_period_percpu (5) 2 489d 490d 0/24 auto-closed as invalid on 2021/09/04 07:15
upstream KCSAN: data-race in fprop_new_period / fprop_reflect_period_percpu (3) 2 666d 698d 0/24 auto-closed as invalid on 2021/03/11 15:36
upstream KCSAN: data-race in fprop_new_period / fprop_reflect_period_percpu (6) 1 280d 280d 0/24 auto-closed as invalid on 2022/04/01 06:25
upstream KCSAN: data-race in fprop_new_period / fprop_reflect_period_percpu 1 813d 813d 0/24 auto-closed as invalid on 2020/10/15 13:11
upstream KCSAN: data-race in fprop_new_period / fprop_reflect_period_percpu (4) 3 554d 621d 0/24 auto-closed as invalid on 2021/07/02 00:21

Sample crash report:
==================================================================
BUG: KCSAN: data-race in fprop_new_period / fprop_reflect_period_percpu

read-write to 0xffffffff86ea23f0 of 4 bytes by interrupt on cpu 0:
 fprop_new_period+0xf7/0x170 lib/flex_proportions.c:83
 writeout_period+0x55/0xe0 mm/page-writeback.c:612
 call_timer_fn+0x2e/0x240 kernel/time/timer.c:1474
 expire_timers+0x116/0x240 kernel/time/timer.c:1519
 __run_timers+0x350/0x400 kernel/time/timer.c:1790
 run_timer_softirq+0x56/0x60 kernel/time/timer.c:1805
 __do_softirq+0x158/0x2e3 kernel/softirq.c:571
 __irq_exit_rcu kernel/softirq.c:650 [inline]
 irq_exit_rcu+0x41/0x70 kernel/softirq.c:662
 sysvec_apic_timer_interrupt+0x8d/0xb0 arch/x86/kernel/apic/apic.c:1106
 asm_sysvec_apic_timer_interrupt+0x1b/0x20
 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:111 [inline]
 acpi_idle_do_entry drivers/acpi/processor_idle.c:554 [inline]
 acpi_idle_enter+0x283/0x310 drivers/acpi/processor_idle.c:691
 cpuidle_enter_state+0x2ee/0x7a0 drivers/cpuidle/cpuidle.c:237
 cpuidle_enter+0x3c/0x60 drivers/cpuidle/cpuidle.c:351
 call_cpuidle kernel/sched/idle.c:155 [inline]
 cpuidle_idle_call kernel/sched/idle.c:236 [inline]
 do_idle+0x1b2/0x250 kernel/sched/idle.c:303
 cpu_startup_entry+0x15/0x20 kernel/sched/idle.c:400
 rest_init+0xe8/0xf0 init/main.c:726
 start_kernel+0x0/0x656 init/main.c:882
 start_kernel+0x5d1/0x656 init/main.c:1137
 secondary_startup_64_no_verify+0xcf/0xdb

read to 0xffffffff86ea23f0 of 4 bytes by task 1865 on cpu 1:
 fprop_reflect_period_percpu+0x22/0x1a0 lib/flex_proportions.c:192
 __fprop_add_percpu lib/flex_proportions.c:223 [inline]
 __fprop_add_percpu_max+0x54/0x180 lib/flex_proportions.c:281
 wb_domain_writeout_add mm/page-writeback.c:559 [inline]
 __wb_writeout_add+0x7e/0x1d0 mm/page-writeback.c:583
 __folio_end_writeback+0x2f4/0x540 mm/page-writeback.c:2902
 folio_end_writeback+0x57/0x130 mm/filemap.c:1646
 end_page_writeback+0x3b/0xe0 mm/folio-compat.c:26
 ext4_finish_bio+0x421/0x520 fs/ext4/page-io.c:145
 ext4_release_io_end+0x98/0x200 fs/ext4/page-io.c:160
 ext4_end_io_end fs/ext4/page-io.c:194 [inline]
 ext4_do_flush_completed_IO fs/ext4/page-io.c:259 [inline]
 ext4_end_io_rsv_work+0x319/0x3a0 fs/ext4/page-io.c:273
 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

value changed: 0x00000031 -> 0x00000032

Reported by Kernel Concurrency Sanitizer on:
CPU: 1 PID: 1865 Comm: kworker/u4:5 Not tainted 5.19.0-rc3-syzkaller-00048-gde5c208d533a-dirty #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011
Workqueue: ext4-rsv-conversion ext4_end_io_rsv_work
==================================================================

Crashes (5):
Manager Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Title
ci2-upstream-kcsan-gce 2022/06/23 18:07 upstream de5c208d533a 912f5df7 .config log report info KCSAN: data-race in fprop_new_period / fprop_reflect_period_percpu
ci2-upstream-kcsan-gce 2022/06/03 17:38 upstream 50fd82b3a9a9 eee80d3c .config log report info KCSAN: data-race in fprop_new_period / fprop_reflect_period_percpu
ci2-upstream-kcsan-gce 2022/05/05 10:17 upstream a7391ad35724 b3f09415 .config log report info KCSAN: data-race in fprop_new_period / fprop_reflect_period_percpu
ci2-upstream-kcsan-gce 2022/04/12 04:48 upstream ce522ba9ef7e af01ee7d .config log report info KCSAN: data-race in fprop_new_period / fprop_reflect_period_percpu
ci2-upstream-kcsan-gce 2022/04/05 15:27 upstream 312310928417 0127c10f .config log report info KCSAN: data-race in fprop_new_period / fprop_reflect_period_percpu
* Struck through repros no longer work on HEAD.