kmem_cache_node 51KB 51KB kmem_cache 78KB 78KB oom-kill:constraint=CONSTRAINT_NONE,nodemask=(null),cpuset=syz3,mems_allowed=0,global_oom,task_memcg=/syz3,task=syz-executor.3,pid=16612,uid=0 BUG: sleeping function called from invalid context at kernel/locking/mutex.c:577 in_atomic(): 1, irqs_disabled(): 0, non_block: 0, pid: 16612, name: syz-executor.3 preempt_count: 1, expected: 0 RCU nest depth: 0, expected: 0 3 locks held by syz-executor.3/16612: #0: ffff88800d7f0130 (sk_lock-AF_PACKET){+.+.}-{0:0}, at: lock_sock include/net/sock.h:1667 [inline] #0: ffff88800d7f0130 (sk_lock-AF_PACKET){+.+.}-{0:0}, at: packet_setsockopt+0x156/0x3c40 net/packet/af_packet.c:3771 #1: ffffffff852791a8 (oom_lock){+.+.}-{3:3}, at: __alloc_pages_may_oom mm/page_alloc.c:4279 [inline] #1: ffffffff852791a8 (oom_lock){+.+.}-{3:3}, at: __alloc_pages_slowpath.constprop.0+0xcc9/0x1f10 mm/page_alloc.c:5061 #2: ffff88803a2308a0 (&p->alloc_lock){+.+.}-{2:2}, at: spin_lock include/linux/spinlock.h:354 [inline] #2: ffff88803a2308a0 (&p->alloc_lock){+.+.}-{2:2}, at: task_lock include/linux/sched/task.h:179 [inline] #2: ffff88803a2308a0 (&p->alloc_lock){+.+.}-{2:2}, at: find_lock_task_mm+0xe3/0x2b0 mm/oom_kill.c:144 Preemption disabled at: [<0000000000000000>] 0x0 CPU: 0 PID: 16612 Comm: syz-executor.3 Not tainted 5.16.0-rc6-next-20211224 #1 Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS rel-1.14.0-0-g155821a1990b-prebuilt.qemu.org 04/01/2014 Call Trace: __dump_stack lib/dump_stack.c:88 [inline] dump_stack_lvl+0x8b/0xb3 lib/dump_stack.c:106 __might_resched.cold+0x222/0x26b kernel/sched/core.c:9583 __mutex_lock_common kernel/locking/mutex.c:577 [inline] __mutex_lock+0x9e/0x1480 kernel/locking/mutex.c:733 futex_cleanup_begin kernel/futex/core.c:1058 [inline] futex_exit_release+0x2d/0x220 kernel/futex/core.c:1110 __oom_kill_process+0x373/0xf90 mm/oom_kill.c:893 oom_kill_process+0xd7/0x5c0 mm/oom_kill.c:1003 out_of_memory+0x1198/0x1460 mm/oom_kill.c:1114 __alloc_pages_may_oom mm/page_alloc.c:4330 [inline] __alloc_pages_slowpath.constprop.0+0x1972/0x1f10 mm/page_alloc.c:5061 __alloc_pages+0x403/0x4e0 mm/page_alloc.c:5392 alloc_pages+0x1a0/0x2f0 mm/mempolicy.c:2271 vm_area_alloc_pages mm/vmalloc.c:2904 [inline] __vmalloc_area_node mm/vmalloc.c:2967 [inline] __vmalloc_node_range+0xb2a/0xfd0 mm/vmalloc.c:3106 __vmalloc_node+0xb5/0x100 mm/vmalloc.c:3156 alloc_one_pg_vec_page net/packet/af_packet.c:4301 [inline] alloc_pg_vec net/packet/af_packet.c:4326 [inline] packet_set_ring+0xb60/0x1b20 net/packet/af_packet.c:4411 packet_setsockopt+0x1b4f/0x3c40 net/packet/af_packet.c:3788 __sys_setsockopt+0x180/0x2a0 net/socket.c:2177 __do_sys_setsockopt net/socket.c:2188 [inline] __se_sys_setsockopt net/socket.c:2185 [inline] __x64_sys_setsockopt+0xba/0x150 net/socket.c:2185 do_syscall_x64 arch/x86/entry/common.c:50 [inline] do_syscall_64+0x3b/0x90 arch/x86/entry/common.c:80 entry_SYSCALL_64_after_hwframe+0x44/0xae RIP: 0033:0x7fc4c8b82b19 Code: ff ff c3 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 40 00 48 89 f8 48 89 f7 48 89 d6 48 89 ca 4d 89 c2 4d 89 c8 4c 8b 4c 24 08 0f 05 <48> 3d 01 f0 ff ff 73 01 c3 48 c7 c1 bc ff ff ff f7 d8 64 89 01 48 RSP: 002b:00007fc4c60f8188 EFLAGS: 00000246 ORIG_RAX: 0000000000000036 RAX: ffffffffffffffda RBX: 00007fc4c8c95f60 RCX: 00007fc4c8b82b19 RDX: 000000000000000d RSI: 0000000000000107 RDI: 0000000000000003 RBP: 00007fc4c8bdcf6d R08: 0000000000000010 R09: 0000000000000000 R10: 0000000020000100 R11: 0000000000000246 R12: 0000000000000000 R13: 00007ffcfdb52f8f R14: 00007fc4c60f8300 R15: 0000000000022000 ============================= [ BUG: Invalid wait context ] 5.16.0-rc6-next-20211224 #1 Tainted: G W ----------------------------- syz-executor.3/16612 is trying to lock: ffff88803a2312b0 (&tsk->futex_exit_mutex){+.+.}-{3:3}, at: futex_cleanup_begin kernel/futex/core.c:1058 [inline] ffff88803a2312b0 (&tsk->futex_exit_mutex){+.+.}-{3:3}, at: futex_exit_release+0x2d/0x220 kernel/futex/core.c:1110 other info that might help us debug this: context-{4:4} 3 locks held by syz-executor.3/16612: #0: ffff88800d7f0130 (sk_lock-AF_PACKET){+.+.}-{0:0}, at: lock_sock include/net/sock.h:1667 [inline] #0: ffff88800d7f0130 (sk_lock-AF_PACKET){+.+.}-{0:0}, at: packet_setsockopt+0x156/0x3c40 net/packet/af_packet.c:3771 #1: ffffffff852791a8 (oom_lock){+.+.}-{3:3}, at: __alloc_pages_may_oom mm/page_alloc.c:4279 [inline] #1: ffffffff852791a8 (oom_lock){+.+.}-{3:3}, at: __alloc_pages_slowpath.constprop.0+0xcc9/0x1f10 mm/page_alloc.c:5061 #2: ffff88803a2308a0 (&p->alloc_lock){+.+.}-{2:2}, at: spin_lock include/linux/spinlock.h:354 [inline] #2: ffff88803a2308a0 (&p->alloc_lock){+.+.}-{2:2}, at: task_lock include/linux/sched/task.h:179 [inline] #2: ffff88803a2308a0 (&p->alloc_lock){+.+.}-{2:2}, at: find_lock_task_mm+0xe3/0x2b0 mm/oom_kill.c:144 stack backtrace: CPU: 0 PID: 16612 Comm: syz-executor.3 Tainted: G W 5.16.0-rc6-next-20211224 #1 Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS rel-1.14.0-0-g155821a1990b-prebuilt.qemu.org 04/01/2014 Call Trace: __dump_stack lib/dump_stack.c:88 [inline] dump_stack_lvl+0x8b/0xb3 lib/dump_stack.c:106 print_lock_invalid_wait_context kernel/locking/lockdep.c:4678 [inline] check_wait_context kernel/locking/lockdep.c:4739 [inline] __lock_acquire.cold+0xc8/0x3b4 kernel/locking/lockdep.c:4977 lock_acquire kernel/locking/lockdep.c:5639 [inline] lock_acquire+0x1a2/0x4d0 kernel/locking/lockdep.c:5604 __mutex_lock_common kernel/locking/mutex.c:600 [inline] __mutex_lock+0x136/0x1480 kernel/locking/mutex.c:733 futex_cleanup_begin kernel/futex/core.c:1058 [inline] futex_exit_release+0x2d/0x220 kernel/futex/core.c:1110 __oom_kill_process+0x373/0xf90 mm/oom_kill.c:893 oom_kill_process+0xd7/0x5c0 mm/oom_kill.c:1003 out_of_memory+0x1198/0x1460 mm/oom_kill.c:1114 __alloc_pages_may_oom mm/page_alloc.c:4330 [inline] __alloc_pages_slowpath.constprop.0+0x1972/0x1f10 mm/page_alloc.c:5061 __alloc_pages+0x403/0x4e0 mm/page_alloc.c:5392 alloc_pages+0x1a0/0x2f0 mm/mempolicy.c:2271 vm_area_alloc_pages mm/vmalloc.c:2904 [inline] __vmalloc_area_node mm/vmalloc.c:2967 [inline] __vmalloc_node_range+0xb2a/0xfd0 mm/vmalloc.c:3106 __vmalloc_node+0xb5/0x100 mm/vmalloc.c:3156 alloc_one_pg_vec_page net/packet/af_packet.c:4301 [inline] alloc_pg_vec net/packet/af_packet.c:4326 [inline] packet_set_ring+0xb60/0x1b20 net/packet/af_packet.c:4411 packet_setsockopt+0x1b4f/0x3c40 net/packet/af_packet.c:3788 __sys_setsockopt+0x180/0x2a0 net/socket.c:2177 __do_sys_setsockopt net/socket.c:2188 [inline] __se_sys_setsockopt net/socket.c:2185 [inline] __x64_sys_setsockopt+0xba/0x150 net/socket.c:2185 do_syscall_x64 arch/x86/entry/common.c:50 [inline] do_syscall_64+0x3b/0x90 arch/x86/entry/common.c:80 entry_SYSCALL_64_after_hwframe+0x44/0xae RIP: 0033:0x7fc4c8b82b19 Code: ff ff c3 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 40 00 48 89 f8 48 89 f7 48 89 d6 48 89 ca 4d 89 c2 4d 89 c8 4c 8b 4c 24 08 0f 05 <48> 3d 01 f0 ff ff 73 01 c3 48 c7 c1 bc ff ff ff f7 d8 64 89 01 48 RSP: 002b:00007fc4c60f8188 EFLAGS: 00000246 ORIG_RAX: 0000000000000036 RAX: ffffffffffffffda RBX: 00007fc4c8c95f60 RCX: 00007fc4c8b82b19 RDX: 000000000000000d RSI: 0000000000000107 RDI: 0000000000000003 RBP: 00007fc4c8bdcf6d R08: 0000000000000010 R09: 0000000000000000 R10: 0000000020000100 R11: 0000000000000246 R12: 0000000000000000 R13: 00007ffcfdb52f8f R14: 00007fc4c60f8300 R15: 0000000000022000 Out of memory (oom_kill_allocating_task): Killed process 16611 (syz-executor.3) total-vm:93676kB, anon-rss:388kB, file-rss:34140kB, shmem-rss:0kB, UID:0 pgtables:136kB oom_score_adj:1000 oom_reaper: reaped process 16611 (syz-executor.3), now anon-rss:0kB, file-rss:33976kB, shmem-rss:0kB syz-executor.3: vmalloc error: size 887635968, page order 0, failed to allocate pages, mode:0xdc0(GFP_KERNEL|__GFP_ZERO), nodemask=(null),cpuset=syz3,mems_allowed=0 CPU: 0 PID: 16612 Comm: syz-executor.3 Tainted: G W 5.16.0-rc6-next-20211224 #1 Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS rel-1.14.0-0-g155821a1990b-prebuilt.qemu.org 04/01/2014 Call Trace: __dump_stack lib/dump_stack.c:88 [inline] dump_stack_lvl+0x8b/0xb3 lib/dump_stack.c:106 warn_alloc.cold+0x87/0x18d mm/page_alloc.c:4236 __vmalloc_area_node mm/vmalloc.c:2978 [inline] __vmalloc_node_range+0xd50/0xfd0 mm/vmalloc.c:3106 __vmalloc_node+0xb5/0x100 mm/vmalloc.c:3156 alloc_one_pg_vec_page net/packet/af_packet.c:4301 [inline] alloc_pg_vec net/packet/af_packet.c:4326 [inline] packet_set_ring+0xb60/0x1b20 net/packet/af_packet.c:4411 packet_setsockopt+0x1b4f/0x3c40 net/packet/af_packet.c:3788 __sys_setsockopt+0x180/0x2a0 net/socket.c:2177 __do_sys_setsockopt net/socket.c:2188 [inline] __se_sys_setsockopt net/socket.c:2185 [inline] __x64_sys_setsockopt+0xba/0x150 net/socket.c:2185 do_syscall_x64 arch/x86/entry/common.c:50 [inline] do_syscall_64+0x3b/0x90 arch/x86/entry/common.c:80 entry_SYSCALL_64_after_hwframe+0x44/0xae RIP: 0033:0x7fc4c8b82b19 Code: Unable to access opcode bytes at RIP 0x7fc4c8b82aef. RSP: 002b:00007fc4c60f8188 EFLAGS: 00000246 ORIG_RAX: 0000000000000036 RAX: ffffffffffffffda RBX: 00007fc4c8c95f60 RCX: 00007fc4c8b82b19 RDX: 000000000000000d RSI: 0000000000000107 RDI: 0000000000000003 RBP: 00007fc4c8bdcf6d R08: 0000000000000010 R09: 0000000000000000 R10: 0000000020000100 R11: 0000000000000246 R12: 0000000000000000 R13: 00007ffcfdb52f8f R14: 00007fc4c60f8300 R15: 0000000000022000 Mem-Info: active_anon:6372 inactive_anon:38937 isolated_anon:0 active_file:43 inactive_file:43 isolated_file:3 unevictable:0 dirty:3 writeback:0 slab_reclaimable:7394 slab_unreclaimable:62849 mapped:69688 shmem:124 pagetables:2390 bounce:0 kernel_misc_reclaimable:0 free:3544 free_pcp:276 free_cma:0 Node 0 active_anon:25488kB inactive_anon:155748kB active_file:172kB inactive_file:172kB unevictable:0kB isolated(anon):0kB isolated(file):12kB mapped:278752kB dirty:12kB writeback:0kB shmem:496kB writeback_tmp:0kB kernel_stack:5408kB pagetables:9560kB all_unreclaimable? yes Node 0 DMA free:6512kB boost:0kB min:44kB low:56kB high:68kB reserved_highatomic:0KB active_anon:0kB inactive_anon:0kB active_file:0kB inactive_file:0kB unevictable:0kB writepending:0kB present:15992kB managed:15360kB mlocked:0kB bounce:0kB free_pcp:0kB local_pcp:0kB free_cma:0kB lowmem_reserve[]: 0 1617 1617 1617 Node 0 DMA32 free:7664kB boost:0kB min:5120kB low:6776kB high:8432kB reserved_highatomic:2048KB active_anon:25488kB inactive_anon:155832kB active_file:184kB inactive_file:288kB unevictable:0kB writepending:12kB present:2080640kB managed:1660836kB mlocked:0kB bounce:0kB free_pcp:1064kB local_pcp:400kB free_cma:0kB lowmem_reserve[]: 0 0 0 0 Node 0 DMA: 0*4kB 0*8kB 1*16kB (U) 1*32kB (U) 1*64kB (U) 0*128kB 1*256kB (U) 0*512kB 0*1024kB 1*2048kB (M) 1*4096kB (E) = 6512kB Node 0 DMA32: 651*4kB (UMEH) 252*8kB (UMH) 89*16kB (UMH) 20*32kB (UMH) 12*64kB (UMH) 1*128kB (H) 1*256kB (H) 0*512kB 0*1024kB 0*2048kB 0*4096kB = 7836kB Node 0 hugepages_total=0 hugepages_free=0 hugepages_surp=0 hugepages_size=2048kB 269 total pagecache pages 0 pages in swap cache Swap cache stats: add 0, delete 0, find 0/0 Free swap = 0kB Total swap = 0kB 524158 pages RAM 0 pages HighMem/MovableOnly 105109 pages reserved loop1: detected capacity change from 0 to 240 ISO 9660 Extensions: Microsoft Joliet Level 3 loop4: detected capacity change from 0 to 4096 loop1: detected capacity change from 0 to 240 ISO 9660 Extensions: Microsoft Joliet Level 3 FAULT_INJECTION: forcing a failure. name failslab, interval 1, probability 0, space 0, times 0 CPU: 0 PID: 16649 Comm: syz-executor.2 Tainted: G W 5.16.0-rc6-next-20211224 #1 Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS rel-1.14.0-0-g155821a1990b-prebuilt.qemu.org 04/01/2014 loop1: detected capacity change from 0 to 240 Call Trace: __dump_stack lib/dump_stack.c:88 [inline] dump_stack_lvl+0x8b/0xb3 lib/dump_stack.c:106 fail_dump lib/fault-inject.c:52 [inline] should_fail.cold+0x5/0xa lib/fault-inject.c:146 should_failslab+0x5/0x10 mm/slab_common.c:1304 slab_pre_alloc_hook mm/slab.h:716 [inline] slab_alloc_node mm/slub.c:3144 [inline] slab_alloc mm/slub.c:3238 [inline] kmem_cache_alloc+0x5b/0x480 mm/slub.c:3243 mem_pool_alloc mm/kmemleak.c:430 [inline] create_object.isra.0+0x3a/0xa20 mm/kmemleak.c:586 kmemleak_alloc_recursive include/linux/kmemleak.h:43 [inline] slab_post_alloc_hook mm/slab.h:744 [inline] slab_alloc_node mm/slub.c:3230 [inline] slab_alloc mm/slub.c:3238 [inline] kmem_cache_alloc+0x239/0x480 mm/slub.c:3243 kmem_cache_zalloc include/linux/slab.h:705 [inline] lsm_inode_alloc security/security.c:593 [inline] security_inode_alloc+0x34/0x160 security/security.c:1010 inode_init_always+0x52e/0xc50 fs/inode.c:195 alloc_inode+0x84/0x230 fs/inode.c:267 new_inode_pseudo fs/inode.c:1018 [inline] new_inode+0x23/0x240 fs/inode.c:1047 proc_pid_make_inode+0x26/0x3c0 fs/proc/base.c:1898 proc_pident_instantiate+0x81/0x310 fs/proc/base.c:2613 proc_pident_lookup+0x1e7/0x270 fs/proc/base.c:2649 __lookup_slow+0x252/0x490 fs/namei.c:1707 lookup_slow fs/namei.c:1724 [inline] walk_component+0x411/0x6a0 fs/namei.c:2020 link_path_walk.part.0+0x7f8/0xf80 fs/namei.c:2347 link_path_walk fs/namei.c:2272 [inline] path_openat+0x263/0x28a0 fs/namei.c:3605 do_filp_open+0x1aa/0x400 fs/namei.c:3636 do_sys_openat2+0x16d/0x4d0 fs/open.c:1214 do_sys_open fs/open.c:1230 [inline] __do_sys_openat fs/open.c:1246 [inline] __se_sys_openat fs/open.c:1241 [inline] __x64_sys_openat+0x13f/0x1f0 fs/open.c:1241 do_syscall_x64 arch/x86/entry/common.c:50 [inline] do_syscall_64+0x3b/0x90 arch/x86/entry/common.c:80 entry_SYSCALL_64_after_hwframe+0x44/0xae RIP: 0033:0x7f9568dd9a04 Code: 84 00 00 00 00 00 44 89 54 24 0c e8 96 f9 ff ff 44 8b 54 24 0c 44 89 e2 48 89 ee 41 89 c0 bf 9c ff ff ff b8 01 01 00 00 0f 05 <48> 3d 00 f0 ff ff 77 34 44 89 c7 89 44 24 0c e8 c8 f9 ff ff 8b 44 RSP: 002b:00007f956639c0b0 EFLAGS: 00000293 ORIG_RAX: 0000000000000101 RAX: ffffffffffffffda RBX: 00007f9568f39f60 RCX: 00007f9568dd9a04 RDX: 0000000000000000 RSI: 00007f9568e7ff82 RDI: 00000000ffffff9c RBP: 00007f9568e7ff82 R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000293 R12: 0000000000000000 R13: 00007ffc9f443e9f R14: 00007f956639c300 R15: 0000000000022000 ISO 9660 Extensions: Microsoft Joliet Level 3 loop1: detected capacity change from 0 to 240 ISO 9660 Extensions: Microsoft Joliet Level 3