syzbot


INFO: task hung in blk_queue_enter (2)

Status: auto-obsoleted due to no activity on 2023/11/09 05:10
Subsystems: block
[Documentation on labels]
First crash: 266d, last: 264d
Similar bugs (4)
Kernel Title Repro Cause bisect Fix bisect Count Last Reported Patched Status
linux-4.19 INFO: task hung in blk_queue_enter 1 540d 540d 0/1 auto-obsoleted due to no activity on 2023/03/08 06:36
upstream INFO: task hung in blk_queue_enter block C 1595 2123d 2195d 8/26 fixed on 2018/07/09 18:05
android-414 INFO: task hung in blk_queue_enter 1 1971d 1844d 0/1 auto-closed as invalid on 2019/06/06 06:07
android-49 INFO: task hung in blk_queue_enter 1 1959d 1844d 0/3 auto-closed as invalid on 2019/06/18 00:11

Sample crash report:
INFO: task udevd:29693 blocked for more than 143 seconds.
      Not tainted 6.5.0-rc4-syzkaller-00111-gf176638af476 #0
"echo 0 > /proc/sys/kernel/hung_task_timeout_secs" disables this message.
task:udevd           state:D stack:26992 pid:29693 ppid:2376   flags:0x00004002
Call Trace:
 <TASK>
 context_switch kernel/sched/core.c:5381 [inline]
 __schedule+0xc79/0x30a0 kernel/sched/core.c:6710
 schedule+0xe7/0x1b0 kernel/sched/core.c:6786
 blk_queue_enter+0x3aa/0x620 block/blk-core.c:326
 blk_mq_alloc_request+0x416/0x860 block/blk-mq.c:592
 scsi_alloc_request drivers/scsi/scsi_lib.c:1139 [inline]
 scsi_execute_cmd+0x129/0x770 drivers/scsi/scsi_lib.c:217
 ioctl_internal_command.constprop.0+0xe6/0x3e0 drivers/scsi/scsi_ioctl.c:79
 scsi_set_medium_removal+0x12d/0x1f0 drivers/scsi/scsi_ioctl.c:139
 sd_release+0x10b/0x130 drivers/scsi/sd.c:1423
 blkdev_put_whole+0xa5/0xe0 block/bdev.c:680
 blkdev_put+0x40f/0x8e0 block/bdev.c:915
 blkdev_release+0x82/0xa0 block/fops.c:532
 __fput+0x3fd/0xac0 fs/file_table.c:384
 task_work_run+0x14d/0x240 kernel/task_work.c:179
 resume_user_mode_work include/linux/resume_user_mode.h:49 [inline]
 exit_to_user_mode_loop kernel/entry/common.c:171 [inline]
 exit_to_user_mode_prepare+0x1e4/0x1f0 kernel/entry/common.c:204
 __syscall_exit_to_user_mode_work kernel/entry/common.c:286 [inline]
 syscall_exit_to_user_mode+0x1d/0x50 kernel/entry/common.c:297
 do_syscall_64+0x44/0xb0 arch/x86/entry/common.c:86
 entry_SYSCALL_64_after_hwframe+0x63/0xcd
RIP: 0033:0x7fd85b2a30a8
RSP: 002b:00007ffe9918ca08 EFLAGS: 00000246 ORIG_RAX: 0000000000000003
RAX: 0000000000000000 RBX: 00007fd85b177ae0 RCX: 00007fd85b2a30a8
RDX: 00005655751289ce RSI: 00007ffe9918c208 RDI: 0000000000000008
RBP: 0000565010137e10 R08: 0000000000000006 R09: afd82df3fc3897a2
R10: 000000000000010f R11: 0000000000000246 R12: 0000000000000002
R13: 0000565010129250 R14: 0000000000000008 R15: 0000565010116910
 </TASK>
INFO: task kworker/1:3:32458 blocked for more than 143 seconds.
      Not tainted 6.5.0-rc4-syzkaller-00111-gf176638af476 #0
