Date
July 22, 2025, 5:13 a.m.
Environment | |
---|---|
qemu-arm64 | |
qemu-x86_64 |
[ 30.443481] ================================================================== [ 30.443575] BUG: KASAN: slab-out-of-bounds in kmalloc_memmove_invalid_size+0x154/0x2e0 [ 30.443637] Read of size 64 at addr fff00000c923d204 by task kunit_try_catch/213 [ 30.443687] [ 30.443719] CPU: 1 UID: 0 PID: 213 Comm: kunit_try_catch Tainted: G B W N 6.16.0-rc7-next-20250722 #1 PREEMPT [ 30.443808] Tainted: [B]=BAD_PAGE, [W]=WARN, [N]=TEST [ 30.444217] Hardware name: linux,dummy-virt (DT) [ 30.444325] Call trace: [ 30.444351] show_stack+0x20/0x38 (C) [ 30.444404] dump_stack_lvl+0x8c/0xd0 [ 30.444450] print_report+0x118/0x5e8 [ 30.444497] kasan_report+0xdc/0x128 [ 30.444538] kasan_check_range+0x100/0x1a8 [ 30.444604] __asan_memmove+0x3c/0x98 [ 30.444647] kmalloc_memmove_invalid_size+0x154/0x2e0 [ 30.444700] kunit_try_run_case+0x170/0x3f0 [ 30.444746] kunit_generic_run_threadfn_adapter+0x88/0x100 [ 30.444798] kthread+0x328/0x630 [ 30.445062] ret_from_fork+0x10/0x20 [ 30.445379] [ 30.445425] Allocated by task 213: [ 30.445547] kasan_save_stack+0x3c/0x68 [ 30.445656] kasan_save_track+0x20/0x40 [ 30.445725] kasan_save_alloc_info+0x40/0x58 [ 30.445877] __kasan_kmalloc+0xd4/0xd8 [ 30.445914] __kmalloc_cache_noprof+0x16c/0x3c0 [ 30.445962] kmalloc_memmove_invalid_size+0xb0/0x2e0 [ 30.446011] kunit_try_run_case+0x170/0x3f0 [ 30.446051] kunit_generic_run_threadfn_adapter+0x88/0x100 [ 30.446573] kthread+0x328/0x630 [ 30.446669] ret_from_fork+0x10/0x20 [ 30.446756] [ 30.446854] The buggy address belongs to the object at fff00000c923d200 [ 30.446854] which belongs to the cache kmalloc-64 of size 64 [ 30.446969] The buggy address is located 4 bytes inside of [ 30.446969] allocated 64-byte region [fff00000c923d200, fff00000c923d240) [ 30.447059] [ 30.447078] The buggy address belongs to the physical page: [ 30.447562] page: refcount:0 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x10923d [ 30.447689] flags: 0xbfffe0000000000(node=0|zone=2|lastcpupid=0x1ffff) [ 30.447836] page_type: f5(slab) [ 30.447878] raw: 0bfffe0000000000 fff00000c00018c0 dead000000000122 0000000000000000 [ 30.447955] raw: 0000000000000000 0000000080200020 00000000f5000000 0000000000000000 [ 30.448328] page dumped because: kasan: bad access detected [ 30.448381] [ 30.448466] Memory state around the buggy address: [ 30.448581] fff00000c923d100: 00 00 00 00 00 01 fc fc fc fc fc fc fc fc fc fc [ 30.448635] fff00000c923d180: fa fb fb fb fb fb fb fb fc fc fc fc fc fc fc fc [ 30.448767] >fff00000c923d200: 00 00 00 00 00 00 00 00 fc fc fc fc fc fc fc fc [ 30.448807] ^ [ 30.449110] fff00000c923d280: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc [ 30.449234] fff00000c923d300: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc [ 30.449332] ==================================================================
[ 25.330613] ================================================================== [ 25.331114] BUG: KASAN: slab-out-of-bounds in kmalloc_memmove_invalid_size+0x16f/0x330 [ 25.331740] Read of size 64 at addr ffff8881055f0104 by task kunit_try_catch/230 [ 25.332070] [ 25.332177] CPU: 1 UID: 0 PID: 230 Comm: kunit_try_catch Tainted: G B N 6.16.0-rc7-next-20250722 #1 PREEMPT(voluntary) [ 25.332225] Tainted: [B]=BAD_PAGE, [N]=TEST [ 25.332238] Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.16.3-debian-1.16.3-2 04/01/2014 [ 25.332258] Call Trace: [ 25.332283] <TASK> [ 25.332299] dump_stack_lvl+0x73/0xb0 [ 25.332328] print_report+0xd1/0x640 [ 25.332351] ? __virt_addr_valid+0x1db/0x2d0 [ 25.332374] ? kmalloc_memmove_invalid_size+0x16f/0x330 [ 25.332399] ? kasan_complete_mode_report_info+0x2a/0x200 [ 25.332425] ? kmalloc_memmove_invalid_size+0x16f/0x330 [ 25.332449] kasan_report+0x141/0x180 [ 25.332471] ? kmalloc_memmove_invalid_size+0x16f/0x330 [ 25.332499] kasan_check_range+0x10c/0x1c0 [ 25.332523] __asan_memmove+0x27/0x70 [ 25.332546] kmalloc_memmove_invalid_size+0x16f/0x330 [ 25.332570] ? __pfx_kmalloc_memmove_invalid_size+0x10/0x10 [ 25.332595] ? __schedule+0x10da/0x2b60 [ 25.332620] ? __pfx_read_tsc+0x10/0x10 [ 25.332803] ? ktime_get_ts64+0x86/0x230 [ 25.332848] kunit_try_run_case+0x1a5/0x480 [ 25.332885] ? __pfx_kunit_try_run_case+0x10/0x10 [ 25.332909] ? _raw_spin_lock_irqsave+0xa1/0x100 [ 25.332934] ? _raw_spin_unlock_irqrestore+0x5f/0x90 [ 25.332959] ? __kthread_parkme+0x82/0x180 [ 25.332979] ? preempt_count_sub+0x50/0x80 [ 25.333001] ? __pfx_kunit_try_run_case+0x10/0x10 [ 25.333025] kunit_generic_run_threadfn_adapter+0x85/0xf0 [ 25.333048] ? __pfx_kunit_generic_run_threadfn_adapter+0x10/0x10 [ 25.333072] kthread+0x337/0x6f0 [ 25.333091] ? trace_preempt_on+0x20/0xc0 [ 25.333114] ? __pfx_kthread+0x10/0x10 [ 25.333134] ? _raw_spin_unlock_irq+0x47/0x80 [ 25.333158] ? calculate_sigpending+0x7b/0xa0 [ 25.333192] ? __pfx_kthread+0x10/0x10 [ 25.333213] ret_from_fork+0x116/0x1d0 [ 25.333233] ? __pfx_kthread+0x10/0x10 [ 25.333253] ret_from_fork_asm+0x1a/0x30 [ 25.333284] </TASK> [ 25.333295] [ 25.340694] Allocated by task 230: [ 25.340852] kasan_save_stack+0x45/0x70 [ 25.341049] kasan_save_track+0x18/0x40 [ 25.341247] kasan_save_alloc_info+0x3b/0x50 [ 25.341405] __kasan_kmalloc+0xb7/0xc0 [ 25.341539] __kmalloc_cache_noprof+0x189/0x420 [ 25.341698] kmalloc_memmove_invalid_size+0xac/0x330 [ 25.341901] kunit_try_run_case+0x1a5/0x480 [ 25.342161] kunit_generic_run_threadfn_adapter+0x85/0xf0 [ 25.342417] kthread+0x337/0x6f0 [ 25.342583] ret_from_fork+0x116/0x1d0 [ 25.342770] ret_from_fork_asm+0x1a/0x30 [ 25.342974] [ 25.343065] The buggy address belongs to the object at ffff8881055f0100 [ 25.343065] which belongs to the cache kmalloc-64 of size 64 [ 25.343824] The buggy address is located 4 bytes inside of [ 25.343824] allocated 64-byte region [ffff8881055f0100, ffff8881055f0140) [ 25.344405] [ 25.344573] The buggy address belongs to the physical page: [ 25.344767] page: refcount:0 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x1055f0 [ 25.345130] flags: 0x200000000000000(node=0|zone=2) [ 25.345465] page_type: f5(slab) [ 25.345584] raw: 0200000000000000 ffff8881000418c0 dead000000000122 0000000000000000 [ 25.345815] raw: 0000000000000000 0000000080200020 00000000f5000000 0000000000000000 [ 25.346050] page dumped because: kasan: bad access detected [ 25.346218] [ 25.346431] Memory state around the buggy address: [ 25.346695] ffff8881055f0000: 00 00 00 00 00 01 fc fc fc fc fc fc fc fc fc fc [ 25.347042] ffff8881055f0080: fa fb fb fb fb fb fb fb fc fc fc fc fc fc fc fc [ 25.347749] >ffff8881055f0100: 00 00 00 00 00 00 00 00 fc fc fc fc fc fc fc fc [ 25.348091] ^ [ 25.348449] ffff8881055f0180: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc [ 25.348720] ffff8881055f0200: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc [ 25.348981] ==================================================================