Date
July 25, 2025, 3:13 a.m.
Environment | |
---|---|
qemu-arm64 | |
qemu-x86_64 |
[ 33.382448] ================================================================== [ 33.382522] BUG: KASAN: invalid-free in kmem_cache_invalid_free+0x184/0x3c8 [ 33.382597] Free of addr fff00000c9ade001 by task kunit_try_catch/243 [ 33.386688] [ 33.386755] CPU: 1 UID: 0 PID: 243 Comm: kunit_try_catch Tainted: G B W N 6.16.0-rc7-next-20250725 #1 PREEMPT [ 33.386851] Tainted: [B]=BAD_PAGE, [W]=WARN, [N]=TEST [ 33.386882] Hardware name: linux,dummy-virt (DT) [ 33.386915] Call trace: [ 33.387071] show_stack+0x20/0x38 (C) [ 33.387251] dump_stack_lvl+0x8c/0xd0 [ 33.387338] print_report+0x118/0x5e8 [ 33.387394] kasan_report_invalid_free+0xc0/0xe8 [ 33.387470] check_slab_allocation+0xfc/0x108 [ 33.387525] __kasan_slab_pre_free+0x2c/0x48 [ 33.387571] kmem_cache_free+0xf0/0x468 [ 33.387741] kmem_cache_invalid_free+0x184/0x3c8 [ 33.387827] kunit_try_run_case+0x170/0x3f0 [ 33.389702] kunit_generic_run_threadfn_adapter+0x88/0x100 [ 33.389759] kthread+0x328/0x630 [ 33.389804] ret_from_fork+0x10/0x20 [ 33.389854] [ 33.389873] Allocated by task 243: [ 33.389906] kasan_save_stack+0x3c/0x68 [ 33.389946] kasan_save_track+0x20/0x40 [ 33.389983] kasan_save_alloc_info+0x40/0x58 [ 33.390022] __kasan_slab_alloc+0xa8/0xb0 [ 33.390055] kmem_cache_alloc_noprof+0x10c/0x398 [ 33.390096] kmem_cache_invalid_free+0x12c/0x3c8 [ 33.390134] kunit_try_run_case+0x170/0x3f0 [ 33.390171] kunit_generic_run_threadfn_adapter+0x88/0x100 [ 33.390212] kthread+0x328/0x630 [ 33.390245] ret_from_fork+0x10/0x20 [ 33.390278] [ 33.390298] The buggy address belongs to the object at fff00000c9ade000 [ 33.390298] which belongs to the cache test_cache of size 200 [ 33.390355] The buggy address is located 1 bytes inside of [ 33.390355] 200-byte region [fff00000c9ade000, fff00000c9ade0c8) [ 33.390414] [ 33.390435] The buggy address belongs to the physical page: [ 33.390474] page: refcount:0 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x109ade [ 33.390529] flags: 0xbfffe0000000000(node=0|zone=2|lastcpupid=0x1ffff) [ 33.390580] page_type: f5(slab) [ 33.390621] raw: 0bfffe0000000000 fff00000c56bca00 dead000000000122 0000000000000000 [ 33.390680] raw: 0000000000000000 00000000800f000f 00000000f5000000 0000000000000000 [ 33.390741] page dumped because: kasan: bad access detected [ 33.390773] [ 33.390813] Memory state around the buggy address: [ 33.390849] fff00000c9addf00: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff [ 33.390923] fff00000c9addf80: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff [ 33.391233] >fff00000c9ade000: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 [ 33.391347] ^ [ 33.391385] fff00000c9ade080: 00 00 00 00 00 00 00 00 00 fc fc fc fc fc fc fc [ 33.391430] fff00000c9ade100: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc [ 33.391499] ==================================================================
[ 26.518527] ================================================================== [ 26.518923] BUG: KASAN: invalid-free in kmem_cache_invalid_free+0x1d8/0x460 [ 26.519177] Free of addr ffff88810625b001 by task kunit_try_catch/260 [ 26.519375] [ 26.519459] CPU: 1 UID: 0 PID: 260 Comm: kunit_try_catch Tainted: G B N 6.16.0-rc7-next-20250725 #1 PREEMPT(voluntary) [ 26.519507] Tainted: [B]=BAD_PAGE, [N]=TEST [ 26.519520] Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.16.3-debian-1.16.3-2 04/01/2014 [ 26.519541] Call Trace: [ 26.519555] <TASK> [ 26.519574] dump_stack_lvl+0x73/0xb0 [ 26.519604] print_report+0xd1/0x640 [ 26.519626] ? __virt_addr_valid+0x1db/0x2d0 [ 26.519652] ? kasan_complete_mode_report_info+0x2a/0x200 [ 26.519678] ? kmem_cache_invalid_free+0x1d8/0x460 [ 26.519702] kasan_report_invalid_free+0x10a/0x130 [ 26.519726] ? kmem_cache_invalid_free+0x1d8/0x460 [ 26.519752] ? kmem_cache_invalid_free+0x1d8/0x460 [ 26.519776] check_slab_allocation+0x11f/0x130 [ 26.519798] __kasan_slab_pre_free+0x28/0x40 [ 26.519818] kmem_cache_free+0xed/0x420 [ 26.519838] ? kmem_cache_alloc_noprof+0x123/0x3f0 [ 26.519863] ? kmem_cache_invalid_free+0x1d8/0x460 [ 26.519889] kmem_cache_invalid_free+0x1d8/0x460 [ 26.519913] ? __pfx_kmem_cache_invalid_free+0x10/0x10 [ 26.519937] ? finish_task_switch.isra.0+0x153/0x700 [ 26.520009] ? __switch_to+0x47/0xf80 [ 26.520040] ? __pfx_read_tsc+0x10/0x10 [ 26.520064] ? ktime_get_ts64+0x86/0x230 [ 26.520091] kunit_try_run_case+0x1a5/0x480 [ 26.520121] ? __pfx_kunit_try_run_case+0x10/0x10 [ 26.520145] ? _raw_spin_lock_irqsave+0xa1/0x100 [ 26.520168] ? _raw_spin_unlock_irqrestore+0x5f/0x90 [ 26.520195] ? __kthread_parkme+0x82/0x180 [ 26.520215] ? preempt_count_sub+0x50/0x80 [ 26.520239] ? __pfx_kunit_try_run_case+0x10/0x10 [ 26.520264] kunit_generic_run_threadfn_adapter+0x85/0xf0 [ 26.520289] ? __pfx_kunit_generic_run_threadfn_adapter+0x10/0x10 [ 26.520314] kthread+0x337/0x6f0 [ 26.520334] ? trace_preempt_on+0x20/0xc0 [ 26.520360] ? __pfx_kthread+0x10/0x10 [ 26.520381] ? _raw_spin_unlock_irq+0x47/0x80 [ 26.520406] ? calculate_sigpending+0x7b/0xa0 [ 26.520431] ? __pfx_kthread+0x10/0x10 [ 26.520453] ret_from_fork+0x116/0x1d0 [ 26.520473] ? __pfx_kthread+0x10/0x10 [ 26.520494] ret_from_fork_asm+0x1a/0x30 [ 26.520527] </TASK> [ 26.520538] [ 26.537621] Allocated by task 260: [ 26.537765] kasan_save_stack+0x45/0x70 [ 26.538284] kasan_save_track+0x18/0x40 [ 26.538673] kasan_save_alloc_info+0x3b/0x50 [ 26.539239] __kasan_slab_alloc+0x91/0xa0 [ 26.539625] kmem_cache_alloc_noprof+0x123/0x3f0 [ 26.540230] kmem_cache_invalid_free+0x157/0x460 [ 26.540666] kunit_try_run_case+0x1a5/0x480 [ 26.540826] kunit_generic_run_threadfn_adapter+0x85/0xf0 [ 26.541456] kthread+0x337/0x6f0 [ 26.541734] ret_from_fork+0x116/0x1d0 [ 26.541871] ret_from_fork_asm+0x1a/0x30 [ 26.542369] [ 26.542549] The buggy address belongs to the object at ffff88810625b000 [ 26.542549] which belongs to the cache test_cache of size 200 [ 26.543533] The buggy address is located 1 bytes inside of [ 26.543533] 200-byte region [ffff88810625b000, ffff88810625b0c8) [ 26.544143] [ 26.544325] The buggy address belongs to the physical page: [ 26.544822] page: refcount:0 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x10625b [ 26.545499] flags: 0x200000000000000(node=0|zone=2) [ 26.545676] page_type: f5(slab) [ 26.545846] raw: 0200000000000000 ffff888106258000 dead000000000122 0000000000000000 [ 26.546622] raw: 0000000000000000 00000000800f000f 00000000f5000000 0000000000000000 [ 26.547358] page dumped because: kasan: bad access detected [ 26.548000] [ 26.548071] Memory state around the buggy address: [ 26.548249] ffff88810625af00: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc [ 26.548899] ffff88810625af80: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc [ 26.549487] >ffff88810625b000: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 [ 26.549703] ^ [ 26.549914] ffff88810625b080: 00 00 00 00 00 00 00 00 00 fc fc fc fc fc fc fc [ 26.550557] ffff88810625b100: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc [ 26.551371] ==================================================================