syzbot


INFO: task hung in add_early_randomness (3)

Status: auto-obsoleted due to no activity on 2023/08/22 21:25
Subsystems: crypto
[Documentation on labels]
First crash: 402d, last: 344d
Similar bugs (3)
Kernel Title Repro Cause bisect Fix bisect Count Last Reported Patched Status
upstream INFO: task hung in add_early_randomness crypto 1 857d 857d 0/26 closed as invalid on 2022/02/08 09:50
upstream INFO: task hung in add_early_randomness (2) usb crypto C done 182 481d 699d 22/26 fixed on 2023/02/24 13:50
linux-5.15 INFO: task hung in add_early_randomness 20 286d 412d 0/3 auto-obsoleted due to no activity on 2023/10/20 14:04

Sample crash report:
INFO: task kworker/0:8:5084 blocked for more than 143 seconds.
      Not tainted 6.4.0-rc3-syzkaller-00017-g9d646009f65d #0
"echo 0 > /proc/sys/kernel/hung_task_timeout_secs" disables this message.
task:kworker/0:8     state:D stack:22072 pid:5084  ppid:2      flags:0x00004000
Workqueue: usb_hub_wq hub_event
Call Trace:
 <TASK>
 context_switch kernel/sched/core.c:5343 [inline]
 __schedule+0x187b/0x4900 kernel/sched/core.c:6669
 schedule+0xc3/0x180 kernel/sched/core.c:6745
 schedule_preempt_disabled+0x13/0x20 kernel/sched/core.c:6804
 __mutex_lock_common+0xe33/0x2530 kernel/locking/mutex.c:679
 __mutex_lock kernel/locking/mutex.c:747 [inline]
 mutex_lock_nested+0x1b/0x20 kernel/locking/mutex.c:799
 add_early_randomness+0x1d/0x1a0 drivers/char/hw_random/core.c:69
 hwrng_register+0x3a4/0x440 drivers/char/hw_random/core.c:584
 chaoskey_probe+0x73b/0xae0 drivers/usb/misc/chaoskey.c:204
 usb_probe_interface+0x5c4/0xb00 drivers/usb/core/driver.c:396
 really_probe+0x294/0xc30 drivers/base/dd.c:658
 __driver_probe_device+0x1a2/0x3d0 drivers/base/dd.c:800
 driver_probe_device+0x50/0x420 drivers/base/dd.c:830
 __device_attach_driver+0x2d3/0x520 drivers/base/dd.c:958
 bus_for_each_drv+0x24a/0x2d0 drivers/base/bus.c:457
 __device_attach+0x32f/0x510 drivers/base/dd.c:1030
 bus_probe_device+0x185/0x260 drivers/base/bus.c:532
 device_add+0xb75/0xf60 drivers/base/core.c:3625
 usb_set_configuration+0x1976/0x1fb0 drivers/usb/core/message.c:2211
 usb_generic_driver_probe+0x88/0x140 drivers/usb/core/generic.c:238
 usb_probe_device+0x134/0x270 drivers/usb/core/driver.c:293
 really_probe+0x294/0xc30 drivers/base/dd.c:658
 __driver_probe_device+0x1a2/0x3d0 drivers/base/dd.c:800
 driver_probe_device+0x50/0x420 drivers/base/dd.c:830
 __device_attach_driver+0x2d3/0x520 drivers/base/dd.c:958
 bus_for_each_drv+0x24a/0x2d0 drivers/base/bus.c:457
 __device_attach+0x32f/0x510 drivers/base/dd.c:1030
 bus_probe_device+0x185/0x260 drivers/base/bus.c:532
 device_add+0xb75/0xf60 drivers/base/core.c:3625
 usb_new_device+0xb7e/0x18d0 drivers/usb/core/hub.c:2575
 hub_port_connect drivers/usb/core/hub.c:5407 [inline]
 hub_port_connect_change drivers/usb/core/hub.c:5551 [inline]
 port_event drivers/usb/core/hub.c:5711 [inline]
 hub_event+0x3016/0x5460 drivers/usb/core/hub.c:5793
 process_one_work+0x8a0/0x10e0 kernel/workqueue.c:2405
 worker_thread+0xa63/0x1210 kernel/workqueue.c:2552
 kthread+0x2b8/0x350 kernel/kthread.c:379
 ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:308
 </TASK>

Showing all locks held in the system:
1 lock held by rcu_tasks_kthre/13:
 #0: ffffffff8cf276f0 (rcu_tasks.tasks_gp_mutex){+.+.}-{3:3}, at: rcu_tasks_one_gp+0x29/0xd20 kernel/rcu/tasks.h:518
1 lock held by rcu_tasks_trace/14:
 #0: ffffffff8cf27ab0 (rcu_tasks_trace.tasks_gp_mutex){+.+.}-{3:3}, at: rcu_tasks_one_gp+0x29/0xd20 kernel/rcu/tasks.h:518
