syzbot


INFO: task hung in blkdev_get_by_dev

Status: upstream: reported C repro on 2025/06/21 06:39
Bug presence: origin:upstream
[Documentation on labels]
Reported-by: syzbot+2ce2823cf6fe5ca3845c@syzkaller.appspotmail.com
First crash: 66d, last: 5d19h
Bug presence (1)
Date Name Commit Repro Result
2025/07/27 upstream (ToT) b711733e89a3 C [report] INFO: task hung in bdev_open
Similar bugs (11)
Kernel Title Rank 🛈 Repro Cause bisect Fix bisect Count Last Reported Patched Status
linux-6.1 INFO: task hung in blkdev_get_by_dev origin:lts-only 1 C done 25 288d 575d 3/3 fixed on 2025/01/02 10:34
linux-5.15 INFO: task hung in blkdev_get_by_dev (2) 1 1 716d 716d 0/3 auto-obsoleted due to no activity on 2023/12/18 22:46
upstream INFO: task hung in blkdev_get_by_dev (3) block 1 1 1266d 1266d 0/29 auto-closed as invalid on 2022/05/08 09:47
linux-5.15 INFO: task hung in blkdev_get_by_dev 1 1 848d 848d 0/3 auto-obsoleted due to no activity on 2023/08/23 09:06
linux-5.15 INFO: task hung in blkdev_get_by_dev (4) 1 3 91d 91d 0/3 upstream: reported on 2025/05/27 06:24
linux-5.15 INFO: task hung in blkdev_get_by_dev (3) 1 17 352d 572d 0/3 auto-obsoleted due to no activity on 2024/12/17 17:06
linux-6.1 INFO: task hung in blkdev_get_by_dev (2) 1 2 7d05h 48d 0/3 upstream: reported on 2025/07/08 23:59
upstream INFO: task hung in blkdev_get_by_dev fs 1 1 1645d 1645d 0/29 auto-closed as invalid on 2021/05/23 22:12
upstream INFO: task hung in blkdev_get_by_dev (4) block 1 1 1095d 1095d 0/29 auto-obsoleted due to no activity on 2022/11/25 11:03
upstream INFO: task hung in blkdev_get_by_dev (2) block 1 1727 1298d 1377d 0/29 closed as dup on 2021/11/21 14:02
upstream INFO: task hung in blkdev_get_by_dev (5) block 1 C error error 32 136d 908d 0/29 upstream: reported C repro on 2023/03/02 18:11

Sample crash report:
INFO: task syz.2.18:6038 blocked for more than 143 seconds.
      Not tainted 6.6.100-syzkaller #0
"echo 0 > /proc/sys/kernel/hung_task_timeout_secs" disables this message.
task:syz.2.18        state:D stack:26664 pid:6038  ppid:5922   flags:0x00004004
Call Trace:
 <TASK>
 context_switch kernel/sched/core.c:5381 [inline]
 __schedule+0x14d2/0x44d0 kernel/sched/core.c:6700
 schedule+0xbd/0x170 kernel/sched/core.c:6774
 schedule_preempt_disabled+0x13/0x20 kernel/sched/core.c:6833
 __mutex_lock_common kernel/locking/mutex.c:679 [inline]
 __mutex_lock+0x6b7/0xcc0 kernel/locking/mutex.c:747
 blkdev_get_by_dev+0x121/0x600 block/bdev.c:788
 blkdev_open+0x152/0x360 block/fops.c:589
 do_dentry_open+0x8c6/0x1500 fs/open.c:929
 do_open fs/namei.c:3632 [inline]
 path_openat+0x274b/0x3190 fs/namei.c:3789
 do_filp_open+0x1c5/0x3d0 fs/namei.c:3816
 do_sys_openat2+0x12c/0x1c0 fs/open.c:1419
 do_sys_open fs/open.c:1434 [inline]
 __do_sys_openat fs/open.c:1450 [inline]
 __se_sys_openat fs/open.c:1445 [inline]
 __x64_sys_openat+0x139/0x160 fs/open.c:1445
 do_syscall_x64 arch/x86/entry/common.c:51 [inline]
 do_syscall_64+0x55/0xb0 arch/x86/entry/common.c:81
 entry_SYSCALL_64_after_hwframe+0x68/0xd2
