Hay
Date
June 7, 2025, 10:40 a.m.

Environment
qemu-arm64
qemu-x86_64

[   20.355429] ==================================================================
[   20.356605] BUG: KASAN: slab-out-of-bounds in kmalloc_big_oob_right+0x2b8/0x308
[   20.357297] Write of size 1 at addr fff00000c69a9f00 by task kunit_try_catch/132
[   20.357825] 
[   20.358212] CPU: 1 UID: 0 PID: 132 Comm: kunit_try_catch Tainted: G    B            N 6.12.33-rc1 #1
[   20.358415] Tainted: [B]=BAD_PAGE, [N]=TEST
[   20.358491] Hardware name: linux,dummy-virt (DT)
[   20.358578] Call trace:
[   20.358642]  dump_backtrace+0x9c/0x128
[   20.358758]  show_stack+0x20/0x38
[   20.358858]  dump_stack_lvl+0x8c/0xd0
[   20.358990]  print_report+0x118/0x5f0
[   20.359098]  kasan_report+0xdc/0x128
[   20.359179]  __asan_report_store1_noabort+0x20/0x30
[   20.359232]  kmalloc_big_oob_right+0x2b8/0x308
[   20.359280]  kunit_try_run_case+0x170/0x3f0
[   20.359326]  kunit_generic_run_threadfn_adapter+0x88/0x100
[   20.359433]  kthread+0x24c/0x2d0
[   20.359539]  ret_from_fork+0x10/0x20
[   20.359632] 
[   20.366590] Allocated by task 132:
[   20.367114]  kasan_save_stack+0x3c/0x68
[   20.367573]  kasan_save_track+0x20/0x40
[   20.368152]  kasan_save_alloc_info+0x40/0x58
[   20.368747]  __kasan_kmalloc+0xd4/0xd8
[   20.369523]  __kmalloc_cache_noprof+0x154/0x320
[   20.370153]  kmalloc_big_oob_right+0xb8/0x308
[   20.370689]  kunit_try_run_case+0x170/0x3f0
[   20.371224]  kunit_generic_run_threadfn_adapter+0x88/0x100
[   20.372749]  kthread+0x24c/0x2d0
[   20.373198]  ret_from_fork+0x10/0x20
[   20.373710] 
[   20.374028] The buggy address belongs to the object at fff00000c69a8000
[   20.374028]  which belongs to the cache kmalloc-8k of size 8192
[   20.375185] The buggy address is located 0 bytes to the right of
[   20.375185]  allocated 7936-byte region [fff00000c69a8000, fff00000c69a9f00)
[   20.376655] 
[   20.376983] The buggy address belongs to the physical page:
[   20.377569] page: refcount:1 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x1069a8
[   20.378510] head: order:3 mapcount:0 entire_mapcount:0 nr_pages_mapped:0 pincount:0
[   20.379332] flags: 0xbfffe0000000040(head|node=0|zone=2|lastcpupid=0x1ffff)
[   20.380347] page_type: f5(slab)
[   20.380791] raw: 0bfffe0000000040 fff00000c0002280 dead000000000122 0000000000000000
[   20.381623] raw: 0000000000000000 0000000080020002 00000001f5000000 0000000000000000
[   20.382424] head: 0bfffe0000000040 fff00000c0002280 dead000000000122 0000000000000000
[   20.383205] head: 0000000000000000 0000000080020002 00000001f5000000 0000000000000000
[   20.384194] head: 0bfffe0000000003 ffffc1ffc31a6a01 ffffffffffffffff 0000000000000000
[   20.384994] head: 0000000000000008 0000000000000000 00000000ffffffff 0000000000000000
[   20.385742] page dumped because: kasan: bad access detected
[   20.386332] 
[   20.386645] Memory state around the buggy address:
[   20.387144]  fff00000c69a9e00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
[   20.388223]  fff00000c69a9e80: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
[   20.388940] >fff00000c69a9f00: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc
[   20.389632]                    ^
[   20.390093]  fff00000c69a9f80: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc
[   20.390811]  fff00000c69aa000: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc
[   20.392240] ==================================================================

