lowmemorykiller: Killing 'syz-executor539' (2048) (tgid 2048), adj 1000, to free 44kB on behalf of 'kswapd0' (33) because cache 36400kB is below limit 65536kB for oom_score_adj 12 Free memory is -12892kB above reserved ================================= [ INFO: inconsistent lock state ] 4.9.189+ #4 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: [<000000006d2f5b09>] 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: 4415 hardirqs last enabled at (4415): [<00000000dddf4769>] vprintk_emit+0x25c/0x6f0 kernel/printk/printk.c:1897 hardirqs last disabled at (4414): [<00000000101089ad>] vprintk_emit+0x6d/0x6f0 kernel/printk/printk.c:1801 softirqs last enabled at (2342): [<000000006f7035e1>] __do_softirq+0x474/0x964 kernel/softirq.c:314 softirqs last disabled at (2335): [<0000000005c56acf>] invoke_softirq kernel/softirq.c:368 [inline] softirqs last disabled at (2335): [<0000000005c56acf>] 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: [<00000000ac2ccc5e>] shrink_slab.part.0+0xb2/0xa20 mm/vmscan.c:472 stack backtrace: CPU: 1 PID: 33 Comm: kswapd0 Not tainted 4.9.189+ #4 ffff8801d8417420 ffffffff81b65c01 00000000000000f0 ffff8801d995af80 ffffffff83caf7a0 ffff8801d995b878 ffffffff84250fc0 ffff8801d8417498 ffffffff81408330 0000000000000000 ffffffff00000001 0000000000000001 Call Trace: [<0000000019c8fcd7>] __dump_stack lib/dump_stack.c:15 [inline] [<0000000019c8fcd7>] dump_stack+0xc1/0x120 lib/dump_stack.c:51 [<000000001de744b1>] print_usage_bug kernel/locking/lockdep.c:2387 [inline] [<000000001de744b1>] print_usage_bug.cold+0x452/0x5a2 kernel/locking/lockdep.c:2354 [<00000000eae5bab1>] valid_state kernel/locking/lockdep.c:2400 [inline] [<00000000eae5bab1>] mark_lock_irq kernel/locking/lockdep.c:2602 [inline] [<00000000eae5bab1>] mark_lock+0x6c7/0x12e0 kernel/locking/lockdep.c:3065 [<00000000cdec28fb>] mark_irqflags kernel/locking/lockdep.c:2958 [inline] [<00000000cdec28fb>] __lock_acquire+0x5be/0x4390 kernel/locking/lockdep.c:3302 [<00000000ef4fd319>] lock_acquire+0x133/0x3d0 kernel/locking/lockdep.c:3756 [<00000000419c08fa>] down_read+0x44/0xb0 kernel/locking/rwsem.c:22 [<000000006d2f5b09>] get_cmdline+0xa3/0x2d0 mm/util.c:641 [<00000000230d85bc>] handle_lmk_event+0x169/0x920 drivers/staging/android/lowmemorykiller.c:116 [<000000007199ff37>] lowmem_scan+0x6f3/0xb70 drivers/staging/android/lowmemorykiller.c:354 [<0000000021176575>] do_shrink_slab mm/vmscan.c:399 [inline] [<0000000021176575>] shrink_slab.part.0+0x3cf/0xa20 mm/vmscan.c:502 [<00000000eb2a34df>] shrink_slab mm/vmscan.c:466 [inline] [<00000000eb2a34df>] shrink_node+0x1ed/0x750 mm/vmscan.c:2604 [<000000005a12350f>] kswapd_shrink_node mm/vmscan.c:3209 [inline] [<000000005a12350f>] balance_pgdat mm/vmscan.c:3329 [inline] [<000000005a12350f>] kswapd+0x7f8/0x13b0 mm/vmscan.c:3523 [<00000000eab7b051>] kthread+0x278/0x310 kernel/kthread.c:211 [<00000000b304bfbf>] ret_from_fork+0x5c/0x70 arch/x86/entry/entry_64.S:375 syz-executor539: vmalloc: allocation failure, allocated 1304621056 of 4294971392 bytes, mode:0x24000c2(GFP_KERNEL|__GFP_HIGHMEM) oom_reaper: reaped process 2048 (syz-executor539), now anon-rss:0kB, file-rss:0kB, shmem-rss:0kB syz-executor539 invoked oom-killer: gfp_mask=0x24200ca(GFP_HIGHUSER_MOVABLE), nodemask=0, order=0, oom_score_adj=0 CPU: 1 PID: 2051 Comm: syz-executor539 Not tainted 4.9.189+ #4 ffff8801ce8576f0 ffffffff81b65c01 ffff8801ce857a48 ffffffff833f14f0 0000000000000000 ffff8801ce857a60 0000000000000000 ffff8801ce857770 ffffffff81506abb 0000000000000000 0000000000000000 ffffffff828289d5 Call Trace: [<0000000019c8fcd7>] __dump_stack lib/dump_stack.c:15 [inline] [<0000000019c8fcd7>] dump_stack+0xc1/0x120 lib/dump_stack.c:51 [<000000008c0fd38a>] dump_header.isra.0+0x142/0x74c mm/oom_kill.c:417 [<0000000054dc7380>] oom_kill_process.cold+0xd/0xa74 mm/oom_kill.c:852 [<00000000613db1dc>] out_of_memory mm/oom_kill.c:1069 [inline] [<00000000613db1dc>] out_of_memory+0x29b/0xea0 mm/oom_kill.c:1009 [<00000000a109dfb6>] __alloc_pages_may_oom mm/page_alloc.c:3136 [inline] [<00000000a109dfb6>] __alloc_pages_slowpath mm/page_alloc.c:3750 [inline] [<00000000a109dfb6>] __alloc_pages_nodemask+0x1730/0x1a80 mm/page_alloc.c:3861 [<0000000087d4d2dc>] __alloc_pages include/linux/gfp.h:433 [inline] [<0000000087d4d2dc>] __alloc_pages_node include/linux/gfp.h:446 [inline] [<0000000087d4d2dc>] alloc_pages_node include/linux/gfp.h:460 [inline] [<0000000087d4d2dc>] __page_cache_alloc include/linux/pagemap.h:208 [inline] [<0000000087d4d2dc>] pagecache_get_page+0x248/0x740 mm/filemap.c:1367 [<00000000ace91503>] filemap_fault+0xb1f/0x1360 mm/filemap.c:2331 [<0000000046285935>] ext4_filemap_fault+0x72/0xa0 fs/ext4/inode.c:5854 [<000000003034af2b>] __do_fault+0x2a8/0x6c0 mm/memory.c:2855 [<00000000f85793d3>] do_read_fault mm/memory.c:3202 [inline] [<00000000f85793d3>] do_fault mm/memory.c:3338 [inline] [<00000000f85793d3>] handle_pte_fault mm/memory.c:3547 [inline] [<00000000f85793d3>] __handle_mm_fault mm/memory.c:3634 [inline] [<00000000f85793d3>] handle_mm_fault+0x11bc/0x2420 mm/memory.c:3671 [<00000000a2553687>] __do_page_fault+0x3f0/0xa60 arch/x86/mm/fault.c:1404 [<00000000113b48e3>] do_page_fault+0x28/0x30 arch/x86/mm/fault.c:1467 [<00000000e245c279>] page_fault+0x25/0x30 arch/x86/entry/entry_64.S:956 Mem-Info: active_anon:3225 inactive_anon:41 isolated_anon:0 active_file:0 inactive_file:15 isolated_file:0 unevictable:0 dirty:1 writeback:7 unstable:0 slab_reclaimable:4256 slab_unreclaimable:56458 mapped:13 shmem:48 pagetables:360 bounce:0 free:55 free_pcp:8 free_cma:0 Node 0 active_anon:12900kB inactive_anon:164kB active_file:0kB inactive_file:60kB unevictable:0kB isolated(anon):0kB isolated(file):0kB mapped:52kB dirty:4kB writeback:28kB shmem:192kB writeback_tmp:0kB unstable:0kB pages_scanned:0 all_unreclaimable? yes DMA32 free:16kB min:4696kB low:7712kB high:10728kB active_anon:0kB inactive_anon:0kB active_file:0kB inactive_file:0kB unevictable:0kB writepending:0kB present:3145324kB managed:3020100kB mlocked:0kB slab_reclaimable:0kB slab_unreclaimable:4kB kernel_stack:0kB pagetables:0kB bounce:0kB free_pcp:0kB local_pcp:0kB free_cma:0kB Normal free:204kB min:5580kB low:9168kB high:12756kB active_anon:12900kB inactive_anon:164kB active_file:0kB inactive_file:60kB unevictable:0kB writepending:32kB present:4718592kB managed:3589316kB mlocked:0kB slab_reclaimable:17024kB slab_unreclaimable:225828kB kernel_stack:3456kB pagetables:1440kB bounce:0kB free_pcp:32kB local_pcp:0kB free_cma:0kB DMA32: 0*4kB 0*8kB 0*16kB 0*32kB 0*64kB 0*128kB 0*256kB 0*512kB 0*1024kB 0*2048kB 0*4096kB = 0kB 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 313625 pages reserved [ pid ] uid tgid total_vm rss nr_ptes nr_pmds swapents oom_score_adj name [ 470] 0 470 5384 181 17 4 0 -1000 udevd [ 585] 0 585 5383 181 16 4 0 -1000 udevd [ 587] 0 587 5383 181 16 4 0 -1000 udevd [ 1752] 0 1752 2492 573 9 3 0 0 dhclient [ 1893] 0 1893 14231 107 23 3 0 0 rsyslogd [ 1948] 0 1948 4724 51 15 3 0 0 cron [ 1966] 0 1966 3735 45 11 3 0 0 mcstransd [ 1976] 0 1976 12489 152 28 3 0 -1000 sshd [ 1984] 0 1984 12926 1228 27 3 0 0 restorecond [ 2024] 0 2024 3648 38 13 3 0 0 getty [ 2037] 0 2037 3648 42 13 3 0 0 getty [ 2038] 0 2038 3648 42 13 3 0 0 getty [ 2039] 0 2039 3648 42 13 3 0 0 getty [ 2040] 0 2040 3648 43 13 3 0 0 getty [ 2041] 0 2041 3648 43 13 3 0 0 getty [ 2042] 0 2042 3648 41 13 3 0 0 getty [ 2043] 0 2043 17820 197 39 3 0 0 sshd [ 2045] 0 2045 4380 1 4 2 0 0 syz-executor539 [ 2046] 0 2046 4380 11 4 2 0 0 syz-executor539 [ 2047] 0 2047 4380 11 4 2 0 0 syz-executor539 [ 2048] 0 2048 4380 0 5 2 0 1000 syz-executor539 [ 2049] 0 2049 4380 11 4 2 0 0 syz-executor539 [ 2050] 0 2050 4380 11 4 2 0 0 syz-executor539 [ 2051] 0 2051 4380 11 4 2 0 0 syz-executor539 [ 2052] 0 2052 4380 11 4 2 0 0 syz-executor539 [ 2053] 0 2053 4380 11 5 2 0 1000 syz-executor539 [ 2054] 0 2054 4380 11 5 2 0 1000 syz-executor539 [ 2055] 0 2055 4380 11 5 2 0 1000 syz-executor539 [ 2056] 0 2056 4380 11 5 2 0 1000 syz-executor539 [ 2057] 0 2057 4380 11 5 2 0 1000 syz-executor539 Out of memory: Kill process 2053 (syz-executor539) score 999 or sacrifice child Killed process 2053 (syz-executor539) total-vm:17520kB, anon-rss:44kB, file-rss:0kB, shmem-rss:0kB syz-executor539: vmalloc: allocation failure, allocated 1151344640 of 4294971392 bytes, mode:0x24000c2(GFP_KERNEL|__GFP_HIGHMEM) CPU: 0 PID: 2053 Comm: syz-executor539 Not tainted 4.9.189+ #4 ffff8801cefe7a08 ffffffff81b65c01 1ffff10039dfcf43 dffffc0000000000 ffffffff82aab240 0000000000000000 0000000000400000 ffff8801cefe7b30 ffffffff81507d73 0000000041b58ab3 ffffffff82e3b338 ffffffff81431920 Call Trace: [<0000000019c8fcd7>] __dump_stack lib/dump_stack.c:15 [inline] [<0000000019c8fcd7>] dump_stack+0xc1/0x120 lib/dump_stack.c:51 [<00000000e5ceaeee>] warn_alloc.cold+0x76/0x93 mm/page_alloc.c:3069 [<00000000b81a435c>] __vmalloc_area_node mm/vmalloc.c:1665 [inline] [<00000000b81a435c>] __vmalloc_node_range+0x3ff/0x610 mm/vmalloc.c:1706 [<00000000a80abe76>] __vmalloc_node mm/vmalloc.c:1749 [inline] [<00000000a80abe76>] __vmalloc_node_flags mm/vmalloc.c:1763 [inline] [<00000000a80abe76>] vmalloc+0x5c/0x70 mm/vmalloc.c:1778 [<0000000057668f05>] xt_alloc_table_info+0xc8/0x100 net/netfilter/x_tables.c:997 [<000000002c5312fe>] do_replace net/ipv6/netfilter/ip6_tables.c:1175 [inline] [<000000002c5312fe>] do_ip6t_set_ctl+0x231/0x480 net/ipv6/netfilter/ip6_tables.c:1712 [<00000000b0be44a2>] nf_sockopt net/netfilter/nf_sockopt.c:105 [inline] [<00000000b0be44a2>] nf_setsockopt+0x6d/0xc0 net/netfilter/nf_sockopt.c:114 [<000000004dd6670f>] ipv6_setsockopt net/ipv6/ipv6_sockglue.c:922 [inline] [<000000004dd6670f>] ipv6_setsockopt+0x10b/0x140 net/ipv6/ipv6_sockglue.c:906 [<000000001e5217c2>] tcp_setsockopt net/ipv4/tcp.c:2759 [inline] [<000000001e5217c2>] tcp_setsockopt+0x8a/0xe0 net/ipv4/tcp.c:2753 [<00000000bcfce092>] sock_common_setsockopt+0x9a/0xe0 net/core/sock.c:2710 [<000000000b926c58>] SYSC_setsockopt net/socket.c:1786 [inline] [<000000000b926c58>] SyS_setsockopt+0x159/0x240 net/socket.c:1765