RIP: 0033:0x7fa64dd8d310
RSP: 002b:00007ffee8a711d0 EFLAGS: 00000293 ORIG_RAX: 0000000000000101
RAX: ffffffffffffffda RBX: 0000000000000000 RCX: 00007fa64dd8d310
RDX: 0000000000000000 RSI: 00007ffee8a71270 RDI: 00000000ffffff9c
RBP: 00007ffee8a71270 R08: 0000000000000000 R09: 002364626e2f7665
R10: 0000000000000000 R11: 0000000000000293 R12: cccccccccccccccd
R13: 00007fa64dfb5fa0 R14: 00007fa64dfb5fa0 R15: 0000000000000003
 </TASK>
INFO: task syz.3.19:6048 blocked for more than 143 seconds.
      Not tainted 6.6.100-syzkaller #0
"echo 0 > /proc/sys/kernel/hung_task_timeout_secs" disables this message.
task:syz.3.19        state:D stack:26664 pid:6048  ppid:5921   flags:0x00004004
Call Trace:
 <TASK>
 context_switch kernel/sched/core.c:5381 [inline]
 __schedule+0x14d2/0x44d0 kernel/sched/core.c:6700
 schedule+0xbd/0x170 kernel/sched/core.c:6774
 schedule_preempt_disabled+0x13/0x20 kernel/sched/core.c:6833
 __mutex_lock_common kernel/locking/mutex.c:679 [inline]
 __mutex_lock+0x6b7/0xcc0 kernel/locking/mutex.c:747
 blkdev_get_by_dev+0x121/0x600 block/bdev.c:788
 blkdev_open+0x152/0x360 block/fops.c:589
 do_dentry_open+0x8c6/0x1500 fs/open.c:929
 do_open fs/namei.c:3632 [inline]
 path_openat+0x274b/0x3190 fs/namei.c:3789
 do_filp_open+0x1c5/0x3d0 fs/namei.c:3816
 do_sys_openat2+0x12c/0x1c0 fs/open.c:1419
 do_sys_open fs/open.c:1434 [inline]
 __do_sys_openat fs/open.c:1450 [inline]
 __se_sys_openat fs/open.c:1445 [inline]
 __x64_sys_openat+0x139/0x160 fs/open.c:1445
 do_syscall_x64 arch/x86/entry/common.c:51 [inline]
 do_syscall_64+0x55/0xb0 arch/x86/entry/common.c:81
 entry_SYSCALL_64_after_hwframe+0x68/0xd2
RIP: 0033:0x7fe88c58d310
RSP: 002b:00007ffe8468d940 EFLAGS: 00000293 ORIG_RAX: 0000000000000101
RAX: ffffffffffffffda RBX: 0000000000000000 RCX: 00007fe88c58d310
RDX: 0000000000000000 RSI: 00007ffe8468d9e0 RDI: 00000000ffffff9c
RBP: 00007ffe8468d9e0 R08: 0000000000000000 R09: 002364626e2f7665
R10: 0000000000000000 R11: 0000000000000293 R12: cccccccccccccccd
R13: 00007fe88c7b5fa0 R14: 00007fe88c7b5fa0 R15: 0000000000000003
 </TASK>

Showing all locks held in the system:
5 locks held by kworker/u4:0/11:
1 lock held by khungtaskd/29:
 #0: ffffffff8cd2fba0 (rcu_read_lock){....}-{1:2}, at: rcu_lock_acquire include/linux/rcupdate.h:334 [inline]
 #0: ffffffff8cd2fba0 (rcu_read_lock){....}-{1:2}, at: rcu_read_lock include/linux/rcupdate.h:786 [inline]
 #0: ffffffff8cd2fba0 (rcu_read_lock){....}-{1:2}, at: debug_show_all_locks+0x55/0x290 kernel/locking/lockdep.c:6633