[   16.452922] ==================================================================
[   16.453913] BUG: KASAN: slab-out-of-bounds in kmalloc_big_oob_right+0x318/0x370
[   16.454491] Write of size 1 at addr ffff888101efdf00 by task kunit_try_catch/149
[   16.455160] 
[   16.455751] CPU: 1 UID: 0 PID: 149 Comm: kunit_try_catch Tainted: G    B            N 6.12.33-rc1 #1
[   16.455893] Tainted: [B]=BAD_PAGE, [N]=TEST
[   16.455929] Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.16.3-debian-1.16.3-2 04/01/2014
[   16.455986] Call Trace:
[   16.456023]  <TASK>
[   16.456073]  dump_stack_lvl+0x73/0xb0
[   16.456155]  print_report+0xd1/0x640
[   16.456255]  ? __virt_addr_valid+0x1db/0x2d0
[   16.456363]  ? kmalloc_big_oob_right+0x318/0x370
[   16.456463]  ? kasan_complete_mode_report_info+0x2a/0x200
[   16.456539]  ? kmalloc_big_oob_right+0x318/0x370
[   16.456611]  kasan_report+0x140/0x180
[   16.456689]  ? kmalloc_big_oob_right+0x318/0x370
[   16.456908]  __asan_report_store1_noabort+0x1b/0x30
[   16.456984]  kmalloc_big_oob_right+0x318/0x370
[   16.457062]  ? __pfx_kmalloc_big_oob_right+0x10/0x10
[   16.457100]  ? sysvec_apic_timer_interrupt+0x50/0x90
[   16.457136]  ? trace_hardirqs_on+0x37/0xe0
[   16.457170]  ? __pfx_read_tsc+0x10/0x10
[   16.457197]  ? ktime_get_ts64+0x84/0x230
[   16.457266]  kunit_try_run_case+0x1a6/0x480
[   16.457301]  ? __pfx_kunit_try_run_case+0x10/0x10
[   16.457332]  ? _raw_spin_lock_irqsave+0xa2/0x110
[   16.457360]  ? __kthread_parkme+0x82/0x160
[   16.457387]  ? preempt_count_sub+0x50/0x80
[   16.457418]  ? __pfx_kunit_try_run_case+0x10/0x10
[   16.457470]  ? __pfx_kunit_generic_run_threadfn_adapter+0x10/0x10
[   16.457600]  kunit_generic_run_threadfn_adapter+0x85/0xf0
[   16.457640]  kthread+0x257/0x310
[   16.457666]  ? __pfx_kthread+0x10/0x10
[   16.457693]  ret_from_fork+0x41/0x80
[   16.457722]  ? __pfx_kthread+0x10/0x10
[   16.457747]  ret_from_fork_asm+0x1a/0x30
[   16.457789]  </TASK>
[   16.457803] 
[   16.475142] Allocated by task 149:
[   16.475836]  kasan_save_stack+0x45/0x70
[   16.476336]  kasan_save_track+0x18/0x40
[   16.476881]  kasan_save_alloc_info+0x3b/0x50
[   16.477925]  __kasan_kmalloc+0xb7/0xc0
[   16.478248]  __kmalloc_cache_noprof+0x168/0x350
[   16.478995]  kmalloc_big_oob_right+0xaa/0x370
[   16.479587]  kunit_try_run_case+0x1a6/0x480
[   16.480125]  kunit_generic_run_threadfn_adapter+0x85/0xf0
[   16.481043]  kthread+0x257/0x310
[   16.481414]  ret_from_fork+0x41/0x80
[   16.482037]  ret_from_fork_asm+0x1a/0x30
[   16.482435] 
[   16.482998] The buggy address belongs to the object at ffff888101efc000
[   16.482998]  which belongs to the cache kmalloc-8k of size 8192
[   16.484074] The buggy address is located 0 bytes to the right of
[   16.484074]  allocated 7936-byte region [ffff888101efc000, ffff888101efdf00)
[   16.485104] 
[   16.485360] The buggy address belongs to the physical page:
[   16.485811] page: refcount:1 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x101ef8
[   16.487381] head: order:3 mapcount:0 entire_mapcount:0 nr_pages_mapped:0 pincount:0
[   16.488340] flags: 0x200000000000040(head|node=0|zone=2)
[   16.488666] page_type: f5(slab)
[   16.489232] raw: 0200000000000040 ffff888100042280 dead000000000122 0000000000000000
[   16.489992] raw: 0000000000000000 0000000080020002 00000001f5000000 0000000000000000
[   16.490750] head: 0200000000000040 ffff888100042280 dead000000000122 0000000000000000
[   16.491511] head: 0000000000000000 0000000080020002 00000001f5000000 0000000000000000
[   16.493253] head: 0200000000000003 ffffea000407be01 ffffffffffffffff 0000000000000000
[   16.494380] head: 0000000000000008 0000000000000000 00000000ffffffff 0000000000000000
[   16.495344] page dumped because: kasan: bad access detected
[   16.495667] 
[   16.495831] Memory state around the buggy address:
[   16.496638]  ffff888101efde00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
[   16.497691]  ffff888101efde80: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
[   16.498505] >ffff888101efdf00: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc
[   16.499777]                    ^
[   16.500131]  ffff888101efdf80: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc
[   16.501343]  ffff888101efe000: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc
[   16.502269] ==================================================================