Hay
Date
July 16, 2025, 3:10 p.m.

Environment
qemu-arm64
qemu-x86_64

[   16.388571] ==================================================================
[   16.388742] BUG: KASAN: slab-out-of-bounds in kmalloc_node_oob_right+0x2f4/0x330
[   16.388816] Read of size 1 at addr fff00000c65d7000 by task kunit_try_catch/140
[   16.388901] 
[   16.389032] CPU: 1 UID: 0 PID: 140 Comm: kunit_try_catch Tainted: G    B            N  6.16.0-rc6 #1 PREEMPT 
[   16.389156] Tainted: [B]=BAD_PAGE, [N]=TEST
[   16.389189] Hardware name: linux,dummy-virt (DT)
[   16.389219] Call trace:
[   16.389242]  show_stack+0x20/0x38 (C)
[   16.389294]  dump_stack_lvl+0x8c/0xd0
[   16.389343]  print_report+0x118/0x5d0
[   16.389389]  kasan_report+0xdc/0x128
[   16.389434]  __asan_report_load1_noabort+0x20/0x30
[   16.389484]  kmalloc_node_oob_right+0x2f4/0x330
[   16.389581]  kunit_try_run_case+0x170/0x3f0
[   16.389641]  kunit_generic_run_threadfn_adapter+0x88/0x100
[   16.389702]  kthread+0x328/0x630
[   16.389983]  ret_from_fork+0x10/0x20
[   16.390093] 
[   16.390208] Allocated by task 140:
[   16.390403]  kasan_save_stack+0x3c/0x68
[   16.390560]  kasan_save_track+0x20/0x40
[   16.390619]  kasan_save_alloc_info+0x40/0x58
[   16.390676]  __kasan_kmalloc+0xd4/0xd8
[   16.390733]  __kmalloc_cache_node_noprof+0x178/0x3d0
[   16.390815]  kmalloc_node_oob_right+0xbc/0x330
[   16.390883]  kunit_try_run_case+0x170/0x3f0
[   16.390939]  kunit_generic_run_threadfn_adapter+0x88/0x100
[   16.391126]  kthread+0x328/0x630
[   16.391185]  ret_from_fork+0x10/0x20
[   16.391267] 
[   16.391300] The buggy address belongs to the object at fff00000c65d6000
[   16.391300]  which belongs to the cache kmalloc-4k of size 4096
[   16.391457] The buggy address is located 0 bytes to the right of
[   16.391457]  allocated 4096-byte region [fff00000c65d6000, fff00000c65d7000)
[   16.391651] 
[   16.391769] The buggy address belongs to the physical page:
[   16.391986] page: refcount:0 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x1065d0
[   16.392203] head: order:3 mapcount:0 entire_mapcount:0 nr_pages_mapped:0 pincount:0
[   16.392610] flags: 0xbfffe0000000040(head|node=0|zone=2|lastcpupid=0x1ffff)
[   16.392844] page_type: f5(slab)
[   16.392981] raw: 0bfffe0000000040 fff00000c0002140 dead000000000122 0000000000000000
[   16.393102] raw: 0000000000000000 0000000080040004 00000000f5000000 0000000000000000
[   16.393334] head: 0bfffe0000000040 fff00000c0002140 dead000000000122 0000000000000000
[   16.393421] head: 0000000000000000 0000000080040004 00000000f5000000 0000000000000000
[   16.393597] head: 0bfffe0000000003 ffffc1ffc3197401 00000000ffffffff 00000000ffffffff
[   16.393683] head: ffffffffffffffff 0000000000000000 00000000ffffffff 0000000000000008
[   16.393861] page dumped because: kasan: bad access detected
[   16.394005] 
[   16.394053] Memory state around the buggy address:
[   16.394102]  fff00000c65d6f00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
[   16.394194]  fff00000c65d6f80: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
[   16.394320] >fff00000c65d7000: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc
[   16.394359]                    ^
[   16.394393]  fff00000c65d7080: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc
[   16.394549]  fff00000c65d7100: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc
[   16.394614] ==================================================================

