Date
July 23, 2025, 3:10 a.m.
Environment | |
---|---|
qemu-arm64 | |
qemu-x86_64 |
[ 30.411571] ================================================================== [ 30.411653] BUG: KASAN: slab-out-of-bounds in kmalloc_oob_memset_2+0x150/0x2f8 [ 30.411909] Write of size 2 at addr fff00000c99bca77 by task kunit_try_catch/205 [ 30.411975] [ 30.412035] CPU: 0 UID: 0 PID: 205 Comm: kunit_try_catch Tainted: G B N 6.16.0-rc7-next-20250723 #1 PREEMPT [ 30.412276] Tainted: [B]=BAD_PAGE, [N]=TEST [ 30.412302] Hardware name: linux,dummy-virt (DT) [ 30.412648] Call trace: [ 30.412694] show_stack+0x20/0x38 (C) [ 30.412785] dump_stack_lvl+0x8c/0xd0 [ 30.412893] print_report+0x118/0x5e8 [ 30.412987] kasan_report+0xdc/0x128 [ 30.413333] kasan_check_range+0x100/0x1a8 [ 30.413472] __asan_memset+0x34/0x78 [ 30.413541] kmalloc_oob_memset_2+0x150/0x2f8 [ 30.413784] kunit_try_run_case+0x170/0x3f0 [ 30.414026] kunit_generic_run_threadfn_adapter+0x88/0x100 [ 30.414139] kthread+0x328/0x630 [ 30.414294] ret_from_fork+0x10/0x20 [ 30.414433] [ 30.414483] Allocated by task 205: [ 30.414565] kasan_save_stack+0x3c/0x68 [ 30.415042] kasan_save_track+0x20/0x40 [ 30.415182] kasan_save_alloc_info+0x40/0x58 [ 30.415261] __kasan_kmalloc+0xd4/0xd8 [ 30.415430] __kmalloc_cache_noprof+0x16c/0x3c0 [ 30.415487] kmalloc_oob_memset_2+0xb0/0x2f8 [ 30.415557] kunit_try_run_case+0x170/0x3f0 [ 30.415805] kunit_generic_run_threadfn_adapter+0x88/0x100 [ 30.416106] kthread+0x328/0x630 [ 30.416308] ret_from_fork+0x10/0x20 [ 30.416383] [ 30.416660] The buggy address belongs to the object at fff00000c99bca00 [ 30.416660] which belongs to the cache kmalloc-128 of size 128 [ 30.416842] The buggy address is located 119 bytes inside of [ 30.416842] allocated 120-byte region [fff00000c99bca00, fff00000c99bca78) [ 30.417009] [ 30.417068] The buggy address belongs to the physical page: [ 30.417224] page: refcount:0 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x1099bc [ 30.417329] flags: 0xbfffe0000000000(node=0|zone=2|lastcpupid=0x1ffff) [ 30.417431] page_type: f5(slab) [ 30.417473] raw: 0bfffe0000000000 fff00000c0001a00 dead000000000122 0000000000000000 [ 30.417542] raw: 0000000000000000 0000000080100010 00000000f5000000 0000000000000000 [ 30.417939] page dumped because: kasan: bad access detected [ 30.418095] [ 30.418154] Memory state around the buggy address: [ 30.418223] fff00000c99bc900: fa fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 30.418407] fff00000c99bc980: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc [ 30.418467] >fff00000c99bca00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 fc [ 30.418664] ^ [ 30.418976] fff00000c99bca80: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc [ 30.419079] fff00000c99bcb00: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc [ 30.419180] ==================================================================
[ 25.231678] ================================================================== [ 25.232776] BUG: KASAN: slab-out-of-bounds in kmalloc_oob_memset_2+0x166/0x330 [ 25.233506] Write of size 2 at addr ffff888104657c77 by task kunit_try_catch/221 [ 25.233894] [ 25.234021] CPU: 1 UID: 0 PID: 221 Comm: kunit_try_catch Tainted: G B N 6.16.0-rc7-next-20250723 #1 PREEMPT(voluntary) [ 25.234331] Tainted: [B]=BAD_PAGE, [N]=TEST [ 25.234345] Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.16.3-debian-1.16.3-2 04/01/2014 [ 25.234366] Call Trace: [ 25.234401] <TASK> [ 25.234420] dump_stack_lvl+0x73/0xb0 [ 25.234451] print_report+0xd1/0x640 [ 25.234474] ? __virt_addr_valid+0x1db/0x2d0 [ 25.234499] ? kmalloc_oob_memset_2+0x166/0x330 [ 25.234521] ? kasan_complete_mode_report_info+0x2a/0x200 [ 25.234547] ? kmalloc_oob_memset_2+0x166/0x330 [ 25.234568] kasan_report+0x141/0x180 [ 25.234590] ? kmalloc_oob_memset_2+0x166/0x330 [ 25.234616] kasan_check_range+0x10c/0x1c0 [ 25.234639] __asan_memset+0x27/0x50 [ 25.234662] kmalloc_oob_memset_2+0x166/0x330 [ 25.234685] ? __pfx_kmalloc_oob_memset_2+0x10/0x10 [ 25.234707] ? __schedule+0x10da/0x2b60 [ 25.234733] ? __pfx_read_tsc+0x10/0x10 [ 25.234755] ? ktime_get_ts64+0x86/0x230 [ 25.234782] kunit_try_run_case+0x1a5/0x480 [ 25.234807] ? __pfx_kunit_try_run_case+0x10/0x10 [ 25.234832] ? _raw_spin_lock_irqsave+0xa1/0x100 [ 25.234857] ? _raw_spin_unlock_irqrestore+0x5f/0x90 [ 25.234883] ? __kthread_parkme+0x82/0x180 [ 25.234903] ? preempt_count_sub+0x50/0x80 [ 25.234926] ? __pfx_kunit_try_run_case+0x10/0x10 [ 25.234950] kunit_generic_run_threadfn_adapter+0x85/0xf0 [ 25.234974] ? __pfx_kunit_generic_run_threadfn_adapter+0x10/0x10 [ 25.234997] kthread+0x337/0x6f0 [ 25.235017] ? trace_preempt_on+0x20/0xc0 [ 25.235042] ? __pfx_kthread+0x10/0x10 [ 25.235062] ? _raw_spin_unlock_irq+0x47/0x80 [ 25.235085] ? calculate_sigpending+0x7b/0xa0 [ 25.235109] ? __pfx_kthread+0x10/0x10 [ 25.235130] ret_from_fork+0x116/0x1d0 [ 25.235160] ? __pfx_kthread+0x10/0x10 [ 25.235181] ret_from_fork_asm+0x1a/0x30 [ 25.235213] </TASK> [ 25.235224] [ 25.245647] Allocated by task 221: [ 25.245954] kasan_save_stack+0x45/0x70 [ 25.246385] kasan_save_track+0x18/0x40 [ 25.246789] kasan_save_alloc_info+0x3b/0x50 [ 25.247192] __kasan_kmalloc+0xb7/0xc0 [ 25.247653] __kmalloc_cache_noprof+0x189/0x420 [ 25.248105] kmalloc_oob_memset_2+0xac/0x330 [ 25.248587] kunit_try_run_case+0x1a5/0x480 [ 25.248984] kunit_generic_run_threadfn_adapter+0x85/0xf0 [ 25.249479] kthread+0x337/0x6f0 [ 25.249802] ret_from_fork+0x116/0x1d0 [ 25.250182] ret_from_fork_asm+0x1a/0x30 [ 25.250604] [ 25.250704] The buggy address belongs to the object at ffff888104657c00 [ 25.250704] which belongs to the cache kmalloc-128 of size 128 [ 25.251233] The buggy address is located 119 bytes inside of [ 25.251233] allocated 120-byte region [ffff888104657c00, ffff888104657c78) [ 25.252351] [ 25.252554] The buggy address belongs to the physical page: [ 25.253059] page: refcount:0 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x104657 [ 25.253360] flags: 0x200000000000000(node=0|zone=2) [ 25.253835] page_type: f5(slab) [ 25.254134] raw: 0200000000000000 ffff888100041a00 dead000000000122 0000000000000000 [ 25.254706] raw: 0000000000000000 0000000080100010 00000000f5000000 0000000000000000 [ 25.254933] page dumped because: kasan: bad access detected [ 25.255100] [ 25.255179] Memory state around the buggy address: [ 25.255371] ffff888104657b00: fa fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 25.255687] ffff888104657b80: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc [ 25.255965] >ffff888104657c00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 fc [ 25.256341] ^ [ 25.256593] ffff888104657c80: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc [ 25.256907] ffff888104657d00: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc [ 25.257303] ==================================================================