================================================================== BUG: KCSAN: data-race in __bpf_get_stackid / bcmp write to 0xffff88810c959d60 of 88 bytes by task 5967 on cpu 1: __bpf_get_stackid+0x761/0x800 kernel/bpf/stackmap.c:288 ____bpf_get_stackid kernel/bpf/stackmap.c:324 [inline] bpf_get_stackid+0xe9/0x120 kernel/bpf/stackmap.c:300 ____bpf_get_stackid_raw_tp kernel/trace/bpf_trace.c:1628 [inline] bpf_get_stackid_raw_tp+0xf6/0x120 kernel/trace/bpf_trace.c:1617 bpf_prog_53f0063d4d7f65ce+0x2a/0x32 bpf_dispatcher_nop_func include/linux/bpf.h:1350 [inline] __bpf_prog_run include/linux/filter.h:721 [inline] bpf_prog_run include/linux/filter.h:728 [inline] __bpf_trace_run kernel/trace/bpf_trace.c:2075 [inline] bpf_trace_run2+0x107/0x1c0 kernel/trace/bpf_trace.c:2116 __do_trace_kfree include/trace/events/kmem.h:97 [inline] trace_kfree include/trace/events/kmem.h:97 [inline] kfree+0x351/0x400 mm/slub.c:6813 bpf_check+0xc215/0xd9d0 kernel/bpf/verifier.c:24781 bpf_prog_load+0xf6e/0x1100 kernel/bpf/syscall.c:3077 __sys_bpf+0x469/0x7c0 kernel/bpf/syscall.c:6149 __do_sys_bpf kernel/bpf/syscall.c:6259 [inline] __se_sys_bpf kernel/bpf/syscall.c:6257 [inline] __x64_sys_bpf+0x41/0x50 kernel/bpf/syscall.c:6257 x64_sys_call+0x2aee/0x3000 arch/x86/include/generated/asm/syscalls_64.h:322 do_syscall_x64 arch/x86/entry/syscall_64.c:63 [inline] do_syscall_64+0xd2/0x200 arch/x86/entry/syscall_64.c:94 entry_SYSCALL_64_after_hwframe+0x77/0x7f read to 0xffff88810c959d80 of 8 bytes by task 5989 on cpu 0: memcmp lib/string.c:683 [inline] bcmp+0x23/0x90 lib/string.c:715 memcmp include/linux/fortify-string.h:727 [inline] __bpf_get_stackid+0x371/0x800 kernel/bpf/stackmap.c:279 ____bpf_get_stackid kernel/bpf/stackmap.c:324 [inline] bpf_get_stackid+0xe9/0x120 kernel/bpf/stackmap.c:300 ____bpf_get_stackid_raw_tp kernel/trace/bpf_trace.c:1628 [inline] bpf_get_stackid_raw_tp+0xf6/0x120 kernel/trace/bpf_trace.c:1617 bpf_prog_53f0063d4d7f65ce+0x2a/0x32 bpf_dispatcher_nop_func include/linux/bpf.h:1350 [inline] __bpf_prog_run include/linux/filter.h:721 [inline] bpf_prog_run include/linux/filter.h:728 [inline] __bpf_trace_run kernel/trace/bpf_trace.c:2075 [inline] bpf_trace_run2+0x107/0x1c0 kernel/trace/bpf_trace.c:2116 __do_trace_kfree include/trace/events/kmem.h:97 [inline] trace_kfree include/trace/events/kmem.h:97 [inline] kfree+0x351/0x400 mm/slub.c:6813 hash_ip4_ahash_destroy+0x1b7/0x220 net/netfilter/ipset/ip_set_hash_gen.h:441 hash_ip4_destroy+0x48/0x170 net/netfilter/ipset/ip_set_hash_gen.h:455 _destroy_all_sets+0x195/0x220 net/netfilter/ipset/ip_set_core.c:1220 ip_set_destroy+0x2ae/0x3e0 net/netfilter/ipset/ip_set_core.c:1259 nfnetlink_rcv_msg+0x4c6/0x590 net/netfilter/nfnetlink.c:302 netlink_rcv_skb+0x123/0x220 net/netlink/af_netlink.c:2552 nfnetlink_rcv+0x167/0x16c0 net/netfilter/nfnetlink.c:669 netlink_unicast_kernel net/netlink/af_netlink.c:1320 [inline] netlink_unicast+0x5c0/0x690 net/netlink/af_netlink.c:1346 netlink_sendmsg+0x58b/0x6b0 net/netlink/af_netlink.c:1896 sock_sendmsg_nosec net/socket.c:727 [inline] __sock_sendmsg+0x145/0x180 net/socket.c:742 ____sys_sendmsg+0x31e/0x4e0 net/socket.c:2630 ___sys_sendmsg+0x17b/0x1d0 net/socket.c:2684 __sys_sendmsg net/socket.c:2716 [inline] __do_sys_sendmsg net/socket.c:2721 [inline] __se_sys_sendmsg net/socket.c:2719 [inline] __x64_sys_sendmsg+0xd4/0x160 net/socket.c:2719 x64_sys_call+0x191e/0x3000 arch/x86/include/generated/asm/syscalls_64.h:47 do_syscall_x64 arch/x86/entry/syscall_64.c:63 [inline] do_syscall_64+0xd2/0x200 arch/x86/entry/syscall_64.c:94 entry_SYSCALL_64_after_hwframe+0x77/0x7f value changed: 0xffffffff84926b27 -> 0xffffffff8163d6a5 Reported by Kernel Concurrency Sanitizer on: CPU: 0 UID: 0 PID: 5989 Comm: syz.0.892 Not tainted syzkaller #0 PREEMPT(voluntary) Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 10/02/2025 ================================================================== syz.0.892 (5989) used greatest stack depth: 9352 bytes left