1 lock held by khungtaskd/28:
 #0: ffffffff8cf27520 (rcu_read_lock){....}-{1:2}, at: rcu_lock_acquire+0x0/0x30
1 lock held by hwrng/732:
 #0: ffffffff8d666548 (reading_mutex){+.+.}-{3:3}, at: hwrng_fillfn+0xe6/0x3c0 drivers/char/hw_random/core.c:505
2 locks held by getty/4752:
 #0: ffff888028a7c098 (&tty->ldisc_sem){++++}-{0:0}, at: tty_ldisc_ref_wait+0x25/0x70 drivers/tty/tty_ldisc.c:243
 #1: ffffc900015b02f0 (&ldata->atomic_read_lock){+.+.}-{3:3}, at: n_tty_read+0x6ab/0x1db0 drivers/tty/n_tty.c:2176
6 locks held by kworker/0:8/5084:
 #0: ffff888147647d38 ((wq_completion)usb_hub_wq){+.+.}-{0:0}, at: process_one_work+0x77e/0x10e0 kernel/workqueue.c:2378
 #1: ffffc900044ffd20 ((work_completion)(&hub->events)){+.+.}-{0:0}, at: process_one_work+0x7c8/0x10e0 kernel/workqueue.c:2380
 #2: ffff888022416190 (&dev->mutex){....}-{3:3}, at: device_lock include/linux/device.h:837 [inline]
 #2: ffff888022416190 (&dev->mutex){....}-{3:3}, at: hub_event+0x20e/0x5460 drivers/usb/core/hub.c:5739
 #3: ffff888076a02190 (&dev->mutex){....}-{3:3}, at: device_lock include/linux/device.h:837 [inline]
 #3: ffff888076a02190 (&dev->mutex){....}-{3:3}, at: __device_attach+0x8e/0x510 drivers/base/dd.c:1005
 #4: ffff888014ab9160 (&dev->mutex){....}-{3:3}, at: device_lock include/linux/device.h:837 [inline]
 #4: ffff888014ab9160 (&dev->mutex){....}-{3:3}, at: __device_attach+0x8e/0x510 drivers/base/dd.c:1005
 #5: ffffffff8d666548 (reading_mutex){+.+.}-{3:3}, at: add_early_randomness+0x1d/0x1a0 drivers/char/hw_random/core.c:69
2 locks held by kworker/1:9/5127:
 #0: ffff888012472538 ((wq_completion)rcu_gp){+.+.}-{0:0}, at: process_one_work+0x77e/0x10e0 kernel/workqueue.c:2378
 #1: ffffc90004c0fd20 ((work_completion)(&rew->rew_work)){+.+.}-{0:0}, at: process_one_work+0x7c8/0x10e0 kernel/workqueue.c:2380
4 locks held by udevd/5153:
 #0: ffff88802cb7f540 (&p->lock){+.+.}-{3:3}, at: seq_read_iter+0xb2/0xd10 fs/seq_file.c:182
 #1: ffff88807cf05488 (&of->mutex){+.+.}-{3:3}, at: kernfs_seq_start+0x53/0x3a0 fs/kernfs/file.c:154
 #2: ffff88802b33f008 (kn->active#30){.+.+}-{0:0}, at: kernfs_seq_start+0x72/0x3a0 fs/kernfs/file.c:155
 #3: ffff888076a02190 (&dev->mutex){....}-{3:3}, at: device_lock_interruptible include/linux/device.h:842 [inline]
 #3: ffff888076a02190 (&dev->mutex){....}-{3:3}, at: manufacturer_show+0x26/0xa0 drivers/usb/core/sysfs.c:142
3 locks held by kworker/u4:7/5313:
 #0: ffff8880b983c1d8 (&rq->__lock){-.-.}-{2:2}, at: raw_spin_rq_lock_nested+0x2a/0x140 kernel/sched/core.c:558
 #1: ffff8880b98287c8 (&per_cpu_ptr(group->pcpu, cpu)->seq){-.-.}-{0:0}, at: psi_task_switch+0x441/0x770 kernel/sched/psi.c:996
 #2: ffff8880b98295d8 (&base->lock){-.-.}-{2:2}, at: lock_timer_base+0x120/0x260 kernel/time/timer.c:999
3 locks held by kworker/u4:9/985:
3 locks held by kworker/1:0/3122:
 #0: ffff888012470d38 ((wq_completion)events){+.+.}-{0:0}, at: process_one_work+0x77e/0x10e0 kernel/workqueue.c:2378
 #1: ffffc9001540fd20 ((work_completion)(&pwq->unbound_release_work)){+.+.}-{0:0}, at: process_one_work+0x7c8/0x10e0 kernel/workqueue.c:2380
 #2: ffffffff8cf2cbf8 (rcu_state.exp_mutex){+.+.}-{3:3}, at: exp_funnel_lock kernel/rcu/tree_exp.h:293 [inline]
 #2: ffffffff8cf2cbf8 (rcu_state.exp_mutex){+.+.}-{3:3}, at: synchronize_rcu_expedited+0x3a3/0x890 kernel/rcu/tree_exp.h:992
