Date
July 16, 2025, 3:10 p.m.
Environment | |
---|---|
qemu-arm64 | |
qemu-x86_64 |
[ 16.737685] ================================================================== [ 16.737770] BUG: KASAN: slab-out-of-bounds in kmalloc_memmove_invalid_size+0x154/0x2e0 [ 16.737825] Read of size 64 at addr fff00000c6adf404 by task kunit_try_catch/182 [ 16.737877] [ 16.737907] CPU: 1 UID: 0 PID: 182 Comm: kunit_try_catch Tainted: G B N 6.16.0-rc6 #1 PREEMPT [ 16.738060] Tainted: [B]=BAD_PAGE, [N]=TEST [ 16.738088] Hardware name: linux,dummy-virt (DT) [ 16.738280] Call trace: [ 16.738336] show_stack+0x20/0x38 (C) [ 16.738388] dump_stack_lvl+0x8c/0xd0 [ 16.738456] print_report+0x118/0x5d0 [ 16.738539] kasan_report+0xdc/0x128 [ 16.738584] kasan_check_range+0x100/0x1a8 [ 16.738632] __asan_memmove+0x3c/0x98 [ 16.738697] kmalloc_memmove_invalid_size+0x154/0x2e0 [ 16.738820] kunit_try_run_case+0x170/0x3f0 [ 16.738867] kunit_generic_run_threadfn_adapter+0x88/0x100 [ 16.738934] kthread+0x328/0x630 [ 16.739103] ret_from_fork+0x10/0x20 [ 16.739222] [ 16.739244] Allocated by task 182: [ 16.739275] kasan_save_stack+0x3c/0x68 [ 16.739319] kasan_save_track+0x20/0x40 [ 16.739358] kasan_save_alloc_info+0x40/0x58 [ 16.739399] __kasan_kmalloc+0xd4/0xd8 [ 16.739435] __kmalloc_cache_noprof+0x16c/0x3c0 [ 16.739476] kmalloc_memmove_invalid_size+0xb0/0x2e0 [ 16.739614] kunit_try_run_case+0x170/0x3f0 [ 16.739779] kunit_generic_run_threadfn_adapter+0x88/0x100 [ 16.739904] kthread+0x328/0x630 [ 16.739973] ret_from_fork+0x10/0x20 [ 16.740069] [ 16.740157] The buggy address belongs to the object at fff00000c6adf400 [ 16.740157] which belongs to the cache kmalloc-64 of size 64 [ 16.740239] The buggy address is located 4 bytes inside of [ 16.740239] allocated 64-byte region [fff00000c6adf400, fff00000c6adf440) [ 16.740416] [ 16.740464] The buggy address belongs to the physical page: [ 16.740806] page: refcount:0 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x106adf [ 16.740914] flags: 0xbfffe0000000000(node=0|zone=2|lastcpupid=0x1ffff) [ 16.741004] page_type: f5(slab) [ 16.741077] raw: 0bfffe0000000000 fff00000c00018c0 dead000000000122 0000000000000000 [ 16.741150] raw: 0000000000000000 0000000080200020 00000000f5000000 0000000000000000 [ 16.741194] page dumped because: kasan: bad access detected [ 16.741261] [ 16.741630] Memory state around the buggy address: [ 16.741779] fff00000c6adf300: 00 00 00 00 00 01 fc fc fc fc fc fc fc fc fc fc [ 16.741913] fff00000c6adf380: fa fb fb fb fb fb fb fb fc fc fc fc fc fc fc fc [ 16.742001] >fff00000c6adf400: 00 00 00 00 00 00 00 00 fc fc fc fc fc fc fc fc [ 16.742087] ^ [ 16.742121] fff00000c6adf480: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc [ 16.742410] fff00000c6adf500: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc [ 16.742513] ==================================================================
[ 12.774347] ================================================================== [ 12.775670] BUG: KASAN: slab-out-of-bounds in kmalloc_memmove_invalid_size+0x16f/0x330 [ 12.776895] Read of size 64 at addr ffff888103084384 by task kunit_try_catch/199 [ 12.777984] [ 12.778367] CPU: 1 UID: 0 PID: 199 Comm: kunit_try_catch Tainted: G B N 6.16.0-rc6 #1 PREEMPT(voluntary) [ 12.778418] Tainted: [B]=BAD_PAGE, [N]=TEST [ 12.778430] Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.16.3-debian-1.16.3-2 04/01/2014 [ 12.778504] Call Trace: [ 12.778519] <TASK> [ 12.778539] dump_stack_lvl+0x73/0xb0 [ 12.778666] print_report+0xd1/0x610 [ 12.778691] ? __virt_addr_valid+0x1db/0x2d0 [ 12.778718] ? kmalloc_memmove_invalid_size+0x16f/0x330 [ 12.778744] ? kasan_complete_mode_report_info+0x2a/0x200 [ 12.778779] ? kmalloc_memmove_invalid_size+0x16f/0x330 [ 12.778805] kasan_report+0x141/0x180 [ 12.778826] ? kmalloc_memmove_invalid_size+0x16f/0x330 [ 12.778857] kasan_check_range+0x10c/0x1c0 [ 12.778881] __asan_memmove+0x27/0x70 [ 12.778901] kmalloc_memmove_invalid_size+0x16f/0x330 [ 12.778926] ? __pfx_kmalloc_memmove_invalid_size+0x10/0x10 [ 12.778954] ? __schedule+0x10cc/0x2b60 [ 12.779039] ? __pfx_read_tsc+0x10/0x10 [ 12.779065] ? ktime_get_ts64+0x86/0x230 [ 12.779091] kunit_try_run_case+0x1a5/0x480 [ 12.779119] ? __pfx_kunit_try_run_case+0x10/0x10 [ 12.779142] ? _raw_spin_lock_irqsave+0xa1/0x100 [ 12.779166] ? _raw_spin_unlock_irqrestore+0x5f/0x90 [ 12.779197] ? __kthread_parkme+0x82/0x180 [ 12.779219] ? preempt_count_sub+0x50/0x80 [ 12.779244] ? __pfx_kunit_try_run_case+0x10/0x10 [ 12.779268] kunit_generic_run_threadfn_adapter+0x85/0xf0 [ 12.779293] ? __pfx_kunit_generic_run_threadfn_adapter+0x10/0x10 [ 12.779319] kthread+0x337/0x6f0 [ 12.779338] ? trace_preempt_on+0x20/0xc0 [ 12.779363] ? __pfx_kthread+0x10/0x10 [ 12.779384] ? _raw_spin_unlock_irq+0x47/0x80 [ 12.779405] ? calculate_sigpending+0x7b/0xa0 [ 12.779431] ? __pfx_kthread+0x10/0x10 [ 12.779453] ret_from_fork+0x116/0x1d0 [ 12.779472] ? __pfx_kthread+0x10/0x10 [ 12.779493] ret_from_fork_asm+0x1a/0x30 [ 12.779525] </TASK> [ 12.779537] [ 12.791728] Allocated by task 199: [ 12.792094] kasan_save_stack+0x45/0x70 [ 12.792414] kasan_save_track+0x18/0x40 [ 12.792723] kasan_save_alloc_info+0x3b/0x50 [ 12.792942] __kasan_kmalloc+0xb7/0xc0 [ 12.793366] __kmalloc_cache_noprof+0x189/0x420 [ 12.793796] kmalloc_memmove_invalid_size+0xac/0x330 [ 12.794267] kunit_try_run_case+0x1a5/0x480 [ 12.794704] kunit_generic_run_threadfn_adapter+0x85/0xf0 [ 12.794969] kthread+0x337/0x6f0 [ 12.795316] ret_from_fork+0x116/0x1d0 [ 12.795608] ret_from_fork_asm+0x1a/0x30 [ 12.795929] [ 12.796068] The buggy address belongs to the object at ffff888103084380 [ 12.796068] which belongs to the cache kmalloc-64 of size 64 [ 12.796909] The buggy address is located 4 bytes inside of [ 12.796909] allocated 64-byte region [ffff888103084380, ffff8881030843c0) [ 12.797729] [ 12.797870] The buggy address belongs to the physical page: [ 12.798489] page: refcount:0 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x103084 [ 12.798868] flags: 0x200000000000000(node=0|zone=2) [ 12.799451] page_type: f5(slab) [ 12.799801] raw: 0200000000000000 ffff8881000418c0 dead000000000122 0000000000000000 [ 12.800273] raw: 0000000000000000 0000000080200020 00000000f5000000 0000000000000000 [ 12.800837] page dumped because: kasan: bad access detected [ 12.801367] [ 12.801474] Memory state around the buggy address: [ 12.801909] ffff888103084280: 00 00 00 00 00 01 fc fc fc fc fc fc fc fc fc fc [ 12.802341] ffff888103084300: fa fb fb fb fb fb fb fb fc fc fc fc fc fc fc fc [ 12.802849] >ffff888103084380: 00 00 00 00 00 00 00 00 fc fc fc fc fc fc fc fc [ 12.803322] ^ [ 12.803825] ffff888103084400: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc [ 12.804513] ffff888103084480: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc [ 12.804955] ==================================================================