Hay
Date
May 15, 2025, 10:38 a.m.

Environment
qemu-arm64
qemu-x86_64

[   17.791999] ==================================================================
[   17.792063] BUG: KASAN: slab-out-of-bounds in kmalloc_large_oob_right+0x278/0x2b8
[   17.792420] Write of size 1 at addr fff00000c67ee00a by task kunit_try_catch/146
[   17.792492] 
[   17.792531] CPU: 1 UID: 0 PID: 146 Comm: kunit_try_catch Tainted: G    B            N  6.15.0-rc6-next-20250515 #1 PREEMPT 
[   17.792655] Tainted: [B]=BAD_PAGE, [N]=TEST
[   17.792680] Hardware name: linux,dummy-virt (DT)
[   17.792709] Call trace:
[   17.792730]  show_stack+0x20/0x38 (C)
[   17.792777]  dump_stack_lvl+0x8c/0xd0
[   17.792881]  print_report+0x118/0x608
[   17.792930]  kasan_report+0xdc/0x128
[   17.793050]  __asan_report_store1_noabort+0x20/0x30
[   17.793208]  kmalloc_large_oob_right+0x278/0x2b8
[   17.793255]  kunit_try_run_case+0x170/0x3f0
[   17.793299]  kunit_generic_run_threadfn_adapter+0x88/0x100
[   17.793349]  kthread+0x328/0x630
[   17.793395]  ret_from_fork+0x10/0x20
[   17.793441] 
[   17.793476] The buggy address belongs to the physical page:
[   17.793507] page: refcount:1 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x1067ec
[   17.793556] head: order:2 mapcount:0 entire_mapcount:0 nr_pages_mapped:0 pincount:0
[   17.793600] flags: 0xbfffe0000000040(head|node=0|zone=2|lastcpupid=0x1ffff)
[   17.793654] page_type: f8(unknown)
[   17.793691] raw: 0bfffe0000000040 0000000000000000 dead000000000122 0000000000000000
[   17.793854] raw: 0000000000000000 0000000000000000 00000001f8000000 0000000000000000
[   17.793978] head: 0bfffe0000000040 0000000000000000 dead000000000122 0000000000000000
[   17.794050] head: 0000000000000000 0000000000000000 00000001f8000000 0000000000000000
[   17.794098] head: 0bfffe0000000002 ffffc1ffc319fb01 00000000ffffffff 00000000ffffffff
[   17.794144] head: ffffffffffffffff 0000000000000000 00000000ffffffff 0000000000000004
[   17.794195] page dumped because: kasan: bad access detected
[   17.794277] 
[   17.794296] Memory state around the buggy address:
[   17.794338]  fff00000c67edf00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
[   17.794378]  fff00000c67edf80: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
[   17.794418] >fff00000c67ee000: 00 02 fe fe fe fe fe fe fe fe fe fe fe fe fe fe
[   17.794454]                       ^
[   17.794481]  fff00000c67ee080: fe fe fe fe fe fe fe fe fe fe fe fe fe fe fe fe
[   17.794536]  fff00000c67ee100: fe fe fe fe fe fe fe fe fe fe fe fe fe fe fe fe
[   17.794635] ==================================================================


