Hay
Date
July 4, 2025, 11:11 p.m.

Environment
qemu-x86_64

[   13.955397] ==================================================================
[   13.956077] BUG: KASAN: slab-use-after-free in kasan_strings+0xcbc/0xe80
[   13.956520] Read of size 1 at addr ffff888103994910 by task kunit_try_catch/276
[   13.956747] 
[   13.956847] CPU: 1 UID: 0 PID: 276 Comm: kunit_try_catch Tainted: G    B            N  6.16.0-rc4 #1 PREEMPT(voluntary) 
[   13.956898] Tainted: [B]=BAD_PAGE, [N]=TEST
[   13.956910] Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.16.3-debian-1.16.3-2 04/01/2014
[   13.956936] Call Trace:
[   13.956957]  <TASK>
[   13.956979]  dump_stack_lvl+0x73/0xb0
[   13.957010]  print_report+0xd1/0x650
[   13.957043]  ? __virt_addr_valid+0x1db/0x2d0
[   13.957066]  ? kasan_strings+0xcbc/0xe80
[   13.957087]  ? kasan_complete_mode_report_info+0x64/0x200
[   13.957109]  ? kasan_strings+0xcbc/0xe80
[   13.957129]  kasan_report+0x141/0x180
[   13.957150]  ? kasan_strings+0xcbc/0xe80
[   13.957174]  __asan_report_load1_noabort+0x18/0x20
[   13.957198]  kasan_strings+0xcbc/0xe80
[   13.957216]  ? trace_hardirqs_on+0x37/0xe0
[   13.957252]  ? __pfx_kasan_strings+0x10/0x10
[   13.957587]  ? finish_task_switch.isra.0+0x153/0x700
[   13.957621]  ? __switch_to+0x47/0xf50
[   13.957649]  ? __schedule+0x10cc/0x2b60
[   13.957672]  ? __pfx_read_tsc+0x10/0x10
[   13.957694]  ? ktime_get_ts64+0x86/0x230
[   13.957717]  kunit_try_run_case+0x1a5/0x480
[   13.957743]  ? __pfx_kunit_try_run_case+0x10/0x10
[   13.957764]  ? _raw_spin_lock_irqsave+0xa1/0x100
[   13.957788]  ? _raw_spin_unlock_irqrestore+0x5f/0x90
[   13.957810]  ? __kthread_parkme+0x82/0x180
[   13.957830]  ? preempt_count_sub+0x50/0x80
[   13.957852]  ? __pfx_kunit_try_run_case+0x10/0x10
[   13.957875]  kunit_generic_run_threadfn_adapter+0x85/0xf0
[   13.957897]  ? __pfx_kunit_generic_run_threadfn_adapter+0x10/0x10
[   13.957920]  kthread+0x337/0x6f0
[   13.957939]  ? trace_preempt_on+0x20/0xc0
[   13.957961]  ? __pfx_kthread+0x10/0x10
[   13.957981]  ? _raw_spin_unlock_irq+0x47/0x80
[   13.958001]  ? calculate_sigpending+0x7b/0xa0
[   13.958025]  ? __pfx_kthread+0x10/0x10
[   13.958046]  ret_from_fork+0x116/0x1d0
[   13.958063]  ? __pfx_kthread+0x10/0x10
[   13.958082]  ret_from_fork_asm+0x1a/0x30
[   13.958113]  </TASK>
[   13.958124] 
[   13.973732] Allocated by task 276:
[   13.974042]  kasan_save_stack+0x45/0x70
[   13.974433]  kasan_save_track+0x18/0x40
[   13.974817]  kasan_save_alloc_info+0x3b/0x50
[   13.975280]  __kasan_kmalloc+0xb7/0xc0
[   13.975577]  __kmalloc_cache_noprof+0x189/0x420
[   13.975735]  kasan_strings+0xc0/0xe80
[   13.975866]  kunit_try_run_case+0x1a5/0x480
[   13.976013]  kunit_generic_run_threadfn_adapter+0x85/0xf0
[   13.976186]  kthread+0x337/0x6f0
[   13.976607]  ret_from_fork+0x116/0x1d0
[   13.976948]  ret_from_fork_asm+0x1a/0x30
[   13.977368] 
[   13.977876] Freed by task 276:
[   13.978178]  kasan_save_stack+0x45/0x70
[   13.978627]  kasan_save_track+0x18/0x40
[   13.978977]  kasan_save_free_info+0x3f/0x60
[   13.979399]  __kasan_slab_free+0x56/0x70
[   13.979846]  kfree+0x222/0x3f0
[   13.980270]  kasan_strings+0x2aa/0xe80
[   13.980617]  kunit_try_run_case+0x1a5/0x480
[   13.980944]  kunit_generic_run_threadfn_adapter+0x85/0xf0
[   13.981121]  kthread+0x337/0x6f0
[   13.981595]  ret_from_fork+0x116/0x1d0
[   13.981968]  ret_from_fork_asm+0x1a/0x30
[   13.982377] 
[   13.982631] The buggy address belongs to the object at ffff888103994900
[   13.982631]  which belongs to the cache kmalloc-32 of size 32
[   13.983764] The buggy address is located 16 bytes inside of
[   13.983764]  freed 32-byte region [ffff888103994900, ffff888103994920)
[   13.984195] 
[   13.984382] The buggy address belongs to the physical page:
[   13.984950] page: refcount:0 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x103994
[   13.986060] flags: 0x200000000000000(node=0|zone=2)
[   13.986794] page_type: f5(slab)
[   13.986928] raw: 0200000000000000 ffff888100041780 dead000000000122 0000000000000000
[   13.987164] raw: 0000000000000000 0000000080400040 00000000f5000000 0000000000000000
[   13.987432] page dumped because: kasan: bad access detected
[   13.987913] 
[   13.988004] Memory state around the buggy address:
[   13.988178]  ffff888103994800: fa fb fb fb fc fc fc fc 00 00 00 fc fc fc fc fc
[   13.988581]  ffff888103994880: 00 00 00 fc fc fc fc fc 00 00 07 fc fc fc fc fc
[   13.988838] >ffff888103994900: fa fb fb fb fc fc fc fc fa fb fb fb fc fc fc fc
[   13.989167]                          ^
[   13.989609]  ffff888103994980: fa fb fb fb fc fc fc fc 00 00 00 fc fc fc fc fc
[   13.989924]  ffff888103994a00: fa fb fb fb fc fc fc fc fa fb fb fb fc fc fc fc
[   13.990164] ==================================================================