syzbot


INFO: task hung in io_wq_put_and_exit (2)

Status: closed as invalid on 2022/02/08 09:40
Reported-by: syzbot+@syzkaller.appspotmail.com
First crash: 387d, last: 358d
similar bugs (2):
Kernel Title Repro Cause bisect Fix bisect Count Last Reported Patched Status
upstream INFO: task hung in io_wq_put_and_exit (3) C error unreliable 62 25d 254d 0/24 upstream: reported C repro on 2022/03/23 17:52
upstream INFO: task hung in io_wq_put_and_exit C unreliable 628 389d 450d 22/24 fixed on 2021/11/10 00:50

Sample crash report:
INFO: task syz-executor.2:10910 blocked for more than 143 seconds.
      Not tainted 5.16.0-rc4-syzkaller #0
"echo 0 > /proc/sys/kernel/hung_task_timeout_secs" disables this message.
task:syz-executor.2  state:D stack:27816 pid:10910 ppid:  3634 flags:0x00024004
Call Trace:
 <TASK>
 context_switch kernel/sched/core.c:4972 [inline]
 __schedule+0xa9a/0x4940 kernel/sched/core.c:6253
 schedule+0xd2/0x260 kernel/sched/core.c:6326
 schedule_timeout+0x1db/0x2a0 kernel/time/timer.c:1857
 do_wait_for_common kernel/sched/completion.c:85 [inline]
 __wait_for_common kernel/sched/completion.c:106 [inline]
 wait_for_common kernel/sched/completion.c:117 [inline]
 wait_for_completion+0x174/0x270 kernel/sched/completion.c:138
 io_wq_exit_workers fs/io-wq.c:1224 [inline]
 io_wq_put_and_exit+0x33a/0xb70 fs/io-wq.c:1259
 io_uring_clean_tctx fs/io_uring.c:9801 [inline]
 io_uring_cancel_generic+0x61d/0x690 fs/io_uring.c:9882
 io_uring_files_cancel include/linux/io_uring.h:16 [inline]
 do_exit+0x60c/0x2b40 kernel/exit.c:787
 do_group_exit+0x125/0x310 kernel/exit.c:929
 get_signal+0x47d/0x2220 kernel/signal.c:2852
 arch_do_signal_or_restart+0x2a9/0x1c40 arch/x86/kernel/signal.c:868
 handle_signal_work kernel/entry/common.c:148 [inline]
 exit_to_user_mode_loop kernel/entry/common.c:172 [inline]
 exit_to_user_mode_prepare+0x17d/0x290 kernel/entry/common.c:207
 __syscall_exit_to_user_mode_work kernel/entry/common.c:289 [inline]
 syscall_exit_to_user_mode+0x19/0x60 kernel/entry/common.c:300
 do_syscall_64+0x42/0xb0 arch/x86/entry/common.c:86
 entry_SYSCALL_64_after_hwframe+0x44/0xae
RIP: 0033:0x7fe5cc6b8b49
RSP: 002b:00007fe5cb22e218 EFLAGS: 00000246 ORIG_RAX: 00000000000000ca
RAX: fffffffffffffe00 RBX: 00007fe5cc7cbf68 RCX: 00007fe5cc6b8b49
RDX: 0000000000000000 RSI: 0000000000000080 RDI: 00007fe5cc7cbf68
RBP: 00007fe5cc7cbf60 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000246 R12: 00007fe5cc7cbf6c
R13: 00007ffd4b7fc53f R14: 00007fe5cb22e300 R15: 0000000000022000
 </TASK>

Showing all locks held in the system:
1 lock held by khungtaskd/27:
 #0: ffffffff8bb811a0 (rcu_read_lock){....}-{1:2}, at: debug_show_all_locks+0x53/0x260 kernel/locking/lockdep.c:6458
4 locks held by klogd/2960:
 #0: ffff8880b9c39b18 (&rq->__lock){-.-.}-{2:2}, at: raw_spin_rq_lock_nested+0x2b/0x120 kernel/sched/core.c:478
 #1: ffff8880b9c279c8 (&per_cpu_ptr(group->pcpu, cpu)->seq){-.-.}-{0:0}, at: fs_reclaim_acquire+0xb2/0x160 mm/page_alloc.c:4548
 #2: ffff88807db2ca18 (&p->pi_lock){-.-.}-{2:2}, at: try_to_wake_up+0xab/0x15a0 kernel/sched/core.c:4003
 #3: ffff8880b9c39b18 (&rq->__lock){-.-.}-{2:2}, at: raw_spin_rq_lock_nested+0x2b/0x120 kernel/sched/core.c:478
2 locks held by getty/3283:
 #0: ffff88814ae59098 (&tty->ldisc_sem){++++}-{0:0}, at: tty_ldisc_ref_wait+0x22/0x80 drivers/tty/tty_ldisc.c:252
 #1: ffffc90002b8e2e8 (&ldata->atomic_read_lock){+.+.}-{3:3}, at: n_tty_read+0xcf0/0x1230 drivers/tty/n_tty.c:2113
