Hay
Date
July 11, 2025, 10:11 a.m.

Environment
e850-96
qemu-x86_64

[   57.612515] ==================================================================
[   57.619506] BUG: KASAN: slab-use-after-free in kasan_strings+0x95c/0xb00
[   57.626183] Read of size 1 at addr ffff0008016ffe10 by task kunit_try_catch/343
[   57.633475] 
[   57.634960] CPU: 5 UID: 0 PID: 343 Comm: kunit_try_catch Tainted: G    B            N  6.16.0-rc5-next-20250711 #1 PREEMPT 
[   57.635017] Tainted: [B]=BAD_PAGE, [N]=TEST
[   57.635035] Hardware name: WinLink E850-96 board (DT)
[   57.635061] Call trace:
[   57.635074]  show_stack+0x20/0x38 (C)
[   57.635111]  dump_stack_lvl+0x8c/0xd0
[   57.635146]  print_report+0x118/0x5d0
[   57.635174]  kasan_report+0xdc/0x128
[   57.635200]  __asan_report_load1_noabort+0x20/0x30
[   57.635232]  kasan_strings+0x95c/0xb00
[   57.635261]  kunit_try_run_case+0x170/0x3f0
[   57.635301]  kunit_generic_run_threadfn_adapter+0x88/0x100
[   57.635334]  kthread+0x328/0x630
[   57.635363]  ret_from_fork+0x10/0x20
[   57.635400] 
[   57.698579] Allocated by task 343:
[   57.701966]  kasan_save_stack+0x3c/0x68
[   57.705783]  kasan_save_track+0x20/0x40
[   57.709602]  kasan_save_alloc_info+0x40/0x58
[   57.713856]  __kasan_kmalloc+0xd4/0xd8
[   57.717588]  __kmalloc_cache_noprof+0x16c/0x3c0
[   57.722102]  kasan_strings+0xc8/0xb00
[   57.725748]  kunit_try_run_case+0x170/0x3f0
[   57.729914]  kunit_generic_run_threadfn_adapter+0x88/0x100
[   57.735384]  kthread+0x328/0x630
[   57.738595]  ret_from_fork+0x10/0x20
[   57.742154] 
[   57.743631] Freed by task 343:
[   57.746670]  kasan_save_stack+0x3c/0x68
[   57.750487]  kasan_save_track+0x20/0x40
[   57.754306]  kasan_save_free_info+0x4c/0x78
[   57.758473]  __kasan_slab_free+0x6c/0x98
[   57.762379]  kfree+0x214/0x3c8
[   57.765417]  kasan_strings+0x24c/0xb00
[   57.769151]  kunit_try_run_case+0x170/0x3f0
[   57.773317]  kunit_generic_run_threadfn_adapter+0x88/0x100
[   57.778785]  kthread+0x328/0x630
[   57.781997]  ret_from_fork+0x10/0x20
[   57.785556] 
[   57.787033] The buggy address belongs to the object at ffff0008016ffe00
[   57.787033]  which belongs to the cache kmalloc-32 of size 32
[   57.799358] The buggy address is located 16 bytes inside of
[   57.799358]  freed 32-byte region [ffff0008016ffe00, ffff0008016ffe20)
[   57.811423] 
[   57.812900] The buggy address belongs to the physical page:
[   57.818458] page: refcount:0 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x8816ff
[   57.826443] flags: 0xbfffe0000000000(node=0|zone=2|lastcpupid=0x1ffff)
[   57.832952] page_type: f5(slab)
[   57.836087] raw: 0bfffe0000000000 ffff000800002780 dead000000000100 dead000000000122
[   57.843808] raw: 0000000000000000 0000000000400040 00000000f5000000 0000000000000000
[   57.851529] page dumped because: kasan: bad access detected
[   57.857083] 
[   57.858559] Memory state around the buggy address:
[   57.863338]  ffff0008016ffd00: 00 00 00 00 fc fc fc fc fa fb fb fb fc fc fc fc
[   57.870541]  ffff0008016ffd80: fa fb fb fb fc fc fc fc fa fb fb fb fc fc fc fc
[   57.877747] >ffff0008016ffe00: fa fb fb fb fc fc fc fc fa fb fb fb fc fc fc fc
[   57.884947]                          ^
[   57.888683]  ffff0008016ffe80: fa fb fb fb fc fc fc fc 00 00 00 fc fc fc fc fc
[   57.895888]  ffff0008016fff00: fa fb fb fb fc fc fc fc fa fb fb fb fc fc fc fc
[   57.903089] ==================================================================

