syzbot


WARNING in task_non_contending

Status: auto-closed as invalid on 2019/03/27 15:23
First crash: 2245d, last: 2245d

Sample crash report:
loop5: p253 start 1 is beyond EOD, truncated
loop5: p254 start 1 is beyond EOD, truncated
loop5: p255 start 1 is beyond EOD, truncated
sched: DL replenish lagged too much
------------[ cut here ]------------
WARNING: CPU: 0 PID: 30135 at kernel/sched/deadline.c:222 task_non_contending+0xa45/0xf40 kernel/sched/deadline.c:256
Kernel panic - not syncing: panic_on_warn set ...

CPU: 0 PID: 30135 Comm: syz-executor3 Not tainted 4.14.72+ #11
Call Trace:
 __dump_stack lib/dump_stack.c:17 [inline]
 dump_stack+0xb9/0x11b lib/dump_stack.c:53
 panic+0x1bf/0x3a4 kernel/panic.c:181
 __warn.cold.7+0x148/0x185 kernel/panic.c:542
 report_bug+0x1f7/0x26c lib/bug.c:186
 fixup_bug arch/x86/kernel/traps.c:177 [inline]
 do_error_trap+0x1ba/0x2c0 arch/x86/kernel/traps.c:295
 invalid_op+0x18/0x40 arch/x86/entry/entry_64.S:944
RIP: 0010:task_non_contending+0xa45/0xf40 kernel/sched/deadline.c:256
RSP: 0018:ffff8801c7ff7900 EFLAGS: 00010002
RAX: 0000000000000001 RBX: ffff8801c38bc680 RCX: 0000000000000000
RDX: 0000000000000000 RSI: ffff8801c38bc680 RDI: ffff8801dbb24a20
RBP: ffff8801c38bc6bc R08: 0000000000000001 R09: 0000000000000000
R10: ffff8801c38bced8 R11: 0000000000000001 R12: ffff8801c38bc9b8
R13: ffff8801dba00000 R14: 000000000002a240 R15: ffff8801c38bc680
 __schedule+0x9af/0x1ed0 kernel/sched/core.c:3388
 do_task_dead+0xc7/0x100 kernel/sched/core.c:3463
 do_exit+0x1544/0x2800 kernel/exit.c:922
 do_group_exit+0x100/0x2e0 kernel/exit.c:968
 get_signal+0x4e5/0x1470 kernel/signal.c:2348
 do_signal+0x8f/0x1660 arch/x86/kernel/signal.c:809
 exit_to_usermode_loop+0x116/0x150 arch/x86/entry/common.c:159
 prepare_exit_to_usermode arch/x86/entry/common.c:198 [inline]
 syscall_return_slowpath arch/x86/entry/common.c:267 [inline]
 do_syscall_64+0x35d/0x4b0 arch/x86/entry/common.c:294
 entry_SYSCALL_64_after_hwframe+0x42/0xb7
RIP: 0033:0x457579
RSP: 002b:00007fc0cfa99cf8 EFLAGS: 00000246 ORIG_RAX: 00000000000000ca
RAX: fffffffffffffe00 RBX: 000000000072bfa8 RCX: 0000000000457579
RDX: 0000000000000000 RSI: 0000000000000080 RDI: 000000000072bfa8
RBP: 000000000072bfa0 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000246 R12: 000000000072bfac
R13: 00007ffc382de54f R14: 00007fc0cfa9a9c0 R15: 0000000000000001

======================================================
WARNING: possible circular locking dependency detected
4.14.72+ #11 Not tainted
------------------------------------------------------
syz-executor3/30135 is trying to acquire lock:
 ((console_sem).lock){-.-.}, at: [<ffffffff945f03ee>] down_trylock+0xe/0x70 kernel/locking/semaphore.c:136

but task is already holding lock:
 (&rq->lock){-.-.}, at: [<ffffffff95c4447a>] rq_lock kernel/sched/sched.h:1835 [inline]
 (&rq->lock){-.-.}, at: [<ffffffff95c4447a>] __schedule+0x19a/0x1ed0 kernel/sched/core.c:3376

which lock already depends on the new lock.


the existing dependency chain (in reverse order) is:

