================================================================== BUG: KASAN: slab-out-of-bounds in ocfs2_replay_truncate_records fs/ocfs2/alloc.c:5967 [inline] BUG: KASAN: slab-out-of-bounds in __ocfs2_flush_truncate_log+0x7c7/0x10e0 fs/ocfs2/alloc.c:6062 Read of size 4 at addr ffff888020771ac0 by task syz-executor/6716 CPU: 0 UID: 0 PID: 6716 Comm: syz-executor Tainted: G W 6.16.0-syzkaller-02094-g86aa72182095 #0 PREEMPT_{RT,(full)} Tainted: [W]=WARN Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 07/12/2025 Call Trace: dump_stack_lvl+0x189/0x250 lib/dump_stack.c:120 print_address_description mm/kasan/report.c:378 [inline] print_report+0xca/0x240 mm/kasan/report.c:482 kasan_report+0x118/0x150 mm/kasan/report.c:595 ocfs2_replay_truncate_records fs/ocfs2/alloc.c:5967 [inline] __ocfs2_flush_truncate_log+0x7c7/0x10e0 fs/ocfs2/alloc.c:6062 ocfs2_flush_truncate_log+0x4f/0x70 fs/ocfs2/alloc.c:6084 ocfs2_sync_fs+0x116/0x310 fs/ocfs2/super.c:406 sync_filesystem+0x1cb/0x250 fs/sync.c:66 generic_shutdown_super+0x6f/0x2c0 fs/super.c:622 kill_block_super+0x44/0x90 fs/super.c:1766 deactivate_locked_super+0xb9/0x130 fs/super.c:474 cleanup_mnt+0x425/0x4c0 fs/namespace.c:1378 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 RIP: 0033:0x7fca1b73f327 Code: a8 ff ff ff f7 d8 64 89 01 48 83 c8 ff c3 0f 1f 44 00 00 31 f6 e9 09 00 00 00 66 0f 1f 84 00 00 00 00 00 b8 a6 00 00 00 0f 05 <48> 3d 00 f0 ff ff 77 01 c3 48 c7 c2 a8 ff ff ff f7 d8 64 89 02 b8 RSP: 002b:00007fff19685718 EFLAGS: 00000246 ORIG_RAX: 00000000000000a6 RAX: 0000000000000000 RBX: 00007fca1b7b0134 RCX: 00007fca1b73f327 RDX: 0000000000000000 RSI: 0000000000000009 RDI: 00007fff196857d0 RBP: 00007fff196857d0 R08: 0000000000000000 R09: 0000000000000000 R10: 00000000ffffffff R11: 0000000000000246 R12: 00007fff19686850 R13: 00007fca1b7b0134 R14: 0000000000032db4 R15: 00007fff19686890 Allocated by task 33: kasan_save_stack mm/kasan/common.c:47 [inline] kasan_save_track+0x3e/0x80 mm/kasan/common.c:68 unpoison_slab_object mm/kasan/common.c:319 [inline] __kasan_slab_alloc+0x6c/0x80 mm/kasan/common.c:345 kasan_slab_alloc include/linux/kasan.h:250 [inline] slab_post_alloc_hook mm/slub.c:4148 [inline] slab_alloc_node mm/slub.c:4197 [inline] kmem_cache_alloc_noprof+0x143/0x310 mm/slub.c:4204 lsm_inode_alloc security/security.c:755 [inline] security_inode_alloc+0x39/0x330 security/security.c:1697 inode_init_always_gfp+0x9bf/0xd70 fs/inode.c:306 inode_init_always include/linux/fs.h:3306 [inline] alloc_inode+0x82/0x1b0 fs/inode.c:353 new_inode+0x22/0x170 fs/inode.c:1145 __shmem_get_inode mm/shmem.c:3049 [inline] shmem_get_inode+0x346/0xe00 mm/shmem.c:3123 shmem_mknod+0x18c/0x3e0 mm/shmem.c:3844 vfs_mknod+0x37f/0x3c0 fs/namei.c:4235 handle_create drivers/base/devtmpfs.c:233 [inline] handle drivers/base/devtmpfs.c:389 [inline] devtmpfs_work_loop+0x98b/0xd20 drivers/base/devtmpfs.c:404 devtmpfsd+0x4d/0x50 drivers/base/devtmpfs.c:446 kthread+0x70e/0x8a0 kernel/kthread.c:464 ret_from_fork+0x3f9/0x770 arch/x86/kernel/process.c:148 ret_from_fork_asm+0x1a/0x30 arch/x86/entry/entry_64.S:245 The buggy address belongs to the object at ffff888020771a50 which belongs to the cache lsm_inode_cache of size 112 The buggy address is located 0 bytes to the right of allocated 112-byte region [ffff888020771a50, ffff888020771ac0) The buggy address belongs to the physical page: page: refcount:0 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x20771 flags: 0x80000000000000(node=0|zone=1) page_type: f5(slab) raw: 0080000000000000 ffff88801ae8e280 dead000000000122 0000000000000000 raw: 0000000000000000 0000000000170017 00000000f5000000 0000000000000000 page dumped because: kasan: bad access detected page_owner tracks the page as allocated page last allocated via order 0, migratetype Unmovable, gfp_mask 0x52c40(GFP_NOFS|__GFP_NOWARN|__GFP_NORETRY|__GFP_COMP), pid 33, tgid 33 (kdevtmpfs), ts 10129602331, free_ts 9833563220 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+0x2119/0x21b0 mm/page_alloc.c:3669 __alloc_frozen_pages_noprof+0x181/0x370 mm/page_alloc.c:4959 alloc_pages_mpol+0xd1/0x380 mm/mempolicy.c:2419 alloc_slab_page mm/slub.c:2451 [inline] allocate_slab+0x8a/0x3b0 mm/slub.c:2619 new_slab mm/slub.c:2673 [inline] ___slab_alloc+0x8e7/0xe20 mm/slub.c:3859 __slab_alloc mm/slub.c:3949 [inline] __slab_alloc_node mm/slub.c:4024 [inline] slab_alloc_node mm/slub.c:4185 [inline] kmem_cache_alloc_noprof+0xe6/0x310 mm/slub.c:4204 lsm_inode_alloc security/security.c:755 [inline] security_inode_alloc+0x39/0x330 security/security.c:1697 inode_init_always_gfp+0x9bf/0xd70 fs/inode.c:306 inode_init_always include/linux/fs.h:3306 [inline] alloc_inode+0x82/0x1b0 fs/inode.c:353 new_inode+0x22/0x170 fs/inode.c:1145 __shmem_get_inode mm/shmem.c:3049 [inline] shmem_get_inode+0x346/0xe00 mm/shmem.c:3123 shmem_mknod+0x18c/0x3e0 mm/shmem.c:3844 vfs_mknod+0x37f/0x3c0 fs/namei.c:4235 handle_create drivers/base/devtmpfs.c:233 [inline] handle drivers/base/devtmpfs.c:389 [inline] devtmpfs_work_loop+0x98b/0xd20 drivers/base/devtmpfs.c:404 devtmpfsd+0x4d/0x50 drivers/base/devtmpfs.c:446 page last free pid 31 tgid 31 stack trace: reset_page_owner include/linux/page_owner.h:25 [inline] free_pages_prepare mm/page_alloc.c:1248 [inline] __free_frozen_pages+0xbe5/0xdf0 mm/page_alloc.c:2706 vfree+0x2ad/0x470 mm/vmalloc.c:3434 delayed_vfree_work+0x55/0x80 mm/vmalloc.c:3353 process_one_work kernel/workqueue.c:3238 [inline] process_scheduled_works+0xade/0x17b0 kernel/workqueue.c:3321 worker_thread+0x8a0/0xda0 kernel/workqueue.c:3402 kthread+0x70e/0x8a0 kernel/kthread.c:464 ret_from_fork+0x3f9/0x770 arch/x86/kernel/process.c:148 ret_from_fork_asm+0x1a/0x30 arch/x86/entry/entry_64.S:245 Memory state around the buggy address: ffff888020771980: fc fc fc fc 00 00 00 00 00 00 00 00 00 00 00 00 ffff888020771a00: 00 00 fc fc fc fc fc fc fc fc 00 00 00 00 00 00 >ffff888020771a80: 00 00 00 00 00 00 00 00 fc fc fc fc fc fc fc fc ^ ffff888020771b00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 fc fc ffff888020771b80: fc fc fc fc fc fc 00 00 00 00 00 00 00 00 00 00 ==================================================================