INFO: task hung in ptmx_open

Status: upstream: reported on 2026/07/30 13:51
Reported-by: syzbot+bd4b7a73b2975cf1b2d3@syzkaller.appspotmail.com
First crash: 12d, last: 12d
Similar bugs (5)
Kernel Title Rank 🛈 Repro Cause bisect Fix bisect Count Last Reported Patched Status
linux-5.15 INFO: task hung in ptmx_open 1 4 11h27m 13d 0/3 upstream: reported on 2026/07/29 05:43
upstream INFO: task hung in ptmx_open serial 1 4 1650d 1724d 0/29 closed as invalid on 2022/02/08 09:40
android-49 INFO: task hung in ptmx_open 1 1 2880d 2880d 0/3 auto-closed as invalid on 2019/03/21 04:01
upstream INFO: task hung in ptmx_open (2) serial 1 6 470d 634d 0/29 auto-obsoleted due to no activity on 2025/07/27 16:38
upstream INFO: task hung in ptmx_open (3) prio:high serial 1 7 112d 321d 0/29 auto-obsoleted due to no activity on 2026/07/20 22:39

Sample crash report:
INFO: task syz.1.1995:10015 blocked for more than 143 seconds.
      Not tainted syzkaller #0
"echo 0 > /proc/sys/kernel/hung_task_timeout_secs" disables this message.
task:syz.1.1995      state:D stack:28368 pid:10015 ppid:4920   flags:0x00004004
Call Trace:
 <TASK>
 context_switch kernel/sched/core.c:5246 [inline]
 __schedule+0x107f/0x4030 kernel/sched/core.c:6563
 schedule+0xb9/0x180 kernel/sched/core.c:6639
 schedule_preempt_disabled+0xf/0x20 kernel/sched/core.c:6698
 __mutex_lock_common kernel/locking/mutex.c:679 [inline]
 __mutex_lock+0x548/0xae0 kernel/locking/mutex.c:747
 ptmx_open+0xcc/0x2c0 drivers/tty/pty.c:823
 chrdev_open+0x585/0x5f0 fs/char_dev.c:414
 do_dentry_open+0x7dd/0x10b0 fs/open.c:882
 do_open fs/namei.c:3634 [inline]
 path_openat+0x2674/0x2f10 fs/namei.c:3791
 do_filp_open+0x1ee/0x420 fs/namei.c:3818
 do_sys_openat2+0x14b/0x4f0 fs/open.c:1320
 do_sys_open fs/open.c:1336 [inline]
 __do_sys_openat fs/open.c:1352 [inline]
 __se_sys_openat fs/open.c:1347 [inline]
 __x64_sys_openat+0x135/0x160 fs/open.c:1347
 do_syscall_x64 arch/x86/entry/common.c:46 [inline]
 do_syscall_64+0x4c/0xa0 arch/x86/entry/common.c:76
 entry_SYSCALL_64_after_hwframe+0x68/0xd2
RIP: 0033:0x7f0e1cb9df99
RSP: 002b:00007f0e1db14028 EFLAGS: 00000246 ORIG_RAX: 0000000000000101
RAX: ffffffffffffffda RBX: 00007f0e1ce25fa0 RCX: 00007f0e1cb9df99
RDX: 0000000000000041 RSI: 0000200000000040 RDI: ffffffffffffff9c
RBP: 00007f0e1cc34ec4 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000
R13: 00007f0e1ce26038 R14: 00007f0e1ce25fa0 R15: 00007ffc27f66f18
 </TASK>

Showing all locks held in the system:
1 lock held by rcu_tasks_kthre/12:
 #0: ffffffff8cb2e4f0 (rcu_tasks.tasks_gp_mutex){+.+.}-{3:3}, at: rcu_tasks_one_gp+0x33/0xef0 kernel/rcu/tasks.h:517
1 lock held by rcu_tasks_trace/13:
 #0: ffffffff8cb2ed10 (rcu_tasks_trace.tasks_gp_mutex){+.+.}-{3:3}, at: rcu_tasks_one_gp+0x33/0xef0 kernel/rcu/tasks.h:517
1 lock held by khungtaskd/27:
 #0: ffffffff8cb2db60 (rcu_read_lock){....}-{1:2}, at: rcu_lock_acquire include/linux/rcupdate.h:350 [inline]
 #0: ffffffff8cb2db60 (rcu_read_lock){....}-{1:2}, at: rcu_read_lock include/linux/rcupdate.h:791 [inline]
 #0: ffffffff8cb2db60 (rcu_read_lock){....}-{1:2}, at: debug_show_all_locks+0x51/0x290 kernel/locking/lockdep.c:6527
2 locks held by getty/4029:
 #0: ffff88814d8e7098 (&tty->ldisc_sem){++++}-{0:0}, at: tty_ldisc_ref_wait+0x21/0x70 drivers/tty/tty_ldisc.c:244
 #1: ffffc9000327b2f0 (&ldata->atomic_read_lock){+.+.}-{3:3}, at: n_tty_read+0x41e/0x1360 drivers/tty/n_tty.c:2198
