INFO: task hung in tun_chr_close (2)

9 views
Skip to first unread message

syzbot

unread,
Oct 2, 2021, 8:40:26 AM10/2/21
to syzkaller...@googlegroups.com
Hello,

syzbot found the following issue on:

HEAD commit: c2276d585654 Linux 4.19.208
git tree: linux-4.19.y
console output: https://syzkaller.appspot.com/x/log.txt?x=13c5e23f300000
kernel config: https://syzkaller.appspot.com/x/.config?x=9080caca9deef589
dashboard link: https://syzkaller.appspot.com/bug?extid=6ac7c1dcb590b18db697
compiler: gcc version 10.2.1 20210110 (Debian 10.2.1-6)

Unfortunately, I don't have any reproducer for this issue yet.

IMPORTANT: if you fix the issue, please add the following tag to the commit:
Reported-by: syzbot+6ac7c1...@syzkaller.appspotmail.com

ieee802154 phy0 wpan0: encryption failed: -22
ieee802154 phy1 wpan1: encryption failed: -22
Bluetooth: hci0: command 0x0406 tx timeout
device wlan1 left promiscuous mode
device geneve2 left promiscuous mode
INFO: task syz-executor.4:10636 blocked for more than 140 seconds.
Not tainted 4.19.208-syzkaller #0
"echo 0 > /proc/sys/kernel/hung_task_timeout_secs" disables this message.
syz-executor.4 D28648 10636 8118 0x00000004
Call Trace:
context_switch kernel/sched/core.c:2828 [inline]
__schedule+0x887/0x2040 kernel/sched/core.c:3517
schedule+0x8d/0x1b0 kernel/sched/core.c:3561
schedule_preempt_disabled+0xf/0x20 kernel/sched/core.c:3619
__mutex_lock_common kernel/locking/mutex.c:1016 [inline]
__mutex_lock+0x5f0/0x1190 kernel/locking/mutex.c:1078
tun_detach drivers/net/tun.c:759 [inline]
tun_chr_close+0x3a/0x180 drivers/net/tun.c:3323
__fput+0x2ce/0x890 fs/file_table.c:278
task_work_run+0x148/0x1c0 kernel/task_work.c:113
tracehook_notify_resume include/linux/tracehook.h:193 [inline]
exit_to_usermode_loop+0x251/0x2a0 arch/x86/entry/common.c:167
prepare_exit_to_usermode arch/x86/entry/common.c:198 [inline]
syscall_return_slowpath arch/x86/entry/common.c:271 [inline]
do_syscall_64+0x538/0x620 arch/x86/entry/common.c:296
entry_SYSCALL_64_after_hwframe+0x49/0xbe
RIP: 0033:0x7f92f1e1551b
Code: Bad RIP value.
RSP: 002b:00007fffbef80760 EFLAGS: 00000293 ORIG_RAX: 0000000000000003
RAX: 0000000000000000 RBX: 0000000000000005 RCX: 00007f92f1e1551b
RDX: 0000001b2f127e30 RSI: ffffffff83771795 RDI: 0000000000000004
RBP: 0000000000000001 R08: 0000000000000000 R09: 0000001b2f124da8
R10: 00000000000002fc R11: 0000000000000293 R12: 00007f92f1f67b60
R13: 00007f92f1f67b60 R14: 00007f92f1f66f60 R15: 00000000002059cb

