INFO: task hung in blkdev_reread_part

2 views
Skip to first unread message

syzbot

unread,
Dec 9, 2017, 5:43:02 AM12/9/17
to linux-...@vger.kernel.org, mi...@redhat.com, pet...@infradead.org, syzkall...@googlegroups.com
Hello,

syzkaller hit the following crash on
a0651c7fa2c088a605f63792279859608ed7f2c8
git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/master
compiler: gcc (GCC) 7.1.1 20170620
.config is attached
Raw console output is attached.

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


netlink: 16 bytes leftover after parsing attributes in process
`syz-executor1'.
INFO: task syz-executor4:9515 blocked for more than 120 seconds.
Not tainted 4.15.0-rc1+ #204
"echo 0 > /proc/sys/kernel/hung_task_timeout_secs" disables this message.
syz-executor4 D20544 9515 3350 0x00000004
Call Trace:
context_switch kernel/sched/core.c:2799 [inline]
__schedule+0x8eb/0x2060 kernel/sched/core.c:3375
schedule+0xf5/0x430 kernel/sched/core.c:3434
schedule_preempt_disabled+0x10/0x20 kernel/sched/core.c:3492
__mutex_lock_common kernel/locking/mutex.c:833 [inline]
__mutex_lock+0xaad/0x1a80 kernel/locking/mutex.c:893
mutex_lock_nested+0x16/0x20 kernel/locking/mutex.c:908
blkdev_reread_part+0x1e/0x40 block/ioctl.c:192
loop_reread_partitions+0x12f/0x1a0 drivers/block/loop.c:619
loop_set_status+0x9ba/0xf60 drivers/block/loop.c:1161
loop_set_status64+0x95/0x100 drivers/block/loop.c:1271
lo_ioctl+0xd98/0x1b90 drivers/block/loop.c:1381
__blkdev_driver_ioctl block/ioctl.c:303 [inline]
blkdev_ioctl+0x1759/0x1e00 block/ioctl.c:601
block_ioctl+0xea/0x130 fs/block_dev.c:1860
vfs_ioctl fs/ioctl.c:46 [inline]
do_vfs_ioctl+0x1b1/0x1530 fs/ioctl.c:686
SYSC_ioctl fs/ioctl.c:701 [inline]
SyS_ioctl+0x8f/0xc0 fs/ioctl.c:692
entry_SYSCALL_64_fastpath+0x1f/0x96
RIP: 0033:0x4529d9
RSP: 002b:00007f09e88bbc58 EFLAGS: 00000212 ORIG_RAX: 0000000000000010
RAX: ffffffffffffffda RBX: 0000000000758020 RCX: 00000000004529d9
RDX: 0000000020a8ff18 RSI: 0000000000004c04 RDI: 0000000000000016
RBP: 0000000000000540 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000212 R12: 00000000006f4ea0
R13: 00000000ffffffff R14: 00007f09e88bc6d4 R15: 0000000000000000

Showing all locks held in the system:
2 locks held by khungtaskd/674:
#0: (rcu_read_lock){....}, at: [<00000000396cd1a8>]
check_hung_uninterruptible_tasks kernel/hung_task.c:175 [inline]
#0: (rcu_read_lock){....}, at: [<00000000396cd1a8>] watchdog+0x1c5/0xd60
kernel/hung_task.c:249
#1: (tasklist_lock){.+.+}, at: [<0000000096a7b7f4>]
debug_show_all_locks+0xd3/0x400 kernel/locking/lockdep.c:4554
2 locks held by getty/3054:
#0: (&tty->ldisc_sem){++++}, at: [<00000000c828faca>]
ldsem_down_read+0x37/0x40 drivers/tty/tty_ldsem.c:365
#1: (&ldata->atomic_read_lock){+.+.}, at: [<00000000a7f4335e>]
n_tty_read+0x2f2/0x1a10 drivers/tty/n_tty.c:2131
2 locks held by getty/3055:
#0: (&tty->ldisc_sem){++++}, at: [<00000000c828faca>]
ldsem_down_read+0x37/0x40 drivers/tty/tty_ldsem.c:365
#1: (&ldata->atomic_read_lock){+.+.}, at: [<00000000a7f4335e>]
n_tty_read+0x2f2/0x1a10 drivers/tty/n_tty.c:2131
2 locks held by getty/3056:
#0: (&tty->ldisc_sem){++++}, at: [<00000000c828faca>]
ldsem_down_read+0x37/0x40 drivers/tty/tty_ldsem.c:365
#1: (&ldata->atomic_read_lock){+.+.}, at: [<00000000a7f4335e>]
n_tty_read+0x2f2/0x1a10 drivers/tty/n_tty.c:2131
2 locks held by getty/3057:
#0: (&tty->ldisc_sem){++++}, at: [<00000000c828faca>]
ldsem_down_read+0x37/0x40 drivers/tty/tty_ldsem.c:365
#1: (&ldata->atomic_read_lock){+.+.}, at: [<00000000a7f4335e>]
n_tty_read+0x2f2/0x1a10 drivers/tty/n_tty.c:2131
2 locks held by getty/3058:
#0: (&tty->ldisc_sem){++++}, at: [<00000000c828faca>]
ldsem_down_read+0x37/0x40 drivers/tty/tty_ldsem.c:365
#1: (&ldata->atomic_read_lock){+.+.}, at: [<00000000a7f4335e>]
n_tty_read+0x2f2/0x1a10 drivers/tty/n_tty.c:2131
2 locks held by getty/3059:
#0: (&tty->ldisc_sem){++++}, at: [<00000000c828faca>]
ldsem_down_read+0x37/0x40 drivers/tty/tty_ldsem.c:365
#1: (&ldata->atomic_read_lock){+.+.}, at: [<00000000a7f4335e>]
n_tty_read+0x2f2/0x1a10 drivers/tty/n_tty.c:2131
2 locks held by getty/3060:
#0: (&tty->ldisc_sem){++++}, at: [<00000000c828faca>]
ldsem_down_read+0x37/0x40 drivers/tty/tty_ldsem.c:365
#1: (&ldata->atomic_read_lock){+.+.}, at: [<00000000a7f4335e>]
n_tty_read+0x2f2/0x1a10 drivers/tty/n_tty.c:2131
2 locks held by syz-executor4/9515:
#0: (&lo->lo_ctl_mutex/1){+.+.}, at: [<00000000e7502bc1>]
lo_ioctl+0x8b/0x1b90 drivers/block/loop.c:1355
#1: (&bdev->bd_mutex){+.+.}, at: [<00000000435b4ba4>]
blkdev_reread_part+0x1e/0x40 block/ioctl.c:192
1 lock held by syz-executor4/9522:
#0: (&lo->lo_ctl_mutex/1){+.+.}, at: [<00000000e7502bc1>]
lo_ioctl+0x8b/0x1b90 drivers/block/loop.c:1355
1 lock held by syz-executor4/9541:
#0: (&bdev->bd_mutex){+.+.}, at: [<00000000b174d747>]
__blkdev_get+0x158/0x10e0 fs/block_dev.c:1439
1 lock held by syz-executor7/9521:
#0: (&lo->lo_ctl_mutex/1){+.+.}, at: [<00000000e7502bc1>]
lo_ioctl+0x8b/0x1b90 drivers/block/loop.c:1355
1 lock held by syz-executor7/9525:
#0: (&lo->lo_ctl_mutex/1){+.+.}, at: [<00000000e7502bc1>]
lo_ioctl+0x8b/0x1b90 drivers/block/loop.c:1355
1 lock held by syz-executor7/9547:
#0: (&bdev->bd_mutex){+.+.}, at: [<00000000b174d747>]
__blkdev_get+0x158/0x10e0 fs/block_dev.c:1439
2 locks held by blkid/9520:
#0: (&bdev->bd_mutex){+.+.}, at: [<00000000b174d747>]
__blkdev_get+0x158/0x10e0 fs/block_dev.c:1439
#1: (loop_index_mutex){+.+.}, at: [<000000005253b538>] lo_open+0x1b/0xa0
drivers/block/loop.c:1571
1 lock held by syz-executor0/9527:
#0: (loop_index_mutex){+.+.}, at: [<00000000268a88d7>]
loop_control_ioctl+0x89/0x490 drivers/block/loop.c:1932
1 lock held by syz-executor0/9554:
#0: (loop_index_mutex){+.+.}, at: [<00000000268a88d7>]
loop_control_ioctl+0x89/0x490 drivers/block/loop.c:1932
2 locks held by syz-executor5/9526:
#0: (loop_index_mutex){+.+.}, at: [<00000000268a88d7>]
loop_control_ioctl+0x89/0x490 drivers/block/loop.c:1932
#1: (&lo->lo_ctl_mutex#2){+.+.}, at: [<000000001a5f807e>]
loop_control_ioctl+0x1a7/0x490 drivers/block/loop.c:1946
1 lock held by syz-executor5/9542:
#0: (loop_index_mutex){+.+.}, at: [<00000000268a88d7>]
loop_control_ioctl+0x89/0x490 drivers/block/loop.c:1932
1 lock held by syz-executor2/9530:
#0: (loop_index_mutex){+.+.}, at: [<00000000268a88d7>]
loop_control_ioctl+0x89/0x490 drivers/block/loop.c:1932
1 lock held by syz-executor2/9564:
#0: (loop_index_mutex){+.+.}, at: [<00000000268a88d7>]
loop_control_ioctl+0x89/0x490 drivers/block/loop.c:1932
1 lock held by syz-executor6/9534:
#0: (loop_index_mutex){+.+.}, at: [<00000000268a88d7>]
loop_control_ioctl+0x89/0x490 drivers/block/loop.c:1932
1 lock held by syz-executor6/9556:
#0: (loop_index_mutex){+.+.}, at: [<00000000268a88d7>]
loop_control_ioctl+0x89/0x490 drivers/block/loop.c:1932
1 lock held by syz-executor3/9539:
#0: (loop_index_mutex){+.+.}, at: [<00000000268a88d7>]
loop_control_ioctl+0x89/0x490 drivers/block/loop.c:1932
1 lock held by syz-executor3/9565:
#0: (loop_index_mutex){+.+.}, at: [<00000000268a88d7>]
loop_control_ioctl+0x89/0x490 drivers/block/loop.c:1932
1 lock held by syz-executor1/9543:
#0: (loop_index_mutex){+.+.}, at: [<00000000268a88d7>]
loop_control_ioctl+0x89/0x490 drivers/block/loop.c:1932
1 lock held by syz-executor1/9566:
#0: (loop_index_mutex){+.+.}, at: [<00000000268a88d7>]
loop_control_ioctl+0x89/0x490 drivers/block/loop.c:1932

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

NMI backtrace for cpu 0
CPU: 0 PID: 674 Comm: khungtaskd Not tainted 4.15.0-rc1+ #204
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS
Google 01/01/2011
Call Trace:
__dump_stack lib/dump_stack.c:17 [inline]
dump_stack+0x194/0x257 lib/dump_stack.c:53
nmi_cpu_backtrace+0x1d2/0x210 lib/nmi_backtrace.c:103
nmi_trigger_cpumask_backtrace+0x122/0x180 lib/nmi_backtrace.c:62
arch_trigger_cpumask_backtrace+0x14/0x20 arch/x86/kernel/apic/hw_nmi.c:38
trigger_all_cpu_backtrace include/linux/nmi.h:138 [inline]
check_hung_task kernel/hung_task.c:132 [inline]
check_hung_uninterruptible_tasks kernel/hung_task.c:190 [inline]
watchdog+0x90c/0xd60 kernel/hung_task.c:249
kthread+0x37a/0x440 kernel/kthread.c:238
ret_from_fork+0x24/0x30 arch/x86/entry/entry_64.S:441
Sending NMI from CPU 0 to CPUs 1:
NMI backtrace for cpu 1 skipped: idling at native_safe_halt+0x6/0x10
arch/x86/include/asm/irqflags.h:54


---
This bug is generated by a dumb bot. It may contain errors.
See https://goo.gl/tpsmEJ for details.
Direct all questions to syzk...@googlegroups.com.
Please credit me with: Reported-by: syzbot <syzk...@googlegroups.com>

syzbot will keep track of this bug report.
Once a fix for this bug is merged into any tree, reply to this email with:
#syz fix: exact-commit-title
To mark this as a duplicate of another syzbot report, please reply with:
#syz dup: exact-subject-of-another-report
If it's a one-off invalid bug report, please reply with:
#syz invalid
Note: if the crash happens again, it will cause creation of a new bug
report.
Note: all commands must start from beginning of the line in the email body.
config.txt
raw.log

Dmitry Vyukov

unread,
Dec 12, 2017, 11:29:23 AM12/12/17
to syzbot, LKML, Ingo Molnar, Peter Zijlstra, syzkall...@googlegroups.com, Jens Axboe, Ming Lei, Omar Sandoval, Hannes Reinecke, sh...@fb.com
On Sat, Dec 9, 2017 at 11:43 AM, syzbot
<bot+7ca1333efc3e4a9174...@syzkaller.appspotmail.com>
wrote:
+loop maintainers

#syz dup: INFO: task hung in lo_ioctl

> ---
> This bug is generated by a dumb bot. It may contain errors.
> See https://goo.gl/tpsmEJ for details.
> Direct all questions to syzk...@googlegroups.com.
> Please credit me with: Reported-by: syzbot <syzk...@googlegroups.com>
>
> syzbot will keep track of this bug report.
> Once a fix for this bug is merged into any tree, reply to this email with:
> #syz fix: exact-commit-title
> To mark this as a duplicate of another syzbot report, please reply with:
> #syz dup: exact-subject-of-another-report
> If it's a one-off invalid bug report, please reply with:
> #syz invalid
> Note: if the crash happens again, it will cause creation of a new bug
> report.
> Note: all commands must start from beginning of the line in the email body.
>
> --
> You received this message because you are subscribed to the Google Groups
> "syzkaller-bugs" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to syzkaller-bug...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/syzkaller-bugs/f403045fbfa01847a2055fe5f728%40google.com.
> For more options, visit https://groups.google.com/d/optout.
Reply all
Reply to author
Forward
0 new messages