2 locks held by getty/5550:
 #0: ffff8880321020a0 (&tty->ldisc_sem){++++}-{0:0}, at: tty_ldisc_ref_wait+0x25/0x70 drivers/tty/tty_ldisc.c:243
 #1: ffffc9000327b2f0 (&ldata->atomic_read_lock){+.+.}-{3:3}, at: n_tty_read+0x425/0x1380 drivers/tty/n_tty.c:2217
3 locks held by kworker/u5:3/5919:
 #0: ffff8880645add38 ((wq_completion)hci6){+.+.}-{0:0}, at: process_one_work kernel/workqueue.c:2609 [inline]
 #0: ffff8880645add38 ((wq_completion)hci6){+.+.}-{0:0}, at: process_scheduled_works+0x957/0x15b0 kernel/workqueue.c:2711
 #1: ffffc90003287d00 ((work_completion)(&hdev->cmd_sync_work)){+.+.}-{0:0}, at: process_one_work kernel/workqueue.c:2609 [inline]
 #1: ffffc90003287d00 ((work_completion)(&hdev->cmd_sync_work)){+.+.}-{0:0}, at: process_scheduled_works+0x957/0x15b0 kernel/workqueue.c:2711
 #2: ffff888079214e70 (&hdev->req_lock){+.+.}-{3:3}, at: hci_cmd_sync_work+0x1d4/0x390 net/bluetooth/hci_sync.c:326
1 lock held by udevd/5950:
 #0: ffff8881401e04c8 (&disk->open_mutex){+.+.}-{3:3}, at: blkdev_get_by_dev+0x121/0x600 block/bdev.c:788
1 lock held by udevd/5951:
 #0: ffff888021d334c8 (&disk->open_mutex){+.+.}-{3:3}, at: blkdev_get_by_dev+0x121/0x600 block/bdev.c:788
1 lock held by udevd/5952:
 #0: ffff888021de34c8 (&disk->open_mutex){+.+.}-{3:3}, at: blkdev_get_by_dev+0x121/0x600 block/bdev.c:788
1 lock held by udevd/6028:
 #0: ffff888021dfb4c8 (&disk->open_mutex){+.+.}-{3:3}, at: blkdev_get_by_dev+0x121/0x600 block/bdev.c:788
1 lock held by udevd/6029:
 #0: ffff888141f384c8 (&disk->open_mutex){+.+.}-{3:3}, at: blkdev_get_by_dev+0x121/0x600 block/bdev.c:788
1 lock held by udevd/6033:
 #0: ffff888141bd74c8 (&disk->open_mutex){+.+.}-{3:3}, at: blkdev_get_by_dev+0x121/0x600 block/bdev.c:788
1 lock held by udevd/6035:
 #0: ffff888141fb04c8 (&disk->open_mutex){+.+.}-{3:3}, at: blkdev_get_by_dev+0x121/0x600 block/bdev.c:788
1 lock held by udevd/6036:
 #0: ffff888021f864c8 (&disk->open_mutex){+.+.}-{3:3}, at: blkdev_get_by_dev+0x121/0x600 block/bdev.c:788
1 lock held by syz.2.18/6038:
 #0: ffff888021d334c8 (&disk->open_mutex){+.+.}-{3:3}, at: blkdev_get_by_dev+0x121/0x600 block/bdev.c:788
1 lock held by udevd/6042:
 #0: ffff8880644504c8 (&disk->open_mutex){+.+.}-{3:3}, at: blkdev_get_by_dev+0x121/0x600 block/bdev.c:788
1 lock held by udevd/6043:
 #0: ffff8880224cb4c8 (&disk->open_mutex){+.+.}-{3:3}, at: blkdev_get_by_dev+0x121/0x600 block/bdev.c:788
1 lock held by udevd/6045:
 #0: ffff888141f504c8 (&disk->open_mutex){+.+.}-{3:3}, at: blkdev_get_by_dev+0x121/0x600 block/bdev.c:788