2 locks held by kworker/u4:6/5097:

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

NMI backtrace for cpu 1
CPU: 1 PID: 27 Comm: khungtaskd Not tainted 5.16.0-rc4-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011
Call Trace:
 <TASK>
 __dump_stack lib/dump_stack.c:88 [inline]
 dump_stack_lvl+0xcd/0x134 lib/dump_stack.c:106
 nmi_cpu_backtrace.cold+0x47/0x144 lib/nmi_backtrace.c:111
 nmi_trigger_cpumask_backtrace+0x1b3/0x230 lib/nmi_backtrace.c:62
 trigger_all_cpu_backtrace include/linux/nmi.h:146 [inline]
 check_hung_uninterruptible_tasks kernel/hung_task.c:210 [inline]
 watchdog+0xc1d/0xf50 kernel/hung_task.c:295
 kthread+0x405/0x4f0 kernel/kthread.c:327
 ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:295
 </TASK>
Sending NMI from CPU 1 to CPUs 0:
NMI backtrace for cpu 0
CPU: 0 PID: 5097 Comm: kworker/u4:6 Not tainted 5.16.0-rc4-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011
Workqueue: bat_events batadv_nc_worker
RIP: 0010:bytes_is_nonzero mm/kasan/generic.c:85 [inline]
RIP: 0010:memory_is_nonzero mm/kasan/generic.c:102 [inline]
RIP: 0010:memory_is_poisoned_n mm/kasan/generic.c:128 [inline]
RIP: 0010:memory_is_poisoned mm/kasan/generic.c:159 [inline]
RIP: 0010:check_region_inline mm/kasan/generic.c:180 [inline]
RIP: 0010:kasan_check_range+0xde/0x180 mm/kasan/generic.c:189
Code: 74 f2 48 89 c2 b8 01 00 00 00 48 85 d2 75 56 5b 5d 41 5c c3 48 85 d2 74 5e 48 01 ea eb 09 48 83 c0 01 48 39 d0 74 50 80 38 00 <74> f2 eb d4 41 bc 08 00 00 00 48 89 ea 45 29 dc 4d 8d 1c 2c eb 0c
RSP: 0018:ffffc900050bf9d0 EFLAGS: 00000046
RAX: fffffbfff1feed40 RBX: fffffbfff1feed41 RCX: ffffffff815b9676
RDX: fffffbfff1feed41 RSI: 0000000000000008 RDI: ffffffff8ff76a00
RBP: fffffbfff1feed40 R08: 0000000000000000 R09: ffffffff8ff76a07
R10: fffffbfff1feed40 R11: 0000000000000000 R12: ffff88802d048c30
R13: ffff88802d048180 R14: 0000000000020000 R15: 000000000002002d
FS:  0000000000000000(0000) GS:ffff8880b9c00000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 000000c0030393c8 CR3: 0000000072d69000 CR4: 00000000003506f0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
Call Trace:
 <TASK>
 instrument_atomic_read include/linux/instrumented.h:71 [inline]
 test_bit include/asm-generic/bitops/instrumented-non-atomic.h:134 [inline]
 hlock_class kernel/locking/lockdep.c:199 [inline]
 check_wait_context kernel/locking/lockdep.c:4700 [inline]
 __lock_acquire+0x3e6/0x54a0 kernel/locking/lockdep.c:4977
 lock_acquire kernel/locking/lockdep.c:5637 [inline]
 lock_acquire+0x1ab/0x510 kernel/locking/lockdep.c:5602
 rcu_lock_acquire include/linux/rcupdate.h:268 [inline]
 rcu_read_lock include/linux/rcupdate.h:688 [inline]
 batadv_nc_process_nc_paths.part.0+0xec/0x3c0 net/batman-adv/network-coding.c:691
 batadv_nc_process_nc_paths net/batman-adv/network-coding.c:683 [inline]
 batadv_nc_worker+0xc46/0xfa0 net/batman-adv/network-coding.c:732
 process_one_work+0x9b2/0x1690 kernel/workqueue.c:2298
 worker_thread+0x658/0x11f0 kernel/workqueue.c:2445
 kthread+0x405/0x4f0 kernel/kthread.c:327
 ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:295
 </TASK>
----------------
Code disassembly (best guess):
   0:	74 f2                	je     0xfffffff4
   2:	48 89 c2             	mov    %rax,%rdx
   5:	b8 01 00 00 00       	mov    $0x1,%eax
   a:	48 85 d2             	test   %rdx,%rdx
   d:	75 56                	jne    0x65
   f:	5b                   	pop    %rbx
  10:	5d                   	pop    %rbp
  11:	41 5c                	pop    %r12
  13:	c3                   	retq
  14:	48 85 d2             	test   %rdx,%rdx
  17:	74 5e                	je     0x77
  19:	48 01 ea             	add    %rbp,%rdx
  1c:	eb 09                	jmp    0x27
  1e:	48 83 c0 01          	add    $0x1,%rax
  22:	48 39 d0             	cmp    %rdx,%rax
  25:	74 50                	je     0x77
  27:	80 38 00             	cmpb   $0x0,(%rax)