"echo 0 > /proc/sys/kernel/hung_task_timeout_secs" disables this message.
task:kworker/1:3     state:D stack:23904 pid:32458 ppid:2      flags:0x00004000
Workqueue: usb_hub_wq hub_event
Call Trace:
 <TASK>
 context_switch kernel/sched/core.c:5381 [inline]
 __schedule+0xc79/0x30a0 kernel/sched/core.c:6710
 schedule+0xe7/0x1b0 kernel/sched/core.c:6786
 schedule_preempt_disabled+0x13/0x20 kernel/sched/core.c:6845
 __mutex_lock_common kernel/locking/mutex.c:679 [inline]
 __mutex_lock+0x967/0x1340 kernel/locking/mutex.c:747
 del_gendisk+0x276/0xab0 block/genhd.c:660
 sd_remove+0x89/0xf0 drivers/scsi/sd.c:3735
 device_remove drivers/base/dd.c:569 [inline]
 device_remove+0x11f/0x170 drivers/base/dd.c:561
 __device_release_driver drivers/base/dd.c:1270 [inline]
 device_release_driver_internal+0x44a/0x610 drivers/base/dd.c:1293
 bus_remove_device+0x22c/0x420 drivers/base/bus.c:574
 device_del+0x39a/0xa40 drivers/base/core.c:3814
 __scsi_remove_device+0x30c/0x3f0 drivers/scsi/scsi_sysfs.c:1489
 scsi_forget_host+0x138/0x190 drivers/scsi/scsi_scan.c:1987
 scsi_remove_host+0x153/0x430 drivers/scsi/hosts.c:181
 quiesce_and_remove_host drivers/usb/storage/usb.c:867 [inline]
 usb_stor_disconnect+0x121/0x270 drivers/usb/storage/usb.c:1087
 usb_unbind_interface+0x1dd/0x8d0 drivers/usb/core/driver.c:458
 device_remove drivers/base/dd.c:569 [inline]
 device_remove+0x11f/0x170 drivers/base/dd.c:561
 __device_release_driver drivers/base/dd.c:1270 [inline]
 device_release_driver_internal+0x44a/0x610 drivers/base/dd.c:1293
 bus_remove_device+0x22c/0x420 drivers/base/bus.c:574
 device_del+0x39a/0xa40 drivers/base/core.c:3814
 usb_disable_device+0x36c/0x7f0 drivers/usb/core/message.c:1416
 usb_disconnect+0x2e1/0x890 drivers/usb/core/hub.c:2252
 hub_port_connect drivers/usb/core/hub.c:5268 [inline]
 hub_port_connect_change drivers/usb/core/hub.c:5568 [inline]
 port_event drivers/usb/core/hub.c:5728 [inline]
 hub_event+0x1be0/0x4f30 drivers/usb/core/hub.c:5810
 process_one_work+0xaa2/0x16f0 kernel/workqueue.c:2597
 worker_thread+0x687/0x1110 kernel/workqueue.c:2748
 kthread+0x33a/0x430 kernel/kthread.c:389
 ret_from_fork+0x2c/0x70 arch/x86/kernel/process.c:145
 ret_from_fork_asm+0x11/0x20 arch/x86/entry/entry_64.S:304
 </TASK>

Showing all locks held in the system:
1 lock held by rcu_tasks_kthre/12:
 #0: ffffffff87ea74b0 (rcu_tasks.tasks_gp_mutex){+.+.}-{3:3}, at: rcu_tasks_one_gp+0x2c/0xe20 kernel/rcu/tasks.h:522
1 lock held by rcu_tasks_trace/13:
 #0: ffffffff87ea71b0 (rcu_tasks_trace.tasks_gp_mutex){+.+.}-{3:3}, at: rcu_tasks_one_gp+0x2c/0xe20 kernel/rcu/tasks.h:522
1 lock held by khungtaskd/28:
 #0: ffffffff87ea80c0 (rcu_read_lock){....}-{1:2}, at: debug_show_all_locks+0x55/0x340 kernel/locking/lockdep.c:6615
