syzbot


INFO: task hung in ipv6_route_ioctl (2)

Status: upstream: reported on 2023/01/28 02:21
Reported-by: syzbot+bf7c6406637722a401e0@syzkaller.appspotmail.com
First crash: 426d, last: 426d
Similar bugs (4)
Kernel Title Repro Cause bisect Fix bisect Count Last Reported Patched Status
linux-4.19 INFO: task hung in ipv6_route_ioctl 1 851d 851d 0/1 auto-closed as invalid on 2022/03/28 22:32
upstream INFO: task hung in ipv6_route_ioctl net 2 1268d 1269d 0/26 auto-closed as invalid on 2021/01/06 04:59
upstream INFO: task hung in ipv6_route_ioctl (2) net 1 1147d 1147d 0/26 auto-closed as invalid on 2021/05/07 00:43
upstream INFO: task hung in rtnetlink_rcv_msg net C inconclusive inconclusive 913 16d 1861d 0/26 upstream: reported C repro on 2019/02/22 17:00

Sample crash report:
Bluetooth: hci9: command 0x0409 tx timeout
ieee802154 phy0 wpan0: encryption failed: -22
ieee802154 phy1 wpan1: encryption failed: -22
INFO: task syz-executor.1:21017 blocked for more than 140 seconds.
      Not tainted 4.19.211-syzkaller #0
"echo 0 > /proc/sys/kernel/hung_task_timeout_secs" disables this message.
syz-executor.1  D29456 21017   8162 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
 ipv6_route_ioctl+0x21a/0x2f0 net/ipv6/route.c:3725
 inet6_ioctl+0x104/0x1b0 net/ipv6/af_inet6.c:559
 sock_do_ioctl+0xce/0x300 net/socket.c:1015
 sock_ioctl+0x2ef/0x5d0 net/socket.c:1135
 vfs_ioctl fs/ioctl.c:46 [inline]
 file_ioctl fs/ioctl.c:501 [inline]
 do_vfs_ioctl+0xcdb/0x12e0 fs/ioctl.c:688
 ksys_ioctl+0x9b/0xc0 fs/ioctl.c:705
 __do_sys_ioctl fs/ioctl.c:712 [inline]
 __se_sys_ioctl fs/ioctl.c:710 [inline]
 __x64_sys_ioctl+0x6f/0xb0 fs/ioctl.c:710
 do_syscall_64+0xf9/0x620 arch/x86/entry/common.c:293
 entry_SYSCALL_64_after_hwframe+0x49/0xbe
RIP: 0033:0x7f61065c80c9
Code: Bad RIP value.
RSP: 002b:00007f6104b3a168 EFLAGS: 00000246 ORIG_RAX: 0000000000000010
RAX: ffffffffffffffda RBX: 00007f61066e7f80 RCX: 00007f61065c80c9
RDX: 00000000200001c0 RSI: 000000000000890b RDI: 0000000000000004
RBP: 00007f6106623ae9 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000
R13: 00007ffe7edc4a7f R14: 00007f6104b3a300 R15: 0000000000022000
INFO: task syz-executor.1:21025 blocked for more than 140 seconds.
      Not tainted 4.19.211-syzkaller #0
"echo 0 > /proc/sys/kernel/hung_task_timeout_secs" disables this message.
syz-executor.1  D29456 21025   8162 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
 ipv6_route_ioctl+0x21a/0x2f0 net/ipv6/route.c:3725
 inet6_ioctl+0x104/0x1b0 net/ipv6/af_inet6.c:559
 sock_do_ioctl+0xce/0x300 net/socket.c:1015
 sock_ioctl+0x2ef/0x5d0 net/socket.c:1135
 vfs_ioctl fs/ioctl.c:46 [inline]
 file_ioctl fs/ioctl.c:501 [inline]
 do_vfs_ioctl+0xcdb/0x12e0 fs/ioctl.c:688
 ksys_ioctl+0x9b/0xc0 fs/ioctl.c:705
 __do_sys_ioctl fs/ioctl.c:712 [inline]
 __se_sys_ioctl fs/ioctl.c:710 [inline]
 __x64_sys_ioctl+0x6f/0xb0 fs/ioctl.c:710
 do_syscall_64+0xf9/0x620 arch/x86/entry/common.c:293
 entry_SYSCALL_64_after_hwframe+0x49/0xbe
