[v5.15] INFO: task hung in blkdev_flush_mapping

1 view
Skip to first unread message

syzbot

unread,
Mar 26, 2024, 10:18:31 AMMar 26
to syzkaller...@googlegroups.com
Hello,

syzbot found the following issue on:

HEAD commit: b95c01af2113 Linux 5.15.152
git tree: linux-5.15.y
console output: https://syzkaller.appspot.com/x/log.txt?x=17041d91180000
kernel config: https://syzkaller.appspot.com/x/.config?x=b26cb65e5b8ad5c7
dashboard link: https://syzkaller.appspot.com/bug?extid=fd75559d2bc0789dcd0f
compiler: Debian clang version 15.0.6, GNU ld (GNU Binutils for Debian) 2.40

Unfortunately, I don't have any reproducer for this issue yet.

Downloadable assets:
disk image: https://storage.googleapis.com/syzbot-assets/5cd4262a21bb/disk-b95c01af.raw.xz
vmlinux: https://storage.googleapis.com/syzbot-assets/85698e4f8310/vmlinux-b95c01af.xz
kernel image: https://storage.googleapis.com/syzbot-assets/f57a616768d4/bzImage-b95c01af.xz

IMPORTANT: if you fix the issue, please add the following tag to the commit:
Reported-by: syzbot+fd7555...@syzkaller.appspotmail.com

INFO: task udevd:5040 blocked for more than 143 seconds.
Not tainted 5.15.152-syzkaller #0
"echo 0 > /proc/sys/kernel/hung_task_timeout_secs" disables this message.
task:udevd state:D stack:25952 pid: 5040 ppid: 2964 flags:0x00004006
Call Trace:
<TASK>
context_switch kernel/sched/core.c:5030 [inline]
__schedule+0x12c4/0x45b0 kernel/sched/core.c:6376
schedule+0x11b/0x1f0 kernel/sched/core.c:6459
io_schedule+0x88/0x100 kernel/sched/core.c:8484
wait_on_page_bit_common+0xa13/0x1180 mm/filemap.c:1356
lock_page include/linux/pagemap.h:625 [inline]
truncate_inode_pages_range+0xc17/0x1290 mm/truncate.c:394
kill_bdev block/bdev.c:77 [inline]
blkdev_flush_mapping+0x182/0x340 block/bdev.c:659
blkdev_put_part block/bdev.c:728 [inline]
blkdev_put+0x46c/0x790 block/bdev.c:952
blkdev_close+0x7c/0xa0 block/fops.c:475
__fput+0x3bf/0x890 fs/file_table.c:280
task_work_run+0x129/0x1a0 kernel/task_work.c:164
exit_task_work include/linux/task_work.h:32 [inline]
do_exit+0x6a3/0x2480 kernel/exit.c:872
do_group_exit+0x144/0x310 kernel/exit.c:994
get_signal+0xc66/0x14e0 kernel/signal.c:2889
arch_do_signal_or_restart+0xc3/0x1890 arch/x86/kernel/signal.c:867
handle_signal_work kernel/entry/common.c:148 [inline]
exit_to_user_mode_loop+0x97/0x130 kernel/entry/common.c:172
exit_to_user_mode_prepare+0xb1/0x140 kernel/entry/common.c:208
__syscall_exit_to_user_mode_work kernel/entry/common.c:290 [inline]
syscall_exit_to_user_mode+0x5d/0x250 kernel/entry/common.c:301
do_syscall_64+0x49/0xb0 arch/x86/entry/common.c:86
entry_SYSCALL_64_after_hwframe+0x61/0xcb
RIP: 0033:0x7f9b7b3dbb6a
RSP: 002b:00007ffc582e9cb8 EFLAGS: 00000246 ORIG_RAX: 0000000000000000
RAX: fffffffffffffffc RBX: 0000000000001000 RCX: 00007f9b7b3dbb6a
RDX: 0000000000000400 RSI: 0000558e5913d5a8 RDI: 0000000000000009
RBP: 0000000000000400 R08: 0000558e5913d580 R09: 0000000000000008
R10: 0000000000000051 R11: 0000000000000246 R12: 0000558e5913d580
R13: 0000558e5913d598 R14: 0000558e59110148 R15: 0000558e591100f0
</TASK>

