syzbot


INFO: task hung in blkdev_get_by_dev

Status: auto-obsoleted due to no activity on 2023/08/23 09:06
Reported-by: syzbot+d16acf6a7992a9ba4c17@syzkaller.appspotmail.com
First crash: 369d, last: 369d
Similar bugs (8)
Kernel Title Repro Cause bisect Fix bisect Count Last Reported Patched Status
linux-6.1 INFO: task hung in blkdev_get_by_dev origin:lts-only C 5 4d14h 97d 0/3 upstream: reported C repro on 2024/01/29 00:39
linux-5.15 INFO: task hung in blkdev_get_by_dev (2) 1 238d 238d 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 788d 788d 0/26 auto-closed as invalid on 2022/05/08 09:47
linux-5.15 INFO: task hung in blkdev_get_by_dev (3) 3 23d 94d 0/3 upstream: reported on 2024/02/01 00:39
upstream INFO: task hung in blkdev_get_by_dev fs 1 1167d 1167d 0/26 auto-closed as invalid on 2021/05/23 22:12
upstream INFO: task hung in blkdev_get_by_dev (4) block 1 616d 616d 0/26 auto-obsoleted due to no activity on 2022/11/25 11:03
upstream INFO: task hung in blkdev_get_by_dev (2) block 1727 819d 899d 0/26 closed as dup on 2021/11/21 14:02
upstream INFO: task hung in blkdev_get_by_dev (5) block C error 32 53d 429d 0/26 upstream: reported C repro on 2023/03/02 18:11

Sample crash report:
INFO: task syz-executor.0:16794 blocked for more than 143 seconds.
      Not tainted 5.15.110-syzkaller #0
"echo 0 > /proc/sys/kernel/hung_task_timeout_secs" disables this message.
task:syz-executor.0  state:D stack:27520 pid:16794 ppid:  3545 flags:0x00004004
Call Trace:
 <TASK>
 context_switch kernel/sched/core.c:5026 [inline]
 __schedule+0x12c4/0x4590 kernel/sched/core.c:6372
 schedule+0x11b/0x1f0 kernel/sched/core.c:6455
 schedule_preempt_disabled+0xf/0x20 kernel/sched/core.c:6514
 __mutex_lock_common+0xe34/0x25a0 kernel/locking/mutex.c:669
 __mutex_lock kernel/locking/mutex.c:729 [inline]
 mutex_lock_nested+0x17/0x20 kernel/locking/mutex.c:743
 blkdev_get_by_dev+0x14d/0xa50 block/bdev.c:817
 blkdev_open+0x138/0x2d0 block/fops.c:463
 do_dentry_open+0x807/0xfb0 fs/open.c:826
 do_open fs/namei.c:3538 [inline]
 path_openat+0x2702/0x2f20 fs/namei.c:3672
 do_filp_open+0x21c/0x460 fs/namei.c:3699
 do_sys_openat2+0x13b/0x500 fs/open.c:1211
 do_sys_open fs/open.c:1227 [inline]
 __do_sys_openat fs/open.c:1243 [inline]
 __se_sys_openat fs/open.c:1238 [inline]
 __x64_sys_openat+0x243/0x290 fs/open.c:1238
 do_syscall_x64 arch/x86/entry/common.c:50 [inline]
 do_syscall_64+0x3d/0xb0 arch/x86/entry/common.c:80
 entry_SYSCALL_64_after_hwframe+0x61/0xcb
RIP: 0033:0x7f6634523169
RSP: 002b:00007f6632a95168 EFLAGS: 00000246 ORIG_RAX: 0000000000000101
RAX: ffffffffffffffda RBX: 00007f6634642f80 RCX: 00007f6634523169
RDX: 0000000000000000 RSI: 0000000020000000 RDI: ffffffffffffff9c
RBP: 00007f663457eca1 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000
R13: 00007ffffb41f5ff R14: 00007f6632a95300 R15: 0000000000022000
 </TASK>
INFO: task syz-executor.1:16803 blocked for more than 144 seconds.
      Not tainted 5.15.110-syzkaller #0
