Hay
Date
July 15, 2025, 2:10 p.m.

Environment
qemu-arm64

[  106.915337] ==================================================================
[  106.916139] BUG: KASAN: invalid-free in kmem_cache_free+0x194/0x42c
[  106.917443] Free of addr ffff0000c66ad001 by task kunit_try_catch/244
[  106.918267] 
[  106.918582] CPU: 1 PID: 244 Comm: kunit_try_catch Tainted: G    B            N 6.1.146-rc1 #1
[  106.919621] Hardware name: linux,dummy-virt (DT)
[  106.920246] Call trace:
[  106.920677]  dump_backtrace+0xe0/0x134
[  106.921346]  show_stack+0x20/0x2c
[  106.921797]  dump_stack_lvl+0x88/0xb4
[  106.922212]  print_report+0x158/0x44c
[  106.922559]  kasan_report_invalid_free+0xa8/0x13c
[  106.923315]  __kasan_slab_free+0x164/0x170
[  106.923978]  slab_free_freelist_hook+0xd8/0x1c0
[  106.924724]  kmem_cache_free+0x194/0x42c
[  106.925486]  kmem_cache_invalid_free+0xe0/0x230
[  106.926247]  kunit_try_run_case+0x8c/0x124
[  106.926917]  kunit_generic_run_threadfn_adapter+0x38/0x54
[  106.927711]  kthread+0x15c/0x170
[  106.928273]  ret_from_fork+0x10/0x20
[  106.928927] 
[  106.929366] Allocated by task 244:
[  106.929858]  kasan_save_stack+0x3c/0x70
[  106.930451]  kasan_set_track+0x2c/0x40
[  106.931036]  kasan_save_alloc_info+0x24/0x34
[  106.931688]  __kasan_slab_alloc+0xa8/0xac
[  106.932311]  kmem_cache_alloc+0x194/0x3b0
[  106.932855]  kmem_cache_invalid_free+0xbc/0x230
[  106.933307]  kunit_try_run_case+0x8c/0x124
[  106.933708]  kunit_generic_run_threadfn_adapter+0x38/0x54
[  106.934224]  kthread+0x15c/0x170
[  106.934579]  ret_from_fork+0x10/0x20
[  106.935155] 
[  106.935425] The buggy address belongs to the object at ffff0000c66ad000
[  106.935425]  which belongs to the cache test_cache of size 200
[  106.936959] The buggy address is located 1 bytes inside of
[  106.936959]  200-byte region [ffff0000c66ad000, ffff0000c66ad0c8)
[  106.938405] 
[  106.938716] The buggy address belongs to the physical page:
[  106.939468] page:00000000f51d9fab refcount:1 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x1066ad
[  106.940409] flags: 0xbfffc0000000200(slab|node=0|zone=2|lastcpupid=0xffff)
[  106.941367] raw: 0bfffc0000000200 0000000000000000 dead000000000122 ffff0000c6446600
[  106.942347] raw: 0000000000000000 00000000800f000f 00000001ffffffff 0000000000000000
[  106.943305] page dumped because: kasan: bad access detected
[  106.943793] 
[  106.943980] Memory state around the buggy address:
[  106.944347]  ffff0000c66acf00: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc
[  106.945338]  ffff0000c66acf80: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc
[  106.946366] >ffff0000c66ad000: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
[  106.947226]                    ^
[  106.947698]  ffff0000c66ad080: 00 00 00 00 00 00 00 00 00 fc fc fc fc fc fc fc
[  106.948614]  ffff0000c66ad100: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc
[  106.949585] ==================================================================