[   25.799662] ==================================================================
[   25.800126] BUG: KASAN: slab-use-after-free in kasan_strings+0xcbc/0xe80
[   25.800497] Read of size 1 at addr ffff88810613f2d0 by task kunit_try_catch/309
[   25.800763] 
[   25.800865] CPU: 1 UID: 0 PID: 309 Comm: kunit_try_catch Tainted: G    B            N  6.16.0-rc5-next-20250711 #1 PREEMPT(voluntary) 
[   25.800919] Tainted: [B]=BAD_PAGE, [N]=TEST
[   25.800931] Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.16.3-debian-1.16.3-2 04/01/2014
[   25.800955] Call Trace:
[   25.800968]  <TASK>
[   25.800987]  dump_stack_lvl+0x73/0xb0
[   25.801019]  print_report+0xd1/0x610
[   25.801041]  ? __virt_addr_valid+0x1db/0x2d0
[   25.801067]  ? kasan_strings+0xcbc/0xe80
[   25.801089]  ? kasan_complete_mode_report_info+0x64/0x200
[   25.801115]  ? kasan_strings+0xcbc/0xe80
[   25.801136]  kasan_report+0x141/0x180
[   25.801158]  ? kasan_strings+0xcbc/0xe80
[   25.801183]  __asan_report_load1_noabort+0x18/0x20
[   25.801207]  kasan_strings+0xcbc/0xe80
[   25.801227]  ? trace_hardirqs_on+0x37/0xe0
[   25.801250]  ? __pfx_kasan_strings+0x10/0x10
[   25.801271]  ? finish_task_switch.isra.0+0x153/0x700
[   25.801294]  ? __switch_to+0x47/0xf80
[   25.801322]  ? __schedule+0x10cc/0x2b60
[   25.801347]  ? __pfx_read_tsc+0x10/0x10
[   25.801370]  ? ktime_get_ts64+0x86/0x230
[   25.801394]  kunit_try_run_case+0x1a5/0x480
[   25.801430]  ? __pfx_kunit_try_run_case+0x10/0x10
[   25.801450]  ? _raw_spin_lock_irqsave+0xa1/0x100
[   25.801475]  ? _raw_spin_unlock_irqrestore+0x5f/0x90
[   25.801497]  ? __kthread_parkme+0x82/0x180
[   25.801518]  ? preempt_count_sub+0x50/0x80
[   25.801541]  ? __pfx_kunit_try_run_case+0x10/0x10
[   25.801562]  kunit_generic_run_threadfn_adapter+0x85/0xf0
[   25.801588]  ? __pfx_kunit_generic_run_threadfn_adapter+0x10/0x10
[   25.801613]  kthread+0x337/0x6f0
[   25.801633]  ? trace_preempt_on+0x20/0xc0
[   25.801655]  ? __pfx_kthread+0x10/0x10
[   25.801676]  ? _raw_spin_unlock_irq+0x47/0x80
[   25.801698]  ? calculate_sigpending+0x7b/0xa0
[   25.801723]  ? __pfx_kthread+0x10/0x10
[   25.801759]  ret_from_fork+0x116/0x1d0
[   25.801778]  ? __pfx_kthread+0x10/0x10
[   25.801799]  ret_from_fork_asm+0x1a/0x30
[   25.801830]  </TASK>
[   25.801842] 
[   25.808856] Allocated by task 309:
[   25.809021]  kasan_save_stack+0x45/0x70
[   25.809157]  kasan_save_track+0x18/0x40
[   25.809284]  kasan_save_alloc_info+0x3b/0x50
[   25.809424]  __kasan_kmalloc+0xb7/0xc0
[   25.809598]  __kmalloc_cache_noprof+0x189/0x420
[   25.809822]  kasan_strings+0xc0/0xe80
[   25.810001]  kunit_try_run_case+0x1a5/0x480
[   25.810271]  kunit_generic_run_threadfn_adapter+0x85/0xf0
[   25.810497]  kthread+0x337/0x6f0
[   25.810613]  ret_from_fork+0x116/0x1d0
[   25.810749]  ret_from_fork_asm+0x1a/0x30
[   25.810882] 
[   25.811049] Freed by task 309:
[   25.811202]  kasan_save_stack+0x45/0x70
[   25.811388]  kasan_save_track+0x18/0x40
[   25.811587]  kasan_save_free_info+0x3f/0x60
[   25.811800]  __kasan_slab_free+0x56/0x70
[   25.811989]  kfree+0x222/0x3f0
[   25.812147]  kasan_strings+0x2aa/0xe80
[   25.812301]  kunit_try_run_case+0x1a5/0x480
[   25.812440]  kunit_generic_run_threadfn_adapter+0x85/0xf0
[   25.812607]  kthread+0x337/0x6f0
[   25.812721]  ret_from_fork+0x116/0x1d0
[   25.812854]  ret_from_fork_asm+0x1a/0x30
[   25.813009] 
[   25.813104] The buggy address belongs to the object at ffff88810613f2c0
[   25.813104]  which belongs to the cache kmalloc-32 of size 32
[   25.813613] The buggy address is located 16 bytes inside of
[   25.813613]  freed 32-byte region [ffff88810613f2c0, ffff88810613f2e0)
[   25.814208] 
[   25.814343] The buggy address belongs to the physical page:
[   25.814605] page: refcount:0 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x10613f
[   25.814926] flags: 0x200000000000000(node=0|zone=2)
[   25.815121] page_type: f5(slab)
[   25.815285] raw: 0200000000000000 ffff888100041780 dead000000000122 0000000000000000
[   25.815610] raw: 0000000000000000 0000000080400040 00000000f5000000 0000000000000000
[   25.815839] page dumped because: kasan: bad access detected
[   25.816004] 
[   25.816066] Memory state around the buggy address:
[   25.816213]  ffff88810613f180: 00 00 00 fc fc fc fc fc fa fb fb fb fc fc fc fc
[   25.816608]  ffff88810613f200: fa fb fb fb fc fc fc fc fa fb fb fb fc fc fc fc
[   25.816940] >ffff88810613f280: fa fb fb fb fc fc fc fc fa fb fb fb fc fc fc fc
[   25.817257]                                                  ^
[   25.817630]  ffff88810613f300: fa fb fb fb fc fc fc fc fa fb fb fb fc fc fc fc
[   25.817871]  ffff88810613f380: 00 00 00 fc fc fc fc fc fa fb fb fb fc fc fc fc
[   25.818074] ==================================================================