6 locks held by kworker/1:2/274:
 #0: ffff88810ca5c138 ((wq_completion)usb_hub_wq){+.+.}-{0:0}, at: arch_atomic64_set arch/x86/include/asm/atomic64_64.h:20 [inline]
 #0: ffff88810ca5c138 ((wq_completion)usb_hub_wq){+.+.}-{0:0}, at: raw_atomic64_set include/linux/atomic/atomic-arch-fallback.h:2608 [inline]
 #0: ffff88810ca5c138 ((wq_completion)usb_hub_wq){+.+.}-{0:0}, at: raw_atomic_long_set include/linux/atomic/atomic-long.h:79 [inline]
 #0: ffff88810ca5c138 ((wq_completion)usb_hub_wq){+.+.}-{0:0}, at: atomic_long_set include/linux/atomic/atomic-instrumented.h:3196 [inline]
 #0: ffff88810ca5c138 ((wq_completion)usb_hub_wq){+.+.}-{0:0}, at: set_work_data kernel/workqueue.c:675 [inline]
 #0: ffff88810ca5c138 ((wq_completion)usb_hub_wq){+.+.}-{0:0}, at: set_work_pool_and_clear_pending kernel/workqueue.c:702 [inline]
 #0: ffff88810ca5c138 ((wq_completion)usb_hub_wq){+.+.}-{0:0}, at: process_one_work+0x96a/0x16f0 kernel/workqueue.c:2567
 #1: ffffc90001d6fd80 ((work_completion)(&hub->events)){+.+.}-{0:0}, at: process_one_work+0x99e/0x16f0 kernel/workqueue.c:2571
 #2: ffff888105fd9190 (&dev->mutex){....}-{3:3}, at: device_lock include/linux/device.h:958 [inline]
 #2: ffff888105fd9190 (&dev->mutex){....}-{3:3}, at: hub_event+0x1be/0x4f30 drivers/usb/core/hub.c:5756
 #3: ffff888105fdc500 (&port_dev->status_lock){+.+.}-{3:3}, at: usb_lock_port drivers/usb/core/hub.c:3138 [inline]
 #3: ffff888105fdc500 (&port_dev->status_lock){+.+.}-{3:3}, at: hub_port_connect drivers/usb/core/hub.c:5325 [inline]
 #3: ffff888105fdc500 (&port_dev->status_lock){+.+.}-{3:3}, at: hub_port_connect_change drivers/usb/core/hub.c:5568 [inline]
 #3: ffff888105fdc500 (&port_dev->status_lock){+.+.}-{3:3}, at: port_event drivers/usb/core/hub.c:5728 [inline]
 #3: ffff888105fdc500 (&port_dev->status_lock){+.+.}-{3:3}, at: hub_event+0x28b4/0x4f30 drivers/usb/core/hub.c:5810
 #4: ffff8881052fc468 (hcd->address0_mutex){+.+.}-{3:3}, at: hub_port_connect drivers/usb/core/hub.c:5326 [inline]
 #4: ffff8881052fc468 (hcd->address0_mutex){+.+.}-{3:3}, at: hub_port_connect_change drivers/usb/core/hub.c:5568 [inline]
 #4: ffff8881052fc468 (hcd->address0_mutex){+.+.}-{3:3}, at: port_event drivers/usb/core/hub.c:5728 [inline]
 #4: ffff8881052fc468 (hcd->address0_mutex){+.+.}-{3:3}, at: hub_event+0x28da/0x4f30 drivers/usb/core/hub.c:5810
 #5: ffffffff888d0e50 (ehci_cf_port_reset_rwsem){.+.+}-{3:3}, at: hub_port_reset+0x1a4/0x1dc0 drivers/usb/core/hub.c:2953
2 locks held by getty/2433:
 #0: ffff888102243098 (&tty->ldisc_sem){++++}-{0:0}, at: tty_ldisc_ref_wait+0x24/0x80 drivers/tty/tty_ldisc.c:243
 #1: ffffc900000452f0 (&ldata->atomic_read_lock){+.+.}-{3:3}, at: n_tty_read+0xfcb/0x1480 drivers/tty/n_tty.c:2187