RIP: 0033:0x7f61065c80c9
Code: Bad RIP value.
RSP: 002b:00007f6104b19168 EFLAGS: 00000246 ORIG_RAX: 0000000000000010
RAX: ffffffffffffffda RBX: 00007f61066e8050 RCX: 00007f61065c80c9
RDX: 00000000200001c0 RSI: 000000000000890b RDI: 0000000000000005
RBP: 00007f6106623ae9 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000
R13: 00007ffe7edc4a7f R14: 00007f6104b19300 R15: 0000000000022000

Showing all locks held in the system:
1 lock held by khungtaskd/1570:
 #0: 000000004ed72124 (rcu_read_lock){....}, at: debug_show_all_locks+0x53/0x265 kernel/locking/lockdep.c:4441
4 locks held by kworker/u4:4/2889:
1 lock held by systemd-journal/4683:
1 lock held by systemd-udevd/4699:
2 locks held by in:imklog/7814:
1 lock held by syz-fuzzer/8117:
3 locks held by syz-fuzzer/8190:
4 locks held by kworker/u4:0/8250:
 #0: 00000000c406f6bf ((wq_completion)"%s"wiphy_name(local->hw.wiphy)){+.+.}, at: process_one_work+0x767/0x1570 kernel/workqueue.c:2124
 #1: 000000000586938d ((work_completion)(&sdata->work)){+.+.}, at: process_one_work+0x79c/0x1570 kernel/workqueue.c:2128
 #2: 000000002502422e (&wdev->mtx){+.+.}, at: sdata_lock net/mac80211/ieee80211_i.h:977 [inline]
 #2: 000000002502422e (&wdev->mtx){+.+.}, at: ieee80211_ibss_work+0x85/0xe10 net/mac80211/ibss.c:1675
 #3: 00000000afa741c4 (&local->sta_mtx){+.+.}, at: ieee80211_ibss_sta_expire net/mac80211/ibss.c:1261 [inline]
 #3: 00000000afa741c4 (&local->sta_mtx){+.+.}, at: ieee80211_sta_merge_ibss net/mac80211/ibss.c:1297 [inline]
 #3: 00000000afa741c4 (&local->sta_mtx){+.+.}, at: ieee80211_ibss_work+0x8d3/0xe10 net/mac80211/ibss.c:1703
2 locks held by syz-executor.3/1089:
 #0: 0000000002b00bed (&sb->s_type->i_mutex_key#13){+.+.}, at: inode_lock include/linux/fs.h:748 [inline]
 #0: 0000000002b00bed (&sb->s_type->i_mutex_key#13){+.+.}, at: __sock_release+0x86/0x2a0 net/socket.c:598
 #1: 0000000008684e3d (rcu_preempt_state.exp_mutex){+.+.}, at: exp_funnel_lock kernel/rcu/tree_exp.h:329 [inline]
 #1: 0000000008684e3d (rcu_preempt_state.exp_mutex){+.+.}, at: _synchronize_rcu_expedited+0x256/0x6f0 kernel/rcu/tree_exp.h:667
1 lock held by syz-executor.3/1125:
 #0: 000000004e889f3b (&sb->s_type->i_mutex_key#13){+.+.}, at: inode_lock include/linux/fs.h:748 [inline]
 #0: 000000004e889f3b (&sb->s_type->i_mutex_key#13){+.+.}, at: __sock_release+0x86/0x2a0 net/socket.c:598
