EXT4-fs error (device loop0): ext4_map_blocks:739: inode #19: block 224: comm syz-executor137: lblock 32 mapped to illegal pblock 224 (length 1) ------------[ cut here ]------------ kernel BUG at fs/ext4/ext4.h:2980! invalid opcode: 0000 [#1] PREEMPT SMP KASAN CPU: 0 PID: 351 Comm: syz-executor137 Not tainted 5.4.225-syzkaller-00003-gf4e4be09c27c #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 03/02/2023 RIP: 0010:ext4_get_group_info fs/ext4/ext4.h:2980 [inline] RIP: 0010:ext4_mb_load_buddy_gfp+0xf29/0xf40 fs/ext4/mballoc.c:1116 Code: ff e8 1b 1b ce ff e9 0a f3 ff ff 89 f9 80 e1 07 80 c1 03 38 c1 0f 8c 52 f3 ff ff e8 21 1b ce ff e9 48 f3 ff ff e8 77 99 a0 ff <0f> 0b e8 70 99 a0 ff 0f 0b e8 69 99 a0 ff 0f 0b e8 62 99 a0 ff 0f RSP: 0018:ffff8881debbf0e8 EFLAGS: 00010293 RAX: ffffffff81c29d89 RBX: 0000000000000001 RCX: ffff8881f36c8fc0 RDX: 0000000000000000 RSI: 00000000fffffac6 RDI: 0000000000000001 RBP: ffff8881db6b2000 R08: ffffffff81c28f32 R09: ffffed103cc6a5ea R10: 0000000000000000 R11: dffffc0000000001 R12: 1ffff1103b6d6e7e R13: dffffc0000000000 R14: 00000000fffffac6 R15: ffff8881db6b73f0 FS: 00007f02b23a2700(0000) GS:ffff8881f6e00000(0000) knlGS:0000000000000000 CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 CR2: 0000000020020000 CR3: 00000001f1fc3000 CR4: 00000000003406f0 DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000 DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400 Call Trace: ext4_discard_preallocations+0x603/0xb90 fs/ext4/mballoc.c:4101 ext4_truncate+0xa12/0x12c0 fs/ext4/inode.c:4644 ext4_truncate_failed_write fs/ext4/truncate.h:20 [inline] ext4_write_begin+0xd5e/0x1900 fs/ext4/inode.c:1396 ext4_da_write_begin+0x4a3/0xfe0 fs/ext4/inode.c:3117 generic_perform_write+0x2c7/0x560 mm/filemap.c:3311 __generic_file_write_iter+0x239/0x490 mm/filemap.c:3440 ext4_file_write_iter+0x499/0x10e0 fs/ext4/file.c:270 call_write_iter include/linux/fs.h:1981 [inline] new_sync_write fs/read_write.c:483 [inline] __vfs_write+0x5d3/0x750 fs/read_write.c:496 vfs_write+0x206/0x4e0 fs/read_write.c:558 ksys_write+0x199/0x2c0 fs/read_write.c:611 do_syscall_64+0xca/0x1c0 arch/x86/entry/common.c:290 entry_SYSCALL_64_after_hwframe+0x5c/0xc1 Modules linked in: ---[ end trace 9a2936a5f4735437 ]--- RIP: 0010:ext4_get_group_info fs/ext4/ext4.h:2980 [inline] RIP: 0010:ext4_mb_load_buddy_gfp+0xf29/0xf40 fs/ext4/mballoc.c:1116 Code: ff e8 1b 1b ce ff e9 0a f3 ff ff 89 f9 80 e1 07 80 c1 03 38 c1 0f 8c 52 f3 ff ff e8 21 1b ce ff e9 48 f3 ff ff e8 77 99 a0 ff <0f> 0b e8 70 99 a0 ff 0f 0b e8 69 99 a0 ff 0f 0b e8 62 99 a0 ff 0f RSP: 0018:ffff8881debbf0e8 EFLAGS: 00010293 RAX: ffffffff81c29d89 RBX: 0000000000000001 RCX: ffff8881f36c8fc0 RDX: 0000000000000000 RSI: 00000000fffffac6 RDI: 0000000000000001 RBP: ffff8881db6b2000 R08: ffffffff81c28f32 R09: ffffed103cc6a5ea R10: 0000000000000000 R11: dffffc0000000001 R12: 1ffff1103b6d6e7e R13: dffffc0000000000 R14: 00000000fffffac6 R15: ffff8881db6b73f0 FS: 00007f02b23a2700(0000) GS:ffff8881f6e00000(0000) knlGS:0000000000000000 CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 CR2: 0000000020020000 CR3: 00000001f1fc3000 CR4: 00000000003406f0 DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000 DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400