5 locks held by kworker/0:4/5267:
4 locks held by kworker/1:5/5366:
 #0: ffff88810ca5c138 ((wq_completion)usb_hub_wq){+.+.}-{0:0}, at: arch_atomic64_set arch/x86/include/asm/atomic64_64.h:20 [inline]
 #0: ffff88810ca5c138 ((wq_completion)usb_hub_wq){+.+.}-{0:0}, at: raw_atomic64_set include/linux/atomic/atomic-arch-fallback.h:2608 [inline]
 #0: ffff88810ca5c138 ((wq_completion)usb_hub_wq){+.+.}-{0:0}, at: raw_atomic_long_set include/linux/atomic/atomic-long.h:79 [inline]
 #0: ffff88810ca5c138 ((wq_completion)usb_hub_wq){+.+.}-{0:0}, at: atomic_long_set include/linux/atomic/atomic-instrumented.h:3196 [inline]
 #0: ffff88810ca5c138 ((wq_completion)usb_hub_wq){+.+.}-{0:0}, at: set_work_data kernel/workqueue.c:675 [inline]
 #0: ffff88810ca5c138 ((wq_completion)usb_hub_wq){+.+.}-{0:0}, at: set_work_pool_and_clear_pending kernel/workqueue.c:702 [inline]
 #0: ffff88810ca5c138 ((wq_completion)usb_hub_wq){+.+.}-{0:0}, at: process_one_work+0x96a/0x16f0 kernel/workqueue.c:2567
 #1: ffffc90001b6fd80 ((work_completion)(&hub->events)){+.+.}-{0:0}, at: process_one_work+0x99e/0x16f0 kernel/workqueue.c:2571
 #2: ffff88810ea7f190 (&dev->mutex){....}-{3:3}, at: device_lock include/linux/device.h:958 [inline]
 #2: ffff88810ea7f190 (&dev->mutex){....}-{3:3}, at: hub_event+0x1be/0x4f30 drivers/usb/core/hub.c:5756
 #3: ffff888106a9f500 (&port_dev->status_lock){+.+.}-{3:3}, at: usb_lock_port drivers/usb/core/hub.c:3138 [inline]
 #3: ffff888106a9f500 (&port_dev->status_lock){+.+.}-{3:3}, at: hub_event+0x5c4/0x4f30 drivers/usb/core/hub.c:5809
1 lock held by udevd/29693:
 #0: ffff888101f56358 (&disk->open_mutex){+.+.}-{3:3}, at: blkdev_put+0xb0/0x8e0 block/bdev.c:901
3 locks held by kworker/0:1/31905:
 #0: ffff888100070d38 ((wq_completion)events){+.+.}-{0:0}, at: arch_atomic64_set arch/x86/include/asm/atomic64_64.h:20 [inline]
 #0: ffff888100070d38 ((wq_completion)events){+.+.}-{0:0}, at: raw_atomic64_set include/linux/atomic/atomic-arch-fallback.h:2608 [inline]
 #0: ffff888100070d38 ((wq_completion)events){+.+.}-{0:0}, at: raw_atomic_long_set include/linux/atomic/atomic-long.h:79 [inline]
 #0: ffff888100070d38 ((wq_completion)events){+.+.}-{0:0}, at: atomic_long_set include/linux/atomic/atomic-instrumented.h:3196 [inline]
 #0: ffff888100070d38 ((wq_completion)events){+.+.}-{0:0}, at: set_work_data kernel/workqueue.c:675 [inline]
 #0: ffff888100070d38 ((wq_completion)events){+.+.}-{0:0}, at: set_work_pool_and_clear_pending kernel/workqueue.c:702 [inline]
 #0: ffff888100070d38 ((wq_completion)events){+.+.}-{0:0}, at: process_one_work+0x96a/0x16f0 kernel/workqueue.c:2567
 #1: ffffc9000d567d80 ((work_completion)(&fw_work->work)){+.+.}-{0:0}, at: process_one_work+0x99e/0x16f0 kernel/workqueue.c:2571
 #2: ffff888106751190 (&dev->mutex){....}-{3:3}, at: device_lock include/linux/device.h:958 [inline]
 #2: ffff888106751190 (&dev->mutex){....}-{3:3}, at: ath9k_hif_usb_firmware_fail drivers/net/wireless/ath/ath9k/hif_usb.c:1163 [inline]
 #2: ffff888106751190 (&dev->mutex){....}-{3:3}, at: ath9k_hif_usb_firmware_cb+0x3b1/0x620 drivers/net/wireless/ath/ath9k/hif_usb.c:1296