1 lock held by syz-executor.4/9145:
 #0: 0000000016ba35ac (&sb->s_type->i_mutex_key#13){+.+.}, at: inode_lock include/linux/fs.h:748 [inline]
 #0: 0000000016ba35ac (&sb->s_type->i_mutex_key#13){+.+.}, at: __sock_release+0x86/0x2a0 net/socket.c:598
1 lock held by syz-executor.4/9163:
 #0: 00000000f9238933 (&sb->s_type->i_mutex_key#13){+.+.}, at: inode_lock include/linux/fs.h:748 [inline]
 #0: 00000000f9238933 (&sb->s_type->i_mutex_key#13){+.+.}, at: __sock_release+0x86/0x2a0 net/socket.c:598
1 lock held by syz-executor.4/9269:
 #0: 00000000832f7d96 (&sb->s_type->i_mutex_key#13){+.+.}, at: inode_lock include/linux/fs.h:748 [inline]
 #0: 00000000832f7d96 (&sb->s_type->i_mutex_key#13){+.+.}, at: __sock_release+0x86/0x2a0 net/socket.c:598
2 locks held by kworker/0:5/15978:
4 locks held by syz-executor.2/20094:
 #0: 00000000887de6d4 (&hdev->req_lock){+.+.}, at: hci_dev_do_close+0x122/0x1020 net/bluetooth/hci_core.c:1629
 #1: 000000002894aac9 (&hdev->lock){+.+.}, at: hci_dev_do_close+0x343/0x1020 net/bluetooth/hci_core.c:1674
 #2: 00000000d4288b4b (hci_cb_list_lock){+.+.}, at: hci_disconn_cfm include/net/bluetooth/hci_core.h:1260 [inline]
 #2: 00000000d4288b4b (hci_cb_list_lock){+.+.}, at: hci_conn_hash_flush+0xda/0x260 net/bluetooth/hci_conn.c:1512
 #3: 0000000008684e3d (rcu_preempt_state.exp_mutex){+.+.}, at: exp_funnel_lock kernel/rcu/tree_exp.h:329 [inline]
 #3: 0000000008684e3d (rcu_preempt_state.exp_mutex){+.+.}, at: _synchronize_rcu_expedited+0x256/0x6f0 kernel/rcu/tree_exp.h:667
2 locks held by syz-executor.3/21012:
1 lock held by syz-executor.1/21017:
 #0: 00000000f2d7fd3f (rtnl_mutex){+.+.}, at: ipv6_route_ioctl+0x21a/0x2f0 net/ipv6/route.c:3725
1 lock held by syz-executor.1/21025:
 #0: 00000000f2d7fd3f (rtnl_mutex){+.+.}, at: ipv6_route_ioctl+0x21a/0x2f0 net/ipv6/route.c:3725
2 locks held by syz-executor.4/21014:
2 locks held by syz-executor.5/21033:
 #0: 000000005802fae5 (pernet_ops_rwsem){++++}, at: copy_net_ns+0x1d8/0x340 net/core/net_namespace.c:435
 #1: 00000000f2d7fd3f (rtnl_mutex){+.+.}, at: gtp_net_exit+0x1ba/0x380 drivers/net/gtp.c:1360
1 lock held by syz-executor.3/21041:
 #0: 00000000f2d7fd3f (rtnl_mutex){+.+.}, at: rtnl_lock net/core/rtnetlink.c:77 [inline]
 #0: 00000000f2d7fd3f (rtnl_mutex){+.+.}, at: rtnetlink_rcv_msg+0x3fe/0xb80 net/core/rtnetlink.c:4779
