loop8: detected capacity change from 0 to 32768 ================================================================== BUG: KASAN: use-after-free in dtMoveEntry fs/jfs/jfs_dtree.c:3934 [inline] BUG: KASAN: use-after-free in dtSplitPage+0x1e37/0x3b20 fs/jfs/jfs_dtree.c:1561 Write of size 1 at addr ffff888039de6000 by task syz.8.263/8428 CPU: 0 UID: 0 PID: 8428 Comm: syz.8.263 Not tainted 6.16.0-rc1-syzkaller-00236-g8c6bc74c7f89 #0 PREEMPT(full) Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 05/07/2025 Call Trace: dump_stack_lvl+0x189/0x250 lib/dump_stack.c:120 print_address_description mm/kasan/report.c:408 [inline] print_report+0xd2/0x2b0 mm/kasan/report.c:521 kasan_report+0x118/0x150 mm/kasan/report.c:634 dtMoveEntry fs/jfs/jfs_dtree.c:3934 [inline] dtSplitPage+0x1e37/0x3b20 fs/jfs/jfs_dtree.c:1561 dtSplitUp fs/jfs/jfs_dtree.c:1092 [inline] dtInsert+0x109b/0x5f40 fs/jfs/jfs_dtree.c:871 jfs_create+0x6c8/0xa80 fs/jfs/namei.c:137 lookup_open fs/namei.c:3708 [inline] open_last_lookups fs/namei.c:3807 [inline] path_openat+0x14f4/0x3830 fs/namei.c:4043 do_filp_open+0x1fa/0x410 fs/namei.c:4073 do_sys_openat2+0x121/0x1c0 fs/open.c:1437 do_sys_open fs/open.c:1452 [inline] __do_sys_creat fs/open.c:1530 [inline] __se_sys_creat fs/open.c:1524 [inline] __x64_sys_creat+0x8f/0xc0 fs/open.c:1524 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:0x7f4b03f8e929 Code: ff ff c3 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 40 00 48 89 f8 48 89 f7 48 89 d6 48 89 ca 4d 89 c2 4d 89 c8 4c 8b 4c 24 08 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:00007f4b04d59038 EFLAGS: 00000246 ORIG_RAX: 0000000000000055 RAX: ffffffffffffffda RBX: 00007f4b041b5fa0 RCX: 00007f4b03f8e929 RDX: 0000000000000000 RSI: 0000000000000032 RDI: 00002000000008c0 RBP: 00007f4b04010b39 R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000 R13: 0000000000000000 R14: 00007f4b041b5fa0 R15: 00007ffc45f2ea88 The buggy address belongs to the physical page: page: refcount:0 mapcount:0 mapping:0000000000000000 index:0x1f pfn:0x39de6 flags: 0xfff00000000000(node=0|zone=1|lastcpupid=0x7ff) raw: 00fff00000000000 ffffea0000e779c8 ffffea0000d10688 0000000000000000 raw: 000000000000001f 0000000000000000 00000000ffffffff 0000000000000000 page dumped because: kasan: bad access detected page_owner tracks the page as freed page last allocated via order 0, migratetype Unmovable, gfp_mask 0x152c40(GFP_NOFS|__GFP_NOWARN|__GFP_NORETRY|__GFP_COMP|__GFP_HARDWALL), pid 5971, tgid 5971 (udevd), ts 254907388098, free_ts 255535920351 set_page_owner include/linux/page_owner.h:32 [inline] post_alloc_hook+0x240/0x2a0 mm/page_alloc.c:1704 prep_new_page mm/page_alloc.c:1712 [inline] get_page_from_freelist+0x21d5/0x22b0 mm/page_alloc.c:3669 __alloc_frozen_pages_noprof+0x181/0x370 mm/page_alloc.c:4959 alloc_pages_mpol+0x232/0x4a0 mm/mempolicy.c:2419 alloc_frozen_pages_noprof mm/mempolicy.c:2490 [inline] alloc_pages_noprof+0xa9/0x190 mm/mempolicy.c:2510 folio_alloc_noprof+0x1e/0x30 mm/mempolicy.c:2520 filemap_alloc_folio_noprof+0xdf/0x470 mm/filemap.c:1007 ractl_alloc_folio mm/readahead.c:186 [inline] page_cache_ra_unbounded+0x2b9/0x7b0 mm/readahead.c:270 do_page_cache_ra mm/readahead.c:327 [inline] force_page_cache_ra mm/readahead.c:356 [inline] page_cache_sync_ra+0x3b9/0xae0 mm/readahead.c:575 filemap_get_pages+0x43c/0x1ea0 mm/filemap.c:2602 filemap_read+0x3f6/0x11a0 mm/filemap.c:2711 blkdev_read_iter+0x30a/0x440 block/fops.c:833 new_sync_read fs/read_write.c:491 [inline] vfs_read+0x4d0/0x980 fs/read_write.c:572 ksys_read+0x145/0x250 fs/read_write.c:715 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 page last free pid 7478 tgid 7478 stack trace: reset_page_owner include/linux/page_owner.h:25 [inline] free_pages_prepare mm/page_alloc.c:1248 [inline] free_unref_folios+0xcd2/0x1570 mm/page_alloc.c:2763 folios_put_refs+0x559/0x640 mm/swap.c:992 folio_batch_release include/linux/pagevec.h:101 [inline] mapping_try_invalidate+0x324/0x410 mm/truncate.c:554 generic_shutdown_super+0x132/0x2c0 fs/super.c:643 kill_block_super+0x44/0x90 fs/super.c:1753 xfs_kill_sb+0x15/0x50 fs/xfs/xfs_super.c:2318 deactivate_locked_super+0xbc/0x130 fs/super.c:474 cleanup_mnt+0x425/0x4c0 fs/namespace.c:1417 task_work_run+0x1d1/0x260 kernel/task_work.c:227 resume_user_mode_work include/linux/resume_user_mode.h:50 [inline] exit_to_user_mode_loop+0xec/0x110 kernel/entry/common.c:114 exit_to_user_mode_prepare include/linux/entry-common.h:330 [inline] syscall_exit_to_user_mode_work include/linux/entry-common.h:414 [inline] syscall_exit_to_user_mode include/linux/entry-common.h:449 [inline] do_syscall_64+0x2bd/0x3b0 arch/x86/entry/syscall_64.c:100 entry_SYSCALL_64_after_hwframe+0x77/0x7f Memory state around the buggy address: ffff888039de5f00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ffff888039de5f80: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 >ffff888039de6000: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ^ ffff888039de6080: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ffff888039de6100: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ==================================================================