"echo 0 > /proc/sys/kernel/hung_task_timeout_secs" disables this message.
task:syz-executor.1  state:D stack:27520 pid:16803 ppid:  3551 flags:0x00004004
Call Trace:
 <TASK>
 context_switch kernel/sched/core.c:5026 [inline]
 __schedule+0x12c4/0x4590 kernel/sched/core.c:6372
 schedule+0x11b/0x1f0 kernel/sched/core.c:6455
 schedule_preempt_disabled+0xf/0x20 kernel/sched/core.c:6514
 __mutex_lock_common+0xe34/0x25a0 kernel/locking/mutex.c:669
 __mutex_lock kernel/locking/mutex.c:729 [inline]
 mutex_lock_nested+0x17/0x20 kernel/locking/mutex.c:743
 blkdev_get_by_dev+0x14d/0xa50 block/bdev.c:817
 blkdev_open+0x138/0x2d0 block/fops.c:463
 do_dentry_open+0x807/0xfb0 fs/open.c:826
 do_open fs/namei.c:3538 [inline]
 path_openat+0x2702/0x2f20 fs/namei.c:3672
 do_filp_open+0x21c/0x460 fs/namei.c:3699
 do_sys_openat2+0x13b/0x500 fs/open.c:1211
 do_sys_open fs/open.c:1227 [inline]
 __do_sys_openat fs/open.c:1243 [inline]
 __se_sys_openat fs/open.c:1238 [inline]
 __x64_sys_openat+0x243/0x290 fs/open.c:1238
 do_syscall_x64 arch/x86/entry/common.c:50 [inline]
 do_syscall_64+0x3d/0xb0 arch/x86/entry/common.c:80
 entry_SYSCALL_64_after_hwframe+0x61/0xcb
RIP: 0033:0x7f31c8bc9169
RSP: 002b:00007f31c713b168 EFLAGS: 00000246 ORIG_RAX: 0000000000000101
RAX: ffffffffffffffda RBX: 00007f31c8ce8f80 RCX: 00007f31c8bc9169
RDX: 0000000000000000 RSI: 0000000020009400 RDI: ffffffffffffff9c
RBP: 00007f31c8c24ca1 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000
R13: 00007ffe90d56baf R14: 00007f31c713b300 R15: 0000000000022000
 </TASK>

Showing all locks held in the system:
1 lock held by ksoftirqd/0/14:
 #0: ffff8880b9a39698 (&rq->__lock){-.-.}-{2:2}, at: raw_spin_rq_lock_nested+0xa8/0x140 kernel/sched/core.c:483
1 lock held by khungtaskd/26:
 #0: ffffffff8c91c4e0 (rcu_read_lock){....}-{1:2}, at: rcu_lock_acquire+0x0/0x30
3 locks held by kcompactd0/29:
2 locks held by getty/3260:
 #0: ffff8880244d7098 (&tty->ldisc_sem){++++}-{0:0}, at: tty_ldisc_ref_wait+0x21/0x70 drivers/tty/tty_ldisc.c:252
 #1: ffffc90002bb62e8 (&ldata->atomic_read_lock){+.+.}-{3:3}, at: n_tty_read+0x6af/0x1da0 drivers/tty/n_tty.c:2147
1 lock held by syz-executor.3/10292:
1 lock held by syz-executor.5/10351:
2 locks held by kworker/u4:0/12773:
1 lock held by syz-executor.5/14734:
1 lock held by syz-executor.0/16794:
 #0: ffff88814784c118 (&disk->open_mutex){+.+.}-{3:3}, at: blkdev_get_by_dev+0x14d/0xa50 block/bdev.c:817
1 lock held by syz-executor.1/16803:
 #0: ffff88814784c118 (&disk->open_mutex){+.+.}-{3:3}, at: blkdev_get_by_dev+0x14d/0xa50 block/bdev.c:817
1 lock held by syz-executor.2/17215:
 #0: ffff88814784c118 (&disk->open_mutex){+.+.}-{3:3}, at: blkdev_get_by_dev+0x14d/0xa50 block/bdev.c:817

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

NMI backtrace for cpu 1
CPU: 1 PID: 26 Comm: khungtaskd Not tainted 5.15.110-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 04/14/2023
Call Trace:
 <TASK>
 __dump_stack lib/dump_stack.c:88 [inline]
 dump_stack_lvl+0x1e3/0x2cb lib/dump_stack.c:106
 nmi_cpu_backtrace+0x46a/0x4a0 lib/nmi_backtrace.c:111
 nmi_trigger_cpumask_backtrace+0x181/0x2a0 lib/nmi_backtrace.c:62
 trigger_all_cpu_backtrace include/linux/nmi.h:148 [inline]
 check_hung_uninterruptible_tasks kernel/hung_task.c:210 [inline]
 watchdog+0xe72/0xeb0 kernel/hung_task.c:295
 kthread+0x3f6/0x4f0 kernel/kthread.c:319
 ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:298
 </TASK>
Sending NMI from CPU 1 to CPUs 0:
NMI backtrace for cpu 0 skipped: idling at native_safe_halt arch/x86/include/asm/irqflags.h:51 [inline]
NMI backtrace for cpu 0 skipped: idling at arch_safe_halt arch/x86/include/asm/irqflags.h:89 [inline]
NMI backtrace for cpu 0 skipped: idling at acpi_safe_halt drivers/acpi/processor_idle.c:109 [inline]
NMI backtrace for cpu 0 skipped: idling at acpi_idle_do_entry+0x10f/0x340 drivers/acpi/processor_idle.c:570

Crashes (1):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2023/05/01 19:01 linux-5.15.y 8a7f2a5c5aa1 62df2017 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan INFO: task hung in blkdev_get_by_dev
* Struck through repros no longer work on HEAD.