Hay
Date
May 26, 2025, 9:10 a.m.

Environment
qemu-arm64
qemu-x86_64

[   20.189718] ==================================================================
[   20.190347] BUG: KASAN: stack-out-of-bounds in kasan_stack_oob+0x238/0x270
[   20.190735] Read of size 1 at addr ffff800080a17c2a by task kunit_try_catch/249
[   20.191078] 
[   20.191246] CPU: 0 UID: 0 PID: 249 Comm: kunit_try_catch Tainted: G    B            N  6.15.0-rc7-next-20250526 #1 PREEMPT 
[   20.191460] Tainted: [B]=BAD_PAGE, [N]=TEST
[   20.191509] Hardware name: linux,dummy-virt (DT)
[   20.191571] Call trace:
[   20.191619]  show_stack+0x20/0x38 (C)
[   20.191754]  dump_stack_lvl+0x8c/0xd0
[   20.191863]  print_report+0x310/0x608
[   20.191964]  kasan_report+0xdc/0x128
[   20.192062]  __asan_report_load1_noabort+0x20/0x30
[   20.192178]  kasan_stack_oob+0x238/0x270
[   20.192274]  kunit_try_run_case+0x170/0x3f0
[   20.192395]  kunit_generic_run_threadfn_adapter+0x88/0x100
[   20.192530]  kthread+0x328/0x630
[   20.192649]  ret_from_fork+0x10/0x20
[   20.192792] 
[   20.192954] The buggy address belongs to stack of task kunit_try_catch/249
[   20.193172]  and is located at offset 138 in frame:
[   20.193518]  kasan_stack_oob+0x0/0x270
[   20.194157] 
[   20.194270] This frame has 4 objects:
[   20.194485]  [48, 49) '__assertion'
[   20.194606]  [64, 72) 'array'
[   20.194681]  [96, 112) '__assertion'
[   20.195386]  [128, 138) 'stack_array'
[   20.195651] 
[   20.195966] The buggy address belongs to the virtual mapping at
[   20.195966]  [ffff800080a10000, ffff800080a19000) created by:
[   20.195966]  kernel_clone+0x150/0x7a8
[   20.196195] 
[   20.196249] The buggy address belongs to the physical page:
[   20.196339] page: refcount:1 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x1077f8
[   20.196762] flags: 0xbfffe0000000000(node=0|zone=2|lastcpupid=0x1ffff)
[   20.197410] raw: 0bfffe0000000000 0000000000000000 dead000000000122 0000000000000000
[   20.197575] raw: 0000000000000000 0000000000000000 00000001ffffffff 0000000000000000
[   20.197845] page dumped because: kasan: bad access detected
[   20.197943] 
[   20.198187] Memory state around the buggy address:
[   20.198344]  ffff800080a17b00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
[   20.198453]  ffff800080a17b80: 00 00 00 00 f1 f1 f1 f1 f1 f1 01 f2 00 f2 f2 f2
[   20.198795] >ffff800080a17c00: 00 00 f2 f2 00 02 f3 f3 00 00 00 00 00 00 00 00
[   20.198863]                                   ^
[   20.198929]  ffff800080a17c80: 00 00 00 00 00 00 00 00 f1 f1 f1 f1 00 00 f2 f2
[   20.199040]  ffff800080a17d00: 00 00 f2 f2 00 00 f3 f3 00 00 00 00 00 00 00 00
[   20.199228] ==================================================================