-> #2 (&rq->lock){-.-.}:
       __raw_spin_lock include/linux/spinlock_api_smp.h:142 [inline]
       _raw_spin_lock+0x2a/0x40 kernel/locking/spinlock.c:152
       rq_lock kernel/sched/sched.h:1835 [inline]
       task_fork_fair+0x59/0x590 kernel/sched/fair.c:11393
       sched_fork+0x48b/0xd30 kernel/sched/core.c:2459
       copy_process.part.6+0x120d/0x6530 kernel/fork.c:1732
       copy_process kernel/fork.c:1573 [inline]
       _do_fork+0x1c2/0xd50 kernel/fork.c:2054
       kernel_thread+0x2f/0x40 kernel/fork.c:2118
       rest_init+0x22/0x2a0 init/main.c:401
       start_kernel+0x6fb/0x739 init/main.c:710
       secondary_startup_64+0xa5/0xb0 arch/x86/kernel/head_64.S:239

-> #1 (&p->pi_lock){-.-.}:
       __raw_spin_lock_irqsave include/linux/spinlock_api_smp.h:110 [inline]
       _raw_spin_lock_irqsave+0x41/0x50 kernel/locking/spinlock.c:160
       try_to_wake_up+0x95/0x1230 kernel/sched/core.c:2030
       up+0x8d/0xd0 kernel/locking/semaphore.c:187
       __up_console_sem+0x44/0x90 kernel/printk/printk.c:245
       console_unlock+0x451/0xb50 kernel/printk/printk.c:2257
       vprintk_emit+0x112/0x150 kernel/printk/printk.c:1766
       vprintk_func+0x58/0x159 kernel/printk/printk_safe.c:401
       printk+0xa7/0xcf kernel/printk/printk.c:1838
       kauditd_printk_skb kernel/audit.c:506 [inline]
       kauditd_hold_skb.cold.13+0x41/0x50 kernel/audit.c:539
       kauditd_send_queue+0xf9/0x140 kernel/audit.c:702
       kauditd_thread+0x4c7/0x660 kernel/audit.c:828
       kthread+0x348/0x420 kernel/kthread.c:232
       ret_from_fork+0x3a/0x50 arch/x86/entry/entry_64.S:402

-> #0 ((console_sem).lock){-.-.}:
       lock_acquire+0x10f/0x380 kernel/locking/lockdep.c:3991
       __raw_spin_lock_irqsave include/linux/spinlock_api_smp.h:110 [inline]
       _raw_spin_lock_irqsave+0x41/0x50 kernel/locking/spinlock.c:160
       down_trylock+0xe/0x70 kernel/locking/semaphore.c:136
       __down_trylock_console_sem+0x33/0xc0 kernel/printk/printk.c:228
       console_trylock+0x13/0xf0 kernel/printk/printk.c:2074
       vprintk_emit+0x104/0x150 kernel/printk/printk.c:1765
       vprintk_func+0x58/0x159 kernel/printk/printk_safe.c:401
       printk+0xa7/0xcf kernel/printk/printk.c:1838
       __warn+0x36/0x50 kernel/panic.c:521
       report_bug+0x1f7/0x26c lib/bug.c:186
       fixup_bug arch/x86/kernel/traps.c:177 [inline]
       do_error_trap+0x1ba/0x2c0 arch/x86/kernel/traps.c:295
       invalid_op+0x18/0x40 arch/x86/entry/entry_64.S:944
       task_non_contending+0xa45/0xf40 kernel/sched/deadline.c:256
       __schedule+0x9af/0x1ed0 kernel/sched/core.c:3388
       do_task_dead+0xc7/0x100 kernel/sched/core.c:3463
       do_exit+0x1544/0x2800 kernel/exit.c:922
       do_group_exit+0x100/0x2e0 kernel/exit.c:968
       get_signal+0x4e5/0x1470 kernel/signal.c:2348
       do_signal+0x8f/0x1660 arch/x86/kernel/signal.c:809
       exit_to_usermode_loop+0x116/0x150 arch/x86/entry/common.c:159
       prepare_exit_to_usermode arch/x86/entry/common.c:198 [inline]
       syscall_return_slowpath arch/x86/entry/common.c:267 [inline]
       do_syscall_64+0x35d/0x4b0 arch/x86/entry/common.c:294
       entry_SYSCALL_64_after_hwframe+0x42/0xb7

other info that might help us debug this:

Chain exists of:
  (console_sem).lock --> &p->pi_lock --> &rq->lock

 Possible unsafe locking scenario:

       CPU0                    CPU1
       ----                    ----
  lock(&rq->lock);
                               lock(&p->pi_lock);
                               lock(&rq->lock);
  lock((console_sem).lock);

 *** DEADLOCK ***

