syzbot


KCSAN: data-race in yama_relation_cleanup / yama_task_free

Status: auto-closed as invalid on 2020/09/04 02:18
Reported-by: syzbot+@syzkaller.appspotmail.com
First crash: 767d, last: 746d
similar bugs (3):
Kernel Title Repro Cause bisect Fix bisect Count Last Reported Patched Status
upstream KCSAN: data-race in yama_relation_cleanup / yama_task_free (2) 1 674d 674d 0/23 auto-closed as invalid on 2020/11/14 15:11
upstream KCSAN: data-race in yama_relation_cleanup / yama_task_free (4) 2 499d 503d 0/23 auto-closed as invalid on 2021/05/17 10:12
upstream KCSAN: data-race in yama_relation_cleanup / yama_task_free (3) 5 566d 616d 0/23 auto-closed as invalid on 2021/03/02 05:29

Sample crash report:
==================================================================
BUG: KCSAN: data-race in yama_relation_cleanup / yama_task_free

write to 0xffff88811e22c410 of 1 bytes by interrupt on cpu 0:
 yama_ptracer_del security/yama/yama_lsm.c:191 [inline]
 yama_task_free+0xc6/0x150 security/yama/yama_lsm.c:207
 security_task_free+0x3f/0xa0 security/security.c:1595
 __put_task_struct+0x96/0x370 kernel/fork.c:750
 put_task_struct include/linux/sched/task.h:126 [inline]
 delayed_put_task_struct+0x52/0x160 kernel/exit.c:172
 rcu_do_batch kernel/rcu/tree.c:2414 [inline]
 rcu_core+0x576/0xac0 kernel/rcu/tree.c:2641
 rcu_core_si+0x9/0x10 kernel/rcu/tree.c:2650
 __do_softirq+0x198/0x360 kernel/softirq.c:292
 asm_call_on_stack+0xf/0x20 arch/x86/entry/entry_64.S:711
 __run_on_irqstack arch/x86/include/asm/irq_stack.h:22 [inline]
 run_on_irqstack_cond arch/x86/include/asm/irq_stack.h:48 [inline]
 do_softirq_own_stack+0x5d/0x80 arch/x86/kernel/irq_64.c:77
 invoke_softirq kernel/softirq.c:387 [inline]
 __irq_exit_rcu+0x115/0x120 kernel/softirq.c:417
 sysvec_apic_timer_interrupt+0xba/0xd0 arch/x86/kernel/apic/apic.c:1091
 asm_sysvec_apic_timer_interrupt+0x12/0x20 arch/x86/include/asm/idtentry.h:585
 native_safe_halt+0xe/0x10 arch/x86/include/asm/irqflags.h:60
 arch_safe_halt arch/x86/include/asm/paravirt.h:150 [inline]
 acpi_safe_halt drivers/acpi/processor_idle.c:111 [inline]
 acpi_idle_do_entry drivers/acpi/processor_idle.c:525 [inline]
 acpi_idle_enter+0x2ff/0x680 drivers/acpi/processor_idle.c:651
 cpuidle_enter_state+0x245/0x5d0 drivers/cpuidle/cpuidle.c:235
 cpuidle_enter+0x3c/0x60 drivers/cpuidle/cpuidle.c:346
 call_cpuidle kernel/sched/idle.c:126 [inline]
 cpuidle_idle_call kernel/sched/idle.c:214 [inline]
 do_idle+0x229/0x310 kernel/sched/idle.c:276
 cpu_startup_entry+0x15/0x20 kernel/sched/idle.c:372
 rest_init+0xd8/0xe0 init/main.c:705
 arch_call_rest_init+0xa/0xb
 start_kernel+0x608/0x6d0 init/main.c:1043
 secondary_startup_64+0xa4/0xb0 arch/x86/kernel/head_64.S:243

read to 0xffff88811e22c410 of 1 bytes by task 15021 on cpu 1:
 yama_relation_cleanup+0x5d/0x150 security/yama/yama_lsm.c:122
 process_one_work+0x3e1/0x9a0 kernel/workqueue.c:2269
 worker_thread+0x665/0xbe0 kernel/workqueue.c:2415
 kthread+0x20d/0x230 kernel/kthread.c:291
 ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:293

Reported by Kernel Concurrency Sanitizer on:
CPU: 1 PID: 15021 Comm: kworker/1:6 Not tainted 5.8.0-rc7-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011
Workqueue: events yama_relation_cleanup
==================================================================

Crashes (4):
Manager Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Title
ci2-upstream-kcsan-gce 2020/07/31 02:11 upstream e2c46b5762c6 8df85ed9 .config log report
ci2-upstream-kcsan-gce 2020/07/25 14:54 upstream 23ee3e4e5bd2 1f7cc1ca .config log report
ci2-upstream-kcsan-gce 2020/07/15 03:54 upstream e9919e11e219 ada108d0 .config log report
ci2-upstream-kcsan-gce 2020/07/09 18:28 upstream 0bddd227f3dc bc238812 .config log report