Showing all locks held in the system:
1 lock held by khungtaskd/1554:
#0: 0000000072229005 (rcu_read_lock){....}, at: debug_show_all_locks+0x53/0x265 kernel/locking/lockdep.c:4441
1 lock held by in:imklog/7788:
#0: 00000000a14e3dc6 (&f->f_pos_lock){+.+.}, at: __fdget_pos+0x26f/0x310 fs/file.c:767
3 locks held by kworker/u4:0/29610:
#0: 0000000029f008b9 ((wq_completion)"%s""netns"){+.+.}, at: process_one_work+0x767/0x1570 kernel/workqueue.c:2124
#1: 000000008a2adb4f (net_cleanup_work){+.+.}, at: process_one_work+0x79c/0x1570 kernel/workqueue.c:2128
#2: 000000004263464b (pernet_ops_rwsem){++++}, at: cleanup_net+0xa8/0x8b0 net/core/net_namespace.c:521
3 locks held by kworker/1:4/19933:
#0: 00000000673546c0 ((wq_completion)"events"){+.+.}, at: process_one_work+0x767/0x1570 kernel/workqueue.c:2124
#1: 00000000212b1ca9 ((linkwatch_work).work){+.+.}, at: process_one_work+0x79c/0x1570 kernel/workqueue.c:2128
#2: 00000000bb70f229 (rtnl_mutex){+.+.}, at: linkwatch_event+0xb/0x60 net/core/link_watch.c:236
2 locks held by syz-executor.4/10183:
#0: 000000002b742019 (&sb->s_type->i_mutex_key#13){+.+.}, at: inode_lock include/linux/fs.h:748 [inline]
#0: 000000002b742019 (&sb->s_type->i_mutex_key#13){+.+.}, at: __sock_release+0x86/0x2a0 net/socket.c:598
#1: 00000000bb70f229 (rtnl_mutex){+.+.}, at: ip6mr_sk_done+0xe0/0x370 net/ipv6/ip6mr.c:1564
2 locks held by syz-executor.4/10205:
#0: 0000000018857f78 (&sb->s_type->i_mutex_key#13){+.+.}, at: inode_lock include/linux/fs.h:748 [inline]
#0: 0000000018857f78 (&sb->s_type->i_mutex_key#13){+.+.}, at: __sock_release+0x86/0x2a0 net/socket.c:598
#1: 00000000bb70f229 (rtnl_mutex){+.+.}, at: ip6mr_sk_done+0xe0/0x370 net/ipv6/ip6mr.c:1564
3 locks held by kworker/1:0/26723:
#0: 00000000673546c0 ((wq_completion)"events"){+.+.}, at: process_one_work+0x767/0x1570 kernel/workqueue.c:2124
#1: 0000000050bd97dd (deferred_process_work){+.+.}, at: process_one_work+0x79c/0x1570 kernel/workqueue.c:2128
#2: 00000000bb70f229 (rtnl_mutex){+.+.}, at: switchdev_deferred_process_work+0xa/0x20 net/switchdev/switchdev.c:150
3 locks held by kworker/u4:5/30319:
#0: 0000000091afc186 ((wq_completion)"cfg80211"){+.+.}, at: process_one_work+0x767/0x1570 kernel/workqueue.c:2124
#1: 00000000bd464d89 ((work_completion)(&(&rdev->dfs_update_channels_wk)->work)){+.+.}, at: process_one_work+0x79c/0x1570 kernel/workqueue.c:2128
#2: 00000000bb70f229 (rtnl_mutex){+.+.}, at: cfg80211_dfs_channels_update_work+0x98/0x5a0 net/wireless/mlme.c:777
1 lock held by syz-executor.4/10636:
#0: 00000000bb70f229 (rtnl_mutex){+.+.}, at: tun_detach drivers/net/tun.c:759 [inline]
#0: 00000000bb70f229 (rtnl_mutex){+.+.}, at: tun_chr_close+0x3a/0x180 drivers/net/tun.c:3323
2 locks held by syz-executor.4/10650:
#0: 00000000bb70f229 (rtnl_mutex){+.+.}, at: rtnl_lock net/core/rtnetlink.c:77 [inline]
#0: 00000000bb70f229 (rtnl_mutex){+.+.}, at: rtnetlink_rcv_msg+0x3fe/0xb80 net/core/rtnetlink.c:4779
#1: 00000000cf677677 (rcu_preempt_state.exp_mutex){+.+.}, at: exp_funnel_lock kernel/rcu/tree_exp.h:297 [inline]
#1: 00000000cf677677 (rcu_preempt_state.exp_mutex){+.+.}, at: _synchronize_rcu_expedited+0x4dc/0x6f0 kernel/rcu/tree_exp.h:667
3 locks held by kworker/1:5/10748:
#0: 00000000337e987b ((wq_completion)"%s"("ipv6_addrconf")){+.+.}, at: process_one_work+0x767/0x1570 kernel/workqueue.c:2124
#1: 0000000076d1eaa5 ((addr_chk_work).work){+.+.}, at: process_one_work+0x79c/0x1570 kernel/workqueue.c:2128
#2: 00000000bb70f229 (rtnl_mutex){+.+.}, at: addrconf_verify_work+0xa/0x20 net/ipv6/addrconf.c:4476
2 locks held by kworker/1:8/10813:
#0: 000000003c5cc6bc ((wq_completion)"rcu_gp"){+.+.}, at: process_one_work+0x767/0x1570 kernel/workqueue.c:2124
#1: 00000000b44c7949 ((work_completion)(&rew.rew_work)){+.+.}, at: process_one_work+0x79c/0x1570 kernel/workqueue.c:2128

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