4 locks held by kworker/u5:0/21046:
 #0: 000000003e916877 ((wq_completion)"%s"hdev->name#2){+.+.}, at: process_one_work+0x767/0x1570 kernel/workqueue.c:2124
 #1: 0000000002bf35fe ((work_completion)(&hdev->rx_work)){+.+.}, at: process_one_work+0x79c/0x1570 kernel/workqueue.c:2128
 #2: 00000000e4331124 (&hdev->lock){+.+.}, at: hci_remote_features_evt net/bluetooth/hci_event.c:2976 [inline]
 #2: 00000000e4331124 (&hdev->lock){+.+.}, at: hci_event_packet+0x2a9d/0x7e20 net/bluetooth/hci_event.c:5853
 #3: 00000000d4288b4b (hci_cb_list_lock){+.+.}, at: hci_connect_cfm include/net/bluetooth/hci_core.h:1245 [inline]
 #3: 00000000d4288b4b (hci_cb_list_lock){+.+.}, at: hci_remote_features_evt net/bluetooth/hci_event.c:3009 [inline]
 #3: 00000000d4288b4b (hci_cb_list_lock){+.+.}, at: hci_event_packet+0x5c8b/0x7e20 net/bluetooth/hci_event.c:5853
1 lock held by syz-executor.5/21051:
 #0: 00000000f2d7fd3f (rtnl_mutex){+.+.}, at: rtnl_lock net/core/rtnetlink.c:77 [inline]
 #0: 00000000f2d7fd3f (rtnl_mutex){+.+.}, at: rtnetlink_rcv_msg+0x3fe/0xb80 net/core/rtnetlink.c:4779
2 locks held by syz-executor.4/21057:
1 lock held by syz-executor.2/21061:
 #0: 00000000f2d7fd3f (rtnl_mutex){+.+.}, at: rtnl_lock net/core/rtnetlink.c:77 [inline]
 #0: 00000000f2d7fd3f (rtnl_mutex){+.+.}, at: rtnetlink_rcv_msg+0x3fe/0xb80 net/core/rtnetlink.c:4779
1 lock held by syz-executor.1/21069:
 #0: 00000000f2d7fd3f (rtnl_mutex){+.+.}, at: rtnl_lock net/core/rtnetlink.c:77 [inline]
 #0: 00000000f2d7fd3f (rtnl_mutex){+.+.}, at: rtnetlink_rcv_msg+0x3fe/0xb80 net/core/rtnetlink.c:4779
4 locks held by kworker/u5:2/21074:
 #0: 000000002f3e1bed ((wq_completion)"%s"hdev->name#2){+.+.}, at: process_one_work+0x767/0x1570 kernel/workqueue.c:2124
 #1: 00000000337558bc ((work_completion)(&hdev->rx_work)){+.+.}, at: process_one_work+0x79c/0x1570 kernel/workqueue.c:2128
 #2: 0000000026ce6186 (&hdev->lock){+.+.}, at: hci_remote_features_evt net/bluetooth/hci_event.c:2976 [inline]
 #2: 0000000026ce6186 (&hdev->lock){+.+.}, at: hci_event_packet+0x2a9d/0x7e20 net/bluetooth/hci_event.c:5853
 #3: 00000000d4288b4b (hci_cb_list_lock){+.+.}, at: hci_connect_cfm include/net/bluetooth/hci_core.h:1245 [inline]
 #3: 00000000d4288b4b (hci_cb_list_lock){+.+.}, at: hci_remote_features_evt net/bluetooth/hci_event.c:3009 [inline]
 #3: 00000000d4288b4b (hci_cb_list_lock){+.+.}, at: hci_event_packet+0x5c8b/0x7e20 net/bluetooth/hci_event.c:5853

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

