Hello,
syzbot found the following issue on:
HEAD commit: f6e38ae624cf Linux 6.1.158
git tree: linux-6.1.y
console output:
https://syzkaller.appspot.com/x/log.txt?x=172fd60a580000
kernel config:
https://syzkaller.appspot.com/x/.config?x=7eb38bd5021fec61
dashboard link:
https://syzkaller.appspot.com/bug?extid=8684f2927c0123fe0326
compiler: Debian clang version 20.1.8 (++20250708063551+0c9f909b7976-1~exp1~20250708183702.136), Debian LLD 20.1.8
syz repro:
https://syzkaller.appspot.com/x/repro.syz?x=12c78212580000
C reproducer:
https://syzkaller.appspot.com/x/repro.c?x=116d6b42580000
Downloadable assets:
disk image:
https://storage.googleapis.com/syzbot-assets/0d8305ca1c94/disk-f6e38ae6.raw.xz
vmlinux:
https://storage.googleapis.com/syzbot-assets/8bc85383c07b/vmlinux-f6e38ae6.xz
kernel image:
https://storage.googleapis.com/syzbot-assets/d337081bce56/bzImage-f6e38ae6.xz
IMPORTANT: if you fix the issue, please add the following tag to the commit:
Reported-by:
syzbot+8684f2...@syzkaller.appspotmail.com
============================================
WARNING: possible recursive locking detected
syzkaller #0 Not tainted
--------------------------------------------
syz.3.27/4534 is trying to acquire lock:
ffffe8ffffd45f28 (&loc_l->lock){-...}-{2:2}, at: bpf_common_lru_push_free kernel/bpf/bpf_lru_list.c:522 [inline]
ffffe8ffffd45f28 (&loc_l->lock){-...}-{2:2}, at: bpf_lru_push_free+0x32e/0xb90 kernel/bpf/bpf_lru_list.c:561
but task is already holding lock:
ffffe8ffffd45f28 (&loc_l->lock){-...}-{2:2}, at: bpf_common_lru_pop_free kernel/bpf/bpf_lru_list.c:448 [inline]
ffffe8ffffd45f28 (&loc_l->lock){-...}-{2:2}, at: bpf_lru_pop_free+0x198/0x1c60 kernel/bpf/bpf_lru_list.c:504
other info that might help us debug this:
Possible unsafe locking scenario:
CPU0
----
lock(&loc_l->lock);
lock(&loc_l->lock);
*** DEADLOCK ***
May be due to missing lock nesting notation
3 locks held by syz.3.27/4534:
#0: ffffffff8cb2aca0 (rcu_read_lock){....}-{1:2}
, at: rcu_lock_acquire include/linux/rcupdate.h:350 [inline]
, at: rcu_read_lock include/linux/rcupdate.h:791 [inline]
, at: bpf_percpu_hash_update+0x27/0x200 kernel/bpf/hashtab.c:2334
#1: ffffe8ffffd45f28 (&loc_l->lock){-...}-{2:2}, at: bpf_common_lru_pop_free kernel/bpf/bpf_lru_list.c:448 [inline]
#1: ffffe8ffffd45f28 (&loc_l->lock){-...}-{2:2}, at: bpf_lru_pop_free+0x198/0x1c60 kernel/bpf/bpf_lru_list.c:504
#2: ffffffff8cb2aca0 (rcu_read_lock){....}-{1:2}, at: rcu_lock_acquire include/linux/rcupdate.h:350 [inline]
#2: ffffffff8cb2aca0 (rcu_read_lock){....}-{1:2}, at: rcu_read_lock include/linux/rcupdate.h:791 [inline]
#2: ffffffff8cb2aca0 (rcu_read_lock){....}-{1:2}, at: __bpf_trace_run kernel/trace/bpf_trace.c:2284 [inline]
#2: ffffffff8cb2aca0 (rcu_read_lock){....}-{1:2}, at: bpf_trace_run2+0xda/0x3b0 kernel/trace/bpf_trace.c:2324
stack backtrace:
CPU: 1 PID: 4534 Comm: syz.3.27 Not tainted syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 10/02/2025
Call Trace:
<TASK>
dump_stack_lvl+0x168/0x22e lib/dump_stack.c:106
__lock_acquire+0x122f/0x7c50 kernel/locking/lockdep.c:-1
lock_acquire+0x1b4/0x490 kernel/locking/lockdep.c:5662
__raw_spin_lock_irqsave include/linux/spinlock_api_smp.h:110 [inline]
_raw_spin_lock_irqsave+0xa4/0xf0 kernel/locking/spinlock.c:162
bpf_common_lru_push_free kernel/bpf/bpf_lru_list.c:522 [inline]
bpf_lru_push_free+0x32e/0xb90 kernel/bpf/bpf_lru_list.c:561
htab_lru_push_free kernel/bpf/hashtab.c:1175 [inline]
htab_lru_map_delete_elem+0x631/0x760 kernel/bpf/hashtab.c:1451
bpf_prog_2c29ac5cdc6b1842+0x3a/0x3e
bpf_dispatcher_nop_func include/linux/bpf.h:1012 [inline]
__bpf_prog_run include/linux/filter.h:603 [inline]
bpf_prog_run include/linux/filter.h:610 [inline]
__bpf_trace_run kernel/trace/bpf_trace.c:2285 [inline]
bpf_trace_run2+0x1cd/0x3b0 kernel/trace/bpf_trace.c:2324
__traceiter_contention_end+0x74/0xa0 include/trace/events/lock.h:122
trace_contention_end+0x13f/0x190 include/trace/events/lock.h:122
__pv_queued_spin_lock_slowpath+0x7e8/0x9c0 kernel/locking/qspinlock.c:560
pv_queued_spin_lock_slowpath arch/x86/include/asm/paravirt.h:591 [inline]
queued_spin_lock_slowpath+0x43/0x50 arch/x86/include/asm/qspinlock.h:51
queued_spin_lock include/asm-generic/qspinlock.h:114 [inline]
do_raw_spin_lock+0x217/0x280 kernel/locking/spinlock_debug.c:115
__raw_spin_lock_irqsave include/linux/spinlock_api_smp.h:111 [inline]
_raw_spin_lock_irqsave+0xb0/0xf0 kernel/locking/spinlock.c:162
bpf_common_lru_pop_free kernel/bpf/bpf_lru_list.c:448 [inline]
bpf_lru_pop_free+0x198/0x1c60 kernel/bpf/bpf_lru_list.c:504
prealloc_lru_pop kernel/bpf/hashtab.c:296 [inline]
__htab_lru_percpu_map_update_elem+0x1ff/0x8c0 kernel/bpf/hashtab.c:1333
bpf_percpu_hash_update+0x115/0x200 kernel/bpf/hashtab.c:2336
bpf_map_update_value+0x310/0x670 kernel/bpf/syscall.c:202
generic_map_update_batch+0x569/0x850 kernel/bpf/syscall.c:1709
bpf_map_do_batch+0x466/0x600 kernel/bpf/syscall.c:-1
__sys_bpf+0x65f/0x6d0 kernel/bpf/syscall.c:-1
__do_sys_bpf kernel/bpf/syscall.c:5131 [inline]
__se_sys_bpf kernel/bpf/syscall.c:5129 [inline]
__x64_sys_bpf+0x78/0x90 kernel/bpf/syscall.c:5129
do_syscall_x64 arch/x86/entry/common.c:51 [inline]
do_syscall_64+0x4c/0xa0 arch/x86/entry/common.c:81
entry_SYSCALL_64_after_hwframe+0x68/0xd2
RIP: 0033:0x7f0a2678f6c9
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:00007f0a27553038 EFLAGS: 00000246 ORIG_RAX: 0000000000000141
RAX: ffffffffffffffda RBX: 00007f0a269e5fa0 RCX: 00007f0a2678f6c9
RDX: 0000000000000038 RSI: 0000200000000200 RDI: 000000000000001a
RBP: 00007f0a26811f91 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000
R13: 00007f0a269e6038 R14: 00007f0a269e5fa0 R15: 00007fff67008378
</TASK>
---
This report is generated by a bot. It may contain errors.
See
https://goo.gl/tpsmEJ for more information about syzbot.
syzbot engineers can be reached at
syzk...@googlegroups.com.
syzbot will keep track of this issue. See:
https://goo.gl/tpsmEJ#status for how to communicate with syzbot.
If the report is already addressed, let syzbot know by replying with:
#syz fix: exact-commit-title
If you want syzbot to run the reproducer, reply with:
#syz test: git://repo/address.git branch-or-commit-hash
If you attach or paste a git patch, syzbot will apply it before testing.
If you want to overwrite report's subsystems, reply with:
#syz set subsystems: new-subsystem
(See the list of subsystem names on the web dashboard)
If the report is a duplicate of another one, reply with:
#syz dup: exact-subject-of-another-report
If you want to undo deduplication, reply with:
#syz undup