8 locks held by kworker/1:3/32458:
 #0: ffff88810ca5c138 ((wq_completion)usb_hub_wq){+.+.}-{0:0}, at: arch_atomic64_set arch/x86/include/asm/atomic64_64.h:20 [inline]
 #0: ffff88810ca5c138 ((wq_completion)usb_hub_wq){+.+.}-{0:0}, at: raw_atomic64_set include/linux/atomic/atomic-arch-fallback.h:2608 [inline]
 #0: ffff88810ca5c138 ((wq_completion)usb_hub_wq){+.+.}-{0:0}, at: raw_atomic_long_set include/linux/atomic/atomic-long.h:79 [inline]
 #0: ffff88810ca5c138 ((wq_completion)usb_hub_wq){+.+.}-{0:0}, at: atomic_long_set include/linux/atomic/atomic-instrumented.h:3196 [inline]
 #0: ffff88810ca5c138 ((wq_completion)usb_hub_wq){+.+.}-{0:0}, at: set_work_data kernel/workqueue.c:675 [inline]
 #0: ffff88810ca5c138 ((wq_completion)usb_hub_wq){+.+.}-{0:0}, at: set_work_pool_and_clear_pending kernel/workqueue.c:702 [inline]
 #0: ffff88810ca5c138 ((wq_completion)usb_hub_wq){+.+.}-{0:0}, at: process_one_work+0x96a/0x16f0 kernel/workqueue.c:2567
 #1: ffffc9000e357d80 ((work_completion)(&hub->events)){+.+.}-{0:0}, at: process_one_work+0x99e/0x16f0 kernel/workqueue.c:2571
 #2: ffff888106771190 (&dev->mutex){....}-{3:3}, at: device_lock include/linux/device.h:958 [inline]
 #2: ffff888106771190 (&dev->mutex){....}-{3:3}, at: hub_event+0x1be/0x4f30 drivers/usb/core/hub.c:5756
 #3: ffff888106a98190 (&dev->mutex){....}-{3:3}, at: device_lock include/linux/device.h:958 [inline]
 #3: ffff888106a98190 (&dev->mutex){....}-{3:3}, at: usb_disconnect+0x10a/0x890 drivers/usb/core/hub.c:2243
 #4: ffff8881194d0160 (&dev->mutex){....}-{3:3}, at: device_lock include/linux/device.h:958 [inline]
 #4: ffff8881194d0160 (&dev->mutex){....}-{3:3}, at: __device_driver_lock drivers/base/dd.c:1093 [inline]
 #4: ffff8881194d0160 (&dev->mutex){....}-{3:3}, at: device_release_driver_internal+0xa4/0x610 drivers/base/dd.c:1290
 #5: ffff88811b7e00e0 (&shost->scan_mutex){+.+.}-{3:3}, at: scsi_remove_host+0x2c/0x430 drivers/scsi/hosts.c:169
 #6: ffff888143de6370 (&dev->mutex){....}-{3:3}, at: device_lock include/linux/device.h:958 [inline]
 #6: ffff888143de6370 (&dev->mutex){....}-{3:3}, at: __device_driver_lock drivers/base/dd.c:1093 [inline]
 #6: ffff888143de6370 (&dev->mutex){....}-{3:3}, at: device_release_driver_internal+0xa4/0x610 drivers/base/dd.c:1290
 #7: ffff888101f56358 (&disk->open_mutex
){+.+.}-{3:3}
, at: del_gendisk+0x276/0xab0 block/genhd.c:660

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

NMI backtrace for cpu 0
CPU: 0 PID: 28 Comm: khungtaskd Not tainted 6.5.0-rc4-syzkaller-00111-gf176638af476 #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 07/26/2023
Call Trace:
 <TASK>
 __dump_stack lib/dump_stack.c:88 [inline]
 dump_stack_lvl+0xd9/0x1b0 lib/dump_stack.c:106
 nmi_cpu_backtrace+0x277/0x380 lib/nmi_backtrace.c:113
 nmi_trigger_cpumask_backtrace+0x27b/0x2e0 lib/nmi_backtrace.c:62
 trigger_all_cpu_backtrace include/linux/nmi.h:160 [inline]
 check_hung_uninterruptible_tasks kernel/hung_task.c:222 [inline]
 watchdog+0xf29/0x11b0 kernel/hung_task.c:379
 kthread+0x33a/0x430 kernel/kthread.c:389
 ret_from_fork+0x2c/0x70 arch/x86/kernel/process.c:145
 ret_from_fork_asm+0x11/0x20 arch/x86/entry/entry_64.S:304
 </TASK>
