From: syzbot <syzbot+d2adb332fe371b0595e3@syzkaller.appspotmail.com>
To: eadavis@qq.com, linux-kernel@vger.kernel.org,
syzkaller-bugs@googlegroups.com
Subject: Re: [syzbot] [bpf?] WARNING: locking bug in bpf_map_put
Date: Fri, 01 Nov 2024 23:16:02 -0700 [thread overview]
Message-ID: <6725c3a2.050a0220.529b6.025c.GAE@google.com> (raw)
In-Reply-To: <tencent_C34B2C1BD325BFBAC0BB5C339C9EB01B4008@qq.com>
Hello,
syzbot has tested the proposed patch but the reproducer is still triggering an issue:
WARNING: locking bug in radix_tree_node_alloc
=============================
[ BUG: Invalid wait context ]
6.12.0-rc5-syzkaller-00299-g11066801dd4b-dirty #0 Not tainted
-----------------------------
syz.0.15/6617 is trying to lock:
ffff8880b8643cc0 (&c->lock){-.-.}-{3:3}, at: local_lock_acquire include/linux/local_lock_internal.h:29 [inline]
ffff8880b8643cc0 (&c->lock){-.-.}-{3:3}, at: ___slab_alloc+0x265/0x14b0 mm/slub.c:3695
other info that might help us debug this:
context-{5:5}
2 locks held by syz.0.15/6617:
#0: ffff8880b863d678 (lock){+.+.}-{3:3}, at: local_lock_acquire include/linux/local_lock_internal.h:29 [inline]
#0: ffff8880b863d678 (lock){+.+.}-{3:3}, at: __radix_tree_preload+0x80/0x860 lib/radix-tree.c:334
#1: ffffffff8e9b57d8 (map_idr_lock){+...}-{2:2}, at: bpf_map_alloc_id+0x21/0xe0 kernel/bpf/syscall.c:355
stack backtrace:
CPU: 0 UID: 0 PID: 6617 Comm: syz.0.15 Not tainted 6.12.0-rc5-syzkaller-00299-g11066801dd4b-dirty #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 09/13/2024
Call Trace:
<TASK>
__dump_stack lib/dump_stack.c:94 [inline]
dump_stack_lvl+0x241/0x360 lib/dump_stack.c:120
print_lock_invalid_wait_context kernel/locking/lockdep.c:4802 [inline]
check_wait_context kernel/locking/lockdep.c:4874 [inline]
__lock_acquire+0x15a8/0x2100 kernel/locking/lockdep.c:5152
lock_acquire+0x1ed/0x550 kernel/locking/lockdep.c:5825
local_lock_acquire include/linux/local_lock_internal.h:29 [inline]
___slab_alloc+0x27e/0x14b0 mm/slub.c:3695
__slab_alloc+0x58/0xa0 mm/slub.c:3908
__slab_alloc_node mm/slub.c:3961 [inline]
slab_alloc_node mm/slub.c:4122 [inline]
kmem_cache_alloc_noprof+0x1c1/0x2a0 mm/slub.c:4141
radix_tree_node_alloc+0x8b/0x3c0 lib/radix-tree.c:276
idr_get_free+0x296/0xab0 lib/radix-tree.c:1506
idr_alloc_u32+0x195/0x330 lib/idr.c:46
idr_alloc_cyclic+0x106/0x300 lib/idr.c:125
bpf_map_alloc_id+0x40/0xe0 kernel/bpf/syscall.c:356
map_create+0xdc3/0x11c0 kernel/bpf/syscall.c:1398
__sys_bpf+0x6c8/0x810 kernel/bpf/syscall.c:5661
__do_sys_bpf kernel/bpf/syscall.c:5786 [inline]
__se_sys_bpf kernel/bpf/syscall.c:5784 [inline]
__x64_sys_bpf+0x7c/0x90 kernel/bpf/syscall.c:5784
do_syscall_x64 arch/x86/entry/common.c:52 [inline]
do_syscall_64+0xf3/0x230 arch/x86/entry/common.c:83
entry_SYSCALL_64_after_hwframe+0x77/0x7f
RIP: 0033:0x7fe23117e719
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 a8 ff ff ff f7 d8 64 89 01 48
RSP: 002b:00007fe231ee3038 EFLAGS: 00000246 ORIG_RAX: 0000000000000141
RAX: ffffffffffffffda RBX: 00007fe231335f80 RCX: 00007fe23117e719
RDX: 0000000000000048 RSI: 00000000200004c0 RDI: 0000000000000000
RBP: 00007fe2311f132e R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000
R13: 0000000000000001 R14: 00007fe231335f80 R15: 00007fff2658b528
</TASK>
Tested on:
commit: 11066801 Merge tag 'linux_kselftest-fixes-6.12-rc6' of..
git tree: upstream
console output: https://syzkaller.appspot.com/x/log.txt?x=143a5630580000
kernel config: https://syzkaller.appspot.com/x/.config?x=a6b0d046ffd0e9c1
dashboard link: https://syzkaller.appspot.com/bug?extid=d2adb332fe371b0595e3
compiler: Debian clang version 15.0.6, GNU ld (GNU Binutils for Debian) 2.40
patch: https://syzkaller.appspot.com/x/patch.diff?x=12ce3340580000
next prev parent reply other threads:[~2024-11-02 6:16 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-11-01 18:28 [syzbot] [bpf?] WARNING: locking bug in bpf_map_put syzbot
2024-11-02 1:57 ` Edward Adam Davis
2024-11-02 2:18 ` syzbot
2024-11-02 3:59 ` Edward Adam Davis
2024-11-02 6:16 ` syzbot [this message]
2024-11-02 8:23 ` Edward Adam Davis
2024-11-02 8:46 ` syzbot
2024-11-04 2:29 ` syzbot
2024-11-04 16:28 ` Sebastian Andrzej Siewior
2024-11-05 2:49 ` Hou Tao
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=6725c3a2.050a0220.529b6.025c.GAE@google.com \
--to=syzbot+d2adb332fe371b0595e3@syzkaller.appspotmail.com \
--cc=eadavis@qq.com \
--cc=linux-kernel@vger.kernel.org \
--cc=syzkaller-bugs@googlegroups.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox