syzbot


WARNING in tree_insert_offset

Status: upstream: reported C repro on 2022/12/08 15:35
Subsystems: btrfs
[Documentation on labels]
Reported-by: syzbot+1630f033e391da47207d@syzkaller.appspotmail.com
First crash: 497d, last: 413d
Fix bisection: failed (error log, bisect log)
  

Sample crash report:
BTRFS info (device loop5): clearing 2 ro feature flag
BTRFS info (device loop5): creating free space tree
BTRFS info (device loop5): setting 1 ro feature flag
BTRFS info (device loop5): setting 2 ro feature flag
BTRFS warning (device <unknown>): duplicate device /dev/loop4 devid 1 generation 8 scanned by syz-executor211 (8196)
WARNING: CPU: 1 PID: 8215 at fs/btrfs/free-space-cache.c:1493 tree_insert_offset+0x127/0x270 fs/btrfs/free-space-cache.c:1493
Kernel panic - not syncing: panic_on_warn set ...

CPU: 1 PID: 8215 Comm: btrfs-ino-cache Not tainted 4.19.211-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 10/26/2022
Call Trace:
 __dump_stack lib/dump_stack.c:77 [inline]
 dump_stack+0x1fc/0x2ef lib/dump_stack.c:118
 panic+0x26a/0x50e kernel/panic.c:186
BTRFS warning (device <unknown>): duplicate device /dev/loop2 devid 1 generation 8 scanned by syz-executor211 (8197)
 __warn.cold+0x20/0x5a kernel/panic.c:541
 report_bug+0x262/0x2b0 lib/bug.c:183
 fixup_bug arch/x86/kernel/traps.c:178 [inline]
 fixup_bug arch/x86/kernel/traps.c:173 [inline]
 do_error_trap+0x1d7/0x310 arch/x86/kernel/traps.c:296
 invalid_op+0x14/0x20 arch/x86/entry/entry_64.S:1038
RIP: 0010:tree_insert_offset+0x127/0x270 fs/btrfs/free-space-cache.c:1493
Code: 89 ef e8 5c c7 6c fe 4c 39 e5 0f 86 50 ff ff ff e8 3e c6 6c fe 48 8d 6b 10 eb 9f e8 33 c6 6c fe 48 85 ed 75 eb e8 29 c6 6c fe <0f> 0b 41 bc ef ff ff ff e9 a0 00 00 00 e8 17 c6 6c fe e8 12 c6 6c
RSP: 0018:ffff8880aec07c78 EFLAGS: 00010293
RAX: ffff888095362000 RBX: ffff88809decaea0 RCX: ffffffff82f5bebb
RDX: 0000000000000000 RSI: ffffffff82f5bf47 RDI: 0000000000000005
RBP: 0000000000000000 R08: 0000000000000001 R09: 0000000000000000
R10: 0000000000000005 R11: 0000000000000000 R12: 0000000000000102
R13: dffffc0000000000 R14: 0000000000000000 R15: ffff88809decae38
 link_free_space fs/btrfs/free-space-cache.c:1651 [inline]
 __btrfs_add_free_space+0x1a8/0xe40 fs/btrfs/free-space-cache.c:2382
 btrfs_unpin_free_ino+0x28e/0x360 fs/btrfs/inode-map.c:281
 caching_kthread+0x82f/0x970 fs/btrfs/inode-map.c:128
 kthread+0x33f/0x460 kernel/kthread.c:259
 ret_from_fork+0x24/0x30 arch/x86/entry/entry_64.S:415
Kernel Offset: disabled
Rebooting in 86400 seconds..

Crashes (6):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2022/12/13 04:10 linux-4.19.y 3f8a27f9e27b 67be1ae7 .config console log report syz C [disk image] [vmlinux] [mounted in repro] ci2-linux-4-19 WARNING in tree_insert_offset
2023/03/02 16:53 linux-4.19.y 3f8a27f9e27b f8902b57 .config console log report info [disk image] [vmlinux] ci2-linux-4-19 WARNING in tree_insert_offset
2023/02/13 16:02 linux-4.19.y 3f8a27f9e27b 957959cb .config console log report info [disk image] [vmlinux] ci2-linux-4-19 WARNING in tree_insert_offset
2023/02/03 08:42 linux-4.19.y 3f8a27f9e27b 33fc5c09 .config console log report info [disk image] [vmlinux] ci2-linux-4-19 WARNING in tree_insert_offset
2022/12/13 03:33 linux-4.19.y 3f8a27f9e27b 67be1ae7 .config console log report info [disk image] [vmlinux] ci2-linux-4-19 WARNING in tree_insert_offset
2022/12/08 15:34 linux-4.19.y 3f8a27f9e27b d88f3abb .config console log report info [disk image] [vmlinux] ci2-linux-4-19 WARNING in tree_insert_offset
* Struck through repros no longer work on HEAD.