NMI backtrace for cpu 1
CPU: 1 PID: 1570 Comm: khungtaskd Not tainted 4.19.211-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/12/2023
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 1 to CPUs 0:
NMI backtrace for cpu 0
CPU: 0 PID: 15978 Comm: kworker/0:5 Not tainted 4.19.211-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/12/2023
Workqueue: events iterate_cleanup_work
RIP: 0010:should_fail_alloc_page mm/page_alloc.c:3078 [inline]
RIP: 0010:prepare_alloc_pages mm/page_alloc.c:4346 [inline]
RIP: 0010:__alloc_pages_nodemask+0x1df/0x2890 mm/page_alloc.c:4393
Code: ff ff 44 89 f7 e8 c1 30 ff ff 44 89 f0 25 00 00 20 00 89 85 54 fe ff ff 0f 85 ad 03 00 00 8b 85 94 fe ff ff 3b 05 cd ff 7f 08 <0f> 82 05 01 00 00 8b 85 84 fe ff ff f6 c4 08 0f 85 f6 00 00 00 80
RSP: 0018:ffff8880ba007a08 EFLAGS: 00000046
RAX: 0000000000000000 RBX: 0000000000000000 RCX: 000000000000e8e8
RDX: 0000000000000000 RSI: 00000000000c4220 RDI: ffff888094496124
RBP: ffff8880ba007c20 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000005 R11: 0000000000000000 R12: 0000000000000001
R13: 00000000000c4220 R14: 00000000000c4220 R15: ffff88823b33a540
FS:  0000000000000000(0000) GS:ffff8880ba000000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 00007fc8225ccac3 CR3: 000000009c3bd000 CR4: 00000000003406f0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000600
Call Trace:
 <IRQ>
 __alloc_pages include/linux/gfp.h:496 [inline]
 __alloc_pages_node include/linux/gfp.h:509 [inline]
 kmem_getpages mm/slab.c:1412 [inline]
 cache_grow_begin+0xa4/0x8a0 mm/slab.c:2682
 cache_alloc_refill+0x273/0x340 mm/slab.c:3049
 ____cache_alloc mm/slab.c:3132 [inline]
 slab_alloc_node mm/slab.c:3327 [inline]
 kmem_cache_alloc_node+0x39e/0x3b0 mm/slab.c:3647
 __alloc_skb+0x71/0x560 net/core/skbuff.c:193
 alloc_skb include/linux/skbuff.h:995 [inline]
 bcm_can_tx+0x259/0x800 net/can/bcm.c:287
 bcm_tx_timeout_tsklet+0x1f0/0x3a0 net/can/bcm.c:414
 tasklet_action_common.constprop.0+0x265/0x360 kernel/softirq.c:522
 __do_softirq+0x265/0x980 kernel/softirq.c:292
 do_softirq_own_stack+0x2a/0x40 arch/x86/entry/entry_64.S:1092
 </IRQ>
 do_softirq.part.0+0x160/0x1c0 kernel/softirq.c:336
 do_softirq kernel/softirq.c:328 [inline]
 __local_bh_enable_ip+0x20e/0x270 kernel/softirq.c:189
 local_bh_enable include/linux/bottom_half.h:32 [inline]
 get_next_corpse net/netfilter/nf_conntrack_core.c:1907 [inline]
 nf_ct_iterate_cleanup+0x239/0x520 net/netfilter/nf_conntrack_core.c:1930
 nf_ct_iterate_cleanup_net net/netfilter/nf_conntrack_core.c:2015 [inline]
 nf_ct_iterate_cleanup_net+0x113/0x170 net/netfilter/nf_conntrack_core.c:2000
 iterate_cleanup_work+0x43/0xd0 net/ipv6/netfilter/nf_nat_masquerade_ipv6.c:113
 process_one_work+0x864/0x1570 kernel/workqueue.c:2153
 worker_thread+0x64c/0x1130 kernel/workqueue.c:2296
 kthread+0x33f/0x460 kernel/kthread.c:259
 ret_from_fork+0x24/0x30 arch/x86/entry/entry_64.S:415

Crashes (1):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2023/01/28 02:21 linux-4.19.y 3f8a27f9e27b 9dfcf09c .config console log report info [disk image] [vmlinux] ci2-linux-4-19 INFO: task hung in ipv6_route_ioctl
* Struck through repros no longer work on HEAD.