Hay
Date
July 17, 2025, 10:12 a.m.

Environment
qemu-arm64
qemu-x86_64

[   29.518731] ==================================================================
[   29.518826] BUG: KASAN: slab-out-of-bounds in kmalloc_oob_16+0x3a0/0x3f8
[   29.518882] Write of size 16 at addr fff00000c7ac92e0 by task kunit_try_catch/197
[   29.518930] 
[   29.518981] CPU: 1 UID: 0 PID: 197 Comm: kunit_try_catch Tainted: G    B            N  6.16.0-rc6-next-20250717 #1 PREEMPT 
[   29.519077] Tainted: [B]=BAD_PAGE, [N]=TEST
[   29.519103] Hardware name: linux,dummy-virt (DT)
[   29.519133] Call trace:
[   29.519155]  show_stack+0x20/0x38 (C)
[   29.519218]  dump_stack_lvl+0x8c/0xd0
[   29.519274]  print_report+0x118/0x5d0
[   29.519319]  kasan_report+0xdc/0x128
[   29.519362]  __asan_report_store16_noabort+0x20/0x30
[   29.519410]  kmalloc_oob_16+0x3a0/0x3f8
[   29.519455]  kunit_try_run_case+0x170/0x3f0
[   29.519511]  kunit_generic_run_threadfn_adapter+0x88/0x100
[   29.519576]  kthread+0x328/0x630
[   29.519618]  ret_from_fork+0x10/0x20
[   29.519664] 
[   29.519681] Allocated by task 197:
[   29.519709]  kasan_save_stack+0x3c/0x68
[   29.519746]  kasan_save_track+0x20/0x40
[   29.519780]  kasan_save_alloc_info+0x40/0x58
[   29.519817]  __kasan_kmalloc+0xd4/0xd8
[   29.519850]  __kmalloc_cache_noprof+0x16c/0x3c0
[   29.519898]  kmalloc_oob_16+0xb4/0x3f8
[   29.519934]  kunit_try_run_case+0x170/0x3f0
[   29.519978]  kunit_generic_run_threadfn_adapter+0x88/0x100
[   29.520019]  kthread+0x328/0x630
[   29.520050]  ret_from_fork+0x10/0x20
[   29.520753] 
[   29.520929] The buggy address belongs to the object at fff00000c7ac92e0
[   29.520929]  which belongs to the cache kmalloc-16 of size 16
[   29.521178] The buggy address is located 0 bytes inside of
[   29.521178]  allocated 13-byte region [fff00000c7ac92e0, fff00000c7ac92ed)
[   29.521301] 
[   29.521322] The buggy address belongs to the physical page:
[   29.521369] page: refcount:0 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x107ac9
[   29.521739] flags: 0xbfffe0000000000(node=0|zone=2|lastcpupid=0x1ffff)
[   29.521823] page_type: f5(slab)
[   29.521910] raw: 0bfffe0000000000 fff00000c0001640 dead000000000100 dead000000000122
[   29.521974] raw: 0000000000000000 0000000080800080 00000000f5000000 0000000000000000
[   29.522345] page dumped because: kasan: bad access detected
[   29.522430] 
[   29.522507] Memory state around the buggy address:
[   29.522604]  fff00000c7ac9180: fa fb fc fc fa fb fc fc fa fb fc fc fa fb fc fc
[   29.522656]  fff00000c7ac9200: fa fb fc fc fa fb fc fc fa fb fc fc 00 00 fc fc
[   29.522721] >fff00000c7ac9280: fa fb fc fc fa fb fc fc fa fb fc fc 00 05 fc fc
[   29.523083]                                                           ^
[   29.523179]  fff00000c7ac9300: 00 00 fc fc fc fc fc fc fc fc fc fc fc fc fc fc
[   29.523253]  fff00000c7ac9380: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc
[   29.523527] ==================================================================

