syzbot


WARNING: bad unlock balance in l2cap_recv_frame (2)

Status: upstream: reported C repro on 2024/09/08 08:19
Bug presence: origin:lts-only
[Documentation on labels]
Reported-by: syzbot+5bfea7abc11dc8a59559@syzkaller.appspotmail.com
First crash: 52d, last: 1h24m
Bug presence (2)
Date Name Commit Repro Result
2024/10/11 linux-5.15.y (ToT) 3a5928702e71 C [report] WARNING: bad unlock balance in l2cap_recv_frame
2024/10/11 upstream (ToT) 1d227fcc7222 C Didn't crash
Similar bugs (3)
Kernel Title Repro Cause bisect Fix bisect Count Last Reported Patched Status
linux-6.1 WARNING: bad unlock balance in l2cap_recv_frame origin:lts-only C done 22 527d 559d 3/3 fixed on 2023/06/26 14:47
upstream WARNING: bad unlock balance in l2cap_recv_frame bluetooth 75 552d 564d 22/28 fixed on 2023/06/08 14:41
linux-5.15 WARNING: bad unlock balance in l2cap_recv_frame origin:lts-only C done 5 525d 549d 3/3 fixed on 2023/06/26 14:47
Fix bisection attempts (1)
Created Duration User Patch Repo Result
2024/10/15 08:35 0m fix candidate upstream error job log

Sample crash report:
=====================================
WARNING: bad unlock balance detected!
5.15.167-syzkaller #0 Not tainted
-------------------------------------
kworker/u5:2/3567 is trying to release lock (&chan->lock) at:
[<ffffffff895b621f>] l2cap_chan_unlock include/net/bluetooth/l2cap.h:860 [inline]
[<ffffffff895b621f>] l2cap_conless_channel net/bluetooth/l2cap_core.c:7770 [inline]
[<ffffffff895b621f>] l2cap_recv_frame+0x136f/0x8ae0 net/bluetooth/l2cap_core.c:7823
but there are no more locks to release!

other info that might help us debug this:
2 locks held by kworker/u5:2/3567:
 #0: ffff888024af0938 ((wq_completion)hci0#2){+.+.}-{0:0}, at: process_one_work+0x78a/0x10c0 kernel/workqueue.c:2283
 #1: ffffc900020f7d20 ((work_completion)(&hdev->rx_work)){+.+.}-{0:0}, at: process_one_work+0x7d0/0x10c0 kernel/workqueue.c:2285

stack backtrace:
CPU: 0 PID: 3567 Comm: kworker/u5:2 Not tainted 5.15.167-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 09/13/2024
Workqueue: hci0 hci_rx_work
Call Trace:
 <TASK>
 __dump_stack lib/dump_stack.c:88 [inline]
 dump_stack_lvl+0x1e3/0x2d0 lib/dump_stack.c:106
 print_unlock_imbalance_bug+0x248/0x2b0 kernel/locking/lockdep.c:5065
 __lock_release kernel/locking/lockdep.c:5302 [inline]
 lock_release+0x596/0x9a0 kernel/locking/lockdep.c:5643
 __mutex_unlock_slowpath+0xde/0x750 kernel/locking/mutex.c:851
 l2cap_chan_unlock include/net/bluetooth/l2cap.h:860 [inline]
 l2cap_conless_channel net/bluetooth/l2cap_core.c:7770 [inline]
 l2cap_recv_frame+0x136f/0x8ae0 net/bluetooth/l2cap_core.c:7823
 hci_acldata_packet net/bluetooth/hci_core.c:4969 [inline]
 hci_rx_work+0x48f/0x990 net/bluetooth/hci_core.c:5160
 process_one_work+0x8a1/0x10c0 kernel/workqueue.c:2310
 worker_thread+0xaca/0x1280 kernel/workqueue.c:2457
 kthread+0x3f6/0x4f0 kernel/kthread.c:334
 ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:287

