Hay
Date
July 17, 2025, 11:11 p.m.

Environment
qemu-arm64
qemu-x86_64

[   16.702245] ==================================================================
[   16.702331] BUG: KASAN: slab-out-of-bounds in kmalloc_oob_memset_16+0x150/0x2f8
[   16.702399] Write of size 16 at addr fff00000c6691869 by task kunit_try_catch/178
[   16.702448] 
[   16.702485] CPU: 1 UID: 0 PID: 178 Comm: kunit_try_catch Tainted: G    B            N  6.16.0-rc6 #1 PREEMPT 
[   16.702574] Tainted: [B]=BAD_PAGE, [N]=TEST
[   16.702600] Hardware name: linux,dummy-virt (DT)
[   16.702631] Call trace:
[   16.702654]  show_stack+0x20/0x38 (C)
[   16.702712]  dump_stack_lvl+0x8c/0xd0
[   16.702766]  print_report+0x118/0x5d0
[   16.702812]  kasan_report+0xdc/0x128
[   16.703188]  kasan_check_range+0x100/0x1a8
[   16.703625]  __asan_memset+0x34/0x78
[   16.703945]  kmalloc_oob_memset_16+0x150/0x2f8
[   16.704015]  kunit_try_run_case+0x170/0x3f0
[   16.704067]  kunit_generic_run_threadfn_adapter+0x88/0x100
[   16.704512]  kthread+0x328/0x630
[   16.704983]  ret_from_fork+0x10/0x20
[   16.705175] 
[   16.705598] Allocated by task 178:
[   16.705777]  kasan_save_stack+0x3c/0x68
[   16.706125]  kasan_save_track+0x20/0x40
[   16.706251]  kasan_save_alloc_info+0x40/0x58
[   16.706321]  __kasan_kmalloc+0xd4/0xd8
[   16.706592]  __kmalloc_cache_noprof+0x16c/0x3c0
[   16.706700]  kmalloc_oob_memset_16+0xb0/0x2f8
[   16.706902]  kunit_try_run_case+0x170/0x3f0
[   16.707123]  kunit_generic_run_threadfn_adapter+0x88/0x100
[   16.707188]  kthread+0x328/0x630
[   16.707253]  ret_from_fork+0x10/0x20
[   16.707401] 
[   16.707647] The buggy address belongs to the object at fff00000c6691800
[   16.707647]  which belongs to the cache kmalloc-128 of size 128
[   16.707956] The buggy address is located 105 bytes inside of
[   16.707956]  allocated 120-byte region [fff00000c6691800, fff00000c6691878)
[   16.708050] 
[   16.708073] The buggy address belongs to the physical page:
[   16.708112] page: refcount:0 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x106691
[   16.708288] flags: 0xbfffe0000000000(node=0|zone=2|lastcpupid=0x1ffff)
[   16.708551] page_type: f5(slab)
[   16.708597] raw: 0bfffe0000000000 fff00000c0001a00 dead000000000122 0000000000000000
[   16.708793] raw: 0000000000000000 0000000080100010 00000000f5000000 0000000000000000
[   16.709258] page dumped because: kasan: bad access detected
[   16.709721] 
[   16.709760] Memory state around the buggy address:
[   16.709812]  fff00000c6691700: fa fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb
[   16.709992]  fff00000c6691780: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc
[   16.710220] >fff00000c6691800: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 fc
[   16.710263]                                                                 ^
[   16.710478]  fff00000c6691880: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc
[   16.710687]  fff00000c6691900: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc
[   16.710783] ==================================================================

