Date
June 7, 2025, 10:40 a.m.
Environment | |
---|---|
qemu-arm64 | |
qemu-x86_64 |
[ 22.991068] ================================================================== [ 22.992176] BUG: KASAN: slab-out-of-bounds in kmalloc_memmove_invalid_size+0x154/0x2e8 [ 22.992997] Read of size 64 at addr fff00000c64c9f04 by task kunit_try_catch/171 [ 22.994454] [ 22.994698] CPU: 0 UID: 0 PID: 171 Comm: kunit_try_catch Tainted: G B N 6.14.11-rc1 #1 [ 22.994803] Tainted: [B]=BAD_PAGE, [N]=TEST [ 22.994835] Hardware name: linux,dummy-virt (DT) [ 22.994873] Call trace: [ 22.994954] show_stack+0x20/0x38 (C) [ 22.995453] dump_stack_lvl+0x8c/0xd0 [ 22.995604] print_report+0x118/0x608 [ 22.995734] kasan_report+0xdc/0x128 [ 22.995872] kasan_check_range+0x100/0x1a8 [ 22.996012] __asan_memmove+0x3c/0x98 [ 22.996127] kmalloc_memmove_invalid_size+0x154/0x2e8 [ 22.996248] kunit_try_run_case+0x170/0x3f0 [ 22.996369] kunit_generic_run_threadfn_adapter+0x88/0x100 [ 22.996480] kthread+0x318/0x620 [ 22.996536] ret_from_fork+0x10/0x20 [ 22.996599] [ 23.004815] Allocated by task 171: [ 23.005289] kasan_save_stack+0x3c/0x68 [ 23.005709] kasan_save_track+0x20/0x40 [ 23.006954] kasan_save_alloc_info+0x40/0x58 [ 23.007574] __kasan_kmalloc+0xd4/0xd8 [ 23.008012] __kmalloc_cache_noprof+0x16c/0x3c0 [ 23.008447] kmalloc_memmove_invalid_size+0xb0/0x2e8 [ 23.009467] kunit_try_run_case+0x170/0x3f0 [ 23.010066] kunit_generic_run_threadfn_adapter+0x88/0x100 [ 23.010697] kthread+0x318/0x620 [ 23.011168] ret_from_fork+0x10/0x20 [ 23.011655] [ 23.011965] The buggy address belongs to the object at fff00000c64c9f00 [ 23.011965] which belongs to the cache kmalloc-64 of size 64 [ 23.013022] The buggy address is located 4 bytes inside of [ 23.013022] allocated 64-byte region [fff00000c64c9f00, fff00000c64c9f40) [ 23.014382] [ 23.015551] The buggy address belongs to the physical page: [ 23.016048] page: refcount:0 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x1064c9 [ 23.016638] flags: 0xbfffe0000000000(node=0|zone=2|lastcpupid=0x1ffff) [ 23.018668] page_type: f5(slab) [ 23.019359] raw: 0bfffe0000000000 fff00000c00018c0 dead000000000122 0000000000000000 [ 23.019960] raw: 0000000000000000 0000000080200020 00000000f5000000 0000000000000000 [ 23.021292] page dumped because: kasan: bad access detected [ 23.022140] [ 23.023027] Memory state around the buggy address: [ 23.023793] fff00000c64c9e00: 00 00 00 00 00 01 fc fc fc fc fc fc fc fc fc fc [ 23.024594] fff00000c64c9e80: fa fb fb fb fb fb fb fb fc fc fc fc fc fc fc fc [ 23.025814] >fff00000c64c9f00: 00 00 00 00 00 00 00 00 fc fc fc fc fc fc fc fc [ 23.026552] ^ [ 23.027210] fff00000c64c9f80: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc [ 23.027794] fff00000c64ca000: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff [ 23.028598] ==================================================================
[ 17.881357] ================================================================== [ 17.882096] BUG: KASAN: slab-out-of-bounds in kmalloc_memmove_invalid_size+0x170/0x330 [ 17.882718] Read of size 64 at addr ffff88810297ae84 by task kunit_try_catch/190 [ 17.883266] [ 17.883499] CPU: 1 UID: 0 PID: 190 Comm: kunit_try_catch Tainted: G B N 6.14.11-rc1 #1 [ 17.883601] Tainted: [B]=BAD_PAGE, [N]=TEST [ 17.883628] Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.16.3-debian-1.16.3-2 04/01/2014 [ 17.883670] Call Trace: [ 17.883715] <TASK> [ 17.883756] dump_stack_lvl+0x73/0xb0 [ 17.883836] print_report+0xd1/0x650 [ 17.883910] ? __virt_addr_valid+0x1db/0x2d0 [ 17.883965] ? kmalloc_memmove_invalid_size+0x170/0x330 [ 17.884023] ? kasan_complete_mode_report_info+0x2a/0x200 [ 17.884082] ? kmalloc_memmove_invalid_size+0x170/0x330 [ 17.884142] kasan_report+0x140/0x180 [ 17.884193] ? kmalloc_memmove_invalid_size+0x170/0x330 [ 17.884252] kasan_check_range+0x10c/0x1c0 [ 17.884305] __asan_memmove+0x27/0x70 [ 17.884356] kmalloc_memmove_invalid_size+0x170/0x330 [ 17.884412] ? __pfx_kmalloc_memmove_invalid_size+0x10/0x10 [ 17.884474] ? __schedule+0xce8/0x2840 [ 17.884540] ? __pfx_read_tsc+0x10/0x10 [ 17.884597] ? ktime_get_ts64+0x86/0x230 [ 17.884663] kunit_try_run_case+0x1a6/0x480 [ 17.884717] ? __pfx_kunit_try_run_case+0x10/0x10 [ 17.884767] ? _raw_spin_lock_irqsave+0xa2/0x110 [ 17.884821] ? _raw_spin_unlock_irqrestore+0x5f/0x90 [ 17.884955] ? __kthread_parkme+0x82/0x160 [ 17.885023] ? preempt_count_sub+0x50/0x80 [ 17.885086] ? __pfx_kunit_try_run_case+0x10/0x10 [ 17.885138] kunit_generic_run_threadfn_adapter+0x85/0xf0 [ 17.885200] ? __pfx_kunit_generic_run_threadfn_adapter+0x10/0x10 [ 17.885402] kthread+0x324/0x6e0 [ 17.885601] ? trace_preempt_on+0x20/0xc0 [ 17.885678] ? __pfx_kthread+0x10/0x10 [ 17.885720] ? _raw_spin_unlock_irq+0x47/0x80 [ 17.885763] ? calculate_sigpending+0x7b/0xa0 [ 17.885804] ? __pfx_kthread+0x10/0x10 [ 17.885846] ret_from_fork+0x41/0x80 [ 17.885906] ? __pfx_kthread+0x10/0x10 [ 17.885948] ret_from_fork_asm+0x1a/0x30 [ 17.886003] </TASK> [ 17.886019] [ 17.904627] Allocated by task 190: [ 17.905033] kasan_save_stack+0x45/0x70 [ 17.905308] kasan_save_track+0x18/0x40 [ 17.906002] kasan_save_alloc_info+0x3b/0x50 [ 17.906838] __kasan_kmalloc+0xb7/0xc0 [ 17.907188] __kmalloc_cache_noprof+0x18a/0x420 [ 17.907795] kmalloc_memmove_invalid_size+0xad/0x330 [ 17.908660] kunit_try_run_case+0x1a6/0x480 [ 17.909050] kunit_generic_run_threadfn_adapter+0x85/0xf0 [ 17.909515] kthread+0x324/0x6e0 [ 17.910774] ret_from_fork+0x41/0x80 [ 17.911035] ret_from_fork_asm+0x1a/0x30 [ 17.911256] [ 17.911877] The buggy address belongs to the object at ffff88810297ae80 [ 17.911877] which belongs to the cache kmalloc-64 of size 64 [ 17.912765] The buggy address is located 4 bytes inside of [ 17.912765] allocated 64-byte region [ffff88810297ae80, ffff88810297aec0) [ 17.913743] [ 17.913936] The buggy address belongs to the physical page: [ 17.915015] page: refcount:0 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x10297a [ 17.915489] flags: 0x200000000000000(node=0|zone=2) [ 17.916312] page_type: f5(slab) [ 17.916544] raw: 0200000000000000 ffff8881000418c0 dead000000000122 0000000000000000 [ 17.917113] raw: 0000000000000000 0000000080200020 00000000f5000000 0000000000000000 [ 17.917790] page dumped because: kasan: bad access detected [ 17.918351] [ 17.919110] Memory state around the buggy address: [ 17.919393] ffff88810297ad80: 00 00 00 00 00 01 fc fc fc fc fc fc fc fc fc fc [ 17.920278] ffff88810297ae00: fa fb fb fb fb fb fb fb fc fc fc fc fc fc fc fc [ 17.920980] >ffff88810297ae80: 00 00 00 00 00 00 00 00 fc fc fc fc fc fc fc fc [ 17.921409] ^ [ 17.922021] ffff88810297af00: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc [ 17.922463] ffff88810297af80: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc [ 17.923013] ==================================================================