syzbot


WARNING: bad unlock balance in traverse

Status: upstream: reported C repro on 2025/02/26 21:31
Subsystems: fs
[Documentation on labels]
Reported-by: syzbot+0b16dd9bd622c40b2bbe@syzkaller.appspotmail.com
First crash: 34d, last: 1d00h
Discussions (1)
Title Replies (including bot) Last reply
[syzbot] [fs?] WARNING: bad unlock balance in traverse 0 (2) 2025/02/26 21:53

Sample crash report:
RBP: 0000000000000001 R08: 00007ffd17221997 R09: 00007fd111db0032
R10: 00000000000005af R11: 0000000000000246 R12: 00007fd111db3618
R13: 00007ffd17221dd8 R14: 0000000000000001 R15: 0000000000000001
 </TASK>
=====================================
WARNING: bad unlock balance detected!
6.14.0-rc4-syzkaller-00052-gac9c34d1e45a #0 Not tainted
-------------------------------------
syz-executor218/5831 is trying to release lock (event_mutex) at:
[<ffffffff82399e2d>] traverse.part.0.constprop.0+0x2bd/0x640 fs/seq_file.c:131
but there are no more locks to release!

other info that might help us debug this:
1 lock held by syz-executor218/5831:
 #0: ffff88802f5d5790 (&p->lock){+.+.}-{4:4}, at: seq_read_iter+0xd8/0x12b0 fs/seq_file.c:182

stack backtrace:
CPU: 1 UID: 0 PID: 5831 Comm: syz-executor218 Not tainted 6.14.0-rc4-syzkaller-00052-gac9c34d1e45a #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 02/12/2025
Call Trace:
 <TASK>
 __dump_stack lib/dump_stack.c:94 [inline]
 dump_stack_lvl+0x116/0x1f0 lib/dump_stack.c:120
 print_unlock_imbalance_bug kernel/locking/lockdep.c:5289 [inline]
 print_unlock_imbalance_bug+0x1aa/0x1f0 kernel/locking/lockdep.c:5263
 __lock_release kernel/locking/lockdep.c:5528 [inline]
 lock_release+0x525/0x6f0 kernel/locking/lockdep.c:5872
 __mutex_unlock_slowpath+0xa3/0x6a0 kernel/locking/mutex.c:891
 traverse.part.0.constprop.0+0x2bd/0x640 fs/seq_file.c:131
 traverse fs/seq_file.c:98 [inline]
 seq_read_iter+0x934/0x12b0 fs/seq_file.c:195
 seq_read+0x39f/0x4e0 fs/seq_file.c:162
 vfs_read+0x1df/0xbf0 fs/read_write.c:563
 ksys_pread64 fs/read_write.c:756 [inline]
 __do_sys_pread64 fs/read_write.c:764 [inline]
 __se_sys_pread64 fs/read_write.c:761 [inline]
 __x64_sys_pread64+0x1f6/0x250 fs/read_write.c:761
 do_syscall_x64 arch/x86/entry/common.c:52 [inline]
 do_syscall_64+0xcd/0x250 arch/x86/entry/common.c:83
 entry_SYSCALL_64_after_hwframe+0x77/0x7f
RIP: 0033:0x7fd111d48329
Code: 48 83 c4 28 c3 e8 17 1a 00 00 0f 1f 80 00 00 00 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 b8 ff ff ff f7 d8 64 89 01 48
RSP: 002b:00007ffd17221bf8 EFLAGS: 00000246 ORIG_RAX: 0000000000000011

Crashes (8):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2025/02/26 21:52 upstream ac9c34d1e45a 6a8fcbc4 .config console log report syz / log C [disk image] [vmlinux] [kernel image] ci-qemu-gce-upstream-auto WARNING: bad unlock balance in traverse
2025/02/26 21:30 upstream ac9c34d1e45a 6a8fcbc4 .config console log report syz / log [disk image] [vmlinux] [kernel image] ci-qemu-gce-upstream-auto WARNING: bad unlock balance in traverse
2025/02/26 21:16 upstream ac9c34d1e45a 6a8fcbc4 .config console log report info [disk image] [vmlinux] [kernel image] ci-qemu-gce-upstream-auto WARNING: bad unlock balance in traverse
2025/02/26 21:11 upstream ac9c34d1e45a 6a8fcbc4 .config console log report info [disk image] [vmlinux] [kernel image] ci-qemu-gce-upstream-auto WARNING: bad unlock balance in traverse
2025/01/29 14:17 upstream 805ba04cb7cc 08fa8553 .config console log report info [disk image] [vmlinux] [kernel image] ci-qemu-gce-upstream-auto WARNING: bad unlock balance in traverse
2025/01/25 02:25 upstream ae8b53aac327 9fbd772e .config console log report info [disk image] [vmlinux] [kernel image] ci-qemu-gce-upstream-auto WARNING: bad unlock balance in traverse
2025/01/24 19:24 upstream 68732c0bf97c 1293872d .config console log report info [disk image] [vmlinux] [kernel image] ci-qemu-gce-upstream-auto WARNING: bad unlock balance in traverse
2025/01/24 19:24 upstream 68732c0bf97c 1293872d .config console log report info [disk image] [vmlinux] [kernel image] ci-qemu-gce-upstream-auto WARNING: bad unlock balance in traverse
* Struck through repros no longer work on HEAD.