syzbot


INFO: task hung in uevent_store

Status: upstream: reported on 2023/01/11 08:32
Reported-by: syzbot+ea1129eab1b2fdee7a84@syzkaller.appspotmail.com
First crash: 658d, last: 658d

Sample crash report:
ieee802154 phy0 wpan0: encryption failed: -22
ieee802154 phy1 wpan1: encryption failed: -22
INFO: task systemd-udevd:4696 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.
systemd-udevd   D24600  4696      1 0x00000100
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
 kobject_uevent_env+0x85d/0x1480 lib/kobject_uevent.c:584
 kobject_synth_uevent+0x700/0x820 lib/kobject_uevent.c:208
 uevent_store+0x21/0x70 drivers/base/core.c:1257
 dev_attr_store+0x56/0x80 drivers/base/core.c:966
 sysfs_kf_write+0x110/0x160 fs/sysfs/file.c:140
 kernfs_fop_write+0x2b0/0x470 fs/kernfs/file.c:316
 __vfs_write+0xf7/0x770 fs/read_write.c:485
 vfs_write+0x1f3/0x540 fs/read_write.c:549
 ksys_write+0x12b/0x2a0 fs/read_write.c:599
 do_syscall_64+0xf9/0x620 arch/x86/entry/common.c:293
 entry_SYSCALL_64_after_hwframe+0x49/0xbe
RIP: 0033:0x7ff1fdd59970
Code: Bad RIP value.
RSP: 002b:00007ffddfa3bd18 EFLAGS: 00000246 ORIG_RAX: 0000000000000001
RAX: ffffffffffffffda RBX: 0000000000000007 RCX: 00007ff1fdd59970
RDX: 0000000000000007 RSI: 000055650ce73900 RDI: 000000000000000e
RBP: 000055650ce73900 R08: 000055650ce6ce10 R09: 00007ff1feee78c0
R10: 000055650ce6dc00 R11: 0000000000000246 R12: 0000000000000007
R13: 0000000000000001 R14: 000055650ce6cd30 R15: 0000000000000007
INFO: task syz-executor.4:3531 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.4  D29592  3531   2016 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
 uevent_net_init+0x202/0x320 lib/kobject_uevent.c:780
 ops_init+0xb3/0x410 net/core/net_namespace.c:129
 setup_net+0x2c2/0x720 net/core/net_namespace.c:316
 copy_net_ns+0x1f7/0x340 net/core/net_namespace.c:439
 create_new_namespaces+0x3f6/0x7b0 kernel/nsproxy.c:107
 unshare_nsproxy_namespaces+0xbd/0x1f0 kernel/nsproxy.c:206
 ksys_unshare+0x36c/0x9a0 kernel/fork.c:2542
 __do_sys_unshare kernel/fork.c:2610 [inline]
 __se_sys_unshare kernel/fork.c:2608 [inline]
 __x64_sys_unshare+0x2d/0x40 kernel/fork.c:2608
 do_syscall_64+0xf9/0x620 arch/x86/entry/common.c:293
 entry_SYSCALL_64_after_hwframe+0x49/0xbe
RIP: 0033:0x7fdfa063d0c9
Code: Bad RIP value.
RSP: 002b:00007fdf9ebaf168 EFLAGS: 00000246 ORIG_RAX: 0000000000000110
RAX: ffffffffffffffda RBX: 00007fdfa075cf80 RCX: 00007fdfa063d0c9
RDX: 0000000000000000 RSI: 0000000000000000 RDI: 0000000040000000
RBP: 00007fdfa0698ae9 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000
R13: 00007ffe74d9863f R14: 00007fdf9ebaf300 R15: 0000000000022000

Showing all locks held in the system:
1 lock held by khungtaskd/1570:
 #0: 0000000024f9e279 (rcu_read_lock){....}, at: debug_show_all_locks+0x53/0x265 kernel/locking/lockdep.c:4441
1 lock held by systemd-journal/4685:
4 locks held by systemd-udevd/4696:
 #0: 000000005ee4e1f4 (sb_writers#5){.+.+}, at: file_start_write include/linux/fs.h:2779 [inline]
 #0: 000000005ee4e1f4 (sb_writers#5){.+.+}, at: vfs_write+0x463/0x540 fs/read_write.c:548
 #1: 00000000a3219010 (&of->mutex){+.+.}, at: kernfs_fop_write+0x200/0x470 fs/kernfs/file.c:307
 #2: 00000000691fb638 (kn->count#2){++++}, at: kernfs_fop_write+0x223/0x470 fs/kernfs/file.c:308
 #3: 000000008f087dad (uevent_sock_mutex){+.+.}, at: kobject_uevent_env+0x85d/0x1480 lib/kobject_uevent.c:584
