loop0: detected capacity change from 0 to 32768 ================================================================== BUG: KASAN: slab-use-after-free in diWrite+0x1209/0x1f40 fs/jfs/jfs_imap.c:753 Write of size 32 at addr ffff888052bb60c0 by task syz.0.0/5321 CPU: 0 UID: 0 PID: 5321 Comm: syz.0.0 Not tainted 6.15.0-rc6-syzkaller-00346-g5723cc3450bc #0 PREEMPT(full) Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.16.3-debian-1.16.3-2~bpo12+1 04/01/2014 Call Trace: dump_stack_lvl+0x189/0x250 lib/dump_stack.c:120 print_address_description mm/kasan/report.c:408 [inline] print_report+0xb4/0x290 mm/kasan/report.c:521 kasan_report+0x118/0x150 mm/kasan/report.c:634 check_region_inline mm/kasan/generic.c:-1 [inline] kasan_check_range+0x29a/0x2b0 mm/kasan/generic.c:189 __asan_memcpy+0x40/0x70 mm/kasan/shadow.c:106 diWrite+0x1209/0x1f40 fs/jfs/jfs_imap.c:753 txCommit+0x852/0x5430 fs/jfs/jfs_txnmgr.c:1255 add_missing_indices+0x87d/0xbc0 fs/jfs/jfs_dtree.c:2664 jfs_readdir+0x1da4/0x3ac0 fs/jfs/jfs_dtree.c:3020 wrap_directory_iterator+0x93/0xe0 fs/readdir.c:65 iterate_dir+0x5ac/0x770 fs/readdir.c:108 __do_sys_getdents64 fs/readdir.c:403 [inline] __se_sys_getdents64+0xe4/0x260 fs/readdir.c:389 do_syscall_x64 arch/x86/entry/syscall_64.c:63 [inline] do_syscall_64+0xf6/0x210 arch/x86/entry/syscall_64.c:94 entry_SYSCALL_64_after_hwframe+0x77/0x7f RIP: 0033:0x7fa5e078e969 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:00007fa5e156d038 EFLAGS: 00000246 ORIG_RAX: 00000000000000d9 RAX: ffffffffffffffda RBX: 00007fa5e09b5fa0 RCX: 00007fa5e078e969 RDX: 0000000000000099 RSI: 0000200000000400 RDI: 0000000000000008 RBP: 00007fa5e0810ab1 R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000 R13: 0000000000000000 R14: 00007fa5e09b5fa0 R15: 00007ffe4d4cabc8 Allocated by task 47: 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:4147 [inline] slab_alloc_node mm/slub.c:4196 [inline] kmem_cache_alloc_node_noprof+0x1bb/0x3c0 mm/slub.c:4248 __alloc_skb+0x112/0x2d0 net/core/skbuff.c:658 alloc_skb include/linux/skbuff.h:1340 [inline] nlmsg_new include/net/netlink.h:1019 [inline] inet6_rt_notify+0xb6/0x240 net/ipv6/route.c:6258 fib6_add_rt2node net/ipv6/ip6_fib.c:1259 [inline] fib6_add+0x1d0d/0x4360 net/ipv6/ip6_fib.c:1488 __ip6_ins_rt net/ipv6/route.c:1351 [inline] ip6_ins_rt+0xc8/0x120 net/ipv6/route.c:1361 __ipv6_ifa_notify+0x63f/0xac0 net/ipv6/addrconf.c:6286 ipv6_ifa_notify net/ipv6/addrconf.c:6325 [inline] addrconf_dad_completed+0x180/0xd60 net/ipv6/addrconf.c:4324 addrconf_dad_work+0xc36/0x14b0 net/ipv6/addrconf.c:-1 process_one_work kernel/workqueue.c:3238 [inline] process_scheduled_works+0xadb/0x17a0 kernel/workqueue.c:3319 worker_thread+0x8a0/0xda0 kernel/workqueue.c:3400 kthread+0x70e/0x8a0 kernel/kthread.c:464 ret_from_fork+0x4b/0x80 arch/x86/kernel/process.c:153 ret_from_fork_asm+0x1a/0x30 arch/x86/entry/entry_64.S:245 Freed by task 47: kasan_save_stack mm/kasan/common.c:47 [inline] kasan_save_track+0x3e/0x80 mm/kasan/common.c:68 kasan_save_free_info+0x46/0x50 mm/kasan/generic.c:576 poison_slab_object mm/kasan/common.c:247 [inline] __kasan_slab_free+0x62/0x70 mm/kasan/common.c:264 kasan_slab_free include/linux/kasan.h:233 [inline] slab_free_hook mm/slub.c:2380 [inline] slab_free mm/slub.c:4642 [inline] kmem_cache_free+0x192/0x3f0 mm/slub.c:4744 netlink_broadcast_filtered+0x103c/0x1140 net/netlink/af_netlink.c:1524 nlmsg_multicast_filtered include/net/netlink.h:1129 [inline] nlmsg_multicast include/net/netlink.h:1148 [inline] nlmsg_notify+0xf0/0x1a0 net/netlink/af_netlink.c:2577 fib6_add_rt2node net/ipv6/ip6_fib.c:1259 [inline] fib6_add+0x1d0d/0x4360 net/ipv6/ip6_fib.c:1488 __ip6_ins_rt net/ipv6/route.c:1351 [inline] ip6_ins_rt+0xc8/0x120 net/ipv6/route.c:1361 __ipv6_ifa_notify+0x63f/0xac0 net/ipv6/addrconf.c:6286 ipv6_ifa_notify net/ipv6/addrconf.c:6325 [inline] addrconf_dad_completed+0x180/0xd60 net/ipv6/addrconf.c:4324 addrconf_dad_work+0xc36/0x14b0 net/ipv6/addrconf.c:-1 process_one_work kernel/workqueue.c:3238 [inline] process_scheduled_works+0xadb/0x17a0 kernel/workqueue.c:3319 worker_thread+0x8a0/0xda0 kernel/workqueue.c:3400 kthread+0x70e/0x8a0 kernel/kthread.c:464 ret_from_fork+0x4b/0x80 arch/x86/kernel/process.c:153 ret_from_fork_asm+0x1a/0x30 arch/x86/entry/entry_64.S:245 The buggy address belongs to the object at ffff888052bb6000 which belongs to the cache skbuff_head_cache of size 240 The buggy address is located 192 bytes inside of freed 240-byte region [ffff888052bb6000, ffff888052bb60f0) The buggy address belongs to the physical page: page: refcount:0 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x52bb6 flags: 0x4fff00000000000(node=1|zone=1|lastcpupid=0x7ff) page_type: f5(slab) raw: 04fff00000000000 ffff88801abde8c0 dead000000000122 0000000000000000 raw: 0000000000000000 00000000000c000c 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 0x52820(GFP_ATOMIC|__GFP_NOWARN|__GFP_NORETRY|__GFP_COMP), pid 47, tgid 47 (kworker/u4:3), ts 86158881209, free_ts 0 set_page_owner include/linux/page_owner.h:32 [inline] post_alloc_hook+0x1d8/0x230 mm/page_alloc.c:1714 prep_new_page mm/page_alloc.c:1722 [inline] get_page_from_freelist+0x21ce/0x22b0 mm/page_alloc.c:3684 __alloc_frozen_pages_noprof+0x181/0x370 mm/page_alloc.c:4966 alloc_pages_mpol+0x232/0x4a0 mm/mempolicy.c:2301 alloc_slab_page mm/slub.c:2450 [inline] allocate_slab+0x8a/0x3b0 mm/slub.c:2618 new_slab mm/slub.c:2672 [inline] ___slab_alloc+0xbfc/0x1480 mm/slub.c:3858 __slab_alloc mm/slub.c:3948 [inline] __slab_alloc_node mm/slub.c:4023 [inline] slab_alloc_node mm/slub.c:4184 [inline] kmem_cache_alloc_node_noprof+0x280/0x3c0 mm/slub.c:4248 __alloc_skb+0x112/0x2d0 net/core/skbuff.c:658 alloc_skb include/linux/skbuff.h:1340 [inline] nlmsg_new include/net/netlink.h:1019 [inline] inet6_rt_notify+0xb6/0x240 net/ipv6/route.c:6258 fib6_add_rt2node net/ipv6/ip6_fib.c:1259 [inline] fib6_add+0x1d0d/0x4360 net/ipv6/ip6_fib.c:1488 __ip6_ins_rt net/ipv6/route.c:1351 [inline] ip6_ins_rt+0xc8/0x120 net/ipv6/route.c:1361 __ipv6_ifa_notify+0x63f/0xac0 net/ipv6/addrconf.c:6286 ipv6_ifa_notify net/ipv6/addrconf.c:6325 [inline] addrconf_dad_completed+0x180/0xd60 net/ipv6/addrconf.c:4324 addrconf_dad_work+0xc36/0x14b0 net/ipv6/addrconf.c:-1 process_one_work kernel/workqueue.c:3238 [inline] process_scheduled_works+0xadb/0x17a0 kernel/workqueue.c:3319 worker_thread+0x8a0/0xda0 kernel/workqueue.c:3400 page_owner free stack trace missing Memory state around the buggy address: ffff888052bb5f80: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ffff888052bb6000: fa fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb >ffff888052bb6080: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fc fc ^ ffff888052bb6100: fc fc fc fc fc fc fc fc fa fb fb fb fb fb fb fb ffff888052bb6180: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb ==================================================================