[   12.416514] ==================================================================
[   12.417462] BUG: KASAN: slab-out-of-bounds in kmalloc_oob_memset_16+0x166/0x330
[   12.418254] Write of size 16 at addr ffff8881026a6b69 by task kunit_try_catch/195
[   12.418753] 
[   12.418986] CPU: 1 UID: 0 PID: 195 Comm: kunit_try_catch Tainted: G    B            N  6.16.0-rc6 #1 PREEMPT(voluntary) 
[   12.419039] Tainted: [B]=BAD_PAGE, [N]=TEST
[   12.419064] Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.16.3-debian-1.16.3-2 04/01/2014
[   12.419087] Call Trace:
[   12.419099]  <TASK>
[   12.419118]  dump_stack_lvl+0x73/0xb0
[   12.419149]  print_report+0xd1/0x610
[   12.419172]  ? __virt_addr_valid+0x1db/0x2d0
[   12.419196]  ? kmalloc_oob_memset_16+0x166/0x330
[   12.419217]  ? kasan_complete_mode_report_info+0x2a/0x200
[   12.419240]  ? kmalloc_oob_memset_16+0x166/0x330
[   12.419261]  kasan_report+0x141/0x180
[   12.419282]  ? kmalloc_oob_memset_16+0x166/0x330
[   12.419309]  kasan_check_range+0x10c/0x1c0
[   12.419332]  __asan_memset+0x27/0x50
[   12.419350]  kmalloc_oob_memset_16+0x166/0x330
[   12.419372]  ? __pfx_kmalloc_oob_memset_16+0x10/0x10
[   12.419394]  ? __schedule+0x10cc/0x2b60
[   12.419416]  ? __pfx_read_tsc+0x10/0x10
[   12.419437]  ? ktime_get_ts64+0x86/0x230
[   12.419461]  kunit_try_run_case+0x1a5/0x480
[   12.419485]  ? __pfx_kunit_try_run_case+0x10/0x10
[   12.419507]  ? _raw_spin_lock_irqsave+0xa1/0x100
[   12.419530]  ? _raw_spin_unlock_irqrestore+0x5f/0x90
[   12.419552]  ? __kthread_parkme+0x82/0x180
[   12.419573]  ? preempt_count_sub+0x50/0x80
[   12.419755]  ? __pfx_kunit_try_run_case+0x10/0x10
[   12.419784]  kunit_generic_run_threadfn_adapter+0x85/0xf0
[   12.419891]  ? __pfx_kunit_generic_run_threadfn_adapter+0x10/0x10
[   12.419915]  kthread+0x337/0x6f0
[   12.419933]  ? trace_preempt_on+0x20/0xc0
[   12.419958]  ? __pfx_kthread+0x10/0x10
[   12.419977]  ? _raw_spin_unlock_irq+0x47/0x80
[   12.419998]  ? calculate_sigpending+0x7b/0xa0
[   12.420022]  ? __pfx_kthread+0x10/0x10
[   12.420042]  ret_from_fork+0x116/0x1d0
[   12.420071]  ? __pfx_kthread+0x10/0x10
[   12.420090]  ret_from_fork_asm+0x1a/0x30
[   12.420122]  </TASK>
[   12.420134] 
[   12.432496] Allocated by task 195:
[   12.433026]  kasan_save_stack+0x45/0x70
[   12.433304]  kasan_save_track+0x18/0x40
[   12.433727]  kasan_save_alloc_info+0x3b/0x50
[   12.433991]  __kasan_kmalloc+0xb7/0xc0
[   12.434182]  __kmalloc_cache_noprof+0x189/0x420
[   12.434385]  kmalloc_oob_memset_16+0xac/0x330
[   12.434575]  kunit_try_run_case+0x1a5/0x480
[   12.434759]  kunit_generic_run_threadfn_adapter+0x85/0xf0
[   12.435569]  kthread+0x337/0x6f0
[   12.436090]  ret_from_fork+0x116/0x1d0
[   12.436366]  ret_from_fork_asm+0x1a/0x30
[   12.436753] 
[   12.436952] The buggy address belongs to the object at ffff8881026a6b00
[   12.436952]  which belongs to the cache kmalloc-128 of size 128
[   12.437859] The buggy address is located 105 bytes inside of
[   12.437859]  allocated 120-byte region [ffff8881026a6b00, ffff8881026a6b78)
[   12.438553] 
[   12.438815] The buggy address belongs to the physical page:
[   12.439233] page: refcount:0 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x1026a6
[   12.439569] flags: 0x200000000000000(node=0|zone=2)
[   12.440029] page_type: f5(slab)
[   12.440432] raw: 0200000000000000 ffff888100041a00 dead000000000122 0000000000000000
[   12.440923] raw: 0000000000000000 0000000080100010 00000000f5000000 0000000000000000
[   12.441253] page dumped because: kasan: bad access detected
[   12.441482] 
[   12.441566] Memory state around the buggy address:
[   12.442299]  ffff8881026a6a00: fa fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb
[   12.442773]  ffff8881026a6a80: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc
[   12.443138] >ffff8881026a6b00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 fc
[   12.443424]                                                                 ^
[   12.444127]  ffff8881026a6b80: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc
[   12.444514]  ffff8881026a6c00: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc
[   12.445266] ==================================================================