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

Environment
qemu-arm64
qemu-x86_64

[   20.065811] ==================================================================
[   20.065906] BUG: KASAN: alloca-out-of-bounds in kasan_alloca_oob_left+0x2b8/0x310
[   20.066015] Read of size 1 at addr ffff800080a37b5f by task kunit_try_catch/251
[   20.066191] 
[   20.066230] CPU: 0 UID: 0 PID: 251 Comm: kunit_try_catch Tainted: G    B            N  6.15.0-rc6-next-20250515 #1 PREEMPT 
[   20.066323] Tainted: [B]=BAD_PAGE, [N]=TEST
[   20.066352] Hardware name: linux,dummy-virt (DT)
[   20.066384] Call trace:
[   20.066409]  show_stack+0x20/0x38 (C)
[   20.066462]  dump_stack_lvl+0x8c/0xd0
[   20.066630]  print_report+0x310/0x608
[   20.066712]  kasan_report+0xdc/0x128
[   20.066797]  __asan_report_load1_noabort+0x20/0x30
[   20.066893]  kasan_alloca_oob_left+0x2b8/0x310
[   20.066972]  kunit_try_run_case+0x170/0x3f0
[   20.067064]  kunit_generic_run_threadfn_adapter+0x88/0x100
[   20.067129]  kthread+0x328/0x630
[   20.067189]  ret_from_fork+0x10/0x20
[   20.067241] 
[   20.067264] The buggy address belongs to stack of task kunit_try_catch/251
[   20.067427] 
[   20.067523] The buggy address belongs to the virtual mapping at
[   20.067523]  [ffff800080a30000, ffff800080a39000) created by:
[   20.067523]  kernel_clone+0x150/0x7a8
[   20.067637] 
[   20.067694] The buggy address belongs to the physical page:
[   20.067735] page: refcount:1 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x1068f7
[   20.067789] flags: 0xbfffe0000000000(node=0|zone=2|lastcpupid=0x1ffff)
[   20.067944] raw: 0bfffe0000000000 0000000000000000 dead000000000122 0000000000000000
[   20.068051] raw: 0000000000000000 0000000000000000 00000001ffffffff 0000000000000000
[   20.068119] page dumped because: kasan: bad access detected
[   20.068179] 
[   20.068231] Memory state around the buggy address:
[   20.068309]  ffff800080a37a00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
[   20.068396]  ffff800080a37a80: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
[   20.068459] >ffff800080a37b00: 00 00 00 00 00 00 00 00 ca ca ca ca 00 02 cb cb
[   20.068498]                                                     ^
[   20.068725]  ffff800080a37b80: cb cb cb cb 00 00 00 00 f1 f1 f1 f1 01 f2 04 f2
[   20.068803]  ffff800080a37c00: 00 f2 f2 f2 00 00 f3 f3 00 00 00 00 00 00 00 00
[   20.068885] ==================================================================


[   16.112393] ==================================================================
[   16.113251] BUG: KASAN: alloca-out-of-bounds in kasan_alloca_oob_left+0x320/0x380
[   16.113856] Read of size 1 at addr ffff888103bc7c3f by task kunit_try_catch/269
[   16.114448] 
[   16.114652] CPU: 1 UID: 0 PID: 269 Comm: kunit_try_catch Tainted: G    B            N  6.15.0-rc6-next-20250515 #1 PREEMPT(voluntary) 
[   16.114796] Tainted: [B]=BAD_PAGE, [N]=TEST
[   16.114824] Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.16.3-debian-1.16.3-2 04/01/2014
[   16.114861] Call Trace:
[   16.114887]  <TASK>
[   16.114923]  dump_stack_lvl+0x73/0xb0
[   16.114983]  print_report+0xd1/0x650
[   16.115029]  ? __virt_addr_valid+0x1db/0x2d0
[   16.115075]  ? kasan_alloca_oob_left+0x320/0x380
[   16.115116]  ? kasan_addr_to_slab+0x11/0xa0
[   16.115150]  ? kasan_alloca_oob_left+0x320/0x380
[   16.115190]  kasan_report+0x141/0x180
[   16.115240]  ? kasan_alloca_oob_left+0x320/0x380
[   16.115334]  __asan_report_load1_noabort+0x18/0x20
[   16.115400]  kasan_alloca_oob_left+0x320/0x380
[   16.115443]  ? __pfx_sched_clock_cpu+0x10/0x10
[   16.115484]  ? finish_task_switch.isra.0+0x153/0x700
[   16.115519]  ? rt_mutex_adjust_prio_chain+0x68e/0x20e0
[   16.115556]  ? trace_hardirqs_on+0x37/0xe0
[   16.115760]  ? __pfx_kasan_alloca_oob_left+0x10/0x10
[   16.115804]  ? __schedule+0x10cc/0x2b60
[   16.115858]  ? __pfx_read_tsc+0x10/0x10
[   16.115882]  ? ktime_get_ts64+0x86/0x230
[   16.115906]  kunit_try_run_case+0x1a5/0x480
[   16.115933]  ? __pfx_kunit_try_run_case+0x10/0x10
[   16.115954]  ? _raw_spin_lock_irqsave+0xa1/0x100
[   16.115976]  ? _raw_spin_unlock_irqrestore+0x5f/0x90
[   16.115997]  ? __kthread_parkme+0x82/0x180
[   16.116018]  ? preempt_count_sub+0x50/0x80
[   16.116041]  ? __pfx_kunit_try_run_case+0x10/0x10
[   16.116062]  kunit_generic_run_threadfn_adapter+0x85/0xf0
[   16.116083]  ? __pfx_kunit_generic_run_threadfn_adapter+0x10/0x10
[   16.116104]  kthread+0x337/0x6f0
[   16.116123]  ? trace_preempt_on+0x20/0xc0
[   16.116144]  ? __pfx_kthread+0x10/0x10
[   16.116163]  ? _raw_spin_unlock_irq+0x47/0x80
[   16.116183]  ? calculate_sigpending+0x7b/0xa0
[   16.116206]  ? __pfx_kthread+0x10/0x10
[   16.116248]  ret_from_fork+0x116/0x1d0
[   16.116269]  ? __pfx_kthread+0x10/0x10
[   16.116288]  ret_from_fork_asm+0x1a/0x30
[   16.116318]  </TASK>
[   16.116332] 
[   16.127218] The buggy address belongs to stack of task kunit_try_catch/269
[   16.128313] 
[   16.128683] The buggy address belongs to the physical page:
[   16.129255] page: refcount:0 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x103bc7
[   16.129858] flags: 0x200000000000000(node=0|zone=2)
[   16.130198] raw: 0200000000000000 ffffea00040ef1c8 ffffea00040ef1c8 0000000000000000
[   16.130836] raw: 0000000000000000 0000000000000000 00000000ffffffff 0000000000000000
[   16.131234] page dumped because: kasan: bad access detected
[   16.131448] 
[   16.131601] Memory state around the buggy address:
[   16.131903]  ffff888103bc7b00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
[   16.132329]  ffff888103bc7b80: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
[   16.132700] >ffff888103bc7c00: 00 00 00 00 ca ca ca ca 00 02 cb cb cb cb cb cb
[   16.132928]                                         ^
[   16.133642]  ffff888103bc7c80: 00 00 00 f1 f1 f1 f1 01 f2 04 f2 00 f2 f2 f2 00
[   16.134098]  ffff888103bc7d00: 00 f3 f3 00 00 00 00 00 00 00 00 00 00 00 00 f1
[   16.134515] ==================================================================