Sending NMI from CPU 0 to CPUs 1:
NMI backtrace for cpu 1
CPU: 1 PID: 5366 Comm: kworker/1:5 Not tainted 6.5.0-rc4-syzkaller-00111-gf176638af476 #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 07/26/2023
Workqueue: usb_hub_wq hub_event
RIP: 0010:io_serial_in+0x87/0xa0 drivers/tty/serial/8250/8250_port.c:410
Code: 93 cb fe 48 8d 7d 40 44 89 e1 48 b8 00 00 00 00 00 fc ff df 48 89 fa d3 e3 48 c1 ea 03 80 3c 02 00 75 16 66 03 5d 40 89 da ec <5b> 0f b6 c0 5d 41 5c c3 e8 1c 44 16 ff eb a6 e8 75 44 16 ff eb e3
RSP: 0018:ffffc90001b6f468 EFLAGS: 00000002
RAX: dffffc0000000000 RBX: 00000000000003fd RCX: 0000000000000000
RDX: 00000000000003fd RSI: ffffffff8280b800 RDI: ffffffff8c1dac20
RBP: ffffffff8c1dabe0 R08: 0000000000000001 R09: 000000000000001f
R10: 0000000000000000 R11: 205d363633355420 R12: 0000000000000000
R13: 0000000000000020 R14: fffffbfff183b5d6 R15: dffffc0000000000
FS:  0000000000000000(0000) GS:ffff8881f6700000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 00007fc251abf6be CR3: 00000001137b9000 CR4: 00000000003506e0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
Call Trace:
 <NMI>
 </NMI>
 <TASK>
 serial_in drivers/tty/serial/8250/8250.h:117 [inline]
 serial_lsr_in drivers/tty/serial/8250/8250.h:139 [inline]
 wait_for_lsr+0xd7/0x180 drivers/tty/serial/8250/8250_port.c:2082
 serial8250_console_fifo_write drivers/tty/serial/8250/8250_port.c:3366 [inline]
 serial8250_console_write+0xce5/0x1060 drivers/tty/serial/8250/8250_port.c:3444
 console_emit_next_record kernel/printk/printk.c:2877 [inline]
 console_flush_all+0x4c8/0xf50 kernel/printk/printk.c:2933
 console_unlock+0xc6/0x1f0 kernel/printk/printk.c:3007
 vprintk_emit+0x1c5/0x640 kernel/printk/printk.c:2307
 dev_vprintk_emit drivers/base/core.c:4840 [inline]
 dev_printk_emit+0xfb/0x140 drivers/base/core.c:4851
 __dev_printk+0xf5/0x270 drivers/base/core.c:4863
 _dev_warn+0xe5/0x120 drivers/base/core.c:4907
 port_event drivers/usb/core/hub.c:5679 [inline]
 hub_event+0x1244/0x4f30 drivers/usb/core/hub.c:5810
 process_one_work+0xaa2/0x16f0 kernel/workqueue.c:2597
 worker_thread+0x687/0x1110 kernel/workqueue.c:2748
 kthread+0x33a/0x430 kernel/kthread.c:389
 ret_from_fork+0x2c/0x70 arch/x86/kernel/process.c:145
 ret_from_fork_asm+0x11/0x20 arch/x86/entry/entry_64.S:304
 </TASK>

Crashes (2):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2023/08/11 05:00 https://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb.git usb-testing f176638af476 da3c3ef8 .config console log report info ci2-upstream-usb INFO: task hung in blk_queue_enter
2023/08/09 20:14 https://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb.git usb-testing f176638af476 13ca4cd6 .config console log report info ci2-upstream-usb INFO: task hung in blk_queue_enter
* Struck through repros no longer work on HEAD.