[lkml]   [2019]   [Sep]   [6]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
Subjectpossible deadlock in __mmu_notifier_invalidate_range_end

syzbot found the following crash on:

HEAD commit: 6d028043 Add linux-next specific files for 20190830
git tree: linux-next
console output:
kernel config:
dashboard link:
compiler: gcc (GCC) 9.0.0 20181231 (experimental)
syz repro:
C reproducer:

The bug was bisected to:

commit e58b341134ca751d9c12bacded12a8b4dd51368d
Author: Stephen Rothwell <>
Date: Fri Aug 30 09:42:14 2019 +0000

Merge remote-tracking branch 'hmm/hmm'

bisection log:
final crash:
console output:

IMPORTANT: if you fix the bug, please add the following tag to the commit:
Fixes: e58b341134ca ("Merge remote-tracking branch 'hmm/hmm'")

WARNING: possible recursive locking detected
5.3.0-rc6-next-20190830 #75 Not tainted
oom_reaper/1065 is trying to acquire lock:
ffffffff8904ff60 (mmu_notifier_invalidate_range_start){+.+.}, at:
__mmu_notifier_invalidate_range_end+0x0/0x360 mm/mmu_notifier.c:169

but task is already holding lock:
ffffffff8904ff60 (mmu_notifier_invalidate_range_start){+.+.}, at:
__oom_reap_task_mm+0x196/0x490 mm/oom_kill.c:542

other info that might help us debug this:
Possible unsafe locking scenario:


*** DEADLOCK ***

May be due to missing lock nesting notation

2 locks held by oom_reaper/1065:
#0: ffff888094ad3990 (&mm->mmap_sem#2){++++}, at: oom_reap_task_mm
mm/oom_kill.c:570 [inline]
#0: ffff888094ad3990 (&mm->mmap_sem#2){++++}, at: oom_reap_task
mm/oom_kill.c:613 [inline]
#0: ffff888094ad3990 (&mm->mmap_sem#2){++++}, at: oom_reaper+0x3a7/0x1320
#1: ffffffff8904ff60 (mmu_notifier_invalidate_range_start){+.+.}, at:
__oom_reap_task_mm+0x196/0x490 mm/oom_kill.c:542

stack backtrace:
CPU: 1 PID: 1065 Comm: oom_reaper Not tainted 5.3.0-rc6-next-20190830 #75
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS
Google 01/01/2011
Call Trace:
__dump_stack lib/dump_stack.c:77 [inline]
dump_stack+0x172/0x1f0 lib/dump_stack.c:113
print_deadlock_bug kernel/locking/lockdep.c:2371 [inline]
check_deadlock kernel/locking/lockdep.c:2412 [inline]
validate_chain kernel/locking/lockdep.c:2955 [inline]
__lock_acquire.cold+0x15d/0x385 kernel/locking/lockdep.c:3955
lock_acquire+0x190/0x410 kernel/locking/lockdep.c:4487
__mmu_notifier_invalidate_range_end+0x3c/0x360 mm/mmu_notifier.c:193
mmu_notifier_invalidate_range_end include/linux/mmu_notifier.h:375 [inline]
__oom_reap_task_mm+0x3fa/0x490 mm/oom_kill.c:552
oom_reap_task_mm mm/oom_kill.c:589 [inline]
oom_reap_task mm/oom_kill.c:613 [inline]
oom_reaper+0x2b2/0x1320 mm/oom_kill.c:651
kthread+0x361/0x430 kernel/kthread.c:255
ret_from_fork+0x24/0x30 arch/x86/entry/entry_64.S:352
oom_reaper: reaped process 10145 (syz-executor282), now anon-rss:16480kB,
file-rss:872kB, shmem-rss:0kB
oom_reaper: reaped process 10144 (syz-executor282), now anon-rss:0kB,
file-rss:0kB, shmem-rss:0kB
oom_reaper: reaped process 10158 (syz-executor282), now anon-rss:16824kB,
file-rss:872kB, shmem-rss:0kB
oom_reaper: reaped process 10187 (syz-executor282), now anon-rss:0kB,
file-rss:0kB, shmem-rss:0kB
oom_reaper: reaped process 10173 (syz-executor282), now anon-rss:0kB,
file-rss:0kB, shmem-rss:0kB
oom_reaper: reaped process 10139 (syz-executor282), now anon-rss:0kB,
file-rss:0kB, shmem-rss:0kB

This bug is generated by a bot. It may contain errors.
See for more information about syzbot.
syzbot engineers can be reached at

syzbot will keep track of this bug report. See: for how to communicate with syzbot.
For information about bisection process see:
syzbot can test patches for this bug, for details see:

 \ /
  Last update: 2019-09-06 19:09    [W:0.026 / U:7.524 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site