Extracting prog: 1m31.137958167s Minimizing prog: 6m18.396409964s Simplifying prog options: 0s Extracting C: 28.89327482s Simplifying C: 7m34.584106463s extracting reproducer from 30 programs first checking the prog from the crash report single: executing 1 programs separately with timeout 30s testing program (duration=30s, {Threaded:true Repeat:true RepeatTimes:0 Procs:5 Slowdown:1 Sandbox:none SandboxArg:0 Leak:false NetInjection:true NetDevices:true NetReset:true Cgroups:true BinfmtMisc:true CloseFDs:true KCSAN:false DevlinkPCI:false NicVF:false USB:true VhciInjection:true Wifi:true IEEE802154:true Sysctl:true Swap:true UseTmpDir:true HandleSegv:true Trace:false LegacyOptions:{Collide:false Fault:false FaultCall:0 FaultNth:0}}): socket$inet_smc-setsockopt$IPT_SO_SET_REPLACE detailed listing: executing program 0: r0 = socket$inet_smc(0x2b, 0x1, 0x0) setsockopt$IPT_SO_SET_REPLACE(r0, 0x4000000000000, 0x40, &(0x7f0000000000)=@raw={'raw\x00', 0xc01, 0x3, 0x2298, 0x1100, 0x5002004a, 0x0, 0x0, 0x0, 0x2200, 0x3c8, 0x3c8, 0x2200, 0x3c8, 0x3, 0x0, {[{{@uncond, 0x60, 0x10a0, 0x1100, 0x0, {}, [@common=@unspec=@cgroup1={{0x1030}, {0x1, 0x0, 0x0, 0x0, './cgroup.cpu/syz1\x00'}}]}, @common=@SET={0x60, 'SET\x00', 0x0, {{0x1, [0x2, 0x1, 0x7], 0x6, 0x2}, {0x2, [0x0, 0x6, 0x4, 0x9, 0x0, 0x89ce99baffcf6900], 0x1, 0x1}}}}, {{@uncond, 0x0, 0x10a0, 0x1100, 0x0, {}, [@common=@unspec=@cgroup1={{0x1030}, {0x0, 0x0, 0x1, 0x1, './cgroup.net/syz1\x00', 0x2, {0x5}}}]}, @common=@inet=@HMARK={0x60, 'HMARK\x00', 0x0, {@ipv4=@loopback, [0xffffff00, 0xff000000, 0xff, 0xff0000ff], 0x4e22, 0x4c20, 0x4e24, 0x4e23, 0xc9, 0x0, 0x3b, 0x83, 0x25}}}], {{'\x00', 0x0, 0x70, 0x98}, {0x28, '\x00', 0x4}}}}, 0x22f8) program crashed: BUG: sleeping function called from invalid context in kernfs_walk_and_get_ns single: successfully extracted reproducer found reproducer with 2 syscalls minimizing guilty program testing program (duration=42.343292458s, {Threaded:true Repeat:true RepeatTimes:0 Procs:5 Slowdown:1 Sandbox:none SandboxArg:0 Leak:false NetInjection:true NetDevices:true NetReset:true Cgroups:true BinfmtMisc:true CloseFDs:true KCSAN:false DevlinkPCI:false NicVF:false USB:true VhciInjection:true Wifi:true IEEE802154:true Sysctl:true Swap:true UseTmpDir:true HandleSegv:true Trace:false LegacyOptions:{Collide:false Fault:false FaultCall:0 FaultNth:0}}): socket$inet_smc detailed listing: executing program 0: socket$inet_smc(0x2b, 0x1, 0x0) program did not crash testing program (duration=42.343292458s, {Threaded:true Repeat:true RepeatTimes:0 Procs:5 Slowdown:1 Sandbox:none SandboxArg:0 Leak:false NetInjection:true NetDevices:true NetReset:true Cgroups:true BinfmtMisc:true CloseFDs:true KCSAN:false DevlinkPCI:false NicVF:false USB:true VhciInjection:true Wifi:true IEEE802154:true Sysctl:true Swap:true UseTmpDir:true HandleSegv:true Trace:false LegacyOptions:{Collide:false Fault:false FaultCall:0 FaultNth:0}}): setsockopt$IPT_SO_SET_REPLACE detailed listing: executing program 0: setsockopt$IPT_SO_SET_REPLACE(0xffffffffffffffff, 0x4000000000000, 0x40, &(0x7f0000000000)=@raw={'raw\x00', 0xc01, 0x3, 0x2298, 0x1100, 0x5002004a, 0x0, 0x0, 0x0, 0x2200, 0x3c8, 0x3c8, 0x2200, 0x3c8, 0x3, 0x0, {[{{@uncond, 0x60, 0x10a0, 0x1100, 0x0, {}, [@common=@unspec=@cgroup1={{0x1030}, {0x1, 0x0, 0x0, 0x0, './cgroup.cpu/syz1\x00'}}]}, @common=@SET={0x60, 'SET\x00', 0x0, {{0x1, [0x2, 0x1, 0x7], 0x6, 0x2}, {0x2, [0x0, 0x6, 0x4, 0x9, 0x0, 0x89ce99baffcf6900], 0x1, 0x1}}}}, {{@uncond, 0x0, 0x10a0, 0x1100, 0x0, {}, [@common=@unspec=@cgroup1={{0x1030}, {0x0, 0x0, 0x1, 0x1, './cgroup.net/syz1\x00', 0x2, {0x5}}}]}, @common=@inet=@HMARK={0x60, 'HMARK\x00', 0x0, {@ipv4=@loopback, [0xffffff00, 0xff000000, 0xff, 0xff0000ff], 0x4e22, 0x4c20, 0x4e24, 0x4e23, 0xc9, 0x0, 0x3b, 0x83, 0x25}}}], {{'\x00', 0x0, 0x70, 0x98}, {0x28, '\x00', 0x4}}}}, 0x22f8) program did not crash testing program (duration=42.343292458s, {Threaded:true Repeat:true RepeatTimes:0 Procs:5 Slowdown:1 Sandbox:none SandboxArg:0 Leak:false NetInjection:true NetDevices:true NetReset:true Cgroups:true BinfmtMisc:true CloseFDs:true KCSAN:false DevlinkPCI:false NicVF:false USB:true VhciInjection:true Wifi:true IEEE802154:true Sysctl:true Swap:true UseTmpDir:true HandleSegv:true Trace:false LegacyOptions:{Collide:false Fault:false FaultCall:0 FaultNth:0}}): socket$inet_smc-setsockopt$IPT_SO_SET_REPLACE detailed listing: executing program 0: r0 = socket$inet_smc(0x2b, 0x1, 0x0) setsockopt$IPT_SO_SET_REPLACE(r0, 0x4000000000000, 0x40, 0x0, 0x0) program did not crash extracting C reproducer testing compiled C program (duration=42.343292458s, {Threaded:true Repeat:true RepeatTimes:0 Procs:5 Slowdown:1 Sandbox:none SandboxArg:0 Leak:false NetInjection:true NetDevices:true NetReset:true Cgroups:true BinfmtMisc:true CloseFDs:true KCSAN:false DevlinkPCI:false NicVF:false USB:true VhciInjection:true Wifi:true IEEE802154:true Sysctl:true Swap:true UseTmpDir:true HandleSegv:true Trace:false LegacyOptions:{Collide:false Fault:false FaultCall:0 FaultNth:0}}): socket$inet_smc-setsockopt$IPT_SO_SET_REPLACE program crashed: BUG: sleeping function called from invalid context in kernfs_walk_and_get_ns simplifying C reproducer testing compiled C program (duration=42.343292458s, {Threaded:false Repeat:true RepeatTimes:0 Procs:5 Slowdown:1 Sandbox:none SandboxArg:0 Leak:false NetInjection:true NetDevices:true NetReset:true Cgroups:true BinfmtMisc:true CloseFDs:true KCSAN:false DevlinkPCI:false NicVF:false USB:true VhciInjection:true Wifi:true IEEE802154:true Sysctl:true Swap:true UseTmpDir:true HandleSegv:true Trace:false LegacyOptions:{Collide:false Fault:false FaultCall:0 FaultNth:0}}): socket$inet_smc-setsockopt$IPT_SO_SET_REPLACE program crashed: BUG: sleeping function called from invalid context in kernfs_walk_and_get_ns testing compiled C program (duration=42.343292458s, {Threaded:false Repeat:false RepeatTimes:0 Procs:1 Slowdown:1 Sandbox:none SandboxArg:0 Leak:false NetInjection:true NetDevices:true NetReset:false Cgroups:false BinfmtMisc:true CloseFDs:true KCSAN:false DevlinkPCI:false NicVF:false USB:true VhciInjection:true Wifi:true IEEE802154:true Sysctl:true Swap:true UseTmpDir:true HandleSegv:true Trace:false LegacyOptions:{Collide:false Fault:false FaultCall:0 FaultNth:0}}): socket$inet_smc-setsockopt$IPT_SO_SET_REPLACE program crashed: BUG: sleeping function called from invalid context in kernfs_walk_and_get_ns testing compiled C program (duration=42.343292458s, {Threaded:false Repeat:false RepeatTimes:0 Procs:1 Slowdown:1 Sandbox: SandboxArg:0 Leak:false NetInjection:false NetDevices:false NetReset:false Cgroups:false BinfmtMisc:false CloseFDs:false KCSAN:false DevlinkPCI:false NicVF:false USB:false VhciInjection:false Wifi:false IEEE802154:true Sysctl:true Swap:false UseTmpDir:true HandleSegv:true Trace:false LegacyOptions:{Collide:false Fault:false FaultCall:0 FaultNth:0}}): socket$inet_smc-setsockopt$IPT_SO_SET_REPLACE program crashed: BUG: sleeping function called from invalid context in kernfs_walk_and_get_ns testing compiled C program (duration=42.343292458s, {Threaded:false Repeat:false RepeatTimes:0 Procs:1 Slowdown:1 Sandbox: SandboxArg:0 Leak:false NetInjection:false NetDevices:false NetReset:false Cgroups:false BinfmtMisc:false CloseFDs:false KCSAN:false DevlinkPCI:false NicVF:false USB:false VhciInjection:false Wifi:false IEEE802154:false Sysctl:true Swap:false UseTmpDir:true HandleSegv:true Trace:false LegacyOptions:{Collide:false Fault:false FaultCall:0 FaultNth:0}}): socket$inet_smc-setsockopt$IPT_SO_SET_REPLACE program crashed: BUG: sleeping function called from invalid context in kernfs_walk_and_get_ns testing compiled C program (duration=42.343292458s, {Threaded:false Repeat:false RepeatTimes:0 Procs:1 Slowdown:1 Sandbox: SandboxArg:0 Leak:false NetInjection:false NetDevices:false NetReset:false Cgroups:false BinfmtMisc:false CloseFDs:false KCSAN:false DevlinkPCI:false NicVF:false USB:false VhciInjection:false Wifi:false IEEE802154:false Sysctl:true Swap:false UseTmpDir:false HandleSegv:true Trace:false LegacyOptions:{Collide:false Fault:false FaultCall:0 FaultNth:0}}): socket$inet_smc-setsockopt$IPT_SO_SET_REPLACE program crashed: BUG: sleeping function called from invalid context in kernfs_walk_and_get_ns testing compiled C program (duration=42.343292458s, {Threaded:false Repeat:false RepeatTimes:0 Procs:1 Slowdown:1 Sandbox: SandboxArg:0 Leak:false NetInjection:false NetDevices:false NetReset:false Cgroups:false BinfmtMisc:false CloseFDs:false KCSAN:false DevlinkPCI:false NicVF:false USB:false VhciInjection:false Wifi:false IEEE802154:false Sysctl:true Swap:false UseTmpDir:false HandleSegv:false Trace:false LegacyOptions:{Collide:false Fault:false FaultCall:0 FaultNth:0}}): socket$inet_smc-setsockopt$IPT_SO_SET_REPLACE program crashed: BUG: sleeping function called from invalid context in kernfs_walk_and_get_ns testing compiled C program (duration=42.343292458s, {Threaded:false Repeat:false RepeatTimes:0 Procs:1 Slowdown:1 Sandbox: SandboxArg:0 Leak:false NetInjection:false NetDevices:false NetReset:false Cgroups:false BinfmtMisc:false CloseFDs:false KCSAN:false DevlinkPCI:false NicVF:false USB:false VhciInjection:false Wifi:false IEEE802154:false Sysctl:false Swap:false UseTmpDir:false HandleSegv:false Trace:false LegacyOptions:{Collide:false Fault:false FaultCall:0 FaultNth:0}}): socket$inet_smc-setsockopt$IPT_SO_SET_REPLACE program crashed: BUG: sleeping function called from invalid context in kernfs_walk_and_get_ns reproducing took 15m53.011781944s repro crashed as (corrupted=false): BUG: sleeping function called from invalid context at kernel/locking/rwsem.c:1497 in_atomic(): 1, irqs_disabled(): 128, non_block: 0, pid: 4022, name: syz-executor631 2 locks held by syz-executor631/4022: #0: ffff0000c1dd8a68 (&smc->clcsock_release_lock){+.+.}-{3:3}, at: smc_setsockopt+0xf4/0xbc8 net/smc/af_smc.c:2458 #1: ffff800014346478 (css_set_lock){....}-{2:2}, at: spin_lock_irq include/linux/spinlock.h:388 [inline] #1: ffff800014346478 (css_set_lock){....}-{2:2}, at: cgroup_get_from_path+0x30/0x300 kernel/cgroup/cgroup.c:6627 irq event stamp: 13984 hardirqs last enabled at (13983): [] __exit_to_kernel_mode arch/arm64/kernel/entry-common.c:81 [inline] hardirqs last enabled at (13983): [] exit_to_kernel_mode+0xe0/0x168 arch/arm64/kernel/entry-common.c:91 hardirqs last disabled at (13984): [] __raw_spin_lock_irq include/linux/spinlock_api_smp.h:126 [inline] hardirqs last disabled at (13984): [] _raw_spin_lock_irq+0x38/0x13c kernel/locking/spinlock.c:170 softirqs last enabled at (13978): [] softirq_handle_end kernel/softirq.c:401 [inline] softirqs last enabled at (13978): [] handle_softirqs+0xa4c/0xbf0 kernel/softirq.c:586 softirqs last disabled at (13911): [] __do_softirq kernel/softirq.c:592 [inline] softirqs last disabled at (13911): [] do_softirq_own_stack include/asm-generic/softirq_stack.h:10 [inline] softirqs last disabled at (13911): [] invoke_softirq kernel/softirq.c:439 [inline] softirqs last disabled at (13911): [] __irq_exit_rcu+0x240/0x440 kernel/softirq.c:641 Preemption disabled at: [] spin_lock_irq include/linux/spinlock.h:388 [inline] [] cgroup_get_from_path+0x30/0x300 kernel/cgroup/cgroup.c:6627 CPU: 0 PID: 4022 Comm: syz-executor631 Not tainted 5.15.182-syzkaller #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 04/19/2025 Call trace: dump_backtrace+0x0/0x43c arch/arm64/kernel/stacktrace.c:152 show_stack+0x2c/0x3c arch/arm64/kernel/stacktrace.c:216 __dump_stack+0x30/0x40 lib/dump_stack.c:88 dump_stack_lvl+0xf8/0x160 lib/dump_stack.c:106 dump_stack+0x1c/0x5c lib/dump_stack.c:113 ___might_sleep+0x358/0x4d4 kernel/sched/core.c:9639 __might_sleep+0x98/0x124 kernel/sched/core.c:9593 down_read+0x3c/0x390 kernel/locking/rwsem.c:1497 kernfs_walk_and_get_ns+0x8c/0x2fc fs/kernfs/dir.c:908 kernfs_walk_and_get include/linux/kernfs.h:559 [inline] cgroup_get_from_path+0x64/0x300 kernel/cgroup/cgroup.c:6629 cgroup_mt_check_v1+0x18c/0x278 net/netfilter/xt_cgroup.c:56 xt_check_match+0x314/0x8a0 net/netfilter/x_tables.c:523 check_match net/ipv4/netfilter/ip_tables.c:472 [inline] find_check_match net/ipv4/netfilter/ip_tables.c:488 [inline] find_check_entry net/ipv4/netfilter/ip_tables.c:538 [inline] translate_table+0xf60/0x17fc net/ipv4/netfilter/ip_tables.c:717 do_replace net/ipv4/netfilter/ip_tables.c:1138 [inline] do_ipt_set_ctl+0xa10/0xe00 net/ipv4/netfilter/ip_tables.c:1636 nf_setsockopt+0x270/0x290 net/netfilter/nf_sockopt.c:101 ip_setsockopt+0x1d0c/0x2978 net/ipv4/ip_sockglue.c:1442 tcp_setsockopt+0x1d4/0x1bf4 net/ipv4/tcp.c:3713 sock_common_setsockopt+0xb0/0xcc net/core/sock.c:3446 smc_setsockopt+0x188/0xbc8 net/smc/af_smc.c:2466 __sys_setsockopt+0x2f8/0x4b0 net/socket.c:2203 __do_sys_setsockopt net/socket.c:2214 [inline] __se_sys_setsockopt net/socket.c:2211 [inline] __arm64_sys_setsockopt+0xb8/0xd4 net/socket.c:2211 __invoke_syscall arch/arm64/kernel/syscall.c:38 [inline] invoke_syscall+0x98/0x2b8 arch/arm64/kernel/syscall.c:52 el0_svc_common+0x138/0x258 arch/arm64/kernel/syscall.c:142 do_el0_svc+0x58/0x14c arch/arm64/kernel/syscall.c:181 el0_svc+0x78/0x1e0 arch/arm64/kernel/entry-common.c:608 el0t_64_sync_handler+0xcc/0xe4 arch/arm64/kernel/entry-common.c:626 el0t_64_sync+0x1a0/0x1a4 arch/arm64/kernel/entry.S:584 ============================= [ BUG: Invalid wait context ] 5.15.182-syzkaller #0 Tainted: G W ----------------------------- syz-executor631/4022 is trying to lock: ffff800014446870 (kernfs_rwsem){++++}-{3:3}, at: kernfs_walk_and_get_ns+0x8c/0x2fc fs/kernfs/dir.c:908 other info that might help us debug this: context-{4:4} 2 locks held by syz-executor631/4022: #0: ffff0000c1dd8a68 (&smc->clcsock_release_lock){+.+.}-{3:3}, at: smc_setsockopt+0xf4/0xbc8 net/smc/af_smc.c:2458 #1: ffff800014346478 (css_set_lock){....}-{2:2}, at: spin_lock_irq include/linux/spinlock.h:388 [inline] #1: ffff800014346478 (css_set_lock){....}-{2:2}, at: cgroup_get_from_path+0x30/0x300 kernel/cgroup/cgroup.c:6627 stack backtrace: CPU: 0 PID: 4022 Comm: syz-executor631 Tainted: G W 5.15.182-syzkaller #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 04/19/2025 Call trace: dump_backtrace+0x0/0x43c arch/arm64/kernel/stacktrace.c:152 show_stack+0x2c/0x3c arch/arm64/kernel/stacktrace.c:216 __dump_stack+0x30/0x40 lib/dump_stack.c:88 dump_stack_lvl+0xf8/0x160 lib/dump_stack.c:106 dump_stack+0x1c/0x5c lib/dump_stack.c:113 print_lock_invalid_wait_context kernel/locking/lockdep.c:4664 [inline] check_wait_context kernel/locking/lockdep.c:4725 [inline] __lock_acquire+0x1acc/0x651c kernel/locking/lockdep.c:4962 lock_acquire+0x1f4/0x620 kernel/locking/lockdep.c:5623 down_read+0xc0/0x390 kernel/locking/rwsem.c:1498 kernfs_walk_and_get_ns+0x8c/0x2fc fs/kernfs/dir.c:908 kernfs_walk_and_get include/linux/kernfs.h:559 [inline] cgroup_get_from_path+0x64/0x300 kernel/cgroup/cgroup.c:6629 cgroup_mt_check_v1+0x18c/0x278 net/netfilter/xt_cgroup.c:56 xt_check_match+0x314/0x8a0 net/netfilter/x_tables.c:523 check_match net/ipv4/netfilter/ip_tables.c:472 [inline] find_check_match net/ipv4/netfilter/ip_tables.c:488 [inline] find_check_entry net/ipv4/netfilter/ip_tables.c:538 [inline] translate_table+0xf60/0x17fc net/ipv4/netfilter/ip_tables.c:717 do_replace net/ipv4/netfilter/ip_tables.c:1138 [inline] do_ipt_set_ctl+0xa10/0xe00 net/ipv4/netfilter/ip_tables.c:1636 nf_setsockopt+0x270/0x290 net/netfilter/nf_sockopt.c:101 ip_setsockopt+0x1d0c/0x2978 net/ipv4/ip_sockglue.c:1442 tcp_setsockopt+0x1d4/0x1bf4 net/ipv4/tcp.c:3713 sock_common_setsockopt+0xb0/0xcc net/core/sock.c:3446 smc_setsockopt+0x188/0xbc8 net/smc/af_smc.c:2466 __sys_setsockopt+0x2f8/0x4b0 net/socket.c:2203 __do_sys_setsockopt net/socket.c:2214 [inline] __se_sys_setsockopt net/socket.c:2211 [inline] __arm64_sys_setsockopt+0xb8/0xd4 net/socket.c:2211 __invoke_syscall arch/arm64/kernel/syscall.c:38 [inline] invoke_syscall+0x98/0x2b8 arch/arm64/kernel/syscall.c:52 el0_svc_common+0x138/0x258 arch/arm64/kernel/syscall.c:142 do_el0_svc+0x58/0x14c arch/arm64/kernel/syscall.c:181 el0_svc+0x78/0x1e0 arch/arm64/kernel/entry-common.c:608 el0t_64_sync_handler+0xcc/0xe4 arch/arm64/kernel/entry-common.c:626 el0t_64_sync+0x1a0/0x1a4 arch/arm64/kernel/entry.S:584 xt_cgroup: invalid path, errno=-2 final repro crashed as (corrupted=false): BUG: sleeping function called from invalid context at kernel/locking/rwsem.c:1497 in_atomic(): 1, irqs_disabled(): 128, non_block: 0, pid: 4022, name: syz-executor631 2 locks held by syz-executor631/4022: #0: ffff0000c1dd8a68 (&smc->clcsock_release_lock){+.+.}-{3:3}, at: smc_setsockopt+0xf4/0xbc8 net/smc/af_smc.c:2458 #1: ffff800014346478 (css_set_lock){....}-{2:2}, at: spin_lock_irq include/linux/spinlock.h:388 [inline] #1: ffff800014346478 (css_set_lock){....}-{2:2}, at: cgroup_get_from_path+0x30/0x300 kernel/cgroup/cgroup.c:6627 irq event stamp: 13984 hardirqs last enabled at (13983): [] __exit_to_kernel_mode arch/arm64/kernel/entry-common.c:81 [inline] hardirqs last enabled at (13983): [] exit_to_kernel_mode+0xe0/0x168 arch/arm64/kernel/entry-common.c:91 hardirqs last disabled at (13984): [] __raw_spin_lock_irq include/linux/spinlock_api_smp.h:126 [inline] hardirqs last disabled at (13984): [] _raw_spin_lock_irq+0x38/0x13c kernel/locking/spinlock.c:170 softirqs last enabled at (13978): [] softirq_handle_end kernel/softirq.c:401 [inline] softirqs last enabled at (13978): [] handle_softirqs+0xa4c/0xbf0 kernel/softirq.c:586 softirqs last disabled at (13911): [] __do_softirq kernel/softirq.c:592 [inline] softirqs last disabled at (13911): [] do_softirq_own_stack include/asm-generic/softirq_stack.h:10 [inline] softirqs last disabled at (13911): [] invoke_softirq kernel/softirq.c:439 [inline] softirqs last disabled at (13911): [] __irq_exit_rcu+0x240/0x440 kernel/softirq.c:641 Preemption disabled at: [] spin_lock_irq include/linux/spinlock.h:388 [inline] [] cgroup_get_from_path+0x30/0x300 kernel/cgroup/cgroup.c:6627 CPU: 0 PID: 4022 Comm: syz-executor631 Not tainted 5.15.182-syzkaller #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 04/19/2025 Call trace: dump_backtrace+0x0/0x43c arch/arm64/kernel/stacktrace.c:152 show_stack+0x2c/0x3c arch/arm64/kernel/stacktrace.c:216 __dump_stack+0x30/0x40 lib/dump_stack.c:88 dump_stack_lvl+0xf8/0x160 lib/dump_stack.c:106 dump_stack+0x1c/0x5c lib/dump_stack.c:113 ___might_sleep+0x358/0x4d4 kernel/sched/core.c:9639 __might_sleep+0x98/0x124 kernel/sched/core.c:9593 down_read+0x3c/0x390 kernel/locking/rwsem.c:1497 kernfs_walk_and_get_ns+0x8c/0x2fc fs/kernfs/dir.c:908 kernfs_walk_and_get include/linux/kernfs.h:559 [inline] cgroup_get_from_path+0x64/0x300 kernel/cgroup/cgroup.c:6629 cgroup_mt_check_v1+0x18c/0x278 net/netfilter/xt_cgroup.c:56 xt_check_match+0x314/0x8a0 net/netfilter/x_tables.c:523 check_match net/ipv4/netfilter/ip_tables.c:472 [inline] find_check_match net/ipv4/netfilter/ip_tables.c:488 [inline] find_check_entry net/ipv4/netfilter/ip_tables.c:538 [inline] translate_table+0xf60/0x17fc net/ipv4/netfilter/ip_tables.c:717 do_replace net/ipv4/netfilter/ip_tables.c:1138 [inline] do_ipt_set_ctl+0xa10/0xe00 net/ipv4/netfilter/ip_tables.c:1636 nf_setsockopt+0x270/0x290 net/netfilter/nf_sockopt.c:101 ip_setsockopt+0x1d0c/0x2978 net/ipv4/ip_sockglue.c:1442 tcp_setsockopt+0x1d4/0x1bf4 net/ipv4/tcp.c:3713 sock_common_setsockopt+0xb0/0xcc net/core/sock.c:3446 smc_setsockopt+0x188/0xbc8 net/smc/af_smc.c:2466 __sys_setsockopt+0x2f8/0x4b0 net/socket.c:2203 __do_sys_setsockopt net/socket.c:2214 [inline] __se_sys_setsockopt net/socket.c:2211 [inline] __arm64_sys_setsockopt+0xb8/0xd4 net/socket.c:2211 __invoke_syscall arch/arm64/kernel/syscall.c:38 [inline] invoke_syscall+0x98/0x2b8 arch/arm64/kernel/syscall.c:52 el0_svc_common+0x138/0x258 arch/arm64/kernel/syscall.c:142 do_el0_svc+0x58/0x14c arch/arm64/kernel/syscall.c:181 el0_svc+0x78/0x1e0 arch/arm64/kernel/entry-common.c:608 el0t_64_sync_handler+0xcc/0xe4 arch/arm64/kernel/entry-common.c:626 el0t_64_sync+0x1a0/0x1a4 arch/arm64/kernel/entry.S:584 ============================= [ BUG: Invalid wait context ] 5.15.182-syzkaller #0 Tainted: G W ----------------------------- syz-executor631/4022 is trying to lock: ffff800014446870 (kernfs_rwsem){++++}-{3:3}, at: kernfs_walk_and_get_ns+0x8c/0x2fc fs/kernfs/dir.c:908 other info that might help us debug this: context-{4:4} 2 locks held by syz-executor631/4022: #0: ffff0000c1dd8a68 (&smc->clcsock_release_lock){+.+.}-{3:3}, at: smc_setsockopt+0xf4/0xbc8 net/smc/af_smc.c:2458 #1: ffff800014346478 (css_set_lock){....}-{2:2}, at: spin_lock_irq include/linux/spinlock.h:388 [inline] #1: ffff800014346478 (css_set_lock){....}-{2:2}, at: cgroup_get_from_path+0x30/0x300 kernel/cgroup/cgroup.c:6627 stack backtrace: CPU: 0 PID: 4022 Comm: syz-executor631 Tainted: G W 5.15.182-syzkaller #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 04/19/2025 Call trace: dump_backtrace+0x0/0x43c arch/arm64/kernel/stacktrace.c:152 show_stack+0x2c/0x3c arch/arm64/kernel/stacktrace.c:216 __dump_stack+0x30/0x40 lib/dump_stack.c:88 dump_stack_lvl+0xf8/0x160 lib/dump_stack.c:106 dump_stack+0x1c/0x5c lib/dump_stack.c:113 print_lock_invalid_wait_context kernel/locking/lockdep.c:4664 [inline] check_wait_context kernel/locking/lockdep.c:4725 [inline] __lock_acquire+0x1acc/0x651c kernel/locking/lockdep.c:4962 lock_acquire+0x1f4/0x620 kernel/locking/lockdep.c:5623 down_read+0xc0/0x390 kernel/locking/rwsem.c:1498 kernfs_walk_and_get_ns+0x8c/0x2fc fs/kernfs/dir.c:908 kernfs_walk_and_get include/linux/kernfs.h:559 [inline] cgroup_get_from_path+0x64/0x300 kernel/cgroup/cgroup.c:6629 cgroup_mt_check_v1+0x18c/0x278 net/netfilter/xt_cgroup.c:56 xt_check_match+0x314/0x8a0 net/netfilter/x_tables.c:523 check_match net/ipv4/netfilter/ip_tables.c:472 [inline] find_check_match net/ipv4/netfilter/ip_tables.c:488 [inline] find_check_entry net/ipv4/netfilter/ip_tables.c:538 [inline] translate_table+0xf60/0x17fc net/ipv4/netfilter/ip_tables.c:717 do_replace net/ipv4/netfilter/ip_tables.c:1138 [inline] do_ipt_set_ctl+0xa10/0xe00 net/ipv4/netfilter/ip_tables.c:1636 nf_setsockopt+0x270/0x290 net/netfilter/nf_sockopt.c:101 ip_setsockopt+0x1d0c/0x2978 net/ipv4/ip_sockglue.c:1442 tcp_setsockopt+0x1d4/0x1bf4 net/ipv4/tcp.c:3713 sock_common_setsockopt+0xb0/0xcc net/core/sock.c:3446 smc_setsockopt+0x188/0xbc8 net/smc/af_smc.c:2466 __sys_setsockopt+0x2f8/0x4b0 net/socket.c:2203 __do_sys_setsockopt net/socket.c:2214 [inline] __se_sys_setsockopt net/socket.c:2211 [inline] __arm64_sys_setsockopt+0xb8/0xd4 net/socket.c:2211 __invoke_syscall arch/arm64/kernel/syscall.c:38 [inline] invoke_syscall+0x98/0x2b8 arch/arm64/kernel/syscall.c:52 el0_svc_common+0x138/0x258 arch/arm64/kernel/syscall.c:142 do_el0_svc+0x58/0x14c arch/arm64/kernel/syscall.c:181 el0_svc+0x78/0x1e0 arch/arm64/kernel/entry-common.c:608 el0t_64_sync_handler+0xcc/0xe4 arch/arm64/kernel/entry-common.c:626 el0t_64_sync+0x1a0/0x1a4 arch/arm64/kernel/entry.S:584 xt_cgroup: invalid path, errno=-2