1 lock held by syz.3.19/6048:
 #0: ffff8881401e04c8 (&disk->open_mutex){+.+.}-{3:3}, at: blkdev_get_by_dev+0x121/0x600 block/bdev.c:788
1 lock held by syz.4.147/6452:
 #0: ffff888021de34c8 (&disk->open_mutex){+.+.}-{3:3}, at: blkdev_get_by_dev+0x121/0x600 block/bdev.c:788
1 lock held by syz.5.152/6459:
 #0: ffff888141f384c8 (&disk->open_mutex){+.+.}-{3:3}, at: blkdev_get_by_dev+0x121/0x600 block/bdev.c:788
1 lock held by syz.6.312/6818:
 #0: ffff888021dfb4c8 (&disk->open_mutex){+.+.}-{3:3}, at: blkdev_get_by_dev+0x121/0x600 block/bdev.c:788
1 lock held by syz.7.317/6828:
 #0: ffff888141bd74c8 (&disk->open_mutex){+.+.}-{3:3}, at: blkdev_get_by_dev+0x121/0x600 block/bdev.c:788
2 locks held by syz.8.1158/8465:
 #0: ffffffff8e01ff90 (cb_lock){++++}-{3:3}, at: genl_rcv+0x19/0x40 net/netlink/genetlink.c:1074
 #1: ffffffff8e01fda8 (genl_mutex){+.+.}-{3:3}, at: genl_lock net/netlink/genetlink.c:33 [inline]
 #1: ffffffff8e01fda8 (genl_mutex){+.+.}-{3:3}, at: genl_op_lock net/netlink/genetlink.c:58 [inline]
 #1: ffffffff8e01fda8 (genl_mutex){+.+.}-{3:3}, at: genl_rcv_msg+0x10e/0x790 net/netlink/genetlink.c:1065
3 locks held by syz.1.1159/8467:
 #0: ffffffff8e01ff90 (cb_lock){++++}-{3:3}, at: genl_rcv+0x19/0x40 net/netlink/genetlink.c:1074
 #1: ffffffff8e01fda8 (genl_mutex){+.+.}-{3:3}, at: genl_lock net/netlink/genetlink.c:33 [inline]
 #1: ffffffff8e01fda8 (genl_mutex){+.+.}-{3:3}, at: genl_op_lock net/netlink/genetlink.c:58 [inline]
 #1: ffffffff8e01fda8 (genl_mutex){+.+.}-{3:3}, at: genl_rcv_msg+0x10e/0x790 net/netlink/genetlink.c:1065
 #2: ffff88807aa4b998 (&nbd->config_lock){+.+.}-{3:3}, at: nbd_genl_connect+0x93f/0x18e0 drivers/block/nbd.c:2033
2 locks held by syz.0.1160/8469:
 #0: ffffffff8e01ff90 (cb_lock){++++}-{3:3}, at: genl_rcv+0x19/0x40 net/netlink/genetlink.c:1074
 #1: ffffffff8e01fda8 (genl_mutex){+.+.}-{3:3}, at: genl_lock net/netlink/genetlink.c:33 [inline]
 #1: ffffffff8e01fda8 (genl_mutex){+.+.}-{3:3}, at: genl_op_lock net/netlink/genetlink.c:58 [inline]
 #1: ffffffff8e01fda8 (genl_mutex){+.+.}-{3:3}, at: genl_rcv_msg+0x10e/0x790 net/netlink/genetlink.c:1065
2 locks held by syz.9.1161/8471:
 #0: ffffffff8e01ff90 (cb_lock){++++}-{3:3}, at: genl_rcv+0x19/0x40 net/netlink/genetlink.c:1074
 #1: ffffffff8e01fda8 (genl_mutex){+.+.}-{3:3}, at: genl_lock net/netlink/genetlink.c:33 [inline]
 #1: ffffffff8e01fda8 (genl_mutex){+.+.}-{3:3}, at: genl_op_lock net/netlink/genetlink.c:58 [inline]
 #1: ffffffff8e01fda8 (genl_mutex){+.+.}-{3:3}, at: genl_rcv_msg+0x10e/0x790 net/netlink/genetlink.c:1065

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

