============================= [ BUG: Invalid wait context ] 6.12.0-syzkaller-12113-gbcc8eda6d349 #0 Not tainted ----------------------------- syz.4.475/7956 is trying to lock: ffffffff8e01dd98 (kernfs_rename_lock){....}-{3:3}, at: kernfs_path_from_node+0x29/0x60 fs/kernfs/dir.c:229 other info that might help us debug this: context-{5:5} 3 locks held by syz.4.475/7956: #0: ffff88802b43ed18 (&rq->__lock){-.-.}-{2:2}, at: raw_spin_rq_lock_nested+0x29/0x130 kernel/sched/core.c:598 #1: ffffffff8ddba940 (rcu_read_lock){....}-{1:3}, at: rcu_lock_acquire include/linux/rcupdate.h:337 [inline] #1: ffffffff8ddba940 (rcu_read_lock){....}-{1:3}, at: rcu_read_lock include/linux/rcupdate.h:849 [inline] #1: ffffffff8ddba940 (rcu_read_lock){....}-{1:3}, at: __bpf_trace_run kernel/trace/bpf_trace.c:2350 [inline] #1: ffffffff8ddba940 (rcu_read_lock){....}-{1:3}, at: bpf_trace_run2+0x1c2/0x590 kernel/trace/bpf_trace.c:2392 #2: ffff888012bf81e0 (&mm->mmap_lock){++++}-{4:4}, at: mmap_read_trylock include/linux/mmap_lock.h:163 [inline] #2: ffff888012bf81e0 (&mm->mmap_lock){++++}-{4:4}, at: stack_map_get_build_id_offset+0x236/0x700 kernel/bpf/stackmap.c:157 stack backtrace: CPU: 0 UID: 0 PID: 7956 Comm: syz.4.475 Not tainted 6.12.0-syzkaller-12113-gbcc8eda6d349 #0 Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.16.3-debian-1.16.3-2~bpo12+1 04/01/2014 Call Trace: __dump_stack lib/dump_stack.c:94 [inline] dump_stack_lvl+0x116/0x1f0 lib/dump_stack.c:120 print_lock_invalid_wait_context kernel/locking/lockdep.c:4826 [inline] check_wait_context kernel/locking/lockdep.c:4898 [inline] __lock_acquire+0x878/0x3c40 kernel/locking/lockdep.c:5176 lock_acquire.part.0+0x11b/0x380 kernel/locking/lockdep.c:5849 __raw_read_lock_irqsave include/linux/rwlock_api_smp.h:160 [inline] _raw_read_lock_irqsave+0x74/0x90 kernel/locking/spinlock.c:236 kernfs_path_from_node+0x29/0x60 fs/kernfs/dir.c:229 kernfs_path include/linux/kernfs.h:598 [inline] cgroup_path include/linux/cgroup.h:599 [inline] get_mm_memcg_path.constprop.0+0xb7/0x3d0 mm/mmap_lock.c:59 __mmap_lock_do_trace_acquire_returned.part.0+0x95/0x2d0 mm/mmap_lock.c:79 __mmap_lock_do_trace_acquire_returned+0x33/0x40 include/trace/events/mmap_lock.h:48 __mmap_lock_trace_acquire_returned include/linux/mmap_lock.h:36 [inline] mmap_read_trylock include/linux/mmap_lock.h:164 [inline] stack_map_get_build_id_offset+0x5d6/0x700 kernel/bpf/stackmap.c:157 __bpf_get_stack+0x309/0xa30 kernel/bpf/stackmap.c:483 ____bpf_get_stack kernel/bpf/stackmap.c:499 [inline] bpf_get_stack+0x32/0x40 kernel/bpf/stackmap.c:496 ____bpf_get_stack_raw_tp kernel/trace/bpf_trace.c:1944 [inline] bpf_get_stack_raw_tp+0x124/0x160 kernel/trace/bpf_trace.c:1934 bpf_prog_ec3b2eefa702d8d3+0x43/0x47 bpf_dispatcher_nop_func include/linux/bpf.h:1290 [inline] __bpf_prog_run include/linux/filter.h:701 [inline] bpf_prog_run include/linux/filter.h:708 [inline] __bpf_trace_run kernel/trace/bpf_trace.c:2351 [inline] bpf_trace_run2+0x231/0x590 kernel/trace/bpf_trace.c:2392 trace_tlb_flush+0xf7/0x180 include/trace/events/tlb.h:38 switch_mm_irqs_off+0x395/0xb10 arch/x86/mm/tlb.c:637 context_switch kernel/sched/core.c:5353 [inline] __schedule+0xc6f/0x5ad0 kernel/sched/core.c:6756 __schedule_loop kernel/sched/core.c:6833 [inline] schedule+0xe7/0x350 kernel/sched/core.c:6848 futex_wait_queue+0xfc/0x1f0 kernel/futex/waitwake.c:370 __futex_wait+0x291/0x3c0 kernel/futex/waitwake.c:669 futex_wait+0xe9/0x380 kernel/futex/waitwake.c:697 do_futex+0x22b/0x350 kernel/futex/syscalls.c:102 __do_sys_futex_time32 kernel/futex/syscalls.c:509 [inline] __se_sys_futex_time32 kernel/futex/syscalls.c:492 [inline] __ia32_sys_futex_time32+0x1da/0x460 kernel/futex/syscalls.c:492 do_syscall_32_irqs_on arch/x86/entry/common.c:165 [inline] __do_fast_syscall_32+0x73/0x120 arch/x86/entry/common.c:386 do_fast_syscall_32+0x32/0x80 arch/x86/entry/common.c:411 entry_SYSENTER_compat_after_hwframe+0x84/0x8e RIP: 0023:0xf73ae579 Code: Unable to access opcode bytes at 0xf73ae54f. RSP: 002b:00000000ffe16eac EFLAGS: 00000202 ORIG_RAX: 00000000000000f0 RAX: ffffffffffffffda RBX: 00000000f73d4f8c RCX: 0000000000000080 RDX: 0000000000000000 RSI: 00000000ffe17078 RDI: 00000000f73a0ff4 RBP: 0000000000000000 R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000 R13: 0000000000000000 R14: 0000000000000000 R15: 0000000000000000