lowmemorykiller: Killing 'syz-executor.3' (4918) (tgid 4918), adj 1000, to free 36072kB on behalf of 'kswapd0' (33) because cache 61680kB is below limit 65536kB for oom_score_adj 12 Free memory is -9664kB above reserved ================================= [ INFO: inconsistent lock state ] 4.9.194+ #0 Not tainted --------------------------------- inconsistent {RECLAIM_FS-ON-W} -> {IN-RECLAIM_FS-R} usage. kswapd0/33 [HC0[0]:SC0[0]:HE1:SE1] takes: (&mm->mmap_sem){+++++?}, at: [<00000000106a2e8c>] get_cmdline+0xa3/0x2d0 mm/util.c:641 mark_held_locks+0xb1/0x100 kernel/locking/lockdep.c:2660 __lockdep_trace_alloc kernel/locking/lockdep.c:2882 [inline] lockdep_trace_alloc+0x18c/0x2b0 kernel/locking/lockdep.c:2897 __alloc_pages_nodemask+0x143/0x1a80 mm/page_alloc.c:3803 __alloc_pages include/linux/gfp.h:433 [inline] __alloc_pages_node include/linux/gfp.h:446 [inline] alloc_pages_node include/linux/gfp.h:460 [inline] pte_alloc_one+0x23/0x110 arch/x86/mm/pgtable.c:29 __pte_alloc+0x26/0x1f0 mm/memory.c:570 move_page_tables+0xb4d/0xd60 mm/mremap.c:232 shift_arg_pages+0x1ae/0x470 fs/exec.c:642 setup_arg_pages+0x60d/0x7c0 fs/exec.c:754 load_elf_binary+0xa84/0x4a90 fs/binfmt_elf.c:860 search_binary_handler fs/exec.c:1621 [inline] search_binary_handler+0x14f/0x700 fs/exec.c:1599 exec_binprm fs/exec.c:1663 [inline] do_execveat_common.isra.0+0xf81/0x1db0 fs/exec.c:1785 do_execve+0x3a/0x50 fs/exec.c:1829 run_init_process+0x33/0x37 init/main.c:904 try_to_run_init_process+0x18/0x48 init/main.c:913 kernel_init+0xf2/0x163 init/main.c:984 ret_from_fork+0x5c/0x70 arch/x86/entry/entry_64.S:375 irq event stamp: 3779 hardirqs last enabled at (3779): [<000000002b76c9c3>] vprintk_emit+0x25c/0x6f0 kernel/printk/printk.c:1897 hardirqs last disabled at (3778): [<00000000aa2c9bdc>] vprintk_emit+0x6d/0x6f0 kernel/printk/printk.c:1801 softirqs last enabled at (2236): [<0000000040c93493>] __do_softirq+0x474/0x964 kernel/softirq.c:314 softirqs last disabled at (2211): [<000000005603096f>] invoke_softirq kernel/softirq.c:368 [inline] softirqs last disabled at (2211): [<000000005603096f>] irq_exit+0x119/0x160 kernel/softirq.c:409 other info that might help us debug this: Possible unsafe locking scenario: CPU0 ---- lock(&mm->mmap_sem); lock(&mm->mmap_sem); *** DEADLOCK *** 1 lock held by kswapd0/33: #0: (shrinker_rwsem){++++..}, at: [<0000000055792d37>] shrink_slab.part.0+0xb2/0xa20 mm/vmscan.c:472 stack backtrace: CPU: 0 PID: 33 Comm: kswapd0 Not tainted 4.9.194+ #0 ffff8801d8417420 ffffffff81b67001 00000000000000f0 ffff8801d995af80 ffffffff83cb0b40 ffff8801d995b878 ffffffff84252000 ffff8801d8417498 ffffffff81408710 0000000000000000 ffffffff00000001 0000000000000001 Call Trace: [<000000008f42c6cc>] __dump_stack lib/dump_stack.c:15 [inline] [<000000008f42c6cc>] dump_stack+0xc1/0x120 lib/dump_stack.c:51 [<000000001131f32c>] print_usage_bug kernel/locking/lockdep.c:2387 [inline] [<000000001131f32c>] print_usage_bug.cold+0x452/0x5a2 kernel/locking/lockdep.c:2354 [<000000004eef6010>] valid_state kernel/locking/lockdep.c:2400 [inline] [<000000004eef6010>] mark_lock_irq kernel/locking/lockdep.c:2602 [inline] [<000000004eef6010>] mark_lock+0x6c7/0x12e0 kernel/locking/lockdep.c:3065 [<00000000b2cafeca>] mark_irqflags kernel/locking/lockdep.c:2958 [inline] [<00000000b2cafeca>] __lock_acquire+0x5be/0x4390 kernel/locking/lockdep.c:3302 [<00000000614bcb33>] lock_acquire+0x133/0x3d0 kernel/locking/lockdep.c:3756 [<00000000d375aae5>] down_read+0x44/0xb0 kernel/locking/rwsem.c:22 [<00000000106a2e8c>] get_cmdline+0xa3/0x2d0 mm/util.c:641 [<000000000582c538>] handle_lmk_event+0x169/0x920 drivers/staging/android/lowmemorykiller.c:116 [<0000000026886079>] lowmem_scan+0x6f3/0xb70 drivers/staging/android/lowmemorykiller.c:354 [<000000000820dbf4>] do_shrink_slab mm/vmscan.c:399 [inline] [<000000000820dbf4>] shrink_slab.part.0+0x3cf/0xa20 mm/vmscan.c:502 [<000000001540cdce>] shrink_slab mm/vmscan.c:466 [inline] [<000000001540cdce>] shrink_node+0x1ed/0x750 mm/vmscan.c:2604 [<000000009ed8b338>] kswapd_shrink_node mm/vmscan.c:3209 [inline] [<000000009ed8b338>] balance_pgdat mm/vmscan.c:3329 [inline] [<000000009ed8b338>] kswapd+0x7f8/0x13b0 mm/vmscan.c:3523 [<00000000ee6b89a5>] kthread+0x278/0x310 kernel/kthread.c:211 [<000000001c422587>] ret_from_fork+0x5c/0x70 arch/x86/entry/entry_64.S:375 lowmemorykiller: Killing 'syz-executor.3' (4931) (tgid 4931), adj 1000, to free 36156kB on behalf of 'kswapd0' (33) because cache 58680kB is below limit 65536kB for oom_score_adj 12 Free memory is -13108kB above reserved lowmemorykiller: Killing 'syz-executor.4' (3967) (tgid 3967), adj 1000, to free 36000kB on behalf of 'syz-executor.5' (5972) because cache 58680kB is below limit 65536kB for oom_score_adj 12 Free memory is -13332kB above reserved lowmemorykiller: Killing 'syz-executor.3' (5986) (tgid 5984), adj 1000, to free 35992kB on behalf of 'syz-executor.5' (5972) because cache 58380kB is below limit 65536kB for oom_score_adj 12 Free memory is -12536kB above reserved lowmemorykiller: Killing 'syz-executor.4' (3967) (tgid 3967), adj 1000, to free 36000kB on behalf of 'syz-executor.0' (6035) because cache 58480kB is below limit 65536kB for oom_score_adj 12 Free memory is -12932kB above reserved syz-executor.0 invoked oom-killer: gfp_mask=0x27080c0(GFP_KERNEL_ACCOUNT|__GFP_ZERO|__GFP_NOTRACK), nodemask=0, order=3, oom_score_adj=0 CPU: 0 PID: 6035 Comm: syz-executor.0 Not tainted 4.9.194+ #0 ffff8800515177e0 ffffffff81b67001 ffff880051517b38 ffffffff833f1c30 0000000000000000 ffff880051517b50 0000000000000003 ffff880051517860 ffffffff81506e44 0000000000000003 0000000000000000 ffffffff8282ac45 Call Trace: [<000000008f42c6cc>] __dump_stack lib/dump_stack.c:15 [inline] [<000000008f42c6cc>] dump_stack+0xc1/0x120 lib/dump_stack.c:51 [<00000000fafb6d23>] dump_header.isra.0+0x142/0x74c mm/oom_kill.c:417 [<00000000c1396e0e>] oom_kill_process.cold+0xd/0xa74 mm/oom_kill.c:852 [<00000000e4c3b0d8>] out_of_memory mm/oom_kill.c:1069 [inline] [<00000000e4c3b0d8>] out_of_memory+0x29b/0xea0 mm/oom_kill.c:1009 [<000000005958a622>] __alloc_pages_may_oom mm/page_alloc.c:3136 [inline] [<000000005958a622>] __alloc_pages_slowpath mm/page_alloc.c:3750 [inline] [<000000005958a622>] __alloc_pages_nodemask+0x1730/0x1a80 mm/page_alloc.c:3861 [<00000000423a621f>] __alloc_pages include/linux/gfp.h:433 [inline] [<00000000423a621f>] __alloc_pages_node include/linux/gfp.h:446 [inline] [<00000000423a621f>] alloc_pages_node include/linux/gfp.h:460 [inline] [<00000000423a621f>] alloc_thread_stack_node kernel/fork.c:214 [inline] [<00000000423a621f>] dup_task_struct kernel/fork.c:494 [inline] [<00000000423a621f>] copy_process.part.0+0x2da/0x6690 kernel/fork.c:1640 [<00000000abe1e0b8>] copy_process kernel/fork.c:1586 [inline] [<00000000abe1e0b8>] _do_fork+0x1c1/0xd50 kernel/fork.c:2111 [<0000000023d161ce>] SYSC_clone kernel/fork.c:2223 [inline] [<0000000023d161ce>] SyS_clone+0x37/0x50 kernel/fork.c:2217 [<00000000a9cd83c5>] do_syscall_64+0x1ad/0x5c0 arch/x86/entry/common.c:288 [<0000000001764686>] entry_SYSCALL_64_after_swapgs+0x5d/0xdb Mem-Info: active_anon:73429 inactive_anon:316 isolated_anon:0 active_file:22 inactive_file:52 isolated_file:0 unevictable:0 dirty:0 writeback:0 unstable:0 slab_reclaimable:5594 slab_unreclaimable:58743 mapped:52244 shmem:477 pagetables:985 bounce:0 free:6329 free_pcp:0 free_cma:0 Node 0 active_anon:293716kB inactive_anon:1264kB active_file:88kB inactive_file:208kB unevictable:0kB isolated(anon):0kB isolated(file):0kB mapped:208976kB dirty:0kB writeback:0kB shmem:1908kB writeback_tmp:0kB unstable:0kB pages_scanned:0 all_unreclaimable? no DMA32 free:18704kB min:4696kB low:7712kB high:10728kB active_anon:1600kB inactive_anon:12kB active_file:0kB inactive_file:0kB unevictable:0kB writepending:0kB present:3145324kB managed:3020092kB mlocked:0kB slab_reclaimable:4kB slab_unreclaimable:1656kB kernel_stack:32kB pagetables:48kB bounce:0kB free_pcp:0kB local_pcp:0kB free_cma:0kB Normal free:6612kB min:5580kB low:9168kB high:12756kB active_anon:292116kB inactive_anon:1252kB active_file:88kB inactive_file:208kB unevictable:0kB writepending:0kB present:4718592kB managed:3589316kB mlocked:0kB slab_reclaimable:22372kB slab_unreclaimable:233316kB kernel_stack:4512kB pagetables:3892kB bounce:0kB free_pcp:0kB local_pcp:0kB free_cma:0kB DMA32: 18*4kB (ME) 7*8kB (UME) 5*16kB (ME) 2*32kB (ME) 2*64kB (UE) 1*128kB (E) 1*256kB (E) 3*512kB (ME) 2*1024kB (ME) 3*2048kB (UME) 2*4096kB (M) = 18704kB 0 pages in swap cache Swap cache stats: add 0, delete 0, find 0/0 Free swap = 0kB Total swap = 0kB 1965979 pages RAM 0 pages HighMem/MovableOnly 313627 pages reserved [ pid ] uid tgid total_vm rss nr_ptes nr_pmds swapents oom_score_adj name [ 470] 0 470 5385 189 16 3 0 -1000 udevd [ 1760] 0 1760 2492 573 9 3 0 0 dhclient [ 1893] 0 1893 30615 161 26 4 0 0 rsyslogd [ 1948] 0 1948 4724 50 15 3 0 0 cron [ 1966] 0 1966 3734 44 11 3 0 0 mcstransd [ 1968] 0 1968 12926 1231 26 3 0 0 restorecond [ 1994] 0 1994 12489 152 28 3 0 -1000 sshd [ 2024] 0 2024 3648 40 13 3 0 0 getty [ 2040] 0 2040 17820 197 38 3 0 0 sshd [ 2042] 0 2042 128808 69268 214 5 0 0 syz-fuzzer [ 2100] 0 2100 18114 15 23 3 0 0 syz-executor.3 [ 2101] 0 2101 18114 16 23 3 0 0 syz-executor.4 [ 2104] 0 2104 18114 15 23 3 0 0 syz-executor.5 [ 2110] 0 2110 18113 8744 25 4 0 0 syz-executor.4 [ 2112] 0 2112 18113 8744 24 4 0 0 syz-executor.3 [ 2114] 0 2114 18113 8744 24 4 0 0 syz-executor.5 [ 3234] 0 3234 5615 406 15 3 0 -1000 udevd [ 3960] 0 3960 18212 8760 27 4 0 1000 syz-executor.4 [ 4087] 0 4087 5384 189 15 3 0 -1000 udevd [ 4374] 0 4374 18212 8761 26 4 0 1000 syz-executor.5 [ 4502] 0 4502 18146 8720 25 3 0 1000 syz-executor.3 [ 5063] 0 5063 18146 8719 24 3 0 1000 syz-executor.3 [ 5129] 0 5129 18212 8760 27 4 0 1000 syz-executor.4 [ 5211] 0 5211 18114 16 23 3 0 0 syz-executor.1 [ 5212] 0 5212 18113 8744 24 4 0 0 syz-executor.1 [ 5434] 0 5434 18179 8723 26 3 0 1000 syz-executor.4 [ 5468] 0 5468 18212 8749 26 3 0 1000 syz-executor.4 [ 5478] 0 5478 18114 17 23 3 0 0 syz-executor.2 [ 5479] 0 5479 18113 8744 24 4 0 0 syz-executor.2 [ 5654] 0 5654 18146 8756 27 4 0 1000 syz-executor.4 [ 5969] 0 5968 18278 8764 26 4 0 1000 syz-executor.5 [ 5973] 0 5973 18278 8764 26 4 0 1000 syz-executor.5 [ 5986] 0 5984 18278 8765 26 4 0 1000 syz-executor.3 [ 6006] 0 6006 18278 8764 26 4 0 1000 syz-executor.5 [ 6017] 0 6017 18179 8498 28 4 0