Date
July 8, 2025, 4:38 p.m.
Environment | |
---|---|
qemu-arm64 | |
qemu-x86_64 |
[ 18.554702] ================================================================== [ 18.554831] BUG: KASAN: invalid-free in kmem_cache_invalid_free+0x184/0x3c8 [ 18.554906] Free of addr fff00000c6e5a001 by task kunit_try_catch/213 [ 18.554951] [ 18.555153] CPU: 1 UID: 0 PID: 213 Comm: kunit_try_catch Tainted: G B N 6.15.6-rc1 #1 PREEMPT [ 18.555388] Tainted: [B]=BAD_PAGE, [N]=TEST [ 18.555450] Hardware name: linux,dummy-virt (DT) [ 18.555487] Call trace: [ 18.555682] show_stack+0x20/0x38 (C) [ 18.555837] dump_stack_lvl+0x8c/0xd0 [ 18.556021] print_report+0x118/0x608 [ 18.556081] kasan_report_invalid_free+0xc0/0xe8 [ 18.556129] check_slab_allocation+0xfc/0x108 [ 18.556238] __kasan_slab_pre_free+0x2c/0x48 [ 18.556572] kmem_cache_free+0xf0/0x468 [ 18.556772] kmem_cache_invalid_free+0x184/0x3c8 [ 18.557134] kunit_try_run_case+0x170/0x3f0 [ 18.557817] kunit_generic_run_threadfn_adapter+0x88/0x100 [ 18.558065] kthread+0x328/0x630 [ 18.558474] ret_from_fork+0x10/0x20 [ 18.558597] [ 18.558619] Allocated by task 213: [ 18.558826] kasan_save_stack+0x3c/0x68 [ 18.559052] kasan_save_track+0x20/0x40 [ 18.559165] kasan_save_alloc_info+0x40/0x58 [ 18.559433] __kasan_slab_alloc+0xa8/0xb0 [ 18.559508] kmem_cache_alloc_noprof+0x10c/0x398 [ 18.559748] kmem_cache_invalid_free+0x12c/0x3c8 [ 18.559820] kunit_try_run_case+0x170/0x3f0 [ 18.559988] kunit_generic_run_threadfn_adapter+0x88/0x100 [ 18.560093] kthread+0x328/0x630 [ 18.560231] ret_from_fork+0x10/0x20 [ 18.560487] [ 18.560659] The buggy address belongs to the object at fff00000c6e5a000 [ 18.560659] which belongs to the cache test_cache of size 200 [ 18.560829] The buggy address is located 1 bytes inside of [ 18.560829] 200-byte region [fff00000c6e5a000, fff00000c6e5a0c8) [ 18.560942] [ 18.561093] The buggy address belongs to the physical page: [ 18.561301] page: refcount:0 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x106e5a [ 18.561444] flags: 0xbfffe0000000000(node=0|zone=2|lastcpupid=0x1ffff) [ 18.561565] page_type: f5(slab) [ 18.561727] raw: 0bfffe0000000000 fff00000c5b8bdc0 dead000000000122 0000000000000000 [ 18.561823] raw: 0000000000000000 00000000800f000f 00000000f5000000 0000000000000000 [ 18.562010] page dumped because: kasan: bad access detected [ 18.562246] [ 18.562358] Memory state around the buggy address: [ 18.562441] fff00000c6e59f00: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc [ 18.562577] fff00000c6e59f80: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc [ 18.562653] >fff00000c6e5a000: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 [ 18.562693] ^ [ 18.562745] fff00000c6e5a080: 00 00 00 00 00 00 00 00 00 fc fc fc fc fc fc fc [ 18.563032] fff00000c6e5a100: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc [ 18.563247] ==================================================================
[ 12.046727] ================================================================== [ 12.048296] BUG: KASAN: invalid-free in kmem_cache_invalid_free+0x1d8/0x460 [ 12.048786] Free of addr ffff8881029de001 by task kunit_try_catch/231 [ 12.049680] [ 12.049811] CPU: 1 UID: 0 PID: 231 Comm: kunit_try_catch Tainted: G B N 6.15.6-rc1 #1 PREEMPT(voluntary) [ 12.049917] Tainted: [B]=BAD_PAGE, [N]=TEST [ 12.049931] Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.16.3-debian-1.16.3-2 04/01/2014 [ 12.049954] Call Trace: [ 12.049969] <TASK> [ 12.049986] dump_stack_lvl+0x73/0xb0 [ 12.050016] print_report+0xd1/0x650 [ 12.050042] ? __virt_addr_valid+0x1db/0x2d0 [ 12.050067] ? kasan_complete_mode_report_info+0x2a/0x200 [ 12.050091] ? kmem_cache_invalid_free+0x1d8/0x460 [ 12.050114] kasan_report_invalid_free+0x10a/0x130 [ 12.050140] ? kmem_cache_invalid_free+0x1d8/0x460 [ 12.050164] ? kmem_cache_invalid_free+0x1d8/0x460 [ 12.050187] check_slab_allocation+0x11f/0x130 [ 12.050210] __kasan_slab_pre_free+0x28/0x40 [ 12.050233] kmem_cache_free+0xed/0x420 [ 12.050255] ? kmem_cache_alloc_noprof+0x123/0x3f0 [ 12.050277] ? kmem_cache_invalid_free+0x1d8/0x460 [ 12.050302] kmem_cache_invalid_free+0x1d8/0x460 [ 12.050325] ? __pfx_kmem_cache_invalid_free+0x10/0x10 [ 12.050346] ? finish_task_switch.isra.0+0x153/0x700 [ 12.050372] ? __switch_to+0x5d9/0xf60 [ 12.050394] ? dequeue_task_fair+0x166/0x4e0 [ 12.050421] ? __pfx_read_tsc+0x10/0x10 [ 12.050442] ? ktime_get_ts64+0x86/0x230 [ 12.050470] kunit_try_run_case+0x1a5/0x480 [ 12.050492] ? __pfx_kunit_try_run_case+0x10/0x10 [ 12.050522] ? _raw_spin_lock_irqsave+0xa1/0x100 [ 12.050549] ? _raw_spin_unlock_irqrestore+0x5f/0x90 [ 12.050574] ? __kthread_parkme+0x82/0x180 [ 12.050597] ? preempt_count_sub+0x50/0x80 [ 12.050622] ? __pfx_kunit_try_run_case+0x10/0x10 [ 12.050644] kunit_generic_run_threadfn_adapter+0x85/0xf0 [ 12.050668] ? __pfx_kunit_generic_run_threadfn_adapter+0x10/0x10 [ 12.050693] kthread+0x337/0x6f0 [ 12.050711] ? trace_preempt_on+0x20/0xc0 [ 12.050736] ? __pfx_kthread+0x10/0x10 [ 12.050755] ? _raw_spin_unlock_irq+0x47/0x80 [ 12.050778] ? calculate_sigpending+0x7b/0xa0 [ 12.050801] ? __pfx_kthread+0x10/0x10 [ 12.050821] ret_from_fork+0x41/0x80 [ 12.050843] ? __pfx_kthread+0x10/0x10 [ 12.050869] ret_from_fork_asm+0x1a/0x30 [ 12.050911] </TASK> [ 12.050922] [ 12.059661] Allocated by task 231: [ 12.059821] kasan_save_stack+0x45/0x70 [ 12.060086] kasan_save_track+0x18/0x40 [ 12.060259] kasan_save_alloc_info+0x3b/0x50 [ 12.060462] __kasan_slab_alloc+0x91/0xa0 [ 12.060679] kmem_cache_alloc_noprof+0x123/0x3f0 [ 12.060897] kmem_cache_invalid_free+0x157/0x460 [ 12.061164] kunit_try_run_case+0x1a5/0x480 [ 12.061316] kunit_generic_run_threadfn_adapter+0x85/0xf0 [ 12.061572] kthread+0x337/0x6f0 [ 12.061747] ret_from_fork+0x41/0x80 [ 12.062358] ret_from_fork_asm+0x1a/0x30 [ 12.062616] [ 12.062720] The buggy address belongs to the object at ffff8881029de000 [ 12.062720] which belongs to the cache test_cache of size 200 [ 12.063268] The buggy address is located 1 bytes inside of [ 12.063268] 200-byte region [ffff8881029de000, ffff8881029de0c8) [ 12.063784] [ 12.063939] The buggy address belongs to the physical page: [ 12.064181] page: refcount:0 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x1029de [ 12.064430] flags: 0x200000000000000(node=0|zone=2) [ 12.064597] page_type: f5(slab) [ 12.064722] raw: 0200000000000000 ffff8881010b33c0 dead000000000122 0000000000000000 [ 12.065041] raw: 0000000000000000 00000000800f000f 00000000f5000000 0000000000000000 [ 12.065397] page dumped because: kasan: bad access detected [ 12.065896] [ 12.065983] Memory state around the buggy address: [ 12.066192] ffff8881029ddf00: 00 00 00 00 00 00 00 00 00 00 00 00 fc fc fc fc [ 12.066411] ffff8881029ddf80: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc [ 12.066902] >ffff8881029de000: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 [ 12.067230] ^ [ 12.067379] ffff8881029de080: 00 00 00 00 00 00 00 00 00 fc fc fc fc fc fc fc [ 12.067919] ffff8881029de100: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc [ 12.068222] ==================================================================