syzbot


INFO: task hung in netlink_dump

Status: auto-closed as invalid on 2021/12/07 11:04
Reported-by: syzbot+@syzkaller.appspotmail.com
First crash: 446d, last: 446d
similar bugs (1):
Kernel Title Repro Cause bisect Fix bisect Count Last Reported Patched Status
upstream INFO: task hung in netlink_dump (2) 2 275d 276d 0/24 auto-closed as invalid on 2022/05/26 21:32

Sample crash report:
INFO: task syz-executor.5:1507 blocked for more than 143 seconds.
      Not tainted 5.14.0-syzkaller #0
"echo 0 > /proc/sys/kernel/hung_task_timeout_secs" disables this message.
task:syz-executor.5  state:D stack:23856 pid: 1507 ppid:  8816 flags:0x00004004
Call Trace:
 context_switch kernel/sched/core.c:4940 [inline]
 __schedule+0xc8d/0x1270 kernel/sched/core.c:6287
 schedule+0x14b/0x210 kernel/sched/core.c:6366
 schedule_preempt_disabled+0xf/0x20 kernel/sched/core.c:6425
 __mutex_lock_common+0xdff/0x2550 kernel/locking/mutex.c:669
 __mutex_lock kernel/locking/mutex.c:729 [inline]
 mutex_lock_nested+0x1a/0x20 kernel/locking/mutex.c:743
 netlink_dump+0xd0/0xc30 net/netlink/af_netlink.c:2233
 netlink_recvmsg+0x6fd/0x11a0 net/netlink/af_netlink.c:2012
 sock_recvmsg_nosec net/socket.c:944 [inline]
 ____sys_recvmsg+0x51d/0x5e0 net/socket.c:2626
 ___sys_recvmsg net/socket.c:2670 [inline]
 do_recvmmsg+0x6e4/0x1680 net/socket.c:2764
 __sys_recvmmsg net/socket.c:2845 [inline]
 __do_sys_recvmmsg net/socket.c:2866 [inline]
 __se_sys_recvmmsg net/socket.c:2859 [inline]
 __x64_sys_recvmmsg+0x1b4/0x240 net/socket.c:2859
 do_syscall_x64 arch/x86/entry/common.c:50 [inline]
 do_syscall_64+0x44/0xd0 arch/x86/entry/common.c:80
 entry_SYSCALL_64_after_hwframe+0x44/0xae
RIP: 0033:0x4665f9
RSP: 002b:00007f6081018188 EFLAGS: 00000246 ORIG_RAX: 000000000000012b
RAX: ffffffffffffffda RBX: 000000000056bf80 RCX: 00000000004665f9
RDX: 00000000000003a4 RSI: 00000000200020c0 RDI: 0000000000000004
RBP: 00000000004bfcc4 R08: 0000000020000000 R09: 0000000000000000
R10: 0000000000000a3c R11: 0000000000000246 R12: 000000000056bf80
R13: 00007ffdc44478ef R14: 00007f6081018300 R15: 0000000000022000

Showing all locks held in the system:
3 locks held by kworker/1:0/20:
 #0: ffff888028473d38 ((wq_completion)ipv6_addrconf){+.+.}-{0:0}, at: process_one_work+0x7ca/0x1140
 #1: ffffc90000da7d20 ((addr_chk_work).work){+.+.}-{0:0}, at: process_one_work+0x808/0x1140 kernel/workqueue.c:2272
 #2: ffffffff8d95b588 (rtnl_mutex){+.+.}-{3:3}, at: addrconf_verify_work+0xa/0x20 net/ipv6/addrconf.c:4590
1 lock held by khungtaskd/1649:
 #0: ffffffff8c91bfc0 (rcu_read_lock){....}-{1:2}, at: rcu_lock_acquire+0x0/0x30
3 locks held by kworker/0:2/2937:
 #0: ffff888011064d38 ((wq_completion)events){+.+.}-{0:0}, at: process_one_work+0x7ca/0x1140
 #1: ffffc90001aefd20 (deferred_process_work){+.+.}-{0:0}, at: process_one_work+0x808/0x1140 kernel/workqueue.c:2272
 #2: ffffffff8d95b588 (rtnl_mutex){+.+.}-{3:3}, at: switchdev_deferred_process_work+0xa/0x20 net/switchdev/switchdev.c:74
1 lock held by in:imklog/8109:
 #0: ffff888017eb7c70 (&f->f_pos_lock){+.+.}-{3:3}, at: __fdget_pos+0x24e/0x2f0 fs/file.c:990
2 locks held by agetty/8099:
 #0: ffff888020e83098 (&tty->ldisc_sem){++++}-{0:0}, at: tty_ldisc_ref_wait+0x21/0x70 drivers/tty/tty_ldisc.c:252
 #1: ffffc900011582e8 (&ldata->atomic_read_lock){+.+.}-{3:3}, at: n_tty_read+0x6c5/0x1c60 drivers/tty/n_tty.c:2113