1 lock held by syz-executor3/30135:
 #0:  (&rq->lock){-.-.}, at: [<ffffffff95c4447a>] rq_lock kernel/sched/sched.h:1835 [inline]
 #0:  (&rq->lock){-.-.}, at: [<ffffffff95c4447a>] __schedule+0x19a/0x1ed0 kernel/sched/core.c:3376

stack backtrace:
CPU: 0 PID: 30135 Comm: syz-executor3 Not tainted 4.14.72+ #11
Call Trace:
 __dump_stack lib/dump_stack.c:17 [inline]
 dump_stack+0xb9/0x11b lib/dump_stack.c:53
 print_circular_bug.isra.18.cold.43+0x2d3/0x40c kernel/locking/lockdep.c:1258
 check_prev_add kernel/locking/lockdep.c:1901 [inline]
 check_prevs_add kernel/locking/lockdep.c:2018 [inline]
 validate_chain kernel/locking/lockdep.c:2460 [inline]
 __lock_acquire+0x2ff9/0x4320 kernel/locking/lockdep.c:3487
 lock_acquire+0x10f/0x380 kernel/locking/lockdep.c:3991
 __raw_spin_lock_irqsave include/linux/spinlock_api_smp.h:110 [inline]
 _raw_spin_lock_irqsave+0x41/0x50 kernel/locking/spinlock.c:160
 down_trylock+0xe/0x70 kernel/locking/semaphore.c:136
 __down_trylock_console_sem+0x33/0xc0 kernel/printk/printk.c:228
 console_trylock+0x13/0xf0 kernel/printk/printk.c:2074
 vprintk_emit+0x104/0x150 kernel/printk/printk.c:1765
 vprintk_func+0x58/0x159 kernel/printk/printk_safe.c:401
 printk+0xa7/0xcf kernel/printk/printk.c:1838
 __warn+0x36/0x50 kernel/panic.c:521
 report_bug+0x1f7/0x26c lib/bug.c:186
 fixup_bug arch/x86/kernel/traps.c:177 [inline]
 do_error_trap+0x1ba/0x2c0 arch/x86/kernel/traps.c:295
 invalid_op+0x18/0x40 arch/x86/entry/entry_64.S:944
RIP: 0010:task_non_contending+0xa45/0xf40 kernel/sched/deadline.c:256
RSP: 0018:ffff8801c7ff7900 EFLAGS: 00010002
RAX: 0000000000000001 RBX: ffff8801c38bc680 RCX: 0000000000000000
RDX: 0000000000000000 RSI: ffff8801c38bc680 RDI: ffff8801dbb24a20
RBP: ffff8801c38bc6bc R08: 0000000000000001 R09: 0000000000000000
R10: ffff8801c38bced8 R11: 0000000000000001 R12: ffff8801c38bc9b8
R13: ffff8801dba00000 R14: 000000000002a240 R15: ffff8801c38bc680
 __schedule+0x9af/0x1ed0 kernel/sched/core.c:3388
 do_task_dead+0xc7/0x100 kernel/sched/core.c:3463
 do_exit+0x1544/0x2800 kernel/exit.c:922
 do_group_exit+0x100/0x2e0 kernel/exit.c:968
 get_signal+0x4e5/0x1470 kernel/signal.c:2348
 do_signal+0x8f/0x1660 arch/x86/kernel/signal.c:809
 exit_to_usermode_loop+0x116/0x150 arch/x86/entry/common.c:159
 prepare_exit_to_usermode arch/x86/entry/common.c:198 [inline]
 syscall_return_slowpath arch/x86/entry/common.c:267 [inline]
 do_syscall_64+0x35d/0x4b0 arch/x86/entry/common.c:294
 entry_SYSCALL_64_after_hwframe+0x42/0xb7
RIP: 0033:0x457579
RSP: 002b:00007fc0cfa99cf8 EFLAGS: 00000246 ORIG_RAX: 00000000000000ca
RAX: fffffffffffffe00 RBX: 000000000072bfa8 RCX: 0000000000457579
RDX: 0000000000000000 RSI: 0000000000000080 RDI: 000000000072bfa8
RBP: 000000000072bfa0 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000246 R12: 000000000072bfac
R13: 00007ffc382de54f R14: 00007fc0cfa9a9c0 R15: 0000000000000001
Shutting down cpus with NMI
Kernel Offset: 0x13400000 from 0xffffffff81000000 (relocation range: 0xffffffff80000000-0xffffffffbfffffff)
Rebooting in 86400 seconds..

Crashes (1):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2018/09/28 15:14 android-4.14 56aae8ee7423 137d7c66 .config console log report ci-android-414-kasan-gce-root
* Struck through repros no longer work on HEAD.