bcachefs (loop0): bch2_get_scanned_nodes(): recovering u64s 11 type btree_ptr_v2 SPOS_MAX len 0 ver 0: seq c6c25c03258c59c5 written 16 min_key POS_MIN durability: 1 ptr: 0:27:0 gen 0 bcachefs (loop0): empty interior btree node at btree=extents level=1 u64s 5 type btree_ptr SPOS_MAX len 0 ver 0, fixing bcachefs (loop0): bch2_btree_repair_topology_recurse(): error ECHILD bcachefs (loop0): empty btree root extents done bcachefs (loop0): accounting_read... done bcachefs (loop0): alloc_read... done bcachefs (loop0): snapshots_read... done bcachefs (loop0): check_allocations... bcachefs (loop0): bucket 0:26 data type btree ptr gen 0 missing in alloc btree while marking u64s 11 type btree_ptr_v2 SPOS_MAX len 0 ver 0: seq ac62141f8dc7e261 written 24 min_key POS_MIN durability: 1 ptr: 0:26:0 gen 0, fixing bcachefs (loop0): bucket 0:38 data type btree ptr gen 0 missing in alloc btree while marking u64s 11 type btree_ptr_v2 SPOS_MAX len 0 ver 0: seq 7589ab5e0c11cc7a written 24 min_key POS_MIN durability: 1 ptr: 0:38:0 gen 0, fixing bcachefs (loop0): bucket 0:41 data type btree ptr gen 0 missing in alloc btree while marking u64s 11 type btree_ptr_v2 SPOS_MAX len 0 ver 0: seq 9aa2895aefce4bdf written 24 min_key POS_MIN durability: 1 ptr: 0:41:0 gen 0, fixing bcachefs (loop0): bucket 0:35 data type btree ptr gen 0 missing in alloc btree while marking u64s 11 type btree_ptr_v2 SPOS_MAX len 0 ver 0: seq c0bef60d07ceb940 written 16 min_key POS_MIN durability: 1 ptr: 0:35:0 gen 0, fixing bcachefs (loop0): bucket 0:28 data type btree ptr gen 0 missing in alloc btree while marking u64s 11 type btree_ptr_v2 SPOS_MAX len 0 ver 0: seq 28f61e078e70b95c written 16 min_key POS_MIN durability: 1 ptr: 0:28:0 gen 0, fixing bcachefs (loop0): bucket 0:29 data type btree ptr gen 0 missing in alloc btree while marking u64s 11 type btree_ptr_v2 SPOS_MAX len 0 ver 0: seq e81e1ed936acf3df written 32 min_key POS_MIN durability: 1 ptr: 0:29:0 gen 0, fixing bcachefs (loop0): bucket 0:1 gen 0 has wrong data_type: got free, should be sb, fixing bcachefs (loop0): bucket 0:1 gen 0 data type sb has wrong dirty_sectors: got 0, should be 256, fixing bcachefs (loop0): bucket 0:2 gen 0 has wrong data_type: got free, should be sb, fixing bcachefs (loop0): bucket 0:2 gen 0 data type sb has wrong dirty_sectors: got 0, should be 256, fixing bcachefs (loop0): bucket 0:3 gen 0 has wrong data_type: got free, should be sb, fixing bcachefs (loop0): bucket 0:3 gen 0 data type sb has wrong dirty_sectors: got 0, should be 256, fixing bcachefs (loop0): bucket 0:4 gen 0 has wrong data_type: got free, should be sb, fixing bcachefs (loop0): bucket 0:4 gen 0 data type sb has wrong dirty_sectors: got 0, should be 256, fixing bcachefs (loop0): bucket 0:5 gen 0 has wrong data_type: got free, should be sb, fixing bcachefs (loop0): bucket 0:5 gen 0 data type sb has wrong dirty_sectors: got 0, should be 256, fixing bcachefs (loop0): bucket 0:6 gen 0 has wrong data_type: got free, should be sb, fixing bcachefs (loop0): bucket 0:6 gen 0 data type sb has wrong dirty_sectors: got 0, should be 256, fixing bcachefs (loop0): bucket 0:7 gen 0 has wrong data_type: got free, should be sb, fixing bcachefs (loop0): bucket 0:7 gen 0 data type sb has wrong dirty_sectors: got 0, should be 256, fixing bcachefs (loop0): bucket 0:8 gen 0 has wrong data_type: got free, should be sb, fixing bcachefs (loop0): bucket 0:8 gen 0 data type sb has wrong dirty_sectors: got 0, should be 8, fixing bcachefs (loop0): bucket 0:9 gen 0 has wrong data_type: got free, should be journal, fixing bcachefs (loop0): bucket 0:9 gen 0 data type journal has wrong dirty_sectors: got 0, should be 256, fixing bcachefs (loop0): bucket 0:10 gen 0 has wrong data_type: got free, should be journal, fixing bcachefs (loop0): bucket 0:10 gen 0 data type journal has wrong dirty_sectors: got 0, should be 256, fixing bcachefs (loop0): bucket 0:11 gen 0 has wrong data_type: got free, should be journal, fixing Ratelimiting new instances of previous error bcachefs (loop0): bucket 0:11 gen 0 data type journal has wrong dirty_sectors: got 0, should be 256, fixing Ratelimiting new instances of previous error done bcachefs (loop0): going read-write bcachefs (loop0): journal_replay... ------------[ cut here ]------------ kernel BUG at fs/bcachefs/btree_update.c:375! Oops: invalid opcode: 0000 [#1] SMP KASAN NOPTI CPU: 0 UID: 0 PID: 5338 Comm: syz.0.0 Not tainted 6.16.0-rc5-syzkaller-00121-gbc9ff192a6c9 #0 PREEMPT(full) Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.16.3-debian-1.16.3-2~bpo12+1 04/01/2014 RIP: 0010:bch2_trans_update_by_path+0x1efb/0x1f30 fs/bcachefs/btree_update.c:375 Code: 80 e1 07 fe c1 38 c1 0f 8c 40 f7 ff ff 48 8b 7c 24 28 e8 48 17 fa fd e9 31 f7 ff ff e8 fe 93 96 fd 90 0f 0b e8 f6 93 96 fd 90 <0f> 0b e8 ee 93 96 fd 90 0f 0b e8 e6 93 96 fd 90 0f 0b e8 de 93 96 RSP: 0018:ffffc9000d64ea08 EFLAGS: 00010293 RAX: ffffffff8429a27a RBX: 0000000000008540 RCX: ffff888000b20000 RDX: 0000000000000000 RSI: 0000000000000000 RDI: 0000000000000000 RBP: 1ffff1100ab98802 R08: ffffffff844da989 R09: 0000000000000002 R10: 0000000000000003 R11: 0000000000000000 R12: 1ffff1100ab9885e R13: ffff888055cc4010 R14: 0000000000000088 R15: ffff888055cc42f0 FS: 00007fbc293eb6c0(0000) GS:ffff88808d21b000(0000) knlGS:0000000000000000 CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 CR2: 00007f21e4b909c0 CR3: 0000000042d42000 CR4: 0000000000352ef0 Call Trace: bch2_trans_update_ip+0x9a6/0x1db0 fs/bcachefs/btree_update.c:531 bch2_trans_update fs/bcachefs/btree_update.h:123 [inline] bch2_journal_replay_key+0x4b0/0xb40 fs/bcachefs/recovery.c:311 bch2_journal_replay+0x171d/0x2630 fs/bcachefs/recovery.c:396 bch2_run_recovery_pass fs/bcachefs/recovery_passes.c:484 [inline] __bch2_run_recovery_passes+0x395/0x1010 fs/bcachefs/recovery_passes.c:539 bch2_run_recovery_passes+0x184/0x210 fs/bcachefs/recovery_passes.c:610 bch2_fs_recovery+0x2690/0x3a50 fs/bcachefs/recovery.c:1005 bch2_fs_start+0xaaf/0xda0 fs/bcachefs/super.c:1213 bch2_fs_get_tree+0xb39/0x1520 fs/bcachefs/fs.c:2488 vfs_get_tree+0x92/0x2b0 fs/super.c:1804 do_new_mount+0x24a/0xa40 fs/namespace.c:3902 do_mount fs/namespace.c:4239 [inline] __do_sys_mount fs/namespace.c:4450 [inline] __se_sys_mount+0x317/0x410 fs/namespace.c:4427 do_syscall_x64 arch/x86/entry/syscall_64.c:63 [inline] do_syscall_64+0xfa/0x3b0 arch/x86/entry/syscall_64.c:94 entry_SYSCALL_64_after_hwframe+0x77/0x7f RIP: 0033:0x7fbc285900ca Code: d8 64 89 02 48 c7 c0 ff ff ff ff eb a6 e8 de 1a 00 00 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 40 00 49 89 ca b8 a5 00 00 00 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:00007fbc293eae68 EFLAGS: 00000246 ORIG_RAX: 00000000000000a5 RAX: ffffffffffffffda RBX: 00007fbc293eaef0 RCX: 00007fbc285900ca RDX: 00002000000058c0 RSI: 0000200000005900 RDI: 00007fbc293eaeb0 RBP: 00002000000058c0 R08: 00007fbc293eaef0 R09: 0000000000010000 R10: 0000000000010000 R11: 0000000000000246 R12: 0000200000005900 R13: 00007fbc293eaeb0 R14: 00000000000058d3 R15: 0000200000000280 Modules linked in: ---[ end trace 0000000000000000 ]--- RIP: 0010:bch2_trans_update_by_path+0x1efb/0x1f30 fs/bcachefs/btree_update.c:375 Code: 80 e1 07 fe c1 38 c1 0f 8c 40 f7 ff ff 48 8b 7c 24 28 e8 48 17 fa fd e9 31 f7 ff ff e8 fe 93 96 fd 90 0f 0b e8 f6 93 96 fd 90 <0f> 0b e8 ee 93 96 fd 90 0f 0b e8 e6 93 96 fd 90 0f 0b e8 de 93 96 RSP: 0018:ffffc9000d64ea08 EFLAGS: 00010293 RAX: ffffffff8429a27a RBX: 0000000000008540 RCX: ffff888000b20000 RDX: 0000000000000000 RSI: 0000000000000000 RDI: 0000000000000000 RBP: 1ffff1100ab98802 R08: ffffffff844da989 R09: 0000000000000002 R10: 0000000000000003 R11: 0000000000000000 R12: 1ffff1100ab9885e R13: ffff888055cc4010 R14: 0000000000000088 R15: ffff888055cc42f0 FS: 00007fbc293eb6c0(0000) GS:ffff88808d21b000(0000) knlGS:0000000000000000 CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 CR2: 000055e4b6f8f168 CR3: 0000000042d42000 CR4: 0000000000352ef0