3 locks held by kworker/0:7/10473:
 #0: ffff888011064d38 ((wq_completion)events){+.+.}-{0:0}, at: process_one_work+0x7ca/0x1140
 #1: ffffc900171d7d20 ((linkwatch_work).work){+.+.}-{0:0}, at: process_one_work+0x808/0x1140 kernel/workqueue.c:2272
 #2: ffffffff8d95b588 (rtnl_mutex){+.+.}-{3:3}, at: linkwatch_event+0xa/0x50 net/core/link_watch.c:251
2 locks held by syz-executor.1/1499:
1 lock held by syz-executor.5/1507:
 #0: ffffffff8d95b588 (rtnl_mutex){+.+.}-{3:3}, at: netlink_dump+0xd0/0xc30 net/netlink/af_netlink.c:2233

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

NMI backtrace for cpu 1
CPU: 1 PID: 1649 Comm: khungtaskd Not tainted 5.14.0-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011
Call Trace:
 __dump_stack lib/dump_stack.c:88 [inline]
 dump_stack_lvl+0x1dc/0x2d8 lib/dump_stack.c:105
 nmi_cpu_backtrace+0x45f/0x490 lib/nmi_backtrace.c:105
 nmi_trigger_cpumask_backtrace+0x16a/0x280 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+0xc54/0xca0 kernel/hung_task.c:295
 kthread+0x453/0x480 kernel/kthread.c:319
 ret_from_fork+0x1f/0x30
Sending NMI from CPU 1 to CPUs 0:
NMI backtrace for cpu 0
CPU: 0 PID: 1499 Comm: syz-executor.1 Not tainted 5.14.0-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011
RIP: 0010:lookup_chain_cache kernel/locking/lockdep.c:3683 [inline]
RIP: 0010:lookup_chain_cache_add kernel/locking/lockdep.c:3702 [inline]
RIP: 0010:validate_chain+0x1c3/0x8240 kernel/locking/lockdep.c:3757
Code: 83 c3 f8 75 15 eb 5a 48 8b 03 48 8d 58 f8 48 85 c0 48 0f 44 d8 48 85 db 74 47 4c 8d 7b 18 4c 89 f8 48 c1 e8 03 42 80 3c 20 00 <74> 08 4c 89 ff e8 63 d4 68 00 49 8b 07 4c 39 f0 74 1c 48 83 c3 08
RSP: 0018:ffffc90000007760 EFLAGS: 00000046
RAX: 1ffffffff1f1ba27 RBX: ffffffff8f8dd120 RCX: ffffffff8164e108
RDX: 0000000000000000 RSI: 0000000000000008 RDI: ffffffff8fd17dc8
RBP: ffffc90000007a70 R08: dffffc0000000000 R09: fffffbfff1fa2fba
R10: fffffbfff1fa2fba R11: 0000000000000000 R12: dffffc0000000000
R13: 1ffff92000000f0c R14: 032b1dd64ede7c81 R15: ffffffff8f8dd138
FS:  00007f869a73c700(0000) GS:ffff8880b9c00000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 0000556d7201caa8 CR3: 0000000027673000 CR4: 00000000001506f0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
Call Trace:
 <IRQ>
 __lock_acquire+0x1382/0x2b00 kernel/locking/lockdep.c:5015
 lock_acquire+0x19f/0x4d0 kernel/locking/lockdep.c:5625
 seqcount_lockdep_reader_access+0xfe/0x230 include/linux/seqlock.h:103
 ktime_get_update_offsets_now+0x45/0x460 kernel/time/timekeeping.c:2297
 hrtimer_update_base kernel/time/hrtimer.c:631 [inline]
 hrtimer_interrupt+0x143/0x1040 kernel/time/hrtimer.c:1793
 local_apic_timer_interrupt arch/x86/kernel/apic/apic.c:1086 [inline]
 __sysvec_apic_timer_interrupt+0xf9/0x270 arch/x86/kernel/apic/apic.c:1103
 sysvec_apic_timer_interrupt+0x8c/0xb0 arch/x86/kernel/apic/apic.c:1097
 </IRQ>
 asm_sysvec_apic_timer_interrupt+0x12/0x20
