================================================================== BUG: KASAN: use-after-free in cleancache_fs_enabled_mapping include/linux/cleancache.h:56 [inline] BUG: KASAN: use-after-free in cleancache_invalidate_page include/linux/cleancache.h:110 [inline] BUG: KASAN: use-after-free in unaccount_page_cache_page+0x6f2/0x760 mm/filemap.c:172 Read of size 4 at addr ffff88811a399470 by task syz.7.4164/14607 CPU: 0 PID: 14607 Comm: syz.7.4164 Not tainted syzkaller #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 10/25/2025 Call Trace: __dump_stack+0x21/0x30 lib/dump_stack.c:88 dump_stack_lvl+0x110/0x170 lib/dump_stack.c:106 print_address_description+0x7f/0x2c0 mm/kasan/report.c:248 __kasan_report mm/kasan/report.c:427 [inline] kasan_report+0xf1/0x140 mm/kasan/report.c:444 __asan_report_load4_noabort+0x14/0x20 mm/kasan/report_generic.c:308 cleancache_fs_enabled_mapping include/linux/cleancache.h:56 [inline] cleancache_invalidate_page include/linux/cleancache.h:110 [inline] unaccount_page_cache_page+0x6f2/0x760 mm/filemap.c:172 __delete_from_page_cache+0xbe/0x470 mm/filemap.c:240 __remove_mapping+0x80a/0x980 mm/vmscan.c:1216 shrink_page_list+0x24fc/0x5540 mm/vmscan.c:1824 shrink_inactive_list mm/vmscan.c:2331 [inline] shrink_list mm/vmscan.c:2576 [inline] shrink_lruvec+0x1209/0x39a0 mm/vmscan.c:5793 shrink_node_memcgs mm/vmscan.c:5985 [inline] shrink_node+0x1205/0x2aa0 mm/vmscan.c:6015 shrink_zones mm/vmscan.c:6221 [inline] do_try_to_free_pages+0x5a8/0x1580 mm/vmscan.c:6279 try_to_free_mem_cgroup_pages+0x261/0x610 mm/vmscan.c:6593 try_charge_memcg+0x3f8/0x14b0 mm/memcontrol.c:2713 try_charge mm/memcontrol.c:2838 [inline] charge_memcg+0x6d/0x1a0 mm/memcontrol.c:6861 __mem_cgroup_charge+0x93/0x280 mm/memcontrol.c:6898 mem_cgroup_charge include/linux/memcontrol.h:715 [inline] shmem_add_to_page_cache+0x64b/0xc50 mm/shmem.c:723 shmem_getpage_gfp+0x116a/0x2310 mm/shmem.c:1946 shmem_getpage mm/shmem.c:156 [inline] shmem_write_begin+0xce/0x1b0 mm/shmem.c:2480 generic_perform_write+0x2b7/0x690 mm/filemap.c:3870 __generic_file_write_iter+0x268/0x480 mm/filemap.c:3998 generic_file_write_iter+0xa9/0x1d0 mm/filemap.c:4030 __kernel_write+0x510/0x950 fs/read_write.c:539 __dump_emit+0x246/0x370 fs/coredump.c:880 dump_emit+0x383/0x3f0 fs/coredump.c:917 dump_user_range+0x86/0x1c0 fs/coredump.c:954 elf_core_dump+0x2a8f/0x2fd0 fs/binfmt_elf.c:2285 do_coredump+0x1452/0x2950 fs/coredump.c:831 get_signal+0x38d/0x1480 kernel/signal.c:2893 arch_do_signal_or_restart+0xdf/0x11c0 arch/x86/kernel/signal.c:867 handle_signal_work kernel/entry/common.c:154 [inline] exit_to_user_mode_loop+0xa7/0xe0 kernel/entry/common.c:178 exit_to_user_mode_prepare+0x87/0xd0 kernel/entry/common.c:214 irqentry_exit_to_user_mode+0x9/0x10 kernel/entry/common.c:320 irqentry_exit+0x12/0x40 kernel/entry/common.c:411 exc_page_fault+0x5e/0xb0 arch/x86/mm/fault.c:1568 asm_exc_page_fault+0x27/0x30 arch/x86/include/asm/idtentry.h:606 RIP: 0033:0x7f5220a76cc1 Code: 00 00 00 00 0f 1f 44 00 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 48 c7 c1 e8 ff ff ff f7 d8 64 89 01 48 83 c8 ff c3 66 2e 0f 1f RSP: 002b:fffffffffffffef0 EFLAGS: 00010217 RAX: 0000000000000000 RBX: 00007f5220cf2090 RCX: 00007f5220a76cb9 RDX: 0000000000000000 RSI: fffffffffffffef0 RDI: 0000000000a00200 RBP: 00007f5220ae4bf7 R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000206 R12: 0000000000000000 R13: 00007f5220cf2128 R14: 00007f5220cf2090 R15: 00007ffd6d672fe8 Allocated by task 14471: kasan_save_stack mm/kasan/common.c:38 [inline] kasan_set_track mm/kasan/common.c:45 [inline] set_alloc_info mm/kasan/common.c:433 [inline] ____kasan_kmalloc mm/kasan/common.c:512 [inline] __kasan_kmalloc+0xda/0x110 mm/kasan/common.c:521 kasan_kmalloc include/linux/kasan.h:227 [inline] kmem_cache_alloc_trace+0x119/0x270 mm/slub.c:3274 kmalloc include/linux/slab.h:619 [inline] kzalloc include/linux/slab.h:750 [inline] alloc_super+0x5e/0x7f0 fs/super.c:203 sget+0x1e4/0x4c0 fs/super.c:637 mount_bdev+0xf6/0x3e0 fs/super.c:1373 f2fs_mount+0x34/0x40 fs/f2fs/super.c:4705 legacy_get_tree+0xed/0x190 fs/fs_context.c:611 vfs_get_tree+0x89/0x260 fs/super.c:1530 do_new_mount+0x25a/0xa20 fs/namespace.c:3034 path_mount+0x659/0xff0 fs/namespace.c:3364 do_mount fs/namespace.c:3377 [inline] __do_sys_mount fs/namespace.c:3585 [inline] __se_sys_mount+0x320/0x390 fs/namespace.c:3562 __x64_sys_mount+0xbf/0xd0 fs/namespace.c:3562 x64_sys_call+0x6bf/0x9a0 arch/x86/include/generated/asm/syscalls_64.h:166 do_syscall_x64 arch/x86/entry/common.c:50 [inline] do_syscall_64+0x4c/0xa0 arch/x86/entry/common.c:80 entry_SYSCALL_64_after_hwframe+0x66/0xd0 Freed by task 381: kasan_save_stack mm/kasan/common.c:38 [inline] kasan_set_track+0x4a/0x70 mm/kasan/common.c:45 kasan_set_free_info+0x23/0x40 mm/kasan/generic.c:370 ____kasan_slab_free+0x125/0x160 mm/kasan/common.c:365 __kasan_slab_free+0x11/0x20 mm/kasan/common.c:373 kasan_slab_free include/linux/kasan.h:193 [inline] slab_free_hook mm/slub.c:1728 [inline] slab_free_freelist_hook+0xc2/0x190 mm/slub.c:1754 slab_free mm/slub.c:3526 [inline] kfree+0xc4/0x270 mm/slub.c:4588 destroy_super_work+0x40/0x50 fs/super.c:165 process_one_work+0x6be/0xba0 kernel/workqueue.c:2325 worker_thread+0xa59/0x1200 kernel/workqueue.c:2472 kthread+0x411/0x500 kernel/kthread.c:337 ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:287 Last potentially related work creation: kasan_save_stack+0x3a/0x60 mm/kasan/common.c:38 __kasan_record_aux_stack+0xd2/0x100 mm/kasan/generic.c:348 kasan_record_aux_stack_noalloc+0xb/0x10 mm/kasan/generic.c:358 insert_work+0x51/0x310 kernel/workqueue.c:1373 __queue_work+0x8e5/0xc60 kernel/workqueue.c:1539 queue_work_on+0xde/0x150 kernel/workqueue.c:1566 queue_work include/linux/workqueue.h:510 [inline] schedule_work include/linux/workqueue.h:571 [inline] destroy_super_rcu+0xd1/0xe0 fs/super.c:172 rcu_do_batch+0x532/0xbe0 kernel/rcu/tree.c:2523 rcu_core+0x5ee/0xf80 kernel/rcu/tree.c:2763 rcu_core_si+0x9/0x10 kernel/rcu/tree.c:2776 handle_softirqs+0x250/0x560 kernel/softirq.c:583 __do_softirq kernel/softirq.c:621 [inline] invoke_softirq kernel/softirq.c:443 [inline] __irq_exit_rcu+0x52/0xf0 kernel/softirq.c:670 irq_exit_rcu+0x9/0x10 kernel/softirq.c:682 instr_sysvec_apic_timer_interrupt arch/x86/kernel/apic/apic.c:1108 [inline] sysvec_apic_timer_interrupt+0xa9/0xc0 arch/x86/kernel/apic/apic.c:1108 asm_sysvec_apic_timer_interrupt+0x1b/0x20 arch/x86/include/asm/idtentry.h:676 Second to last potentially related work creation: kasan_save_stack+0x3a/0x60 mm/kasan/common.c:38 __kasan_record_aux_stack+0xd2/0x100 mm/kasan/generic.c:348 kasan_record_aux_stack_noalloc+0xb/0x10 mm/kasan/generic.c:358 __call_rcu_common kernel/rcu/tree.c:3011 [inline] call_rcu+0x10b/0xf80 kernel/rcu/tree.c:3129 __put_super+0x26b/0x2d0 fs/super.c:299 put_super fs/super.c:313 [inline] deactivate_locked_super+0xd4/0x100 fs/super.c:346 mount_bdev+0x2cc/0x3e0 fs/super.c:1402 f2fs_mount+0x34/0x40 fs/f2fs/super.c:4705 legacy_get_tree+0xed/0x190 fs/fs_context.c:611 vfs_get_tree+0x89/0x260 fs/super.c:1530 do_new_mount+0x25a/0xa20 fs/namespace.c:3034 path_mount+0x659/0xff0 fs/namespace.c:3364 do_mount fs/namespace.c:3377 [inline] __do_sys_mount fs/namespace.c:3585 [inline] __se_sys_mount+0x320/0x390 fs/namespace.c:3562 __x64_sys_mount+0xbf/0xd0 fs/namespace.c:3562 x64_sys_call+0x6bf/0x9a0 arch/x86/include/generated/asm/syscalls_64.h:166 do_syscall_x64 arch/x86/entry/common.c:50 [inline] do_syscall_64+0x4c/0xa0 arch/x86/entry/common.c:80 entry_SYSCALL_64_after_hwframe+0x66/0xd0 The buggy address belongs to the object at ffff88811a399000 which belongs to the cache kmalloc-2k of size 2048 The buggy address is located 1136 bytes inside of 2048-byte region [ffff88811a399000, ffff88811a399800) The buggy address belongs to the page: page:ffffea000468e600 refcount:1 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x11a398 head:ffffea000468e600 order:3 compound_mapcount:0 compound_pincount:0 flags: 0x4000000000010200(slab|head|zone=1) raw: 4000000000010200 0000000000000000 0000000100000001 ffff888100043200 raw: 0000000000000000 0000000000080008 00000001ffffffff 0000000000000000 page dumped because: kasan: bad access detected page_owner tracks the page as allocated page last allocated via order 3, migratetype Unmovable, gfp_mask 0x1d20c0(__GFP_IO|__GFP_FS|__GFP_NOWARN|__GFP_NORETRY|__GFP_COMP|__GFP_NOMEMALLOC|__GFP_HARDWALL), pid 4885, ts 189542092455, free_ts 189048606790 set_page_owner include/linux/page_owner.h:33 [inline] post_alloc_hook+0x192/0x1b0 mm/page_alloc.c:2605 prep_new_page+0x1c/0x110 mm/page_alloc.c:2611 get_page_from_freelist+0x2d3a/0x2dc0 mm/page_alloc.c:4485 __alloc_pages+0x1a2/0x460 mm/page_alloc.c:5808 alloc_slab_page mm/slub.c:-1 [inline] allocate_slab mm/slub.c:1937 [inline] new_slab+0xa1/0x4d0 mm/slub.c:2000 ___slab_alloc+0x381/0x810 mm/slub.c:3033 __slab_alloc+0x49/0x90 mm/slub.c:3120 slab_alloc_node mm/slub.c:3211 [inline] slab_alloc mm/slub.c:3255 [inline] __kmalloc_track_caller+0x169/0x2c0 mm/slub.c:4954 kmemdup+0x26/0x60 mm/util.c:132 neigh_sysctl_register+0xbe/0xa90 net/core/neighbour.c:3652 devinet_sysctl_register+0xaf/0x1e0 net/ipv4/devinet.c:2641 inetdev_init+0x2b9/0x500 net/ipv4/devinet.c:284 inetdev_event+0x1f7/0x10a0 net/ipv4/devinet.c:1544 notifier_call_chain kernel/notifier.c:83 [inline] raw_notifier_call_chain+0x90/0x100 kernel/notifier.c:391 call_netdevice_notifiers_info net/core/dev.c:2057 [inline] call_netdevice_notifiers_extack net/core/dev.c:2069 [inline] call_netdevice_notifiers+0x119/0x190 net/core/dev.c:2083 register_netdevice+0x10e5/0x1460 net/core/dev.c:10436 page last free stack trace: reset_page_owner include/linux/page_owner.h:26 [inline] free_pages_prepare mm/page_alloc.c:1472 [inline] free_pcp_prepare mm/page_alloc.c:1544 [inline] free_unref_page_prepare+0x542/0x550 mm/page_alloc.c:3534 free_unref_page+0xae/0x540 mm/page_alloc.c:3616 free_the_page mm/page_alloc.c:805 [inline] free_compound_page+0x78/0xa0 mm/page_alloc.c:828 destroy_compound_page include/linux/mm.h:1000 [inline] __put_compound_page+0x77/0xb0 mm/swap.c:111 __put_page+0xbc/0xe0 mm/swap.c:127 put_page include/linux/mm.h:1306 [inline] __skb_frag_unref include/linux/skbuff.h:3275 [inline] skb_release_data+0x3d3/0xa10 net/core/skbuff.c:673 skb_release_all net/core/skbuff.c:743 [inline] __kfree_skb+0x50/0x70 net/core/skbuff.c:757 sk_eat_skb include/net/sock.h:2799 [inline] tcp_recvmsg_locked+0x14cd/0x26f0 net/ipv4/tcp.c:2517 tcp_recvmsg+0x23c/0x770 net/ipv4/tcp.c:2563 inet_recvmsg+0x13a/0x480 net/ipv4/af_inet.c:861 sock_recvmsg_nosec net/socket.c:966 [inline] sock_recvmsg net/socket.c:984 [inline] sock_read_iter+0x2b8/0x380 net/socket.c:1057 call_read_iter include/linux/fs.h:2206 [inline] new_sync_read fs/read_write.c:404 [inline] vfs_read+0x6c9/0xc40 fs/read_write.c:485 ksys_read+0x149/0x250 fs/read_write.c:623 __do_sys_read fs/read_write.c:633 [inline] __se_sys_read fs/read_write.c:631 [inline] __x64_sys_read+0x7b/0x90 fs/read_write.c:631 x64_sys_call+0x96d/0x9a0 arch/x86/include/generated/asm/syscalls_64.h:1 do_syscall_x64 arch/x86/entry/common.c:50 [inline] do_syscall_64+0x4c/0xa0 arch/x86/entry/common.c:80 Memory state around the buggy address: ffff88811a399300: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb ffff88811a399380: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb >ffff88811a399400: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb ^ ffff88811a399480: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb ffff88811a399500: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb ================================================================== syz.7.4164 invoked oom-killer: gfp_mask=0xcc0(GFP_KERNEL), order=0, oom_score_adj=1000 CPU: 1 PID: 14607 Comm: syz.7.4164 Tainted: G B syzkaller #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 10/25/2025 Call Trace: __dump_stack+0x21/0x30 lib/dump_stack.c:88 dump_stack_lvl+0x110/0x170 lib/dump_stack.c:106 dump_stack+0x15/0x20 lib/dump_stack.c:113 dump_header+0xdd/0x650 mm/oom_kill.c:473 oom_kill_process+0x1fa/0x2c0 mm/oom_kill.c:1040 out_of_memory+0x64f/0x9d0 mm/oom_kill.c:1183 mem_cgroup_out_of_memory+0x2bb/0x3b0 mm/memcontrol.c:1705 mem_cgroup_oom mm/memcontrol.c:1940 [inline] try_charge_memcg+0xed4/0x14b0 mm/memcontrol.c:2761 try_charge mm/memcontrol.c:2838 [inline] charge_memcg+0x6d/0x1a0 mm/memcontrol.c:6861 __mem_cgroup_charge+0x93/0x280 mm/memcontrol.c:6898 mem_cgroup_charge include/linux/memcontrol.h:715 [inline] shmem_add_to_page_cache+0x64b/0xc50 mm/shmem.c:723 shmem_getpage_gfp+0x116a/0x2310 mm/shmem.c:1946 shmem_getpage mm/shmem.c:156 [inline] shmem_write_begin+0xce/0x1b0 mm/shmem.c:2480 generic_perform_write+0x2b7/0x690 mm/filemap.c:3870 __generic_file_write_iter+0x268/0x480 mm/filemap.c:3998 generic_file_write_iter+0xa9/0x1d0 mm/filemap.c:4030 __kernel_write+0x510/0x950 fs/read_write.c:539 __dump_emit+0x246/0x370 fs/coredump.c:880 dump_emit+0x383/0x3f0 fs/coredump.c:917 dump_user_range+0x86/0x1c0 fs/coredump.c:954 elf_core_dump+0x2a8f/0x2fd0 fs/binfmt_elf.c:2285 do_coredump+0x1452/0x2950 fs/coredump.c:831 get_signal+0x38d/0x1480 kernel/signal.c:2893 arch_do_signal_or_restart+0xdf/0x11c0 arch/x86/kernel/signal.c:867 handle_signal_work kernel/entry/common.c:154 [inline] exit_to_user_mode_loop+0xa7/0xe0 kernel/entry/common.c:178 exit_to_user_mode_prepare+0x87/0xd0 kernel/entry/common.c:214 irqentry_exit_to_user_mode+0x9/0x10 kernel/entry/common.c:320 irqentry_exit+0x12/0x40 kernel/entry/common.c:411 exc_page_fault+0x5e/0xb0 arch/x86/mm/fault.c:1568 asm_exc_page_fault+0x27/0x30 arch/x86/include/asm/idtentry.h:606 RIP: 0033:0x7f5220a76cc1 Code: 00 00 00 00 0f 1f 44 00 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 48 c7 c1 e8 ff ff ff f7 d8 64 89 01 48 83 c8 ff c3 66 2e 0f 1f RSP: 002b:fffffffffffffef0 EFLAGS: 00010217 RAX: 0000000000000000 RBX: 00007f5220cf2090 RCX: 00007f5220a76cb9 RDX: 0000000000000000 RSI: fffffffffffffef0 RDI: 0000000000a00200 RBP: 00007f5220ae4bf7 R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000206 R12: 0000000000000000 R13: 00007f5220cf2128 R14: 00007f5220cf2090 R15: 00007ffd6d672fe8 memory: usage 300196kB, limit 307200kB, failcnt 10621 memory+swap: usage 416408kB, limit 9007199254740988kB, failcnt 0 kmem: usage 0kB, limit 9007199254740988kB, failcnt 0 Memory cgroup stats for /syz7: anon 245760 file 302309376 kernel_stack 0 pagetables 0 percpu 0 sock 0 shmem 302268416 file_mapped 0 file_dirty 0 file_writeback 520192 swapcached 133435392 anon_thp 0 file_thp 0 shmem_thp 0 inactive_anon 307703808 active_anon 933888 inactive_file 20480 active_file 0 unevictable 0 slab_reclaimable 0 slab_unreclaimable 0 slab 0 workingset_refault_anon 238 workingset_refault_file 0 workingset_activate_anon 222 oom-kill:constraint=CONSTRAINT_MEMCG,nodemask=(null),cpuset=syz7,mems_allowed=0,oom_memcg=/syz7,task_memcg=/syz7,task=syz.7.4164,pid=14605,uid=0 Memory cgroup out of memory: Killed process 14605 (syz.7.4164) total-vm:90280kB, anon-rss:1224kB, file-rss:54208kB, shmem-rss:0kB, UID:0 pgtables:200kB oom_score_adj:1000