================================================================== BUG: KASAN: use-after-free in ext4_ext_binsearch fs/ext4/extents.c:827 [inline] BUG: KASAN: use-after-free in ext4_find_extent+0x994/0xb6c fs/ext4/extents.c:946 Read of size 4 at addr ffff0000e1867314 by task kworker/u4:2/148 CPU: 0 PID: 148 Comm: kworker/u4:2 Not tainted syzkaller #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 10/03/2025 Workqueue: writeback wb_workfn (flush-7:0) Call trace: dump_backtrace+0x0/0x43c arch/arm64/kernel/stacktrace.c:152 show_stack+0x2c/0x3c arch/arm64/kernel/stacktrace.c:216 __dump_stack+0x30/0x40 lib/dump_stack.c:88 dump_stack_lvl+0xf8/0x160 lib/dump_stack.c:106 print_address_description+0x78/0x30c mm/kasan/report.c:248 __kasan_report mm/kasan/report.c:434 [inline] kasan_report+0xec/0x15c mm/kasan/report.c:451 __asan_report_load4_noabort+0x44/0x50 mm/kasan/report_generic.c:308 ext4_ext_binsearch fs/ext4/extents.c:827 [inline] ext4_find_extent+0x994/0xb6c fs/ext4/extents.c:946 ext4_ext_map_blocks+0x230/0x5694 fs/ext4/extents.c:4166 ext4_map_blocks+0x7b8/0x167c fs/ext4/inode.c:673 mpage_map_one_extent fs/ext4/inode.c:2408 [inline] mpage_map_and_submit_extent fs/ext4/inode.c:2461 [inline] ext4_writepages+0xf00/0x2c14 fs/ext4/inode.c:2829 do_writepages+0x36c/0x578 mm/page-writeback.c:2386 __writeback_single_inode+0x148/0x11f0 fs/fs-writeback.c:1657 writeback_sb_inodes+0x7fc/0x1378 fs/fs-writeback.c:1940 wb_writeback+0x3d8/0xe44 fs/fs-writeback.c:2114 wb_do_writeback fs/fs-writeback.c:2257 [inline] wb_workfn+0x350/0xdd8 fs/fs-writeback.c:2298 process_one_work+0x79c/0x1140 kernel/workqueue.c:2310 worker_thread+0x8f4/0x101c kernel/workqueue.c:2457 kthread+0x374/0x454 kernel/kthread.c:334 ret_from_fork+0x10/0x20 arch/arm64/kernel/entry.S:856 The buggy address belongs to the page: page:00000000b4960965 refcount:0 mapcount:0 mapping:0000000000000000 index:0x1 pfn:0x121867 flags: 0x5ffc00000000000(node=0|zone=2|lastcpupid=0x7ff) raw: 05ffc00000000000 fffffc0003a18b08 fffffc0003a0b848 0000000000000000 raw: 0000000000000001 0000000000000000 00000000ffffffff 0000000000000000 page dumped because: kasan: bad access detected Memory state around the buggy address: ffff0000e1867200: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ffff0000e1867280: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff >ffff0000e1867300: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ^ ffff0000e1867380: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ffff0000e1867400: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ================================================================== EXT4-fs error (device loop0): ext4_map_blocks:739: inode #15: comm kworker/u4:2: lblock 0 mapped to illegal pblock 0 (length 1) EXT4-fs (loop0): Delayed block allocation failed for inode 15 at logical offset 0 with max blocks 1 with error 117 EXT4-fs (loop0): This should not happen!! Data will be lost EXT4-fs error (device loop0): ext4_map_blocks:739: inode #15: block 86110555277147: comm kworker/u4:2: lblock 0 mapped to illegal pblock 86110555277147 (length 1) EXT4-fs (loop0): Delayed block allocation failed for inode 15 at logical offset 0 with max blocks 1 with error 117 EXT4-fs (loop0): This should not happen!! Data will be lost EXT4-fs error (device loop0): ext4_ext_split:1074: inode #15: comm kworker/u4:2: p_ext > EXT_MAX_EXTENT! EXT4-fs (loop0): Delayed block allocation failed for inode 15 at logical offset 0 with max blocks 1 with error 117 EXT4-fs (loop0): This should not happen!! Data will be lost EXT4-fs error (device loop0): ext4_ext_split:1146: inode #15: comm kworker/u4:2: eh_entries 26982 != eh_max 25964! EXT4-fs (loop0): Delayed block allocation failed for inode 15 at logical offset 0 with max blocks 1 with error 117 EXT4-fs (loop0): This should not happen!! Data will be lost EXT4-fs error (device loop0): ext4_map_blocks:739: inode #15: block 2014339661824: comm kworker/u4:2: lblock 0 mapped to illegal pblock 2014339661824 (length 1) EXT4-fs (loop0): Delayed block allocation failed for inode 15 at logical offset 0 with max blocks 1 with error 117 EXT4-fs (loop0): This should not happen!! Data will be lost EXT4-fs error (device loop0): ext4_map_blocks:739: inode #15: block 71748523475265: comm kworker/u4:2: lblock 0 mapped to illegal pblock 71748523475265 (length 1) EXT4-fs (loop0): Delayed block allocation failed for inode 15 at logical offset 0 with max blocks 1 with error 117 EXT4-fs (loop0): This should not happen!! Data will be lost EXT4-fs error (device loop0): ext4_map_blocks:739: inode #15: block 126969739568179: comm kworker/u4:2: lblock 0 mapped to illegal pblock 126969739568179 (length 1) EXT4-fs (loop0): Delayed block allocation failed for inode 15 at logical offset 0 with max blocks 1 with error 117 EXT4-fs (loop0): This should not happen!! Data will be lost