RBP: 00007ff6f93a61d0 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000001
R13: 00007fffadc22bef R14: 00007ff6f93a6300 R15: 0000000000022000
==================================================================
BUG: KASAN: slab-use-after-free in flush_tlb_func+0x24d/0x560
Write of size 8 at addr ffff8880154e7a40 by task swapper/1/0
CPU: 1 UID: 0 PID: 0 Comm: swapper/1 Not tainted 6.16.0-rc4-next-20250630 #1 PREEMPT(voluntary)
Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS 1.12.0-1 04/01/2014
Call Trace:
dump_stack_lvl+0xca/0x120
print_report+0xcb/0x670
kasan_report+0xca/0x100
kasan_check_range+0x39/0x1b0
flush_tlb_func+0x24d/0x560
__flush_smp_call_function_queue+0x20d/0x740
__sysvec_call_function_single+0x6d/0x360
sysvec_call_function_single+0xa1/0xc0
asm_sysvec_call_function_single+0x1a/0x20
RIP: 0010:pv_native_safe_halt+0x1e/0x30
Code: 90 90 90 90 90 90 90 90 90 90 90 90 f3 0f 1e fa 0f 1f 44 00 00 eb 0c 0f 1f 44 00 00 0f 00 2d 89 34 0d 00 0f 1f 44 00 00 fb f4 7d 6d 02 00 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 00 90 90 90 90
RSP: 0018:ffff888009717e58 EFLAGS: 00000202
RAX: 00000000008a3cfb RBX: 0000000000000001 RCX: ffffffff84b84987
RDX: 0000000000000000 RSI: 0000000000000000 RDI: ffffffff814c6b04
RBP: dffffc0000000000 R08: 0000000000000001 R09: ffffed100d9e630a
R10: ffff88806cf31853 R11: 0000000000000001 R12: ffffffff86438650
R13: 1ffff110012e2fd2 R14: 0000000000000000 R15: 0000000000000000
default_idle+0xe/0x20
default_idle_call+0x6d/0xb0
do_idle+0x344/0x490
cpu_startup_entry+0x4f/0x60
start_secondary+0x1bd/0x210
common_startup_64+0x13e/0x148
Allocated by task 13553:
kasan_save_stack+0x24/0x50
kasan_save_track+0x14/0x30
__kasan_slab_alloc+0x59/0x70
kmem_cache_alloc_noprof+0x13c/0x470
mm_alloc+0x1d/0xd0
alloc_bprm+0x2e3/0x6e0
do_execveat_common+0x235/0x770
__x64_sys_execve+0x95/0xc0
do_syscall_64+0xbf/0x360
entry_SYSCALL_64_after_hwframe+0x77/0x7f
Freed by task 259:
kasan_save_stack+0x24/0x50
kasan_save_track+0x14/0x30
kasan_save_free_info+0x3a/0x60
__kasan_slab_free+0x38/0x50
kmem_cache_free+0x2a1/0x460
finish_task_switch.isra.0+0x478/0x840
__schedule+0xe4e/0x3520
schedule+0xdb/0x390
schedule_hrtimeout_range_clock+0x11f/0x310
do_epoll_wait+0xca8/0xf00
do_compat_epoll_pwait.part.0+0x29/0x1d0
__x64_sys_epoll_pwait+0x1de/0x320
do_syscall_64+0xbf/0x360
entry_SYSCALL_64_after_hwframe+0x77/0x7f
The buggy address belongs to the object at ffff8880154e70c0
which belongs to the cache mm_struct of size 2456
The buggy address is located 2432 bytes inside of
freed 2456-byte region [ffff8880154e70c0, ffff8880154e7a58)
The buggy address belongs to the physical page:
page: refcount:0 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x154e0
head: order:3 mapcount:0 entire_mapcount:0 nr_pages_mapped:0 pincount:0
memcg:ffff88800974a581
flags: 0x100000000000040(head|node=0|zone=1)
page_type: f5(slab)
raw: 0100000000000040 ffff888008c4bc80 dead000000000100 dead000000000122
raw: 0000000000000000 00000000800c000c 00000000f5000000 ffff88800974a581
head: 0100000000000040 ffff888008c4bc80 dead000000000100 dead000000000122
head: 0000000000000000 00000000800c000c 00000000f5000000 ffff88800974a581
head: 0100000000000003 ffffea0000553801 00000000ffffffff 00000000ffffffff
head: 0000000000000000 0000000000000000 00000000ffffffff 0000000000000008
page dumped because: kasan: bad access detected
Memory state around the buggy address:
ffff8880154e7900: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb
ffff8880154e7980: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb
>ffff8880154e7a00: fb fb fb fb fb fb fb fb fb fb fb fc fc fc fc fc
^
ffff8880154e7a80: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc
ffff8880154e7b00: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc
==================================================================
----------------
Code disassembly (best guess):
0: 90 nop
1: 90 nop
2: 90 nop
3: 90 nop
4: 90 nop
5: 90 nop
6: 90 nop
7: 90 nop
8: 90 nop
9: 90 nop
a: 90 nop
b: 90 nop
c: f3 0f 1e fa endbr64
10: 0f 1f 44 00 00 nopl 0x0(%rax,%rax,1)
15: eb 0c jmp 0x23
17: 0f 1f 44 00 00 nopl 0x0(%rax,%rax,1)
1c: 0f 00 2d 89 34 0d 00 verw 0xd3489(%rip) # 0xd34ac
23: 0f 1f 44 00 00 nopl 0x0(%rax,%rax,1)
28: fb sti
29: f4 hlt
* 2a: e9 7d 6d 02 00 jmpq 0x26dac <-- trapping instruction
2f: 66 2e 0f 1f 84 00 00 nopw %cs:0x0(%rax,%rax,1)
36: 00 00 00
39: 0f 1f 00 nopl (%rax)
3c: 90 nop
3d: 90 nop
3e: 90 nop
3f: 90 nop