[   12.816117] ==================================================================
[   12.817314] BUG: KASAN: stack-out-of-bounds in kasan_stack_oob+0x2b5/0x300
[   12.817638] Read of size 1 at addr ffff888103957d02 by task kunit_try_catch/267
[   12.818531] 
[   12.818876] CPU: 0 UID: 0 PID: 267 Comm: kunit_try_catch Tainted: G    B            N  6.15.0-rc7-next-20250526 #1 PREEMPT(voluntary) 
[   12.818931] Tainted: [B]=BAD_PAGE, [N]=TEST
[   12.818945] Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.16.3-debian-1.16.3-2 04/01/2014
[   12.818968] Call Trace:
[   12.818981]  <TASK>
[   12.818997]  dump_stack_lvl+0x73/0xb0
[   12.819063]  print_report+0xd1/0x650
[   12.819087]  ? __virt_addr_valid+0x1db/0x2d0
[   12.819111]  ? kasan_stack_oob+0x2b5/0x300
[   12.819131]  ? kasan_addr_to_slab+0x11/0xa0
[   12.819153]  ? kasan_stack_oob+0x2b5/0x300
[   12.819175]  kasan_report+0x141/0x180
[   12.819197]  ? kasan_stack_oob+0x2b5/0x300
[   12.819222]  __asan_report_load1_noabort+0x18/0x20
[   12.819243]  kasan_stack_oob+0x2b5/0x300
[   12.819263]  ? __pfx_kasan_stack_oob+0x10/0x10
[   12.819283]  ? finish_task_switch.isra.0+0x153/0x700
[   12.819305]  ? __switch_to+0x47/0xf50
[   12.819332]  ? __schedule+0x10cc/0x2b60
[   12.819357]  ? __pfx_read_tsc+0x10/0x10
[   12.819386]  ? ktime_get_ts64+0x86/0x230
[   12.819412]  kunit_try_run_case+0x1a5/0x480
[   12.819434]  ? __pfx_kunit_try_run_case+0x10/0x10
[   12.819454]  ? _raw_spin_lock_irqsave+0xa1/0x100
[   12.819479]  ? _raw_spin_unlock_irqrestore+0x5f/0x90
[   12.819504]  ? __kthread_parkme+0x82/0x180
[   12.819526]  ? preempt_count_sub+0x50/0x80
[   12.819551]  ? __pfx_kunit_try_run_case+0x10/0x10
[   12.819572]  kunit_generic_run_threadfn_adapter+0x85/0xf0
[   12.819597]  ? __pfx_kunit_generic_run_threadfn_adapter+0x10/0x10
[   12.819621]  kthread+0x337/0x6f0
[   12.819641]  ? trace_preempt_on+0x20/0xc0
[   12.819664]  ? __pfx_kthread+0x10/0x10
[   12.819685]  ? _raw_spin_unlock_irq+0x47/0x80
[   12.819706]  ? calculate_sigpending+0x7b/0xa0
[   12.819730]  ? __pfx_kthread+0x10/0x10
[   12.819751]  ret_from_fork+0x116/0x1d0
[   12.819769]  ? __pfx_kthread+0x10/0x10
[   12.819790]  ret_from_fork_asm+0x1a/0x30
[   12.819821]  </TASK>
[   12.819831] 
[   12.832294] The buggy address belongs to stack of task kunit_try_catch/267
[   12.832754]  and is located at offset 138 in frame:
[   12.832977]  kasan_stack_oob+0x0/0x300
[   12.833715] 
[   12.833992] This frame has 4 objects:
[   12.834353]  [48, 49) '__assertion'
[   12.834395]  [64, 72) 'array'
[   12.834540]  [96, 112) '__assertion'
[   12.834698]  [128, 138) 'stack_array'
[   12.834904] 
[   12.835289] The buggy address belongs to the physical page:
[   12.835503] page: refcount:0 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x103957
[   12.835938] flags: 0x200000000000000(node=0|zone=2)
[   12.836115] raw: 0200000000000000 ffffea00040e55c8 ffffea00040e55c8 0000000000000000
[   12.836480] raw: 0000000000000000 0000000000000000 00000000ffffffff 0000000000000000
[   12.836779] page dumped because: kasan: bad access detected
[   12.837016] 
[   12.837089] Memory state around the buggy address:
[   12.837307]  ffff888103957c00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 f1
[   12.837655]  ffff888103957c80: f1 f1 f1 f1 f1 01 f2 00 f2 f2 f2 00 00 f2 f2 00
[   12.838105] >ffff888103957d00: 02 f3 f3 00 00 00 00 00 00 00 00 00 00 00 00 f1
[   12.838344]                    ^
[   12.838521]  ffff888103957d80: f1 f1 f1 00 00 f2 f2 00 00 f2 f2 00 00 f3 f3 00
[   12.838840]  ffff888103957e00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
[   12.839189] ==================================================================