lowmemorykiller: Killing 'syz-executor.5' (4148) (tgid 4148), adj 1000, to free 52768kB on behalf of 'syz-executor.2' (27948) because cache 64044kB is below limit 65536kB for oom_score_adj 12 Free memory is -8756kB above reserved ================================= [ INFO: inconsistent lock state ] 4.9.194+ #0 Not tainted --------------------------------- inconsistent {RECLAIM_FS-ON-W} -> {IN-RECLAIM_FS-R} usage. syz-executor.2/27948 [HC0[0]:SC0[0]:HE1:SE1] takes: (&mm->mmap_sem){+++++?}, at: [<00000000f574c828>] 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] pmd_alloc_one arch/x86/include/asm/pgalloc.h:88 [inline] __pmd_alloc+0x4a/0x330 mm/memory.c:3742 pmd_alloc include/linux/mm.h:1625 [inline] alloc_new_pmd mm/mremap.c:64 [inline] move_page_tables+0xadb/0xd60 mm/mremap.c:212 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: 5579 hardirqs last enabled at (5579): [<00000000a6d191d9>] vprintk_emit+0x25c/0x6f0 kernel/printk/printk.c:1897 hardirqs last disabled at (5578): [<00000000c0259c59>] vprintk_emit+0x6d/0x6f0 kernel/printk/printk.c:1801 softirqs last enabled at (5310): [<00000000a0cfb68c>] __do_softirq+0x474/0x964 kernel/softirq.c:314 softirqs last disabled at (5303): [<00000000231d9a80>] invoke_softirq kernel/softirq.c:368 [inline] softirqs last disabled at (5303): [<00000000231d9a80>] 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 *** 2 locks held by syz-executor.2/27948: #0: (&mm->mmap_sem){+++++?}, at: [<00000000e5afd556>] __do_page_fault+0x25e/0xa60 arch/x86/mm/fault.c:1330 #1: (shrinker_rwsem){++++..}, at: [<00000000da4a6fed>] shrink_slab.part.0+0xb2/0xa20 mm/vmscan.c:472 stack backtrace: CPU: 0 PID: 27948 Comm: syz-executor.2 Not tainted 4.9.194+ #0 ffff88008638f230 ffffffff81b67001 00000000000000f0 ffff88018d34df00 ffffffff83cb0b40 ffff88018d34e820 ffffffff84252000 ffff88008638f2a8 ffffffff81408710 0000000000000000 ffffffff00000001 0000000000000001 Call Trace: [<00000000b1563bc2>] __dump_stack lib/dump_stack.c:15 [inline] [<00000000b1563bc2>] dump_stack+0xc1/0x120 lib/dump_stack.c:51 [<00000000c17876ec>] print_usage_bug kernel/locking/lockdep.c:2387 [inline] [<00000000c17876ec>] print_usage_bug.cold+0x452/0x5a2 kernel/locking/lockdep.c:2354 [<00000000dcc35877>] valid_state kernel/locking/lockdep.c:2400 [inline] [<00000000dcc35877>] mark_lock_irq kernel/locking/lockdep.c:2602 [inline] [<00000000dcc35877>] mark_lock+0x6c7/0x12e0 kernel/locking/lockdep.c:3065 [<000000002ef60307>] mark_irqflags kernel/locking/lockdep.c:2958 [inline] [<000000002ef60307>] __lock_acquire+0x5be/0x4390 kernel/locking/lockdep.c:3302 [<000000009f985a88>] lock_acquire+0x133/0x3d0 kernel/locking/lockdep.c:3756 [<00000000f46c3dc2>] down_read+0x44/0xb0 kernel/locking/rwsem.c:22 [<00000000f574c828>] get_cmdline+0xa3/0x2d0 mm/util.c:641 [<000000000171744f>] handle_lmk_event+0x169/0x920 drivers/staging/android/lowmemorykiller.c:116 [<000000008542cc18>] lowmem_scan+0x6f3/0xb70 drivers/staging/android/lowmemorykiller.c:354 [<0000000085578fd6>] do_shrink_slab mm/vmscan.c:399 [inline] [<0000000085578fd6>] shrink_slab.part.0+0x3cf/0xa20 mm/vmscan.c:502 [<00000000e5bdabf8>] shrink_slab mm/vmscan.c:466 [inline] [<00000000e5bdabf8>] shrink_node+0x1ed/0x750 mm/vmscan.c:2604 [<000000004999e233>] shrink_zones mm/vmscan.c:2751 [inline] [<000000004999e233>] do_try_to_free_pages mm/vmscan.c:2793 [inline] [<000000004999e233>] try_to_free_pages+0x397/0xbd0 mm/vmscan.c:3004 [<00000000959a8c63>] __perform_reclaim mm/page_alloc.c:3332 [inline] [<00000000959a8c63>] __alloc_pages_direct_reclaim mm/page_alloc.c:3354 [inline] [<00000000959a8c63>] __alloc_pages_slowpath mm/page_alloc.c:3704 [inline] [<00000000959a8c63>] __alloc_pages_nodemask+0x930/0x1a80 mm/page_alloc.c:3861 [<000000002140ea6a>] __alloc_pages include/linux/gfp.h:433 [inline] [<000000002140ea6a>] __alloc_pages_node include/linux/gfp.h:446 [inline] [<000000002140ea6a>] alloc_pages_node include/linux/gfp.h:460 [inline] [<000000002140ea6a>] alloc_zeroed_user_highpage_movable include/linux/highmem.h:183 [inline] [<000000002140ea6a>] do_anonymous_page mm/memory.c:2761 [inline] [<000000002140ea6a>] handle_pte_fault mm/memory.c:3545 [inline] [<000000002140ea6a>] __handle_mm_fault mm/memory.c:3634 [inline] [<000000002140ea6a>] handle_mm_fault+0x12e1/0x2420 mm/memory.c:3671 [<0000000006de75d9>] __do_page_fault+0x3f0/0xa60 arch/x86/mm/fault.c:1401 [<000000009d3e384d>] do_page_fault+0x28/0x30 arch/x86/mm/fault.c:1464 [<00000000626f5e4a>] page_fault+0x25/0x30 arch/x86/entry/entry_64.S:956 lowmemorykiller: Killing 'syz-executor.1' (1831) (tgid 1831), adj 1000, to free 52732kB on behalf of 'kswapd0' (33) because cache 58660kB is below limit 65536kB for oom_score_adj 12 Free memory is 16028kB above reserved lowmemorykiller: Killing 'syz-executor.1' (27679) (tgid 27679), adj 1000, to free 52672kB on behalf of 'kswapd0' (33) because cache 49560kB is below limit 65536kB for oom_score_adj 12 Free memory is 20172kB above reserved lowmemorykiller: Killing 'syz-executor.1' (5823) (tgid 5823), adj 1000, to free 52636kB on behalf of 'kswapd0' (33) because cache 49560kB is below limit 65536kB for oom_score_adj 12 Free memory is 47368kB above reserved lowmemorykiller: Killing 'syz-executor.1' (7031) (tgid 7031), adj 1000, to free 52628kB on behalf of 'kswapd0' (33) because cache 49560kB is below limit 65536kB for oom_score_adj 12 Free memory is 33884kB above reserved lowmemorykiller: Killing 'syz-executor.5' (904) (tgid 904), adj 1000, to free 52616kB on behalf of 'kswapd0' (33) because cache 49560kB is below limit 65536kB for oom_score_adj 12 Free memory is 59112kB above reserved lowmemorykiller: Killing 'syz-executor.1' (31767) (tgid 31767), adj 1000, to free 52600kB on behalf of 'kswapd0' (33) because cache 49560kB is below limit 65536kB for oom_score_adj 12 Free memory is 59112kB above reserved audit_printk_skb: 15 callbacks suppressed audit: type=1400 audit(1573533763.200:2980): avc: denied { create } for pid=28003 comm="syz-executor.3" scontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tcontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tclass=netlink_generic_socket permissive=1 audit: type=1400 audit(1573533763.200:2981): avc: denied { write } for pid=28003 comm="syz-executor.3" scontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tcontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tclass=netlink_generic_socket permissive=1 audit: type=1400 audit(1573533763.260:2982): avc: denied { write } for pid=28003 comm="syz-executor.3" scontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tcontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tclass=netlink_generic_socket permissive=1 audit: type=1400 audit(1573533763.450:2983): avc: denied { read } for pid=28003 comm="syz-executor.3" scontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tcontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tclass=netlink_generic_socket permissive=1 audit: type=1400 audit(1573533763.450:2984): avc: denied { write } for pid=28003 comm="syz-executor.3" scontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tcontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tclass=netlink_generic_socket permissive=1 audit: type=1400 audit(1573533764.080:2985): avc: denied { create } for pid=28057 comm="syz-executor.4" scontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tcontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tclass=netlink_generic_socket permissive=1 audit: type=1400 audit(1573533764.110:2986): avc: denied { write } for pid=28057 comm="syz-executor.4" scontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tcontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tclass=netlink_generic_socket permissive=1 audit: type=1400 audit(1573533764.160:2987): avc: denied { write } for pid=28057 comm="syz-executor.4" scontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tcontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tclass=netlink_generic_socket permissive=1 audit: type=1400 audit(1573533764.220:2988): avc: denied { read } for pid=28057 comm="syz-executor.4" scontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tcontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tclass=netlink_generic_socket permissive=1 audit: type=1400 audit(1573533764.630:2989): avc: denied { create } for pid=28128 comm="syz-executor.1" scontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tcontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tclass=netlink_generic_socket permissive=1 audit_printk_skb: 57 callbacks suppressed audit: type=1400 audit(1573533768.420:3009): avc: denied { create } for pid=28485 comm="syz-executor.4" scontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tcontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tclass=netlink_generic_socket permissive=1 audit: type=1400 audit(1573533768.450:3010): avc: denied { write } for pid=28485 comm="syz-executor.4" scontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tcontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tclass=netlink_generic_socket permissive=1 audit: type=1400 audit(1573533768.500:3011): avc: denied { write } for pid=28485 comm="syz-executor.4" scontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tcontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tclass=netlink_generic_socket permissive=1 audit: type=1400 audit(1573533768.530:3012): avc: denied { read } for pid=28485 comm="syz-executor.4" scontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tcontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tclass=netlink_generic_socket permissive=1 audit: type=1400 audit(1573533768.720:3013): avc: denied { create } for pid=28528 comm="syz-executor.3" scontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tcontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tclass=netlink_generic_socket permissive=1 audit: type=1400 audit(1573533768.840:3014): avc: denied { create } for pid=28547 comm="syz-executor.2" scontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tcontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tclass=netlink_generic_socket permissive=1 audit: type=1400 audit(1573533768.930:3015): avc: denied { create } for pid=28539 comm="syz-executor.4" scontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tcontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tclass=netlink_generic_socket permissive=1 audit: type=1400 audit(1573533769.120:3017): avc: denied { create } for pid=28556 comm="syz-executor.2" scontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tcontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tclass=netlink_generic_socket permissive=1 audit: type=1400 audit(1573533769.120:3016): avc: denied { create } for pid=28538 comm="syz-executor.5" scontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tcontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tclass=netlink_generic_socket permissive=1 audit: type=1400 audit(1573533769.120:3018): avc: denied { write } for pid=28538 comm="syz-executor.5" scontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tcontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tclass=netlink_generic_socket permissive=1 lowmemorykiller: Killing 'syz-executor.1' (30682) (tgid 30682), adj 1000, to free 52588kB on behalf of 'kswapd0' (33) because cache 63872kB is below limit 65536kB for oom_score_adj 12 Free memory is 5436kB above reserved lowmemorykiller: Killing 'syz-executor.1' (19710) (tgid 19710), adj 1000, to free 52576kB on behalf of 'kswapd0' (33) because cache 50216kB is below limit 65536kB for oom_score_adj 12 Free memory is 60588kB above reserved