Crashes (148):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2024/10/08 22:10 linux-5.15.y 3a5928702e71 402f1df0 .config console log report syz / log C [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan WARNING: bad unlock balance in l2cap_recv_frame
2024/10/08 20:23 linux-5.15.y 3a5928702e71 402f1df0 .config console log report syz / log C [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan WARNING: bad unlock balance in l2cap_recv_frame
2024/10/05 03:41 linux-5.15.y 3a5928702e71 d7906eff .config console log report syz / log C [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan WARNING: bad unlock balance in l2cap_recv_frame
2024/10/05 03:16 linux-5.15.y 3a5928702e71 d7906eff .config console log report syz / log C [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan WARNING: bad unlock balance in l2cap_recv_frame
2024/10/30 22:09 linux-5.15.y 74cdd62cb470 fb888278 .config console log report syz / log C [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan-arm64 WARNING: bad unlock balance in l2cap_recv_frame
2024/10/30 06:10 linux-5.15.y 74cdd62cb470 66aeb999 .config console log report syz / log C [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan-arm64 WARNING: bad unlock balance in l2cap_recv_frame
2024/10/21 01:23 linux-5.15.y 584a40a22cb9 cd6fc0a3 .config console log report syz / log C [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan-arm64 WARNING: bad unlock balance in l2cap_recv_frame
2024/10/09 05:48 linux-5.15.y 3a5928702e71 402f1df0 .config console log report syz / log C [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan-arm64 WARNING: bad unlock balance in l2cap_recv_frame
2024/10/07 21:02 linux-5.15.y 3a5928702e71 d7906eff .config console log report syz / log C [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan-arm64 WARNING: bad unlock balance in l2cap_recv_frame
2024/09/08 12:36 linux-5.15.y 14e468424d3e 9750182a .config console log report syz / log C [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan-arm64 WARNING: bad unlock balance in l2cap_recv_frame
2024/09/08 11:28 linux-5.15.y 14e468424d3e 9750182a .config console log report syz / log C [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan-arm64 WARNING: bad unlock balance in l2cap_recv_frame
2024/09/08 10:27 linux-5.15.y 14e468424d3e 9750182a .config console log report syz / log C [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan-arm64 WARNING: bad unlock balance in l2cap_recv_frame
2024/09/08 09:22 linux-5.15.y 14e468424d3e 9750182a .config console log report syz / log C [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan-arm64 WARNING: bad unlock balance in l2cap_recv_frame
2024/10/30 11:35 linux-5.15.y 74cdd62cb470 66aeb999 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan WARNING: bad unlock balance in l2cap_recv_frame
2024/10/28 01:06 linux-5.15.y 74cdd62cb470 65e8686b .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan WARNING: bad unlock balance in l2cap_recv_frame
2024/10/20 23:44 linux-5.15.y 584a40a22cb9 cd6fc0a3 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan WARNING: bad unlock balance in l2cap_recv_frame
2024/10/20 15:14 linux-5.15.y 584a40a22cb9 cd6fc0a3 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan WARNING: bad unlock balance in l2cap_recv_frame
2024/10/20 08:39 linux-5.15.y 584a40a22cb9 cd6fc0a3 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan WARNING: bad unlock balance in l2cap_recv_frame
2024/10/20 05:39 linux-5.15.y 584a40a22cb9 cd6fc0a3 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan WARNING: bad unlock balance in l2cap_recv_frame
2024/10/20 05:37 linux-5.15.y 584a40a22cb9 cd6fc0a3 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan WARNING: bad unlock balance in l2cap_recv_frame
2024/10/08 21:34 linux-5.15.y 3a5928702e71 402f1df0 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan WARNING: bad unlock balance in l2cap_recv_frame
2024/10/08 17:13 linux-5.15.y 3a5928702e71 402f1df0 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan WARNING: bad unlock balance in l2cap_recv_frame
2024/10/07 13:46 linux-5.15.y 3a5928702e71 d7906eff .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan WARNING: bad unlock balance in l2cap_recv_frame
2024/10/07 02:51 linux-5.15.y 3a5928702e71 d7906eff .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan WARNING: bad unlock balance in l2cap_recv_frame
2024/10/05 11:09 linux-5.15.y 3a5928702e71 d7906eff .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan WARNING: bad unlock balance in l2cap_recv_frame
2024/10/05 09:30 linux-5.15.y 3a5928702e71 d7906eff .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan WARNING: bad unlock balance in l2cap_recv_frame
2024/10/05 02:49 linux-5.15.y 3a5928702e71 d7906eff .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan WARNING: bad unlock balance in l2cap_recv_frame
2024/10/04 17:04 linux-5.15.y 3a5928702e71 d7906eff .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan WARNING: bad unlock balance in l2cap_recv_frame
2024/10/04 10:19 linux-5.15.y 3a5928702e71 d7906eff .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan WARNING: bad unlock balance in l2cap_recv_frame
2024/10/04 04:16 linux-5.15.y 3a5928702e71 d7906eff .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan WARNING: bad unlock balance in l2cap_recv_frame
2024/10/04 03:05 linux-5.15.y 3a5928702e71 d7906eff .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan WARNING: bad unlock balance in l2cap_recv_frame
2024/10/03 12:48 linux-5.15.y 3a5928702e71 a4c7fd36 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan WARNING: bad unlock balance in l2cap_recv_frame
2024/10/03 12:48 linux-5.15.y 3a5928702e71 a4c7fd36 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan WARNING: bad unlock balance in l2cap_recv_frame
2024/10/02 23:11 linux-5.15.y 3a5928702e71 02f9582a .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan WARNING: bad unlock balance in l2cap_recv_frame
2024/10/02 23:11 linux-5.15.y 3a5928702e71 02f9582a .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan WARNING: bad unlock balance in l2cap_recv_frame
2024/10/02 04:25 linux-5.15.y 3a5928702e71 ea2b66a6 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan WARNING: bad unlock balance in l2cap_recv_frame
2024/10/30 21:38 linux-5.15.y 74cdd62cb470 fb888278 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan-arm64 WARNING: bad unlock balance in l2cap_recv_frame
2024/10/30 05:06 linux-5.15.y 74cdd62cb470 66aeb999 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan-arm64 WARNING: bad unlock balance in l2cap_recv_frame
2024/10/29 12:14 linux-5.15.y 74cdd62cb470 66aeb999 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan-arm64 WARNING: bad unlock balance in l2cap_recv_frame
2024/10/29 12:14 linux-5.15.y 74cdd62cb470 66aeb999 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan-arm64 WARNING: bad unlock balance in l2cap_recv_frame
2024/10/27 20:34 linux-5.15.y 74cdd62cb470 65e8686b .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan-arm64 WARNING: bad unlock balance in l2cap_recv_frame
2024/10/21 00:44 linux-5.15.y 584a40a22cb9 cd6fc0a3 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan-arm64 WARNING: bad unlock balance in l2cap_recv_frame
2024/10/20 12:16 linux-5.15.y 584a40a22cb9 cd6fc0a3 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan-arm64 WARNING: bad unlock balance in l2cap_recv_frame
2024/10/20 07:03 linux-5.15.y 584a40a22cb9 cd6fc0a3 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan-arm64 WARNING: bad unlock balance in l2cap_recv_frame
2024/10/17 23:10 linux-5.15.y 584a40a22cb9 666f77ed .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan-arm64 WARNING: bad unlock balance in l2cap_recv_frame
2024/10/09 05:09 linux-5.15.y 3a5928702e71 402f1df0 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan-arm64 WARNING: bad unlock balance in l2cap_recv_frame
2024/10/08 18:47 linux-5.15.y 3a5928702e71 402f1df0 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan-arm64 WARNING: bad unlock balance in l2cap_recv_frame
2024/10/08 13:53 linux-5.15.y 3a5928702e71 402f1df0 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan-arm64 WARNING: bad unlock balance in l2cap_recv_frame
2024/10/08 02:17 linux-5.15.y 3a5928702e71 d7906eff .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan-arm64 WARNING: bad unlock balance in l2cap_recv_frame
2024/10/08 02:16 linux-5.15.y 3a5928702e71 d7906eff .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan-arm64 WARNING: bad unlock balance in l2cap_recv_frame
2024/10/07 20:33 linux-5.15.y 3a5928702e71 d7906eff .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan-arm64 WARNING: bad unlock balance in l2cap_recv_frame
2024/10/05 20:37 linux-5.15.y 3a5928702e71 d7906eff .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan-arm64 WARNING: bad unlock balance in l2cap_recv_frame
2024/10/05 09:26 linux-5.15.y 3a5928702e71 d7906eff .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan-arm64 WARNING: bad unlock balance in l2cap_recv_frame
2024/10/05 01:26 linux-5.15.y 3a5928702e71 d7906eff .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan-arm64 WARNING: bad unlock balance in l2cap_recv_frame
2024/10/04 18:29 linux-5.15.y 3a5928702e71 d7906eff .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan-arm64 WARNING: bad unlock balance in l2cap_recv_frame
2024/10/04 15:47 linux-5.15.y 3a5928702e71 d7906eff .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan-arm64 WARNING: bad unlock balance in l2cap_recv_frame
2024/10/04 15:14 linux-5.15.y 3a5928702e71 d7906eff .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan-arm64 WARNING: bad unlock balance in l2cap_recv_frame
2024/10/04 12:34 linux-5.15.y 3a5928702e71 d7906eff .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan-arm64 WARNING: bad unlock balance in l2cap_recv_frame
2024/10/04 00:43 linux-5.15.y 3a5928702e71 d7906eff .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan-arm64 WARNING: bad unlock balance in l2cap_recv_frame
2024/09/08 08:18 linux-5.15.y 14e468424d3e 9750182a .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan-arm64 WARNING: bad unlock balance in l2cap_recv_frame
* Struck through repros no longer work on HEAD.