3 locks held by syz-executor.1/24617:
 #0: 00000000ea458132 (&hdev->req_lock){+.+.}, at: hci_dev_do_close+0x122/0x1020 net/bluetooth/hci_core.c:1629
 #1: 00000000b4a7dd4d (&hdev->lock){+.+.}, at: hci_dev_do_close+0x343/0x1020 net/bluetooth/hci_core.c:1674
 #2: 000000008f087dad (uevent_sock_mutex){+.+.}, at: kobject_uevent_env+0x85d/0x1480 lib/kobject_uevent.c:584
4 locks held by syz-executor.4/25804:
3 locks held by kworker/u4:0/32160:
2 locks held by syz-executor.5/1982:
2 locks held by syz-executor.4/3531:
 #0: 00000000654b8037 (pernet_ops_rwsem){++++}, at: copy_net_ns+0x1d8/0x340 net/core/net_namespace.c:435
 #1: 000000008f087dad (uevent_sock_mutex){+.+.}, at: uevent_net_init+0x202/0x320 lib/kobject_uevent.c:780
2 locks held by syz-executor.1/3569:
 #0: 00000000271ffbb6 (&data->open_mutex){+.+.}, at: vhci_create_device drivers/bluetooth/hci_vhci.c:162 [inline]
 #0: 00000000271ffbb6 (&data->open_mutex){+.+.}, at: vhci_get_user drivers/bluetooth/hci_vhci.c:219 [inline]
 #0: 00000000271ffbb6 (&data->open_mutex){+.+.}, at: vhci_write+0x2b0/0x450 drivers/bluetooth/hci_vhci.c:299
 #1: 000000008f087dad (uevent_sock_mutex){+.+.}, at: kobject_uevent_env+0x85d/0x1480 lib/kobject_uevent.c:584
4 locks held by syz-executor.4/3570:
2 locks held by syz-executor.1/3572:
 #0: 000000002c0a3c76 (&data->open_mutex){+.+.}, at: vhci_create_device drivers/bluetooth/hci_vhci.c:162 [inline]
 #0: 000000002c0a3c76 (&data->open_mutex){+.+.}, at: vhci_get_user drivers/bluetooth/hci_vhci.c:219 [inline]
 #0: 000000002c0a3c76 (&data->open_mutex){+.+.}, at: vhci_write+0x2b0/0x450 drivers/bluetooth/hci_vhci.c:299
 #1: 000000008f087dad (uevent_sock_mutex){+.+.}, at: kobject_uevent_env+0x85d/0x1480 lib/kobject_uevent.c:584

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

NMI backtrace for cpu 0
CPU: 0 PID: 1570 Comm: khungtaskd Not tainted 4.19.211-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 10/26/2022
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: 32160 Comm: kworker/u4:0 Not tainted 4.19.211-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 10/26/2022
Workqueue: bat_events batadv_purge_orig
RIP: 0010:get_current arch/x86/include/asm/current.h:15 [inline]
RIP: 0010:__sanitizer_cov_trace_pc+0x4/0x50 kernel/kcov.c:100
Code: e8 11 dd 35 00 e9 ab fe ff ff 4c 89 ef e8 04 dd 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 cc 59 9f 7e 81 e2 00 01 1f 00
RSP: 0018:ffff8880ba107df8 EFLAGS: 00000086
RAX: 1ffffffff13e3053 RBX: ffff8880ba12c4c8 RCX: 1ffff110126e2d7a
RDX: 0000000000000000 RSI: ffffffff86772f87 RDI: ffff888093716b84
RBP: 0000000000000000 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000000 R12: dffffc0000000000
R13: 0000000000000001 R14: 0000000000000040 R15: ffff8880ba12c490
FS:  0000000000000000(0000) GS:ffff8880ba100000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 000000c00076b898 CR3: 000000009bc20000 CR4: 00000000003406e0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
Call Trace:
 <IRQ>
 arch_local_irq_enable arch/x86/include/asm/paravirt.h:799 [inline]
 process_backlog+0x487/0x700 net/core/dev.c:5875
 napi_poll net/core/dev.c:6280 [inline]
 net_rx_action+0x4ac/0xfb0 net/core/dev.c:6346
 __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
 spin_unlock_bh include/linux/spinlock.h:374 [inline]
 batadv_purge_orig_ref+0xa2c/0x1110 net/batman-adv/originator.c:1379
 batadv_purge_orig+0x17/0x60 net/batman-adv/originator.c:1392
 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/11 08:31 linux-4.19.y 3f8a27f9e27b 48bc529a .config console log report info [disk image] [vmlinux] ci2-linux-4-19 INFO: task hung in uevent_store
* Struck through repros no longer work on HEAD.