Date
July 1, 2025, 3:08 p.m.
Environment | |
---|---|
qemu-arm64 | |
qemu-x86_64 |
[ 17.827797] ================================================================== [ 17.828468] BUG: KASAN: invalid-free in kmem_cache_invalid_free+0x184/0x3c8 [ 17.828685] Free of addr fff00000c57dc001 by task kunit_try_catch/212 [ 17.828760] [ 17.828805] CPU: 1 UID: 0 PID: 212 Comm: kunit_try_catch Tainted: G B N 6.16.0-rc4 #1 PREEMPT [ 17.829050] Tainted: [B]=BAD_PAGE, [N]=TEST [ 17.829084] Hardware name: linux,dummy-virt (DT) [ 17.829120] Call trace: [ 17.829144] show_stack+0x20/0x38 (C) [ 17.829405] dump_stack_lvl+0x8c/0xd0 [ 17.829475] print_report+0x118/0x608 [ 17.829525] kasan_report_invalid_free+0xc0/0xe8 [ 17.829722] check_slab_allocation+0xfc/0x108 [ 17.829905] __kasan_slab_pre_free+0x2c/0x48 [ 17.830072] kmem_cache_free+0xf0/0x468 [ 17.830169] kmem_cache_invalid_free+0x184/0x3c8 [ 17.830238] kunit_try_run_case+0x170/0x3f0 [ 17.830618] kunit_generic_run_threadfn_adapter+0x88/0x100 [ 17.830715] kthread+0x328/0x630 [ 17.830807] ret_from_fork+0x10/0x20 [ 17.830860] [ 17.830879] Allocated by task 212: [ 17.831162] kasan_save_stack+0x3c/0x68 [ 17.831328] kasan_save_track+0x20/0x40 [ 17.831413] kasan_save_alloc_info+0x40/0x58 [ 17.831674] __kasan_slab_alloc+0xa8/0xb0 [ 17.831833] kmem_cache_alloc_noprof+0x10c/0x398 [ 17.831949] kmem_cache_invalid_free+0x12c/0x3c8 [ 17.832008] kunit_try_run_case+0x170/0x3f0 [ 17.832048] kunit_generic_run_threadfn_adapter+0x88/0x100 [ 17.832384] kthread+0x328/0x630 [ 17.832462] ret_from_fork+0x10/0x20 [ 17.832593] [ 17.832654] The buggy address belongs to the object at fff00000c57dc000 [ 17.832654] which belongs to the cache test_cache of size 200 [ 17.832737] The buggy address is located 1 bytes inside of [ 17.832737] 200-byte region [fff00000c57dc000, fff00000c57dc0c8) [ 17.832950] [ 17.833114] The buggy address belongs to the physical page: [ 17.833214] page: refcount:0 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x1057dc [ 17.833294] flags: 0xbfffe0000000000(node=0|zone=2|lastcpupid=0x1ffff) [ 17.833505] page_type: f5(slab) [ 17.833830] raw: 0bfffe0000000000 fff00000c57d5280 dead000000000122 0000000000000000 [ 17.833990] raw: 0000000000000000 00000000800f000f 00000000f5000000 0000000000000000 [ 17.834061] page dumped because: kasan: bad access detected [ 17.834289] [ 17.834482] Memory state around the buggy address: [ 17.834541] fff00000c57dbf00: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc [ 17.834905] fff00000c57dbf80: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc [ 17.835081] >fff00000c57dc000: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 [ 17.835128] ^ [ 17.835399] fff00000c57dc080: 00 00 00 00 00 00 00 00 00 fc fc fc fc fc fc fc [ 17.835637] fff00000c57dc100: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc [ 17.835737] ==================================================================
[ 12.340580] ================================================================== [ 12.342446] BUG: KASAN: invalid-free in kmem_cache_invalid_free+0x1d8/0x460 [ 12.343223] Free of addr ffff8881027dc001 by task kunit_try_catch/228 [ 12.343893] [ 12.344134] CPU: 1 UID: 0 PID: 228 Comm: kunit_try_catch Tainted: G B N 6.16.0-rc4 #1 PREEMPT(voluntary) [ 12.344197] Tainted: [B]=BAD_PAGE, [N]=TEST [ 12.344209] Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.16.3-debian-1.16.3-2 04/01/2014 [ 12.344230] Call Trace: [ 12.344243] <TASK> [ 12.344274] dump_stack_lvl+0x73/0xb0 [ 12.344306] print_report+0xd1/0x650 [ 12.344329] ? __virt_addr_valid+0x1db/0x2d0 [ 12.344354] ? kasan_complete_mode_report_info+0x2a/0x200 [ 12.344375] ? kmem_cache_invalid_free+0x1d8/0x460 [ 12.344399] kasan_report_invalid_free+0x10a/0x130 [ 12.344421] ? kmem_cache_invalid_free+0x1d8/0x460 [ 12.344446] ? kmem_cache_invalid_free+0x1d8/0x460 [ 12.344469] check_slab_allocation+0x11f/0x130 [ 12.344489] __kasan_slab_pre_free+0x28/0x40 [ 12.344508] kmem_cache_free+0xed/0x420 [ 12.344528] ? kmem_cache_alloc_noprof+0x123/0x3f0 [ 12.344547] ? kmem_cache_invalid_free+0x1d8/0x460 [ 12.344572] kmem_cache_invalid_free+0x1d8/0x460 [ 12.344595] ? __pfx_kmem_cache_invalid_free+0x10/0x10 [ 12.344617] ? sysvec_apic_timer_interrupt+0x50/0x90 [ 12.344656] ? __pfx_kmem_cache_invalid_free+0x10/0x10 [ 12.344683] kunit_try_run_case+0x1a5/0x480 [ 12.344709] ? __pfx_kunit_try_run_case+0x10/0x10 [ 12.344729] ? _raw_spin_lock_irqsave+0xa1/0x100 [ 12.344752] ? _raw_spin_unlock_irqrestore+0x5f/0x90 [ 12.344773] ? __kthread_parkme+0x82/0x180 [ 12.344793] ? preempt_count_sub+0x50/0x80 [ 12.344817] ? __pfx_kunit_try_run_case+0x10/0x10 [ 12.344839] kunit_generic_run_threadfn_adapter+0x85/0xf0 [ 12.344860] ? __pfx_kunit_generic_run_threadfn_adapter+0x10/0x10 [ 12.344881] kthread+0x337/0x6f0 [ 12.344900] ? trace_preempt_on+0x20/0xc0 [ 12.344923] ? __pfx_kthread+0x10/0x10 [ 12.344942] ? _raw_spin_unlock_irq+0x47/0x80 [ 12.344962] ? calculate_sigpending+0x7b/0xa0 [ 12.344985] ? __pfx_kthread+0x10/0x10 [ 12.345005] ret_from_fork+0x116/0x1d0 [ 12.345032] ? __pfx_kthread+0x10/0x10 [ 12.345051] ret_from_fork_asm+0x1a/0x30 [ 12.345081] </TASK> [ 12.345093] [ 12.357176] Allocated by task 228: [ 12.357525] kasan_save_stack+0x45/0x70 [ 12.358131] kasan_save_track+0x18/0x40 [ 12.358512] kasan_save_alloc_info+0x3b/0x50 [ 12.359013] __kasan_slab_alloc+0x91/0xa0 [ 12.359406] kmem_cache_alloc_noprof+0x123/0x3f0 [ 12.359887] kmem_cache_invalid_free+0x157/0x460 [ 12.360333] kunit_try_run_case+0x1a5/0x480 [ 12.360779] kunit_generic_run_threadfn_adapter+0x85/0xf0 [ 12.361403] kthread+0x337/0x6f0 [ 12.361805] ret_from_fork+0x116/0x1d0 [ 12.362143] ret_from_fork_asm+0x1a/0x30 [ 12.362293] [ 12.362365] The buggy address belongs to the object at ffff8881027dc000 [ 12.362365] which belongs to the cache test_cache of size 200 [ 12.362722] The buggy address is located 1 bytes inside of [ 12.362722] 200-byte region [ffff8881027dc000, ffff8881027dc0c8) [ 12.363859] [ 12.364081] The buggy address belongs to the physical page: [ 12.364589] page: refcount:0 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x1027dc [ 12.365442] flags: 0x200000000000000(node=0|zone=2) [ 12.365952] page_type: f5(slab) [ 12.366357] raw: 0200000000000000 ffff8881015c48c0 dead000000000122 0000000000000000 [ 12.367204] raw: 0000000000000000 00000000800f000f 00000000f5000000 0000000000000000 [ 12.367441] page dumped because: kasan: bad access detected [ 12.367614] [ 12.367818] Memory state around the buggy address: [ 12.368281] ffff8881027dbf00: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc [ 12.369034] ffff8881027dbf80: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc [ 12.369670] >ffff8881027dc000: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 [ 12.370339] ^ [ 12.370463] ffff8881027dc080: 00 00 00 00 00 00 00 00 00 fc fc fc fc fc fc fc [ 12.370778] ffff8881027dc100: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc [ 12.371520] ==================================================================