================================================================== BUG: KASAN: use-after-free in ext4_ext_rm_leaf fs/ext4/extents.c:2596 [inline] BUG: KASAN: use-after-free in ext4_ext_remove_space+0x374f/0x4570 fs/ext4/extents.c:2934 Read of size 4 at addr ffff88812c8e2c18 by task syz-executor/351 CPU: 1 PID: 351 Comm: syz-executor Not tainted syzkaller #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 10/25/2025 Call Trace: __dump_stack+0x21/0x24 lib/dump_stack.c:77 dump_stack_lvl+0x1a7/0x208 lib/dump_stack.c:118 print_address_description+0x7f/0x2c0 mm/kasan/report.c:248 __kasan_report mm/kasan/report.c:435 [inline] kasan_report+0xe2/0x130 mm/kasan/report.c:452 __asan_report_load4_noabort+0x14/0x20 mm/kasan/report_generic.c:308 ext4_ext_rm_leaf fs/ext4/extents.c:2596 [inline] ext4_ext_remove_space+0x374f/0x4570 fs/ext4/extents.c:2934 ext4_ext_truncate+0x169/0x1f0 fs/ext4/extents.c:4467 ext4_truncate+0xb21/0x12d0 fs/ext4/inode.c:4373 ext4_evict_inode+0xf5b/0x1770 fs/ext4/inode.c:290 evict+0x4ae/0x930 fs/inode.c:612 iput_final fs/inode.c:1736 [inline] iput+0x638/0x7c0 fs/inode.c:1762 do_unlinkat+0x347/0x680 fs/namei.c:4050 __do_sys_unlink fs/namei.c:4090 [inline] __se_sys_unlink fs/namei.c:4088 [inline] __x64_sys_unlink+0x49/0x50 fs/namei.c:4088 do_syscall_64+0x31/0x40 arch/x86/entry/common.c:46 entry_SYSCALL_64_after_hwframe+0x61/0xcb RIP: 0033:0x7fab0ddd3fa7 Code: 73 01 c3 48 c7 c1 e8 ff ff ff f7 d8 64 89 01 48 83 c8 ff c3 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 44 00 00 b8 57 00 00 00 0f 05 <48> 3d 00 f0 ff ff 77 01 c3 48 c7 c2 e8 ff ff ff f7 d8 64 89 02 b8 RSP: 002b:00007ffdbd489808 EFLAGS: 00000206 ORIG_RAX: 0000000000000057 RAX: ffffffffffffffda RBX: 0000000000000000 RCX: 00007fab0ddd3fa7 RDX: 00007ffdbd489830 RSI: 00007ffdbd4898c0 RDI: 00007ffdbd4898c0 RBP: 00007ffdbd4898c0 R08: 00007ffdbd48a8c0 R09: 00000000ffffffff R10: 0000000000000100 R11: 0000000000000206 R12: 00007ffdbd48a9b0 R13: 00007fab0de3e71f R14: 00000000000080e8 R15: 00007ffdbd48ba80 The buggy address belongs to the page: page:ffffea0004b23880 refcount:0 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x12c8e2 flags: 0x4000000000000000() raw: 4000000000000000 ffffea0004b23888 ffffea0004b23888 0000000000000000 raw: 0000000000000000 0000000000000000 00000000ffffffff 0000000000000000 page dumped because: kasan: bad access detected page_owner info is not present (never set?) Memory state around the buggy address: ffff88812c8e2b00: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ffff88812c8e2b80: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff >ffff88812c8e2c00: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ^ ffff88812c8e2c80: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ffff88812c8e2d00: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ================================================================== EXT4-fs error (device loop2): ext4_free_blocks:5701: comm syz-executor: Freeing blocks not in datazone - block = 111546515832528, count = 16 EXT4-fs error (device loop2): ext4_free_blocks:5701: comm syz-executor: Freeing blocks not in datazone - block = 111546515808116, count = 24428 EXT4-fs error (device loop2): ext4_free_blocks:5701: comm syz-executor: Freeing blocks not in datazone - block = 111546515808112, count = 16 EXT4-fs error (device loop2): ext4_free_blocks:5701: comm syz-executor: Freeing blocks not in datazone - block = 130151995502691, count = 26723 EXT4-fs error (device loop2): ext4_free_blocks:5701: comm syz-executor: Freeing blocks not in datazone - block = 130151995502688, count = 16 EXT4-fs error (device loop2): ext4_free_blocks:5701: comm syz-executor: Freeing blocks not in datazone - block = 35392517276288, count = 16 EXT4-fs error (device loop2): ext4_free_blocks:5701: comm syz-executor: Freeing blocks not in datazone - block = 35392517251156, count = 25143 EXT4-fs error (device loop2): ext4_free_blocks:5701: comm syz-executor: Freeing blocks not in datazone - block = 35392517251152, count = 16 EXT4-fs error (device loop2): ext4_free_blocks:5701: comm syz-executor: Freeing blocks not in datazone - block = 112589218958528, count = 16 EXT4-fs error (device loop2): ext4_free_blocks:5701: comm syz-executor: Freeing blocks not in datazone - block = 29776, count = 16 EXT4-fs error (device loop2): ext4_free_blocks:5701: comm syz-executor: Freeing blocks not in datazone - block = 0, count = 29791 EXT4-fs error (device loop2): ext4_free_blocks:5701: comm syz-executor: Freeing blocks not in datazone - block = 0, count = 16 EXT4-fs error (device loop2): ext4_free_blocks:5701: comm syz-executor: Freeing blocks not in datazone - block = 123628039739872, count = 16 EXT4-fs error (device loop2): ext4_free_blocks:5701: comm syz-executor: Freeing blocks not in datazone - block = 123628039724912, count = 14962 EXT4-fs error (device loop2): ext4_free_blocks:5701: comm syz-executor: Freeing blocks not in datazone - block = 123628039724912, count = 16 EXT4-fs error (device loop2): ext4_free_blocks:5701: comm syz-executor: Freeing blocks not in datazone - block = 129052667206800, count = 16 EXT4-fs error (device loop2): ext4_free_blocks:5701: comm syz-executor: Freeing blocks not in datazone - block = 129052667178810, count = 28005 EXT4-fs error (device loop2): ext4_free_blocks:5701: comm syz-executor: Freeing blocks not in datazone - block = 129052667178800, count = 16 EXT4-fs error (device loop2): ext4_free_blocks:5701: comm syz-executor: Freeing blocks not in datazone - block = 0, count = 192 EXT4-fs error (device loop2): ext4_free_blocks:5701: comm syz-executor: Freeing blocks not in datazone - block = 2448131378400, count = 16 EXT4-fs error (device loop2): ext4_free_blocks:5701: comm syz-executor: Freeing blocks not in datazone - block = 2448131358720, count = 19688 EXT4-fs error (device loop2): ext4_free_blocks:5701: comm syz-executor: Freeing blocks not in datazone - block = 1, count = 192 EXT4-fs error (device loop2): ext4_free_blocks:5701: comm syz-executor: Freeing blocks not in datazone - block = 2336462209216, count = 12832 EXT4-fs error (device loop2): ext4_free_blocks:5701: comm syz-executor: Freeing blocks not in datazone - block = 37375008, count = 0 EXT4-fs error (device loop2): ext4_free_blocks:5701: comm syz-executor: Freeing blocks not in datazone - block = 37375008, count = 16 EXT4-fs error (device loop2): ext4_free_blocks:5701: comm syz-executor: Freeing blocks not in datazone - block = 0, count = 0 EXT4-fs error (device loop2): ext4_free_blocks:5701: comm syz-executor: Freeing blocks not in datazone - block = 35664736, count = 0 EXT4-fs error (device loop2): ext4_free_blocks:5701: comm syz-executor: Freeing blocks not in datazone - block = 35392466278864, count = 16 EXT4-fs error (device loop2): ext4_free_blocks:5701: comm syz-executor: Freeing blocks not in datazone - block = 35392466264180, count = 14692 EXT4-fs error (device loop2): ext4_free_blocks:5701: comm syz-executor: Freeing blocks not in datazone - block = 35392466264176, count = 16 EXT4-fs error (device loop2): ext4_free_blocks:5701: comm syz-executor: Freeing blocks not in datazone - block = 112589218958528, count = 16 EXT4-fs error (device loop2): ext4_free_blocks:5701: comm syz-executor: Freeing blocks not in datazone - block = 112589218932326, count = 26214 EXT4-fs error (device loop2): ext4_free_blocks:5701: comm syz-executor: Freeing blocks not in datazone - block = 112589218932320, count = 16 EXT4-fs error (device loop2): ext4_free_blocks:5701: comm syz-executor: Freeing blocks not in datazone - block = 119251719708517, count = 25711 EXT4-fs error (device loop2): ext4_free_blocks:5701: comm syz-executor: Freeing blocks not in datazone - block = 119251719708512, count = 16 EXT4-fs error (device loop2): ext4_free_blocks:5701: comm syz-executor: Freeing blocks not in datazone - block = 35392466278352, count = 16