1 lock held by syz-executor.3/6042:
 #0: ffffffff8cf2cac0 (rcu_state.barrier_mutex){+.+.}-{3:3}, at: rcu_barrier+0x4c/0x540 kernel/rcu/tree.c:3961
3 locks held by syz-executor.2/6064:

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

NMI backtrace for cpu 0
CPU: 0 PID: 28 Comm: khungtaskd Not tainted 6.4.0-rc3-syzkaller-00017-g9d646009f65d #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 05/16/2023
Call Trace:
 <TASK>
 __dump_stack lib/dump_stack.c:88 [inline]
 dump_stack_lvl+0x1e7/0x2d0 lib/dump_stack.c:106
 nmi_cpu_backtrace+0x498/0x4d0 lib/nmi_backtrace.c:113
 nmi_trigger_cpumask_backtrace+0x187/0x300 lib/nmi_backtrace.c:62
 trigger_all_cpu_backtrace include/linux/nmi.h:148 [inline]
 check_hung_uninterruptible_tasks kernel/hung_task.c:222 [inline]
 watchdog+0xec2/0xf00 kernel/hung_task.c:379
 kthread+0x2b8/0x350 kernel/kthread.c:379
 ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:308
 </TASK>
Sending NMI from CPU 0 to CPUs 1:
NMI backtrace for cpu 1
CPU: 1 PID: 985 Comm: kworker/u4:9 Not tainted 6.4.0-rc3-syzkaller-00017-g9d646009f65d #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 05/16/2023
Workqueue: netns cleanup_net
RIP: 0010:match_held_lock+0x77/0xb0 kernel/locking/lockdep.c:5168
Code: c7 c2 60 e1 01 90 48 29 d0 48 c1 f8 06 48 ba ab aa aa aa aa aa aa aa 48 0f af d0 bd 01 00 00 00 48 39 ca 74 02 31 ed 89 e8 5b <5d> c3 e8 e2 21 81 f9 31 ed 85 c0 74 f0 83 3d 3d f6 a6 03 00 75 e7
RSP: 0018:ffffc900045af990 EFLAGS: 00000046
RAX: 0000000000000001 RBX: 0000000000000003 RCX: ffffc900045afa03
RDX: 1ffff920008b5f44 RSI: ffffffff8cf27520 RDI: ffff88803f8946c0
RBP: 0000000000000001 R08: dffffc0000000000 R09: fffffbfff1cab8ce
R10: 0000000000000000 R11: dffffc0000000001 R12: 0000000000000003
R13: 000000000000000f R14: ffff88803f894648 R15: ffff88803f8946c0
FS:  0000000000000000(0000) GS:ffff8880b9900000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 00007ffd9bf4cdb8 CR3: 00000000387ad000 CR4: 00000000003506e0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
Call Trace:
 <TASK>
 find_held_lock kernel/locking/lockdep.c:5181 [inline]
 __lock_release kernel/locking/lockdep.c:5366 [inline]
 lock_release+0x24b/0x9d0 kernel/locking/lockdep.c:5711
 rcu_read_unlock include/linux/rcupdate.h:806 [inline]
 cond_resched_rcu+0x8a/0x130 include/linux/sched.h:2164
 ip_vs_conn_flush net/netfilter/ipvs/ip_vs_conn.c:1393 [inline]
 ip_vs_conn_net_cleanup+0x37a/0x520 net/netfilter/ipvs/ip_vs_conn.c:1475
 __ip_vs_cleanup_batch+0x74/0xf0 net/netfilter/ipvs/ip_vs_core.c:2347
 ops_exit_list net/core/net_namespace.c:175 [inline]
 cleanup_net+0x767/0xb80 net/core/net_namespace.c:614
 process_one_work+0x8a0/0x10e0 kernel/workqueue.c:2405
 worker_thread+0xa63/0x1210 kernel/workqueue.c:2552
 kthread+0x2b8/0x350 kernel/kthread.c:379
 ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:308
 </TASK>

Crashes (7):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2023/05/24 21:18 upstream 9d646009f65d 4bce1a3e .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce-smack-root INFO: task hung in add_early_randomness
2023/04/20 19:11 upstream cb0856346a60 2b32bd34 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce INFO: task hung in add_early_randomness
2023/04/18 12:02 upstream 6a8f57ae2eb0 436577a9 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce INFO: task hung in add_early_randomness
2023/04/03 15:32 upstream 7e364e56293b 41147e3e .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce INFO: task hung in add_early_randomness
2023/03/30 07:22 upstream ffe78bbd5121 f325deb0 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce INFO: task hung in add_early_randomness
2023/03/27 16:26 upstream 197b6b60ae7b f8f96aa9 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce-root INFO: task hung in add_early_randomness
2023/04/27 15:47 upstream 6e98b09da931 6f5b1cc4 .config console log report info ci-upstream-kasan-gce-386 INFO: task hung in add_early_randomness
* Struck through repros no longer work on HEAD.