Date
July 4, 2025, 11:10 a.m.
Environment | |
---|---|
qemu-arm64 | |
qemu-x86_64 |
[ 30.293290] ================================================================== [ 30.293723] BUG: KASAN: invalid-free in kmem_cache_invalid_free+0x184/0x3c8 [ 30.293875] Free of addr fff00000c9b0c001 by task kunit_try_catch/244 [ 30.293930] [ 30.294175] CPU: 0 UID: 0 PID: 244 Comm: kunit_try_catch Tainted: G B N 6.16.0-rc4-next-20250704 #1 PREEMPT [ 30.294566] Tainted: [B]=BAD_PAGE, [N]=TEST [ 30.294732] Hardware name: linux,dummy-virt (DT) [ 30.294770] Call trace: [ 30.295126] show_stack+0x20/0x38 (C) [ 30.295197] dump_stack_lvl+0x8c/0xd0 [ 30.295389] print_report+0x118/0x608 [ 30.295603] kasan_report_invalid_free+0xc0/0xe8 [ 30.295829] check_slab_allocation+0xfc/0x108 [ 30.295930] __kasan_slab_pre_free+0x2c/0x48 [ 30.296100] kmem_cache_free+0xf0/0x468 [ 30.296363] kmem_cache_invalid_free+0x184/0x3c8 [ 30.296686] kunit_try_run_case+0x170/0x3f0 [ 30.296822] kunit_generic_run_threadfn_adapter+0x88/0x100 [ 30.296978] kthread+0x328/0x630 [ 30.297066] ret_from_fork+0x10/0x20 [ 30.297479] [ 30.297526] Allocated by task 244: [ 30.297618] kasan_save_stack+0x3c/0x68 [ 30.297707] kasan_save_track+0x20/0x40 [ 30.297914] kasan_save_alloc_info+0x40/0x58 [ 30.298126] __kasan_slab_alloc+0xa8/0xb0 [ 30.298209] kmem_cache_alloc_noprof+0x10c/0x398 [ 30.298557] kmem_cache_invalid_free+0x12c/0x3c8 [ 30.298673] kunit_try_run_case+0x170/0x3f0 [ 30.298837] kunit_generic_run_threadfn_adapter+0x88/0x100 [ 30.299071] kthread+0x328/0x630 [ 30.299233] ret_from_fork+0x10/0x20 [ 30.299491] [ 30.299837] The buggy address belongs to the object at fff00000c9b0c000 [ 30.299837] which belongs to the cache test_cache of size 200 [ 30.300057] The buggy address is located 1 bytes inside of [ 30.300057] 200-byte region [fff00000c9b0c000, fff00000c9b0c0c8) [ 30.300362] [ 30.300392] The buggy address belongs to the physical page: [ 30.300454] page: refcount:0 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x109b0c [ 30.301032] flags: 0xbfffe0000000000(node=0|zone=2|lastcpupid=0x1ffff) [ 30.301165] page_type: f5(slab) [ 30.301490] raw: 0bfffe0000000000 fff00000c45b38c0 dead000000000122 0000000000000000 [ 30.301739] raw: 0000000000000000 00000000800f000f 00000000f5000000 0000000000000000 [ 30.301826] page dumped because: kasan: bad access detected [ 30.301999] [ 30.302021] Memory state around the buggy address: [ 30.302199] fff00000c9b0bf00: fa fb fb fb fb fb fb fb fc fc fc fc fc fc fc fc [ 30.302596] fff00000c9b0bf80: 00 00 00 00 00 01 fc fc fc fc fc fc fc fc fc fc [ 30.303437] >fff00000c9b0c000: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 [ 30.303499] ^ [ 30.303694] fff00000c9b0c080: 00 00 00 00 00 00 00 00 00 fc fc fc fc fc fc fc [ 30.303850] fff00000c9b0c100: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc [ 30.304099] ==================================================================
[ 25.718126] ================================================================== [ 25.719407] BUG: KASAN: invalid-free in kmem_cache_invalid_free+0x1d8/0x460 [ 25.720447] Free of addr ffff888105ab6001 by task kunit_try_catch/260 [ 25.721080] [ 25.721334] CPU: 0 UID: 0 PID: 260 Comm: kunit_try_catch Tainted: G B N 6.16.0-rc4-next-20250704 #1 PREEMPT(voluntary) [ 25.721415] Tainted: [B]=BAD_PAGE, [N]=TEST [ 25.721429] Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.16.3-debian-1.16.3-2 04/01/2014 [ 25.721455] Call Trace: [ 25.721472] <TASK> [ 25.721496] dump_stack_lvl+0x73/0xb0 [ 25.721531] print_report+0xd1/0x650 [ 25.721555] ? __virt_addr_valid+0x1db/0x2d0 [ 25.721583] ? kasan_complete_mode_report_info+0x2a/0x200 [ 25.721609] ? kmem_cache_invalid_free+0x1d8/0x460 [ 25.721634] kasan_report_invalid_free+0x10a/0x130 [ 25.721658] ? kmem_cache_invalid_free+0x1d8/0x460 [ 25.721684] ? kmem_cache_invalid_free+0x1d8/0x460 [ 25.721709] check_slab_allocation+0x11f/0x130 [ 25.721735] __kasan_slab_pre_free+0x28/0x40 [ 25.721756] kmem_cache_free+0xed/0x420 [ 25.721781] ? kmem_cache_alloc_noprof+0x123/0x3f0 [ 25.721807] ? kmem_cache_invalid_free+0x1d8/0x460 [ 25.721834] kmem_cache_invalid_free+0x1d8/0x460 [ 25.721858] ? __pfx_kmem_cache_invalid_free+0x10/0x10 [ 25.721882] ? finish_task_switch.isra.0+0x153/0x700 [ 25.721906] ? __switch_to+0x47/0xf50 [ 25.721937] ? __pfx_read_tsc+0x10/0x10 [ 25.721961] ? ktime_get_ts64+0x86/0x230 [ 25.721989] kunit_try_run_case+0x1a5/0x480 [ 25.722019] ? __pfx_kunit_try_run_case+0x10/0x10 [ 25.722043] ? _raw_spin_lock_irqsave+0xa1/0x100 [ 25.722069] ? _raw_spin_unlock_irqrestore+0x5f/0x90 [ 25.722094] ? __kthread_parkme+0x82/0x180 [ 25.722117] ? preempt_count_sub+0x50/0x80 [ 25.722140] ? __pfx_kunit_try_run_case+0x10/0x10 [ 25.722166] kunit_generic_run_threadfn_adapter+0x85/0xf0 [ 25.722194] ? __pfx_kunit_generic_run_threadfn_adapter+0x10/0x10 [ 25.722220] kthread+0x337/0x6f0 [ 25.722240] ? trace_preempt_on+0x20/0xc0 [ 25.722266] ? __pfx_kthread+0x10/0x10 [ 25.722288] ? _raw_spin_unlock_irq+0x47/0x80 [ 25.722311] ? calculate_sigpending+0x7b/0xa0 [ 25.722338] ? __pfx_kthread+0x10/0x10 [ 25.722360] ret_from_fork+0x116/0x1d0 [ 25.722381] ? __pfx_kthread+0x10/0x10 [ 25.722413] ret_from_fork_asm+0x1a/0x30 [ 25.722461] </TASK> [ 25.722476] [ 25.737184] Allocated by task 260: [ 25.737562] kasan_save_stack+0x45/0x70 [ 25.737949] kasan_save_track+0x18/0x40 [ 25.738410] kasan_save_alloc_info+0x3b/0x50 [ 25.738957] __kasan_slab_alloc+0x91/0xa0 [ 25.739476] kmem_cache_alloc_noprof+0x123/0x3f0 [ 25.739650] kmem_cache_invalid_free+0x157/0x460 [ 25.739814] kunit_try_run_case+0x1a5/0x480 [ 25.740051] kunit_generic_run_threadfn_adapter+0x85/0xf0 [ 25.740767] kthread+0x337/0x6f0 [ 25.741156] ret_from_fork+0x116/0x1d0 [ 25.741600] ret_from_fork_asm+0x1a/0x30 [ 25.742002] [ 25.742253] The buggy address belongs to the object at ffff888105ab6000 [ 25.742253] which belongs to the cache test_cache of size 200 [ 25.743112] The buggy address is located 1 bytes inside of [ 25.743112] 200-byte region [ffff888105ab6000, ffff888105ab60c8) [ 25.744267] [ 25.744462] The buggy address belongs to the physical page: [ 25.744693] page: refcount:0 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x105ab6 [ 25.745116] flags: 0x200000000000000(node=0|zone=2) [ 25.745858] page_type: f5(slab) [ 25.746279] raw: 0200000000000000 ffff888101d9e280 dead000000000122 0000000000000000 [ 25.747148] raw: 0000000000000000 00000000800f000f 00000000f5000000 0000000000000000 [ 25.747800] page dumped because: kasan: bad access detected [ 25.748133] [ 25.748276] Memory state around the buggy address: [ 25.748750] ffff888105ab5f00: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc [ 25.749048] ffff888105ab5f80: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc [ 25.749595] >ffff888105ab6000: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 [ 25.750632] ^ [ 25.750800] ffff888105ab6080: 00 00 00 00 00 00 00 00 00 fc fc fc fc fc fc fc [ 25.751403] ffff888105ab6100: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc [ 25.752007] ==================================================================