Date
July 15, 2025, 11:09 a.m.
Environment | |
---|---|
qemu-arm64 | |
qemu-x86_64 |
[ 15.512655] ================================================================== [ 15.512717] BUG: KASAN: slab-out-of-bounds in kmalloc_oob_memset_2+0x150/0x2f8 [ 15.512768] Write of size 2 at addr fff00000c592ca77 by task kunit_try_catch/173 [ 15.512819] [ 15.513089] CPU: 1 UID: 0 PID: 173 Comm: kunit_try_catch Tainted: G B N 6.16.0-rc6 #1 PREEMPT [ 15.513302] Tainted: [B]=BAD_PAGE, [N]=TEST [ 15.513402] Hardware name: linux,dummy-virt (DT) [ 15.513453] Call trace: [ 15.513475] show_stack+0x20/0x38 (C) [ 15.513525] dump_stack_lvl+0x8c/0xd0 [ 15.513569] print_report+0x118/0x5d0 [ 15.513749] kasan_report+0xdc/0x128 [ 15.513804] kasan_check_range+0x100/0x1a8 [ 15.513893] __asan_memset+0x34/0x78 [ 15.513934] kmalloc_oob_memset_2+0x150/0x2f8 [ 15.514001] kunit_try_run_case+0x170/0x3f0 [ 15.514100] kunit_generic_run_threadfn_adapter+0x88/0x100 [ 15.514151] kthread+0x328/0x630 [ 15.514298] ret_from_fork+0x10/0x20 [ 15.514348] [ 15.514384] Allocated by task 173: [ 15.514411] kasan_save_stack+0x3c/0x68 [ 15.514570] kasan_save_track+0x20/0x40 [ 15.514617] kasan_save_alloc_info+0x40/0x58 [ 15.514656] __kasan_kmalloc+0xd4/0xd8 [ 15.514691] __kmalloc_cache_noprof+0x16c/0x3c0 [ 15.514729] kmalloc_oob_memset_2+0xb0/0x2f8 [ 15.514765] kunit_try_run_case+0x170/0x3f0 [ 15.514801] kunit_generic_run_threadfn_adapter+0x88/0x100 [ 15.514842] kthread+0x328/0x630 [ 15.515189] ret_from_fork+0x10/0x20 [ 15.515272] [ 15.515292] The buggy address belongs to the object at fff00000c592ca00 [ 15.515292] which belongs to the cache kmalloc-128 of size 128 [ 15.515377] The buggy address is located 119 bytes inside of [ 15.515377] allocated 120-byte region [fff00000c592ca00, fff00000c592ca78) [ 15.515512] [ 15.515580] The buggy address belongs to the physical page: [ 15.515609] page: refcount:0 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x10592c [ 15.515706] flags: 0xbfffe0000000000(node=0|zone=2|lastcpupid=0x1ffff) [ 15.515797] page_type: f5(slab) [ 15.515903] raw: 0bfffe0000000000 fff00000c0001a00 dead000000000122 0000000000000000 [ 15.516049] raw: 0000000000000000 0000000080100010 00000000f5000000 0000000000000000 [ 15.516089] page dumped because: kasan: bad access detected [ 15.516157] [ 15.516201] Memory state around the buggy address: [ 15.516232] fff00000c592c900: fa fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 15.516273] fff00000c592c980: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc [ 15.516497] >fff00000c592ca00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 fc [ 15.516537] ^ [ 15.516755] fff00000c592ca80: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc [ 15.516853] fff00000c592cb00: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc [ 15.516924] ==================================================================
[ 12.581934] ================================================================== [ 12.582313] BUG: KASAN: slab-out-of-bounds in kmalloc_oob_memset_2+0x166/0x330 [ 12.583510] Write of size 2 at addr ffff8881032bb877 by task kunit_try_catch/189 [ 12.584656] [ 12.584903] CPU: 0 UID: 0 PID: 189 Comm: kunit_try_catch Tainted: G B N 6.16.0-rc6 #1 PREEMPT(voluntary) [ 12.584951] Tainted: [B]=BAD_PAGE, [N]=TEST [ 12.584962] Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.16.3-debian-1.16.3-2 04/01/2014 [ 12.584984] Call Trace: [ 12.584995] <TASK> [ 12.585012] dump_stack_lvl+0x73/0xb0 [ 12.585046] print_report+0xd1/0x610 [ 12.585068] ? __virt_addr_valid+0x1db/0x2d0 [ 12.585092] ? kmalloc_oob_memset_2+0x166/0x330 [ 12.585114] ? kasan_complete_mode_report_info+0x2a/0x200 [ 12.585138] ? kmalloc_oob_memset_2+0x166/0x330 [ 12.585160] kasan_report+0x141/0x180 [ 12.585182] ? kmalloc_oob_memset_2+0x166/0x330 [ 12.585209] kasan_check_range+0x10c/0x1c0 [ 12.585232] __asan_memset+0x27/0x50 [ 12.585251] kmalloc_oob_memset_2+0x166/0x330 [ 12.585273] ? __kasan_check_write+0x18/0x20 [ 12.585293] ? __pfx_kmalloc_oob_memset_2+0x10/0x10 [ 12.585315] ? sysvec_apic_timer_interrupt+0x50/0x90 [ 12.585341] ? trace_hardirqs_on+0x37/0xe0 [ 12.585365] ? __pfx_read_tsc+0x10/0x10 [ 12.585386] ? ktime_get_ts64+0x86/0x230 [ 12.585411] kunit_try_run_case+0x1a5/0x480 [ 12.585640] ? __pfx_kunit_try_run_case+0x10/0x10 [ 12.585690] ? queued_spin_lock_slowpath+0x116/0xb40 [ 12.585719] ? __kthread_parkme+0x82/0x180 [ 12.585743] ? preempt_count_sub+0x50/0x80 [ 12.585777] ? __pfx_kunit_try_run_case+0x10/0x10 [ 12.585801] kunit_generic_run_threadfn_adapter+0x85/0xf0 [ 12.585827] ? __pfx_kunit_generic_run_threadfn_adapter+0x10/0x10 [ 12.585854] kthread+0x337/0x6f0 [ 12.585874] ? trace_preempt_on+0x20/0xc0 [ 12.585896] ? __pfx_kthread+0x10/0x10 [ 12.585917] ? _raw_spin_unlock_irq+0x47/0x80 [ 12.585939] ? calculate_sigpending+0x7b/0xa0 [ 12.585964] ? __pfx_kthread+0x10/0x10 [ 12.585986] ret_from_fork+0x116/0x1d0 [ 12.586005] ? __pfx_kthread+0x10/0x10 [ 12.586026] ret_from_fork_asm+0x1a/0x30 [ 12.586057] </TASK> [ 12.586068] [ 12.597417] Allocated by task 189: [ 12.598007] kasan_save_stack+0x45/0x70 [ 12.598436] kasan_save_track+0x18/0x40 [ 12.598714] kasan_save_alloc_info+0x3b/0x50 [ 12.599141] __kasan_kmalloc+0xb7/0xc0 [ 12.599622] __kmalloc_cache_noprof+0x189/0x420 [ 12.599866] kmalloc_oob_memset_2+0xac/0x330 [ 12.600069] kunit_try_run_case+0x1a5/0x480 [ 12.600264] kunit_generic_run_threadfn_adapter+0x85/0xf0 [ 12.600978] kthread+0x337/0x6f0 [ 12.601152] ret_from_fork+0x116/0x1d0 [ 12.601558] ret_from_fork_asm+0x1a/0x30 [ 12.601833] [ 12.602100] The buggy address belongs to the object at ffff8881032bb800 [ 12.602100] which belongs to the cache kmalloc-128 of size 128 [ 12.602995] The buggy address is located 119 bytes inside of [ 12.602995] allocated 120-byte region [ffff8881032bb800, ffff8881032bb878) [ 12.603984] [ 12.604075] The buggy address belongs to the physical page: [ 12.604319] page: refcount:0 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x1032bb [ 12.604896] flags: 0x200000000000000(node=0|zone=2) [ 12.605120] page_type: f5(slab) [ 12.605281] raw: 0200000000000000 ffff888100041a00 dead000000000122 0000000000000000 [ 12.606305] raw: 0000000000000000 0000000080100010 00000000f5000000 0000000000000000 [ 12.607022] page dumped because: kasan: bad access detected [ 12.607269] [ 12.607617] Memory state around the buggy address: [ 12.607867] ffff8881032bb700: fa fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 12.608159] ffff8881032bb780: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc [ 12.608889] >ffff8881032bb800: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 fc [ 12.609390] ^ [ 12.610049] ffff8881032bb880: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc [ 12.610741] ffff8881032bb900: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc [ 12.611056] ==================================================================