Hay
Date
July 20, 2025, 11:12 a.m.

Environment
qemu-arm64
qemu-x86_64

[   15.718827] ==================================================================
[   15.718891] BUG: KASAN: slab-out-of-bounds in kmem_cache_oob+0x344/0x430
[   15.718968] Read of size 1 at addr fff00000c700b0c8 by task kunit_try_catch/207
[   15.719019] 
[   15.719073] CPU: 0 UID: 0 PID: 207 Comm: kunit_try_catch Tainted: G    B            N  6.16.0-rc6 #1 PREEMPT 
[   15.719158] Tainted: [B]=BAD_PAGE, [N]=TEST
[   15.719184] Hardware name: linux,dummy-virt (DT)
[   15.719216] Call trace:
[   15.719238]  show_stack+0x20/0x38 (C)
[   15.719290]  dump_stack_lvl+0x8c/0xd0
[   15.719338]  print_report+0x118/0x5d0
[   15.719384]  kasan_report+0xdc/0x128
[   15.719431]  __asan_report_load1_noabort+0x20/0x30
[   15.719482]  kmem_cache_oob+0x344/0x430
[   15.719526]  kunit_try_run_case+0x170/0x3f0
[   15.719573]  kunit_generic_run_threadfn_adapter+0x88/0x100
[   15.719625]  kthread+0x328/0x630
[   15.719678]  ret_from_fork+0x10/0x20
[   15.719727] 
[   15.719746] Allocated by task 207:
[   15.719773]  kasan_save_stack+0x3c/0x68
[   15.719812]  kasan_save_track+0x20/0x40
[   15.719859]  kasan_save_alloc_info+0x40/0x58
[   15.720135]  __kasan_slab_alloc+0xa8/0xb0
[   15.720283]  kmem_cache_alloc_noprof+0x10c/0x398
[   15.720395]  kmem_cache_oob+0x12c/0x430
[   15.720555]  kunit_try_run_case+0x170/0x3f0
[   15.720595]  kunit_generic_run_threadfn_adapter+0x88/0x100
[   15.720638]  kthread+0x328/0x630
[   15.720680]  ret_from_fork+0x10/0x20
[   15.720716] 
[   15.720736] The buggy address belongs to the object at fff00000c700b000
[   15.720736]  which belongs to the cache test_cache of size 200
[   15.720938] The buggy address is located 0 bytes to the right of
[   15.720938]  allocated 200-byte region [fff00000c700b000, fff00000c700b0c8)
[   15.721005] 
[   15.721025] The buggy address belongs to the physical page:
[   15.721090] page: refcount:0 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x10700b
[   15.721153] flags: 0xbfffe0000000000(node=0|zone=2|lastcpupid=0x1ffff)
[   15.721218] page_type: f5(slab)
[   15.721278] raw: 0bfffe0000000000 fff00000c1b5fdc0 dead000000000122 0000000000000000
[   15.721412] raw: 0000000000000000 00000000800f000f 00000000f5000000 0000000000000000
[   15.721553] page dumped because: kasan: bad access detected
[   15.721633] 
[   15.721726] Memory state around the buggy address:
[   15.721868]  fff00000c700af80: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
[   15.721982]  fff00000c700b000: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
[   15.722100] >fff00000c700b080: 00 00 00 00 00 00 00 00 00 fc fc fc fc fc fc fc
[   15.722138]                                               ^
[   15.722220]  fff00000c700b100: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc
[   15.722555]  fff00000c700b180: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc
[   15.722655] ==================================================================