* 2a:	74 f2                	je     0x1e <-- trapping instruction
  2c:	eb d4                	jmp    0x2
  2e:	41 bc 08 00 00 00    	mov    $0x8,%r12d
  34:	48 89 ea             	mov    %rbp,%rdx
  37:	45 29 dc             	sub    %r11d,%r12d
  3a:	4d 8d 1c 2c          	lea    (%r12,%rbp,1),%r11
  3e:	eb 0c                	jmp    0x4c

Crashes (22):
Manager Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Title
ci-upstream-kasan-gce-selinux-root 2021/12/10 05:42 upstream c741e49150db 4d4ce9bc .config log report info INFO: task hung in io_wq_put_and_exit
ci-upstream-kasan-gce 2021/12/10 02:37 upstream c741e49150db 4d4ce9bc .config log report info INFO: task hung in io_wq_put_and_exit
ci-upstream-kasan-gce-selinux-root 2021/12/03 22:11 upstream 5f58da2befa5 c7c20675 .config log report info INFO: task hung in io_wq_put_and_exit
ci-upstream-kasan-gce-root 2021/12/03 02:07 upstream a51e3ac43ddb 61f86278 .config log report info INFO: task hung in io_wq_put_and_exit
ci-upstream-kasan-gce 2021/12/02 20:47 upstream a51e3ac43ddb 61f86278 .config log report info INFO: task hung in io_wq_put_and_exit
ci-upstream-kasan-gce 2021/12/01 10:20 upstream 58e1100fdc59 5fa3eacc .config log report info INFO: task hung in io_wq_put_and_exit
ci-upstream-kasan-gce-smack-root 2021/11/30 02:17 upstream d58071a8a76d d0830353 .config log report info INFO: task hung in io_wq_put_and_exit
ci-upstream-kasan-gce-root 2021/11/28 19:06 upstream 3498e7f2bb41 63eeac02 .config log report info INFO: task hung in io_wq_put_and_exit
ci-upstream-kasan-gce-selinux-root 2021/11/24 12:44 upstream 5d9f4cf36721 545ab074 .config log report info INFO: task hung in io_wq_put_and_exit
ci-upstream-kasan-gce-selinux-root 2021/11/23 19:56 upstream 136057256686 545ab074 .config log report info INFO: task hung in io_wq_put_and_exit
ci-upstream-kasan-gce-smack-root 2021/11/23 17:55 upstream 136057256686 545ab074 .config log report info INFO: task hung in io_wq_put_and_exit
ci-upstream-kasan-gce 2021/11/23 00:23 upstream 136057256686 545ab074 .config log report info INFO: task hung in io_wq_put_and_exit
ci-upstream-kasan-gce 2021/11/20 06:35 upstream 4c388a8e740d 3a9d0024 .config log report info INFO: task hung in io_wq_put_and_exit
ci-upstream-kasan-gce 2021/11/14 08:55 upstream ccfff0a2bd2a 83f5c9b5 .config log report info INFO: task hung in io_wq_put_and_exit
ci-upstream-kasan-gce-root 2021/11/13 10:51 upstream 66f4beaa6c1d 83f5c9b5 .config log report info INFO: task hung in io_wq_put_and_exit
ci-upstream-kasan-gce-root 2021/11/12 19:58 upstream 7246f4dcaccc 83f5c9b5 .config log report info INFO: task hung in io_wq_put_and_exit
ci-upstream-kasan-gce-root 2021/11/12 17:07 upstream 5833291ab6de 83f5c9b5 .config log report info INFO: task hung in io_wq_put_and_exit
ci-upstream-kasan-gce-root 2021/11/11 19:43 upstream debe436e77c7 75b04091 .config log report info INFO: task hung in io_wq_put_and_exit
ci-upstream-kasan-gce 2021/11/11 04:28 upstream 89d714ab6043 75b04091 .config log report info INFO: task hung in io_wq_put_and_exit
ci-upstream-linux-next-kasan-gce-root 2021/11/28 11:18 linux-next f81e94e91878 63eeac02 .config log report info INFO: task hung in io_wq_put_and_exit
ci-upstream-linux-next-kasan-gce-root 2021/11/22 14:26 linux-next 5191249f8803 545ab074 .config log report info INFO: task hung in io_wq_put_and_exit
ci-upstream-linux-next-kasan-gce-root 2021/11/22 02:12 linux-next 5191249f8803 4eb20a4e .config log report info INFO: task hung in io_wq_put_and_exit
* Struck through repros no longer work on HEAD.