NMI backtrace for cpu 0
CPU: 0 PID: 1554 Comm: khungtaskd Not tainted 4.19.208-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011
Call Trace:
__dump_stack lib/dump_stack.c:77 [inline]
dump_stack+0x1fc/0x2ef lib/dump_stack.c:118
nmi_cpu_backtrace.cold+0x63/0xa2 lib/nmi_backtrace.c:101
nmi_trigger_cpumask_backtrace+0x1a6/0x1f0 lib/nmi_backtrace.c:62
trigger_all_cpu_backtrace include/linux/nmi.h:146 [inline]
check_hung_uninterruptible_tasks kernel/hung_task.c:203 [inline]
watchdog+0x991/0xe60 kernel/hung_task.c:287
kthread+0x33f/0x460 kernel/kthread.c:259
ret_from_fork+0x24/0x30 arch/x86/entry/entry_64.S:415
Sending NMI from CPU 0 to CPUs 1:
NMI backtrace for cpu 1
CPU: 1 PID: 4689 Comm: systemd-journal Not tainted 4.19.208-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011
RIP: 0010:__sanitizer_cov_trace_pc+0x0/0x50 kernel/kcov.c:97
Code: ff 48 89 df e8 11 db 35 00 e9 ab fe ff ff 4c 89 ef e8 04 db 35 00 e9 23 fe ff ff 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 <48> 8b 34 24 65 48 8b 04 25 c0 df 01 00 65 8b 15 1c 5b 9f 7e 81 e2
RSP: 0018:ffff8880a0d0fa30 EFLAGS: 00000086
RAX: 0000000000000000 RBX: ffff888055a32c40 RCX: ffffffff812b5e78
RDX: 0000000055a32c40 RSI: ffff8880a0d004c0 RDI: 0000000000000006
RBP: ffff8880d5a32c40 R08: ffff8880a0d0fac8 R09: ffff8880d5a32c40
R10: 0000000000000006 R11: 0000000000000000 R12: 0000000055a32c40
R13: ffff8880a0d0fac8 R14: 0000000000000004 R15: ffff88813be79b00
FS: 00007f58e765d8c0(0000) GS:ffff8880ba100000(0000) knlGS:0000000000000000
CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 00007f58e4dc7000 CR3: 00000000a0d52000 CR4: 00000000003426e0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
Call Trace:
phys_addr_valid arch/x86/mm/physaddr.h:7 [inline]
__phys_addr+0x52/0x110 arch/x86/mm/physaddr.c:27
virt_to_head_page include/linux/mm.h:665 [inline]
free_block+0xa0/0x230 mm/slab.c:3420
cache_flusharray mm/slab.c:3474 [inline]
___cache_free+0x27e/0x3a0 mm/slab.c:3532
qlink_free mm/kasan/quarantine.c:147 [inline]
qlist_free_all+0x79/0x140 mm/kasan/quarantine.c:166
quarantine_reduce+0x1a9/0x230 mm/kasan/quarantine.c:259
kasan_kmalloc+0xa2/0x160 mm/kasan/kasan.c:538
slab_post_alloc_hook mm/slab.h:445 [inline]
slab_alloc mm/slab.c:3397 [inline]
kmem_cache_alloc+0x110/0x370 mm/slab.c:3557
getname_flags+0xce/0x590 fs/namei.c:140
do_sys_open+0x26c/0x520 fs/open.c:1079
do_syscall_64+0xf9/0x620 arch/x86/entry/common.c:293
entry_SYSCALL_64_after_hwframe+0x49/0xbe
RIP: 0033:0x7f58e6bec840
Code: 73 01 c3 48 8b 0d 68 77 20 00 f7 d8 64 89 01 48 83 c8 ff c3 66 0f 1f 44 00 00 83 3d 89 bb 20 00 00 75 10 b8 02 00 00 00 0f 05 <48> 3d 01 f0 ff ff 73 31 c3 48 83 ec 08 e8 1e f6 ff ff 48 89 04 24
RSP: 002b:00007ffd3fc2bf98 EFLAGS: 00000246 ORIG_RAX: 0000000000000002
RAX: ffffffffffffffda RBX: 00007ffd3fc2c2a0 RCX: 00007f58e6bec840
RDX: 00000000000001a0 RSI: 0000000000080042 RDI: 0000556b65c400b0
RBP: 000000000000000d R08: 000000000000c0c1 R09: 00000000ffffffff
R10: 0000000000000069 R11: 0000000000000246 R12: 00000000ffffffff
R13: 0000556b65c34040 R14: 00007ffd3fc2c260 R15: 0000556b65c3fed0
----------------
Code disassembly (best guess), 1 bytes skipped:
0: 48 89 df mov %rbx,%rdi
3: e8 11 db 35 00 callq 0x35db19
8: e9 ab fe ff ff jmpq 0xfffffeb8
d: 4c 89 ef mov %r13,%rdi
10: e8 04 db 35 00 callq 0x35db19
15: e9 23 fe ff ff jmpq 0xfffffe3d
1a: 90 nop
1b: 90 nop
1c: 90 nop
1d: 90 nop
1e: 90 nop
1f: 90 nop
20: 90 nop
21: 90 nop
22: 90 nop
23: 90 nop
24: 90 nop
25: 90 nop
26: 90 nop
27: 90 nop
28: 90 nop
* 29: 48 8b 34 24 mov (%rsp),%rsi <-- trapping instruction
2d: 65 48 8b 04 25 c0 df mov %gs:0x1dfc0,%rax
34: 01 00
36: 65 8b 15 1c 5b 9f 7e mov %gs:0x7e9f5b1c(%rip),%edx # 0x7e9f5b59
3d: 81 .byte 0x81
3e: e2 .byte 0xe2


---
This report is generated by a bot. It may contain errors.
See https://goo.gl/tpsmEJ for more information about syzbot.
syzbot engineers can be reached at syzk...@googlegroups.com.

syzbot will keep track of this issue. See:
https://goo.gl/tpsmEJ#status for how to communicate with syzbot.

syzbot

unread,
May 4, 2022, 5:03:15 AM5/4/22
to syzkaller...@googlegroups.com
Auto-closing this bug as obsolete.
Crashes did not happen for a while, no reproducer and no activity.
Reply all
Reply to author
Forward
0 new messages