u64s 11 type btree_ptr_v2 SPOS_MAX len 0 ver 0: seq c6c25c03258c59c5 written 1032 min_key POS_MIN durability: 1 ptr: 0:27:0 gen 0
node offset 0/1032 bset u64s 34546 bset byte offset 160: bad k->u64s 0 (min 3 max 253), fixing
------------[ cut here ]------------
kernel BUG at arch/x86/mm/physaddr.c:28!
Oops: invalid opcode: 0000 [#1] PREEMPT SMP KASAN NOPTI
CPU: 0 UID: 0 PID: 37 Comm: kworker/0:1H Not tainted 6.12.0-syzkaller #0
Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.16.3-debian-1.16.3-2~bpo12+1 04/01/2014
Workqueue: bcachefs_btree_read_complete btree_node_read_work
RIP: 0010:__phys_addr+0x162/0x170 arch/x86/mm/physaddr.c:28
Code: e8 d3 e9 51 00 48 c7 c7 c0 87 7a 8e 4c 89 f6 4c 89 fa e8 41 43 b3 03 e9 45 ff ff ff e8 b7 e9 51 00 90 0f 0b e8 af e9 51 00 90 <0f> 0b e8 a7 e9 51 00 90 0f 0b 0f 1f 40 00 90 90 90 90 90 90 90 90
RSP: 0018:ffffc9000057ed98 EFLAGS: 00010293
RAX: ffffffff81430061 RBX: 0000000000000001 RCX: ffff88801ddd8000
RDX: 0000000000000000 RSI: 0000000000000001 RDI: 0000000000000000
RBP: 0000000000000000 R08: ffffffff8142ffac R09: 1ffffffff285a106
R10: dffffc0000000000 R11: fffffbfff285a107 R12: ffffea00011663c0
R13: ffffea0000000000 R14: 00006180011663c0 R15: 000000000000002e
FS: 0000000000000000(0000) GS:ffff88801fc00000(0000) knlGS:0000000000000000
CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 0000000000000000 CR3: 0000000048944000 CR4: 0000000000352ef0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
Call Trace:
<TASK>
virt_to_folio include/linux/mm.h:1282 [inline]
virt_to_slab mm/slab.h:206 [inline]
qlink_to_cache mm/kasan/quarantine.c:131 [inline]
qlist_free_all+0x3d/0x140 mm/kasan/quarantine.c:176
kasan_quarantine_reduce+0x14f/0x170 mm/kasan/quarantine.c:286
__kasan_slab_alloc+0x23/0x80 mm/kasan/common.c:329
kasan_slab_alloc include/linux/kasan.h:247 [inline]
slab_post_alloc_hook mm/slub.c:4085 [inline]
slab_alloc_node mm/slub.c:4134 [inline]
__do_kmalloc_node mm/slub.c:4263 [inline]
__kmalloc_node_track_caller_noprof+0x1cd/0x440 mm/slub.c:4283
__do_krealloc mm/slab_common.c:1229 [inline]
krealloc_noprof+0x88/0x120 mm/slab_common.c:1278
bch2_printbuf_make_room+0x1f1/0x350 fs/bcachefs/printbuf.c:59
bch2_prt_printf+0x267/0x6d0 fs/bcachefs/printbuf.c:186
btree_err_msg fs/bcachefs/btree_io.c:519 [inline]
__btree_err+0x171/0x760 fs/bcachefs/btree_io.c:557
validate_bset_keys+0x554/0x1610 fs/bcachefs/btree_io.c:894
bch2_btree_node_read_done+0x2402/0x5e90 fs/bcachefs/btree_io.c:1130
btree_node_read_work+0x68b/0x1260 fs/bcachefs/btree_io.c:1323
process_one_work kernel/workqueue.c:3229 [inline]
process_scheduled_works+0xa63/0x1850 kernel/workqueue.c:3310
worker_thread+0x870/0xd30 kernel/workqueue.c:3391
kthread+0x2f0/0x390 kernel/kthread.c:389
ret_from_fork+0x4b/0x80 arch/x86/kernel/process.c:147
ret_from_fork_asm+0x1a/0x30 arch/x86/entry/entry_64.S:244
</TASK>
Modules linked in:
---[ end trace 0000000000000000 ]---
RIP: 0010:__phys_addr+0x162/0x170 arch/x86/mm/physaddr.c:28
Code: e8 d3 e9 51 00 48 c7 c7 c0 87 7a 8e 4c 89 f6 4c 89 fa e8 41 43 b3 03 e9 45 ff ff ff e8 b7 e9 51 00 90 0f 0b e8 af e9 51 00 90 <0f> 0b e8 a7 e9 51 00 90 0f 0b 0f 1f 40 00 90 90 90 90 90 90 90 90
RSP: 0018:ffffc9000057ed98 EFLAGS: 00010293
RAX: ffffffff81430061 RBX: 0000000000000001 RCX: ffff88801ddd8000
RDX: 0000000000000000 RSI: 0000000000000001 RDI: 0000000000000000
RBP: 0000000000000000 R08: ffffffff8142ffac R09: 1ffffffff285a106
R10: dffffc0000000000 R11: fffffbfff285a107 R12: ffffea00011663c0
R13: ffffea0000000000 R14: 00006180011663c0 R15: 000000000000002e
FS: 0000000000000000(0000) GS:ffff88801fc00000(0000) knlGS:0000000000000000
CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 0000000000000000 CR3: 0000000048944000 CR4: 0000000000352ef0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400