syzbot


INFO: task hung in _free_event

Status: upstream: reported C repro on 2024/11/18 06:32
Subsystems: perf
[Documentation on labels]
Reported-by: syzbot+3c4321e10eea460eb606@syzkaller.appspotmail.com
First crash: 6d23h, last: 6d23h
Discussions (1)
Title Replies (including bot) Last reply
[syzbot] [perf?] INFO: task hung in _free_event 0 (1) 2024/11/18 06:32
Similar bugs (4)
Kernel Title Repro Cause bisect Fix bisect Count Last Reported Patched Status
android-414 INFO: task hung in _free_event 8 1973d 2040d 0/1 auto-closed as invalid on 2019/10/26 01:49
linux-4.19 INFO: task hung in _free_event 1 1657d 1657d 0/1 auto-closed as invalid on 2020/09/05 20:32
linux-6.1 INFO: task hung in _free_event origin:lts-only C 38 12h15m 80d 0/3 upstream: reported C repro on 2024/09/01 12:31
linux-4.14 INFO: task hung in _free_event 1 1530d 1530d 0/1 auto-closed as invalid on 2021/01/10 07:54

Sample crash report:
INFO: task syz-executor369:6029 blocked for more than 143 seconds.
      Not tainted 6.12.0-rc7-syzkaller-00070-g0a9b9d17f3a7 #0
"echo 0 > /proc/sys/kernel/hung_task_timeout_secs" disables this message.
task:syz-executor369 state:D stack:24376 pid:6029  tgid:6029  ppid:5328   flags:0x00004002
Call Trace:
 <TASK>
 context_switch kernel/sched/core.c:5328 [inline]
 __schedule+0x184f/0x4c30 kernel/sched/core.c:6693
 __schedule_loop kernel/sched/core.c:6770 [inline]
 schedule+0x14b/0x320 kernel/sched/core.c:6785
 perf_pending_task_sync kernel/events/core.c:5319 [inline]
 _free_event+0x178/0xf60 kernel/events/core.c:5326
 put_event kernel/events/core.c:5454 [inline]
 perf_event_release_kernel+0x7c1/0x850 kernel/events/core.c:5579
 perf_release+0x38/0x40 kernel/events/core.c:5589
 __fput+0x23f/0x880 fs/file_table.c:431
 task_work_run+0x24f/0x310 kernel/task_work.c:239
 exit_task_work include/linux/task_work.h:43 [inline]
 do_exit+0xa2f/0x28e0 kernel/exit.c:939
 do_group_exit+0x207/0x2c0 kernel/exit.c:1088
 get_signal+0x16a3/0x1740 kernel/signal.c:2918
 arch_do_signal_or_restart+0x96/0x860 arch/x86/kernel/signal.c:337
 exit_to_user_mode_loop kernel/entry/common.c:111 [inline]
 exit_to_user_mode_prepare include/linux/entry-common.h:328 [inline]
 __syscall_exit_to_user_mode_work kernel/entry/common.c:207 [inline]
 syscall_exit_to_user_mode+0xc9/0x370 kernel/entry/common.c:218
 do_syscall_64+0x100/0x230 arch/x86/entry/common.c:89
 entry_SYSCALL_64_after_hwframe+0x77/0x7f
RIP: 0033:0x7f7fa88a3cf9
RSP: 002b:00007ffc8b3be618 EFLAGS: 00000246 ORIG_RAX: 0000000000000038
RAX: 00000000000017af RBX: 0000000000000000 RCX: 00007f7fa88a3cf9
RDX: 0000000000000000 RSI: 0000000000000000 RDI: 000000000000c000
RBP: 0000000000000000 R08: 0000000000000000 R09: 0000000000000006
R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000
R13: 0000000000000000 R14: 0000000000000001 R15: 0000000000000001
 </TASK>

Showing all locks held in the system:
1 lock held by khungtaskd/25:
 #0: ffffffff8e937da0 (rcu_read_lock){....}-{1:2}, at: rcu_lock_acquire include/linux/rcupdate.h:337 [inline]
 #0: ffffffff8e937da0 (rcu_read_lock){....}-{1:2}, at: rcu_read_lock include/linux/rcupdate.h:849 [inline]
 #0: ffffffff8e937da0 (rcu_read_lock){....}-{1:2}, at: debug_show_all_locks+0x55/0x2a0 kernel/locking/lockdep.c:6720
2 locks held by getty/5110:
 #0: ffff8880007e10a0 (&tty->ldisc_sem){++++}-{0:0}, at: tty_ldisc_ref_wait+0x25/0x70 drivers/tty/tty_ldisc.c:243
 #1: ffffc9000039b2f0 (&ldata->atomic_read_lock){+.+.}-{3:3}, at: n_tty_read+0x6a6/0x1e00 drivers/tty/n_tty.c:2211

=============================================

NMI backtrace for cpu 0
CPU: 0 UID: 0 PID: 25 Comm: khungtaskd Not tainted 6.12.0-rc7-syzkaller-00070-g0a9b9d17f3a7 #0
Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.16.3-debian-1.16.3-2~bpo12+1 04/01/2014
Call Trace:
 <TASK>
 __dump_stack lib/dump_stack.c:94 [inline]
 dump_stack_lvl+0x241/0x360 lib/dump_stack.c:120
 nmi_cpu_backtrace+0x49c/0x4d0 lib/nmi_backtrace.c:113
 nmi_trigger_cpumask_backtrace+0x198/0x320 lib/nmi_backtrace.c:62
 trigger_all_cpu_backtrace include/linux/nmi.h:162 [inline]
 check_hung_uninterruptible_tasks kernel/hung_task.c:223 [inline]
 watchdog+0xff4/0x1040 kernel/hung_task.c:379
 kthread+0x2f0/0x390 kernel/kthread.c:389
 ret_from_fork+0x4b/0x80 arch/x86/kernel/process.c:147
 ret_from_fork_asm+0x1a/0x30 arch/x86/entry/entry_64.S:244
 </TASK>

Crashes (1):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2024/11/14 06:27 upstream 0a9b9d17f3a7 a8c99394 .config console log report syz / log C [disk image (non-bootable)] [vmlinux] [kernel image] ci-snapshot-upstream-root INFO: task hung in _free_event
* Struck through repros no longer work on HEAD.