[   13.441780] ==================================================================
[   13.442272] BUG: KASAN: slab-out-of-bounds in kmalloc_large_oob_right+0x2e9/0x330
[   13.442931] Write of size 1 at addr ffff88810250200a by task kunit_try_catch/164
[   13.443205] 
[   13.443366] CPU: 1 UID: 0 PID: 164 Comm: kunit_try_catch Tainted: G    B            N  6.15.0-rc6-next-20250515 #1 PREEMPT(voluntary) 
[   13.443462] Tainted: [B]=BAD_PAGE, [N]=TEST
[   13.443479] Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.16.3-debian-1.16.3-2 04/01/2014
[   13.443502] Call Trace:
[   13.443518]  <TASK>
[   13.443544]  dump_stack_lvl+0x73/0xb0
[   13.443594]  print_report+0xd1/0x650
[   13.443630]  ? __virt_addr_valid+0x1db/0x2d0
[   13.443667]  ? kmalloc_large_oob_right+0x2e9/0x330
[   13.443702]  ? kasan_addr_to_slab+0x11/0xa0
[   13.443728]  ? kmalloc_large_oob_right+0x2e9/0x330
[   13.443749]  kasan_report+0x141/0x180
[   13.443770]  ? kmalloc_large_oob_right+0x2e9/0x330
[   13.443797]  __asan_report_store1_noabort+0x1b/0x30
[   13.443816]  kmalloc_large_oob_right+0x2e9/0x330
[   13.443836]  ? __pfx_kmalloc_large_oob_right+0x10/0x10
[   13.443859]  ? __pfx_kmalloc_large_oob_right+0x10/0x10
[   13.443883]  kunit_try_run_case+0x1a5/0x480
[   13.443906]  ? __pfx_kunit_try_run_case+0x10/0x10
[   13.443925]  ? _raw_spin_lock_irqsave+0xa1/0x100
[   13.443947]  ? _raw_spin_unlock_irqrestore+0x5f/0x90
[   13.443967]  ? __kthread_parkme+0x82/0x180
[   13.443988]  ? preempt_count_sub+0x50/0x80
[   13.444010]  ? __pfx_kunit_try_run_case+0x10/0x10
[   13.444032]  kunit_generic_run_threadfn_adapter+0x85/0xf0
[   13.444052]  ? __pfx_kunit_generic_run_threadfn_adapter+0x10/0x10
[   13.444072]  kthread+0x337/0x6f0
[   13.444090]  ? trace_preempt_on+0x20/0xc0
[   13.444112]  ? __pfx_kthread+0x10/0x10
[   13.444131]  ? _raw_spin_unlock_irq+0x47/0x80
[   13.444150]  ? calculate_sigpending+0x7b/0xa0
[   13.444172]  ? __pfx_kthread+0x10/0x10
[   13.444192]  ret_from_fork+0x116/0x1d0
[   13.444209]  ? __pfx_kthread+0x10/0x10
[   13.444252]  ret_from_fork_asm+0x1a/0x30
[   13.444306]  </TASK>
[   13.444328] 
[   13.454687] The buggy address belongs to the physical page:
[   13.455265] page: refcount:1 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x102500
[   13.456208] head: order:2 mapcount:0 entire_mapcount:0 nr_pages_mapped:0 pincount:0
[   13.456848] flags: 0x200000000000040(head|node=0|zone=2)
[   13.457325] page_type: f8(unknown)
[   13.457958] raw: 0200000000000040 0000000000000000 dead000000000122 0000000000000000
[   13.458775] raw: 0000000000000000 0000000000000000 00000001f8000000 0000000000000000
[   13.459197] head: 0200000000000040 0000000000000000 dead000000000122 0000000000000000
[   13.459727] head: 0000000000000000 0000000000000000 00000001f8000000 0000000000000000
[   13.460190] head: 0200000000000002 ffffea0004094001 00000000ffffffff 00000000ffffffff
[   13.460579] head: ffffffffffffffff 0000000000000000 00000000ffffffff 0000000000000004
[   13.461251] page dumped because: kasan: bad access detected
[   13.461494] 
[   13.461657] Memory state around the buggy address:
[   13.462105]  ffff888102501f00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
[   13.462825]  ffff888102501f80: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
[   13.463042] >ffff888102502000: 00 02 fe fe fe fe fe fe fe fe fe fe fe fe fe fe
[   13.463467]                       ^
[   13.463741]  ffff888102502080: fe fe fe fe fe fe fe fe fe fe fe fe fe fe fe fe
[   13.464227]  ffff888102502100: fe fe fe fe fe fe fe fe fe fe fe fe fe fe fe fe
[   13.464873] ==================================================================