BUG: spinlock bad magic on CPU#1, jfsCommit/274 ================================================================== BUG: KASAN: slab-out-of-bounds in string_nocheck lib/vsprintf.c:642 [inline] BUG: KASAN: slab-out-of-bounds in string+0x218/0x2b0 lib/vsprintf.c:724 Read of size 1 at addr ffff8880611c0978 by task jfsCommit/274 CPU: 1 PID: 274 Comm: jfsCommit Not tainted 5.15.169-syzkaller #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 09/13/2024 Call Trace: __dump_stack lib/dump_stack.c:88 [inline] dump_stack_lvl+0x1e3/0x2d0 lib/dump_stack.c:106 print_address_description+0x63/0x3b0 mm/kasan/report.c:248 __kasan_report mm/kasan/report.c:434 [inline] kasan_report+0x16b/0x1c0 mm/kasan/report.c:451 string_nocheck lib/vsprintf.c:642 [inline] string+0x218/0x2b0 lib/vsprintf.c:724 vsnprintf+0x11a4/0x1c70 lib/vsprintf.c:2811 vprintk_store+0x3ba/0x1300 kernel/printk/printk.c:2164 vprintk_emit+0x83/0x150 kernel/printk/printk.c:2258 _printk+0xd1/0x120 kernel/printk/printk.c:2299 spin_dump kernel/locking/spinlock_debug.c:63 [inline] spin_bug+0x136/0x1d0 kernel/locking/spinlock_debug.c:77 debug_spin_lock_before kernel/locking/spinlock_debug.c:85 [inline] do_raw_spin_lock+0x200/0x370 kernel/locking/spinlock_debug.c:114 __raw_spin_lock_irqsave include/linux/spinlock_api_smp.h:117 [inline] _raw_spin_lock_irqsave+0xdd/0x120 kernel/locking/spinlock.c:162 __wake_up_common_lock kernel/sched/wait.c:137 [inline] __wake_up+0xf5/0x1c0 kernel/sched/wait.c:157 unlock_metapage fs/jfs/jfs_metapage.c:37 [inline] release_metapage+0x155/0xe00 fs/jfs/jfs_metapage.c:737 xtTruncate+0xff9/0x3260 jfs_free_zero_link+0x46a/0x6e0 fs/jfs/namei.c:758 jfs_evict_inode+0x35b/0x440 fs/jfs/inode.c:153 evict+0x529/0x930 fs/inode.c:622 txUpdateMap+0x825/0x9e0 fs/jfs/jfs_txnmgr.c:2401 txLazyCommit fs/jfs/jfs_txnmgr.c:2698 [inline] jfs_lazycommit+0x470/0xc30 fs/jfs/jfs_txnmgr.c:2766 kthread+0x3f6/0x4f0 kernel/kthread.c:334 ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:287 Allocated by task 0: (stack is not available) The buggy address belongs to the object at ffff8880611c0940 which belongs to the cache jfs_ip of size 2240 The buggy address is located 56 bytes inside of 2240-byte region [ffff8880611c0940, ffff8880611c1200) The buggy address belongs to the page: page:ffffea0001847000 refcount:1 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x611c0 head:ffffea0001847000 order:3 compound_mapcount:0 compound_pincount:0 memcg:ffff8880662bc601 flags: 0xfff00000010200(slab|head|node=0|zone=1|lastcpupid=0x7ff) raw: 00fff00000010200 0000000000000000 dead000000000122 ffff888146b20dc0 raw: 0000000000000000 00000000800d000d 00000001ffffffff ffff8880662bc601 page dumped because: kasan: bad access detected page_owner tracks the page as allocated page last allocated via order 3, migratetype Reclaimable, gfp_mask 0x1d2050(__GFP_IO|__GFP_NOWARN|__GFP_NORETRY|__GFP_COMP|__GFP_NOMEMALLOC|__GFP_HARDWALL|__GFP_RECLAIMABLE), pid 4167, ts 150919230724, free_ts 14713837496 prep_new_page mm/page_alloc.c:2426 [inline] get_page_from_freelist+0x322a/0x33c0 mm/page_alloc.c:4159 __alloc_pages+0x272/0x700 mm/page_alloc.c:5423 alloc_slab_page mm/slub.c:1775 [inline] allocate_slab mm/slub.c:1912 [inline] new_slab+0xbb/0x4b0 mm/slub.c:1975 ___slab_alloc+0x6f6/0xe10 mm/slub.c:3008 __slab_alloc mm/slub.c:3095 [inline] slab_alloc_node mm/slub.c:3186 [inline] slab_alloc mm/slub.c:3228 [inline] kmem_cache_alloc+0x18e/0x280 mm/slub.c:3233 jfs_alloc_inode+0x17/0x50 fs/jfs/super.c:105 alloc_inode fs/inode.c:236 [inline] iget_locked+0x194/0x7f0 fs/inode.c:1283 jfs_iget+0x1e/0x3b0 fs/jfs/inode.c:29 jfs_lookup+0x222/0x400 fs/jfs/namei.c:1467 __lookup_slow+0x275/0x3d0 fs/namei.c:1663 lookup_slow+0x53/0x70 fs/namei.c:1680 walk_component+0x48c/0x610 fs/namei.c:1976 lookup_last fs/namei.c:2431 [inline] path_lookupat+0x16f/0x450 fs/namei.c:2455 filename_lookup+0x230/0x5c0 fs/namei.c:2484 user_path_at_empty+0x40/0x180 fs/namei.c:2883 user_path_at include/linux/namei.h:57 [inline] ksys_umount fs/namespace.c:1779 [inline] __do_sys_umount fs/namespace.c:1787 [inline] __se_sys_umount fs/namespace.c:1785 [inline] __x64_sys_umount+0xf0/0x170 fs/namespace.c:1785 page last free stack trace: reset_page_owner include/linux/page_owner.h:24 [inline] free_pages_prepare mm/page_alloc.c:1340 [inline] free_pcp_prepare mm/page_alloc.c:1391 [inline] free_unref_page_prepare+0xc34/0xcf0 mm/page_alloc.c:3317 free_unref_page+0x95/0x2d0 mm/page_alloc.c:3396 free_contig_range+0x95/0xf0 mm/page_alloc.c:9342 destroy_args+0xfe/0x980 mm/debug_vm_pgtable.c:1018 debug_vm_pgtable+0x40d/0x470 mm/debug_vm_pgtable.c:1331 do_one_initcall+0x22b/0x7a0 init/main.c:1302 do_initcall_level+0x157/0x210 init/main.c:1375 do_initcalls+0x49/0x90 init/main.c:1391 kernel_init_freeable+0x425/0x5c0 init/main.c:1615 kernel_init+0x19/0x290 init/main.c:1506 ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:287 Memory state around the buggy address: ffff8880611c0800: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ffff8880611c0880: 00 00 00 00 00 00 00 00 fc fc fc fc fc fc fc fc >ffff8880611c0900: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc ^ ffff8880611c0980: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc ffff8880611c0a00: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc ==================================================================