RIP: 0010:preempt_count arch/x86/include/asm/preempt.h:27 [inline]
RIP: 0010:__local_bh_disable_ip+0x149/0x200 kernel/softirq.c:326
Code: 3c 23 00 74 08 4c 89 f7 e8 c4 7c 7e 00 f6 44 24 41 02 0f 85 a7 00 00 00 f7 44 24 18 00 02 00 00 74 01 fb 65 8b 05 5f b6 b2 7e <25> ff ff ff 7f 44 39 f8 75 43 4c 8b 75 08 4c 89 f7 e8 a1 71 16 00
RSP: 0018:ffffc90002d26600 EFLAGS: 00000206
RAX: 0000000080000200 RBX: 1ffff920005a4cc8 RCX: ffffffff9092f803
RDX: ffffc900112da000 RSI: 0000000000000200 RDI: ffff88802294a610
RBP: ffffc90002d266d0 R08: dffffc0000000000 R09: fffffbfff1fa2fbd
R10: fffffbfff1fa2fbd R11: 0000000000000000 R12: dffffc0000000000
R13: 1ffff920005a4cc4 R14: ffffc90002d26640 R15: 0000000000000200
 get_next_corpse net/netfilter/nf_conntrack_core.c:2229 [inline]
 nf_ct_iterate_cleanup+0xf0/0x3f0 net/netfilter/nf_conntrack_core.c:2275
 nf_ct_iterate_cleanup_net+0x172/0x1e0 net/netfilter/nf_conntrack_core.c:2363
 masq_device_event+0x9b/0xd0 net/netfilter/nf_nat_masquerade.c:88
 notifier_call_chain kernel/notifier.c:83 [inline]
 raw_notifier_call_chain+0xe7/0x170 kernel/notifier.c:391
 __dev_notify_flags+0x306/0x5e0
 dev_change_flags+0xe3/0x190 net/core/dev.c:8833
 do_setlink+0xe12/0x4300 net/core/rtnetlink.c:2719
 rtnl_group_changelink net/core/rtnetlink.c:3242 [inline]
 __rtnl_newlink net/core/rtnetlink.c:3396 [inline]
 rtnl_newlink+0x1155/0x1d10 net/core/rtnetlink.c:3506
 rtnetlink_rcv_msg+0x934/0xe60 net/core/rtnetlink.c:5572
 netlink_rcv_skb+0x200/0x470 net/netlink/af_netlink.c:2504
 netlink_unicast_kernel net/netlink/af_netlink.c:1314 [inline]
 netlink_unicast+0x814/0x9f0 net/netlink/af_netlink.c:1340
 netlink_sendmsg+0xa29/0xe50 net/netlink/af_netlink.c:1929
 sock_sendmsg_nosec net/socket.c:704 [inline]
 sock_sendmsg net/socket.c:724 [inline]
 ____sys_sendmsg+0x5b9/0x910 net/socket.c:2409
 ___sys_sendmsg net/socket.c:2463 [inline]
 __sys_sendmsg+0x36f/0x450 net/socket.c:2492
 do_syscall_x64 arch/x86/entry/common.c:50 [inline]
 do_syscall_64+0x44/0xd0 arch/x86/entry/common.c:80
 entry_SYSCALL_64_after_hwframe+0x44/0xae
RIP: 0033:0x4665f9
Code: ff ff c3 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 40 00 48 89 f8 48 89 f7 48 89 d6 48 89 ca 4d 89 c2 4d 89 c8 4c 8b 4c 24 08 0f 05 <48> 3d 01 f0 ff ff 73 01 c3 48 c7 c1 bc ff ff ff f7 d8 64 89 01 48
RSP: 002b:00007f869a73c188 EFLAGS: 00000246 ORIG_RAX: 000000000000002e
RAX: ffffffffffffffda RBX: 000000000056c038 RCX: 00000000004665f9
RDX: 0000000000000000 RSI: 0000000020000140 RDI: 0000000000000007
RBP: 00000000004bfcc4 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000246 R12: 000000000056c038
R13: 00007ffc7d566d3f R14: 00007f869a73c300 R15: 0000000000022000
----------------
Code disassembly (best guess):
   0:	83 c3 f8             	add    $0xfffffff8,%ebx
   3:	75 15                	jne    0x1a
   5:	eb 5a                	jmp    0x61
   7:	48 8b 03             	mov    (%rbx),%rax
   a:	48 8d 58 f8          	lea    -0x8(%rax),%rbx
   e:	48 85 c0             	test   %rax,%rax
  11:	48 0f 44 d8          	cmove  %rax,%rbx
  15:	48 85 db             	test   %rbx,%rbx
  18:	74 47                	je     0x61
  1a:	4c 8d 7b 18          	lea    0x18(%rbx),%r15
  1e:	4c 89 f8             	mov    %r15,%rax
  21:	48 c1 e8 03          	shr    $0x3,%rax
  25:	42 80 3c 20 00       	cmpb   $0x0,(%rax,%r12,1)
* 2a:	74 08                	je     0x34 <-- trapping instruction
  2c:	4c 89 ff             	mov    %r15,%rdi
  2f:	e8 63 d4 68 00       	callq  0x68d497
  34:	49 8b 07             	mov    (%r15),%rax
  37:	4c 39 f0             	cmp    %r14,%rax
  3a:	74 1c                	je     0x58
  3c:	48 83 c3 08          	add    $0x8,%rbx

Crashes (1):
Manager Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Title
ci-upstream-kasan-gce-smack-root 2021/09/08 10:55 upstream ac08b1c68d1b e2776ee4 .config log report info INFO: task hung in netlink_dump
* Struck through repros no longer work on HEAD.