NMI backtrace for cpu 0
CPU: 0 PID: 29 Comm: khungtaskd Not tainted 6.6.100-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 05/07/2025
Call Trace:
 <TASK>
 dump_stack_lvl+0x16c/0x230 lib/dump_stack.c:106
 nmi_cpu_backtrace+0x39b/0x3d0 lib/nmi_backtrace.c:113
 nmi_trigger_cpumask_backtrace+0x17a/0x2f0 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+0xf41/0xf80 kernel/hung_task.c:379
 kthread+0x2fa/0x390 kernel/kthread.c:388
 ret_from_fork+0x48/0x80 arch/x86/kernel/process.c:152
 ret_from_fork_asm+0x11/0x20 arch/x86/entry/entry_64.S:293
 </TASK>
Sending NMI from CPU 0 to CPUs 1:
NMI backtrace for cpu 1
CPU: 1 PID: 6041 Comm: udevd Not tainted 6.6.100-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 05/07/2025
RIP: 0010:check_kcov_mode kernel/kcov.c:182 [inline]
RIP: 0010:write_comp_data kernel/kcov.c:245 [inline]
RIP: 0010:__sanitizer_cov_trace_cmp8+0x17/0x80 kernel/kcov.c:293
Code: 48 89 44 11 20 c3 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 00 f3 0f 1e fa 48 8b 04 24 65 48 8b 0d 60 22 7e 7e 65 8b 15 61 22 7e 7e <81> e2 00 01 ff 00 74 11 81 fa 00 01 00 00 75 57 83 b9 1c 16 00 00
RSP: 0018:ffffc90003616730 EFLAGS: 00000002
RAX: ffffffff813aa449 RBX: ffffffff81b4a0c0 RCX: ffff888028f09e00
RDX: 0000000080000002 RSI: 0000000000000001 RDI: ffffffff81b4a0c0
RBP: ffffc90003616858 R08: ffffc900036168d0 R09: 000000000000000b
R10: 0000000000000004 R11: 0000000000000000 R12: ffffc90003616808
R13: dffffc0000000000 R14: ffffc9000361683d R15: 0000000000000001
FS:  00007f15e8b74880(0000) GS:ffff8880b8f00000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 00007f7bf96e56c0 CR3: 000000005e1ea000 CR4: 00000000003506e0
Call Trace:
 <TASK>
 orc_find arch/x86/kernel/unwind_orc.c:202 [inline]
 unwind_next_frame+0x189/0x2970 arch/x86/kernel/unwind_orc.c:494
 arch_stack_walk+0x144/0x190 arch/x86/kernel/stacktrace.c:25
 stack_trace_save+0x9c/0xe0 kernel/stacktrace.c:122
 kasan_save_stack+0x3e/0x60 mm/kasan/common.c:45
 __kasan_record_aux_stack+0xaf/0xc0 mm/kasan/generic.c:492
 insert_work+0x3d/0x310 kernel/workqueue.c:1651
 __queue_work+0xc39/0x1020 kernel/workqueue.c:1800
 mod_delayed_work_on+0xc7/0x1a0 kernel/workqueue.c:2025
 kblockd_mod_delayed_work_on+0x29/0x40 block/blk-core.c:1059
 blk_mq_run_hw_queue block/blk-mq.c:2314 [inline]
 blk_mq_submit_bio+0xfb2/0x20e0 block/blk-mq.c:3078
 __submit_bio+0x12b/0x260 block/blk-core.c:610
 __submit_bio_noacct_mq block/blk-core.c:689 [inline]
 submit_bio_noacct_nocheck+0x6bf/0x990 block/blk-core.c:718
 submit_bh fs/buffer.c:2835 [inline]
 block_read_full_folio+0xab0/0xf40 fs/buffer.c:2460
 filemap_read_folio+0x167/0x760 mm/filemap.c:2420
 do_read_cache_folio+0x470/0x7e0 mm/filemap.c:3789
 read_mapping_folio include/linux/pagemap.h:898 [inline]
 read_part_sector+0xd2/0x350 block/partitions/core.c:718
 ldm_validate_partition_table block/partitions/ldm.c:502 [inline]
 ldm_partition+0xf5/0x4260 block/partitions/ldm.c:1440
 check_partition block/partitions/core.c:138 [inline]
 blk_add_partitions block/partitions/core.c:600 [inline]
 bdev_disk_changed+0x73a/0x1410 block/partitions/core.c:689
 blkdev_get_whole+0x30d/0x390 block/bdev.c:655
 blkdev_get_by_dev+0x279/0x600 block/bdev.c:797
 blkdev_open+0x152/0x360 block/fops.c:589
 do_dentry_open+0x8c6/0x1500 fs/open.c:929
 do_open fs/namei.c:3632 [inline]
 path_openat+0x274b/0x3190 fs/namei.c:3789
 do_filp_open+0x1c5/0x3d0 fs/namei.c:3816
 do_sys_openat2+0x12c/0x1c0 fs/open.c:1419
 do_sys_open fs/open.c:1434 [inline]
 __do_sys_openat fs/open.c:1450 [inline]
 __se_sys_openat fs/open.c:1445 [inline]
 __x64_sys_openat+0x139/0x160 fs/open.c:1445
 do_syscall_x64 arch/x86/entry/common.c:51 [inline]
 do_syscall_64+0x55/0xb0 arch/x86/entry/common.c:81
 entry_SYSCALL_64_after_hwframe+0x68/0xd2