Showing all locks held in the system:
1 lock held by khungtaskd/27:
#0: ffffffff8c91f720 (rcu_read_lock){....}-{1:2}, at: rcu_lock_acquire+0x0/0x30
2 locks held by getty/3266:
#0: ffff88814b283098 (&tty->ldisc_sem){++++}-{0:0}, at: tty_ldisc_ref_wait+0x21/0x70 drivers/tty/tty_ldisc.c:252
#1: ffffc90002bad2e8 (&ldata->atomic_read_lock){+.+.}-{3:3}, at: n_tty_read+0x6af/0x1db0 drivers/tty/n_tty.c:2158
3 locks held by kworker/u5:1/3519:
#0: ffff8880238a5938 ((wq_completion)hci8){+.+.}-{0:0}, at: process_one_work+0x78a/0x10c0 kernel/workqueue.c:2283
#1: ffffc90002dc7d20 ((work_completion)(&hdev->power_on)){+.+.}-{0:0}, at: process_one_work+0x7d0/0x10c0 kernel/workqueue.c:2285
#2: ffff88805618cff0 (&hdev->req_lock){+.+.}-{3:3}, at: hci_dev_do_open+0xa4/0x1330 net/bluetooth/hci_core.c:1446
1 lock held by udevd/5040:
#0: ffff88801c1e3918 (&disk->open_mutex){+.+.}-{3:3}, at: blkdev_put+0xfb/0x790 block/bdev.c:912
1 lock held by syz-executor.1/8314:
#0: ffff88801c1e3918 (&disk->open_mutex){+.+.}-{3:3}, at: blkdev_get_by_dev+0x14d/0xa50 block/bdev.c:817
1 lock held by syz-executor.1/8717:
#0: ffff88801c1e3918 (&disk->open_mutex){+.+.}-{3:3}, at: blkdev_get_by_dev+0x14d/0xa50 block/bdev.c:817
1 lock held by syz-executor.1/9196:
#0: ffff88801c1e3918 (&disk->open_mutex){+.+.}-{3:3}, at: blkdev_get_by_dev+0x14d/0xa50 block/bdev.c:817
1 lock held by syz-executor.1/9604:
#0: ffff888076ef6098 (&tty->ldisc_sem){++++}-{0:0}, at: __tty_ldisc_lock drivers/tty/tty_ldisc.c:300 [inline]
#0: ffff888076ef6098 (&tty->ldisc_sem){++++}-{0:0}, at: tty_ldisc_lock_pair_timeout drivers/tty/tty_ldisc.c:363 [inline]
#0: ffff888076ef6098 (&tty->ldisc_sem){++++}-{0:0}, at: tty_ldisc_lock_pair drivers/tty/tty_ldisc.c:377 [inline]
#0: ffff888076ef6098 (&tty->ldisc_sem){++++}-{0:0}, at: tty_ldisc_release+0x10c/0x200 drivers/tty/tty_ldisc.c:802

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

NMI backtrace for cpu 0
CPU: 0 PID: 27 Comm: khungtaskd Not tainted 5.15.152-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 02/29/2024
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 0 to CPUs 1:
NMI backtrace for cpu 1
CPU: 1 PID: 373 Comm: kworker/u4:3 Not tainted 5.15.152-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 02/29/2024
Workqueue: bat_events batadv_iv_send_outstanding_bat_ogm_packet
RIP: 0010:lock_acquire+0x92/0x4f0 kernel/locking/lockdep.c:5591
Code: 81 4c 8d 64 24 40 49 c1 ec 03 48 b8 f1 f1 f1 f1 00 f2 f2 f2 4b 89 04 2c 43 c7 44 2c 09 f2 f2 f2 00 43 c7 44 2c 11 f3 f3 f3 f3 <66> 43 c7 44 2c 15 f3 f3 43 c6 44 2c 17 f3 0f 1f 44 00 00 65 8b 1d
RSP: 0018:ffffc900024e78e0 EFLAGS: 00000a06
RAX: f2f2f200f1f1f1f1 RBX: 0000000000000231 RCX: 0000000000000002
RDX: 0000000000000000 RSI: 0000000000000000 RDI: ffffffff8c91f720
RBP: ffffc900024e7a40 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: dffffc0000000001 R12: 1ffff9200049cf24
R13: dffffc0000000000 R14: 0000000000000000 R15: dffffc0000000000
FS: 0000000000000000(0000) GS:ffff8880b9b00000(0000) knlGS:0000000000000000
CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 000055555563b938 CR3: 00000000232fc000 CR4: 00000000003506e0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
Call Trace:
<NMI>
</NMI>
<TASK>
rcu_lock_acquire+0x2a/0x30 include/linux/rcupdate.h:269
rcu_read_lock include/linux/rcupdate.h:696 [inline]
batadv_iv_ogm_slide_own_bcast_window net/batman-adv/bat_iv_ogm.c:755 [inline]
batadv_iv_ogm_schedule_buff net/batman-adv/bat_iv_ogm.c:826 [inline]
batadv_iv_ogm_schedule+0x429/0x1000 net/batman-adv/bat_iv_ogm.c:869
batadv_iv_send_outstanding_bat_ogm_packet+0x6fa/0x800 net/batman-adv/bat_iv_ogm.c:1713
process_one_work+0x8a1/0x10c0 kernel/workqueue.c:2310
worker_thread+0xaca/0x1280 kernel/workqueue.c:2457
kthread+0x3f6/0x4f0 kernel/kthread.c:319
ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:298
</TASK>


---
This report is generated by a bot. It may contain errors.
See https://goo.gl/tpsmEJ for more information about syzbot.
syzbot engineers can be reached at syzk...@googlegroups.com.

syzbot will keep track of this issue. See:
https://goo.gl/tpsmEJ#status for how to communicate with syzbot.

If the report is already addressed, let syzbot know by replying with:
#syz fix: exact-commit-title

If you want to overwrite report's subsystems, reply with:
#syz set subsystems: new-subsystem
(See the list of subsystem names on the web dashboard)

If the report is a duplicate of another one, reply with:
#syz dup: exact-subject-of-another-report

If you want to undo deduplication, reply with:
#syz undup
Reply all
Reply to author
Forward
0 new messages