[   25.691827] ==================================================================
[   25.692271] BUG: KASAN: slab-out-of-bounds in kmalloc_oob_16+0x452/0x4a0
[   25.692695] Write of size 16 at addr ffff888104561c80 by task kunit_try_catch/215
[   25.692982] 
[   25.693096] CPU: 1 UID: 0 PID: 215 Comm: kunit_try_catch Tainted: G    B            N  6.16.0-rc6-next-20250717 #1 PREEMPT(voluntary) 
[   25.693143] Tainted: [B]=BAD_PAGE, [N]=TEST
[   25.693154] Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.16.3-debian-1.16.3-2 04/01/2014
[   25.693173] Call Trace:
[   25.693185]  <TASK>
[   25.693199]  dump_stack_lvl+0x73/0xb0
[   25.693228]  print_report+0xd1/0x610
[   25.693249]  ? __virt_addr_valid+0x1db/0x2d0
[   25.693272]  ? kmalloc_oob_16+0x452/0x4a0
[   25.693291]  ? kasan_complete_mode_report_info+0x2a/0x200
[   25.693316]  ? kmalloc_oob_16+0x452/0x4a0
[   25.693402]  kasan_report+0x141/0x180
[   25.693423]  ? kmalloc_oob_16+0x452/0x4a0
[   25.693448]  __asan_report_store16_noabort+0x1b/0x30
[   25.693472]  kmalloc_oob_16+0x452/0x4a0
[   25.693492]  ? __pfx_kmalloc_oob_16+0x10/0x10
[   25.693521]  ? __schedule+0x10c6/0x2b60
[   25.693544]  ? __pfx_read_tsc+0x10/0x10
[   25.693564]  ? ktime_get_ts64+0x86/0x230
[   25.693587]  kunit_try_run_case+0x1a5/0x480
[   25.693610]  ? __pfx_kunit_try_run_case+0x10/0x10
[   25.693631]  ? _raw_spin_lock_irqsave+0xa1/0x100
[   25.693652]  ? _raw_spin_unlock_irqrestore+0x5f/0x90
[   25.693674]  ? __kthread_parkme+0x82/0x180
[   25.693697]  ? preempt_count_sub+0x50/0x80
[   25.693720]  ? __pfx_kunit_try_run_case+0x10/0x10
[   25.693742]  kunit_generic_run_threadfn_adapter+0x85/0xf0
[   25.693764]  ? __pfx_kunit_generic_run_threadfn_adapter+0x10/0x10
[   25.693787]  kthread+0x337/0x6f0
[   25.693805]  ? trace_preempt_on+0x20/0xc0
[   25.693828]  ? __pfx_kthread+0x10/0x10
[   25.693848]  ? _raw_spin_unlock_irq+0x47/0x80
[   25.693869]  ? calculate_sigpending+0x7b/0xa0
[   25.693891]  ? __pfx_kthread+0x10/0x10
[   25.693911]  ret_from_fork+0x116/0x1d0
[   25.693936]  ? __pfx_kthread+0x10/0x10
[   25.693955]  ret_from_fork_asm+0x1a/0x30
[   25.693986]  </TASK>
[   25.693995] 
[   25.700896] Allocated by task 215:
[   25.701044]  kasan_save_stack+0x45/0x70
[   25.701251]  kasan_save_track+0x18/0x40
[   25.701417]  kasan_save_alloc_info+0x3b/0x50
[   25.701557]  __kasan_kmalloc+0xb7/0xc0
[   25.701680]  __kmalloc_cache_noprof+0x189/0x420
[   25.701825]  kmalloc_oob_16+0xa8/0x4a0
[   25.701981]  kunit_try_run_case+0x1a5/0x480
[   25.702189]  kunit_generic_run_threadfn_adapter+0x85/0xf0
[   25.702426]  kthread+0x337/0x6f0
[   25.702585]  ret_from_fork+0x116/0x1d0
[   25.702762]  ret_from_fork_asm+0x1a/0x30
[   25.702904] 
[   25.702967] The buggy address belongs to the object at ffff888104561c80
[   25.702967]  which belongs to the cache kmalloc-16 of size 16
[   25.703417] The buggy address is located 0 bytes inside of
[   25.703417]  allocated 13-byte region [ffff888104561c80, ffff888104561c8d)
[   25.703945] 
[   25.704037] The buggy address belongs to the physical page:
[   25.704293] page: refcount:0 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x104561
[   25.704624] flags: 0x200000000000000(node=0|zone=2)
[   25.704866] page_type: f5(slab)
[   25.705003] raw: 0200000000000000 ffff888100041640 dead000000000100 dead000000000122
[   25.705266] raw: 0000000000000000 0000000080800080 00000000f5000000 0000000000000000
[   25.705663] page dumped because: kasan: bad access detected
[   25.705907] 
[   25.705978] Memory state around the buggy address:
[   25.706281]  ffff888104561b80: fa fb fc fc 00 00 fc fc fa fb fc fc fa fb fc fc
[   25.706577]  ffff888104561c00: fa fb fc fc fa fb fc fc fa fb fc fc fa fb fc fc
[   25.706864] >ffff888104561c80: 00 05 fc fc 00 00 fc fc fc fc fc fc fc fc fc fc
[   25.707186]                       ^
[   25.707452]  ffff888104561d00: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc
[   25.707729]  ffff888104561d80: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc
[   25.707937] ==================================================================