[   12.960739] ==================================================================
[   12.961597] BUG: KASAN: slab-out-of-bounds in kmem_cache_oob+0x402/0x530
[   12.962639] Read of size 1 at addr ffff88810273d0c8 by task kunit_try_catch/224
[   12.963505] 
[   12.963779] CPU: 1 UID: 0 PID: 224 Comm: kunit_try_catch Tainted: G    B            N  6.16.0-rc6 #1 PREEMPT(voluntary) 
[   12.963826] Tainted: [B]=BAD_PAGE, [N]=TEST
[   12.963837] Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.16.3-debian-1.16.3-2 04/01/2014
[   12.963857] Call Trace:
[   12.963870]  <TASK>
[   12.963886]  dump_stack_lvl+0x73/0xb0
[   12.963926]  print_report+0xd1/0x610
[   12.963947]  ? __virt_addr_valid+0x1db/0x2d0
[   12.963968]  ? kmem_cache_oob+0x402/0x530
[   12.963989]  ? kasan_complete_mode_report_info+0x2a/0x200
[   12.964010]  ? kmem_cache_oob+0x402/0x530
[   12.964031]  kasan_report+0x141/0x180
[   12.964051]  ? kmem_cache_oob+0x402/0x530
[   12.964077]  __asan_report_load1_noabort+0x18/0x20
[   12.964099]  kmem_cache_oob+0x402/0x530
[   12.964119]  ? trace_hardirqs_on+0x37/0xe0
[   12.964141]  ? __pfx_kmem_cache_oob+0x10/0x10
[   12.964161]  ? finish_task_switch.isra.0+0x153/0x700
[   12.964183]  ? __switch_to+0x47/0xf50
[   12.964210]  ? __pfx_read_tsc+0x10/0x10
[   12.964229]  ? ktime_get_ts64+0x86/0x230
[   12.964253]  kunit_try_run_case+0x1a5/0x480
[   12.964276]  ? __pfx_kunit_try_run_case+0x10/0x10
[   12.964296]  ? _raw_spin_lock_irqsave+0xa1/0x100
[   12.964319]  ? _raw_spin_unlock_irqrestore+0x5f/0x90
[   12.964340]  ? __kthread_parkme+0x82/0x180
[   12.964526]  ? preempt_count_sub+0x50/0x80
[   12.964550]  ? __pfx_kunit_try_run_case+0x10/0x10
[   12.964589]  kunit_generic_run_threadfn_adapter+0x85/0xf0
[   12.964612]  ? __pfx_kunit_generic_run_threadfn_adapter+0x10/0x10
[   12.964635]  kthread+0x337/0x6f0
[   12.964654]  ? trace_preempt_on+0x20/0xc0
[   12.964675]  ? __pfx_kthread+0x10/0x10
[   12.964696]  ? _raw_spin_unlock_irq+0x47/0x80
[   12.964716]  ? calculate_sigpending+0x7b/0xa0
[   12.964740]  ? __pfx_kthread+0x10/0x10
[   12.964761]  ret_from_fork+0x116/0x1d0
[   12.964779]  ? __pfx_kthread+0x10/0x10
[   12.964799]  ret_from_fork_asm+0x1a/0x30
[   12.964828]  </TASK>
[   12.964839] 
[   12.976152] Allocated by task 224:
[   12.976526]  kasan_save_stack+0x45/0x70
[   12.976725]  kasan_save_track+0x18/0x40
[   12.977218]  kasan_save_alloc_info+0x3b/0x50
[   12.977367]  __kasan_slab_alloc+0x91/0xa0
[   12.977871]  kmem_cache_alloc_noprof+0x123/0x3f0
[   12.978108]  kmem_cache_oob+0x157/0x530
[   12.978417]  kunit_try_run_case+0x1a5/0x480
[   12.978851]  kunit_generic_run_threadfn_adapter+0x85/0xf0
[   12.979233]  kthread+0x337/0x6f0
[   12.979542]  ret_from_fork+0x116/0x1d0
[   12.979694]  ret_from_fork_asm+0x1a/0x30
[   12.980077] 
[   12.980290] The buggy address belongs to the object at ffff88810273d000
[   12.980290]  which belongs to the cache test_cache of size 200
[   12.981053] The buggy address is located 0 bytes to the right of
[   12.981053]  allocated 200-byte region [ffff88810273d000, ffff88810273d0c8)
[   12.981549] 
[   12.981627] The buggy address belongs to the physical page:
[   12.982057] page: refcount:0 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x10273d
[   12.982337] flags: 0x200000000000000(node=0|zone=2)
[   12.982577] page_type: f5(slab)
[   12.982818] raw: 0200000000000000 ffff88810100d3c0 dead000000000122 0000000000000000
[   12.983146] raw: 0000000000000000 00000000800f000f 00000000f5000000 0000000000000000
[   12.983586] page dumped because: kasan: bad access detected
[   12.983792] 
[   12.983897] Memory state around the buggy address:
[   12.984079]  ffff88810273cf80: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc
[   12.984369]  ffff88810273d000: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
[   12.984727] >ffff88810273d080: 00 00 00 00 00 00 00 00 00 fc fc fc fc fc fc fc
[   12.985014]                                               ^
[   12.985246]  ffff88810273d100: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc
[   12.985659]  ffff88810273d180: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc
[   12.985988] ==================================================================