RIP: 0033:0x7f15e84a7407
Code: 48 89 fa 4c 89 df e8 38 aa 00 00 8b 93 08 03 00 00 59 5e 48 83 f8 fc 74 1a 5b c3 0f 1f 84 00 00 00 00 00 48 8b 44 24 10 0f 05 <5b> c3 0f 1f 80 00 00 00 00 83 e2 39 83 fa 08 75 de e8 23 ff ff ff
RSP: 002b:00007ffd62595a00 EFLAGS: 00000202 ORIG_RAX: 0000000000000101
RAX: ffffffffffffffda RBX: 00007f15e8b74880 RCX: 00007f15e84a7407
RDX: 0000000000080000 RSI: 0000557f2f902020 RDI: ffffffffffffff9c
RBP: 0000000000000001 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000202 R12: 0000557f1997795f
R13: 0000557f19988660 R14: 0000000000000000 R15: 00000000ffffffff
 </TASK>

Crashes (7):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2025/07/27 11:52 linux-6.6.y dbcb8d8e4163 fb8f743d .config console log report syz / log C [disk image] [vmlinux] [kernel image] ci2-linux-6-6-kasan INFO: task hung in blkdev_get_by_dev
2025/08/21 01:37 linux-6.6.y bb9c90ab9c5a 0b9605c8 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-6-kasan INFO: task hung in blkdev_get_by_dev
2025/08/17 04:03 linux-6.6.y bb9c90ab9c5a 1804e95e .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-6-kasan INFO: task hung in blkdev_get_by_dev
2025/08/17 04:03 linux-6.6.y bb9c90ab9c5a 1804e95e .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-6-kasan INFO: task hung in blkdev_get_by_dev
2025/08/02 18:03 linux-6.6.y 3a8ababb8b6a 7368264b .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-6-kasan INFO: task hung in blkdev_get_by_dev
2025/07/28 21:08 linux-6.6.y dbcb8d8e4163 6654ea9c .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-6-kasan INFO: task hung in blkdev_get_by_dev
2025/06/21 06:39 linux-6.6.y 6282921b6825 d6cdfb8a .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-6-kasan INFO: task hung in blkdev_get_by_dev
* Struck through repros no longer work on HEAD.