[   11.945304] ==================================================================
[   11.945844] BUG: KASAN: slab-out-of-bounds in kmalloc_node_oob_right+0x369/0x3c0
[   11.946174] Read of size 1 at addr ffff8881029f3000 by task kunit_try_catch/157
[   11.946471] 
[   11.946583] CPU: 0 UID: 0 PID: 157 Comm: kunit_try_catch Tainted: G    B            N  6.16.0-rc6 #1 PREEMPT(voluntary) 
[   11.946626] Tainted: [B]=BAD_PAGE, [N]=TEST
[   11.946637] Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.16.3-debian-1.16.3-2 04/01/2014
[   11.946657] Call Trace:
[   11.946668]  <TASK>
[   11.946682]  dump_stack_lvl+0x73/0xb0
[   11.946710]  print_report+0xd1/0x610
[   11.946731]  ? __virt_addr_valid+0x1db/0x2d0
[   11.946791]  ? kmalloc_node_oob_right+0x369/0x3c0
[   11.946818]  ? kasan_complete_mode_report_info+0x2a/0x200
[   11.946842]  ? kmalloc_node_oob_right+0x369/0x3c0
[   11.947248]  kasan_report+0x141/0x180
[   11.947279]  ? kmalloc_node_oob_right+0x369/0x3c0
[   11.947341]  __asan_report_load1_noabort+0x18/0x20
[   11.947367]  kmalloc_node_oob_right+0x369/0x3c0
[   11.947392]  ? __pfx_kmalloc_node_oob_right+0x10/0x10
[   11.947567]  ? __pfx_kmalloc_node_oob_right+0x10/0x10
[   11.947603]  kunit_try_run_case+0x1a5/0x480
[   11.947632]  ? __pfx_kunit_try_run_case+0x10/0x10
[   11.947655]  ? _raw_spin_lock_irqsave+0xa1/0x100
[   11.947680]  ? _raw_spin_unlock_irqrestore+0x5f/0x90
[   11.947704]  ? __kthread_parkme+0x82/0x180
[   11.947727]  ? preempt_count_sub+0x50/0x80
[   11.947765]  ? __pfx_kunit_try_run_case+0x10/0x10
[   11.947789]  kunit_generic_run_threadfn_adapter+0x85/0xf0
[   11.947814]  ? __pfx_kunit_generic_run_threadfn_adapter+0x10/0x10
[   11.947839]  kthread+0x337/0x6f0
[   11.947859]  ? trace_preempt_on+0x20/0xc0
[   11.947882]  ? __pfx_kthread+0x10/0x10
[   11.947903]  ? _raw_spin_unlock_irq+0x47/0x80
[   11.947924]  ? calculate_sigpending+0x7b/0xa0
[   11.947949]  ? __pfx_kthread+0x10/0x10
[   11.947992]  ret_from_fork+0x116/0x1d0
[   11.948012]  ? __pfx_kthread+0x10/0x10
[   11.948032]  ret_from_fork_asm+0x1a/0x30
[   11.948063]  </TASK>
[   11.948073] 
[   11.958663] Allocated by task 157:
[   11.958957]  kasan_save_stack+0x45/0x70
[   11.959305]  kasan_save_track+0x18/0x40
[   11.959564]  kasan_save_alloc_info+0x3b/0x50
[   11.959795]  __kasan_kmalloc+0xb7/0xc0
[   11.960210]  __kmalloc_cache_node_noprof+0x188/0x420
[   11.960482]  kmalloc_node_oob_right+0xab/0x3c0
[   11.960815]  kunit_try_run_case+0x1a5/0x480
[   11.961236]  kunit_generic_run_threadfn_adapter+0x85/0xf0
[   11.961606]  kthread+0x337/0x6f0
[   11.961820]  ret_from_fork+0x116/0x1d0
[   11.961958]  ret_from_fork_asm+0x1a/0x30
[   11.962389] 
[   11.962615] The buggy address belongs to the object at ffff8881029f2000
[   11.962615]  which belongs to the cache kmalloc-4k of size 4096
[   11.963284] The buggy address is located 0 bytes to the right of
[   11.963284]  allocated 4096-byte region [ffff8881029f2000, ffff8881029f3000)
[   11.964183] 
[   11.964292] The buggy address belongs to the physical page:
[   11.964703] page: refcount:0 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x1029f0
[   11.965548] head: order:3 mapcount:0 entire_mapcount:0 nr_pages_mapped:0 pincount:0
[   11.965888] flags: 0x200000000000040(head|node=0|zone=2)
[   11.966353] page_type: f5(slab)
[   11.966666] raw: 0200000000000040 ffff888100042140 dead000000000122 0000000000000000
[   11.967188] raw: 0000000000000000 0000000080040004 00000000f5000000 0000000000000000
[   11.967687] head: 0200000000000040 ffff888100042140 dead000000000122 0000000000000000
[   11.968167] head: 0000000000000000 0000000080040004 00000000f5000000 0000000000000000
[   11.968645] head: 0200000000000003 ffffea00040a7c01 00000000ffffffff 00000000ffffffff
[   11.969261] head: ffffffffffffffff 0000000000000000 00000000ffffffff 0000000000000008
[   11.969749] page dumped because: kasan: bad access detected
[   11.970115] 
[   11.970367] Memory state around the buggy address:
[   11.970716]  ffff8881029f2f00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
[   11.971160]  ffff8881029f2f80: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
[   11.971599] >ffff8881029f3000: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc
[   11.972053]                    ^
[   11.972182]  ffff8881029f3080: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc
[   11.972547]  ffff8881029f3100: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc
[   11.972842] ==================================================================