2 locks held by kworker/0:20/9787:
 #0: ffff888017470938 ((wq_completion)events){+.+.}-{0:0}, at: process_one_work+0x7b4/0x1160 kernel/workqueue.c:2267
 #1: ffffc90003787d00 (console_work){+.+.}-{0:0}, at: process_one_work+0x7b4/0x1160 kernel/workqueue.c:2267
3 locks held by syz.2.1993/10006:
1 lock held by syz.1.1995/10015:
 #0: ffffffff8d290808 (tty_mutex){+.+.}-{3:3}, at: ptmx_open+0xcc/0x2c0 drivers/tty/pty.c:823
1 lock held by syz.9.2186/10803:
 #0: ffffffff8d290808 (tty_mutex){+.+.}-{3:3}, at: tty_open_by_driver drivers/tty/tty_io.c:2045 [inline]
 #0: ffffffff8d290808 (tty_mutex){+.+.}-{3:3}, at: tty_open+0x204/0xcb0 drivers/tty/tty_io.c:2128
1 lock held by syz.7.2412/11595:
 #0: ffffffff8d290808 (tty_mutex){+.+.}-{3:3}, at: tty_open_by_driver drivers/tty/tty_io.c:2045 [inline]
 #0: ffffffff8d290808 (tty_mutex){+.+.}-{3:3}, at: tty_open+0x204/0xcb0 drivers/tty/tty_io.c:2128
1 lock held by syz.4.2603/12459:
 #0: ffffffff8d290808 (tty_mutex){+.+.}-{3:3}, at: ptmx_open+0xcc/0x2c0 drivers/tty/pty.c:823
1 lock held by syz.9.2653/12693:
 #0: ffffffff8d290808 (tty_mutex){+.+.}-{3:3}, at: ptmx_open+0xcc/0x2c0 drivers/tty/pty.c:823
1 lock held by syz.5.2740/13051:
 #0: ffffffff8d290808 (tty_mutex){+.+.}-{3:3}, at: ptmx_open+0xcc/0x2c0 drivers/tty/pty.c:823
7 locks held by syz-executor/13064:
 #0: ffff88807d9e8460 (sb_writers#8){.+.+}-{0:0}, at: vfs_write+0x270/0x9a0 fs/read_write.c:580
 #1: ffff888038ca1c88 (&of->mutex){+.+.}-{3:3}, at: kernfs_fop_write_iter+0x1d8/0x520 fs/kernfs/file.c:343
 #2: ffff888145f68830 (kn->active#53){.+.+}-{0:0}, at: kernfs_get_active_of fs/kernfs/file.c:80 [inline]
 #2: ffff888145f68830 (kn->active#53){.+.+}-{0:0}, at: kernfs_fop_write_iter+0x232/0x520 fs/kernfs/file.c:344
 #3: ffffffff8d66a3a8 (nsim_bus_dev_list_lock){+.+.}-{3:3}, at: del_device_store+0xd3/0x370 drivers/net/netdevsim/bus.c:209
 #4: ffff888072a490e8 (&dev->mutex){....}-{3:3}, at: device_lock include/linux/device.h:885 [inline]
 #4: ffff888072a490e8 (&dev->mutex){....}-{3:3}, at: __device_driver_lock drivers/base/dd.c:1099 [inline]
 #4: ffff888072a490e8 (&dev->mutex){....}-{3:3}, at: device_release_driver_internal+0xb1/0x7c0 drivers/base/dd.c:1302
 #5: ffff888023c832f8 (&devlink->lock_key#10){+.+.}-{3:3}, at: nsim_drv_remove+0x54/0x170 drivers/net/netdevsim/dev.c:1678
 #6: ffffffff8cb33700 (rcu_state.barrier_mutex){+.+.}-{3:3}, at: rcu_barrier+0x48/0x5e0 kernel/rcu/tree.c:4023
1 lock held by rm/13107:
1 lock held by syz.1.2752/13109:

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

NMI backtrace for cpu 0
CPU: 0 PID: 27 Comm: khungtaskd Not tainted syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 07/24/2026
Call Trace:
 <TASK>
 dump_stack_lvl+0x188/0x24e lib/dump_stack.c:106
 nmi_cpu_backtrace+0x3e6/0x460 lib/nmi_backtrace.c:111
 nmi_trigger_cpumask_backtrace+0x1d4/0x450 lib/nmi_backtrace.c:62
 trigger_all_cpu_backtrace include/linux/nmi.h:148 [inline]
 check_hung_uninterruptible_tasks kernel/hung_task.c:220 [inline]
 watchdog+0xf0e/0xf50 kernel/hung_task.c:377
 kthread+0x29d/0x330 kernel/kthread.c:376
 ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:295
 </TASK>

Crashes (1):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2026/07/30 13:50 linux-6.1.y fb28aa725e05 2377cd3d .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan INFO: task hung in ptmx_open
* Struck through repros no longer work on HEAD.