Hay
Date
July 10, 2025, 6:10 p.m.

Environment
qemu-arm64
qemu-x86_64

[   49.783134] ==================================================================
[   49.783207] BUG: KFENCE: use-after-free read in test_krealloc+0x51c/0x830
[   49.783207] 
[   49.783297] Use-after-free read at 0x00000000789fd6be (in kfence-#147):
[   49.783365]  test_krealloc+0x51c/0x830
[   49.783410]  kunit_try_run_case+0x170/0x3f0
[   49.783461]  kunit_generic_run_threadfn_adapter+0x88/0x100
[   49.783507]  kthread+0x328/0x630
[   49.783547]  ret_from_fork+0x10/0x20
[   49.783587] 
[   49.783612] kfence-#147: 0x00000000789fd6be-0x0000000012c3a69e, size=32, cache=kmalloc-32
[   49.783612] 
[   49.783666] allocated by task 337 on cpu 0 at 49.782424s (0.001238s ago):
[   49.783734]  test_alloc+0x29c/0x628
[   49.783775]  test_krealloc+0xc0/0x830
[   49.783814]  kunit_try_run_case+0x170/0x3f0
[   49.783855]  kunit_generic_run_threadfn_adapter+0x88/0x100
[   49.783901]  kthread+0x328/0x630
[   49.783937]  ret_from_fork+0x10/0x20
[   49.783977] 
[   49.784000] freed by task 337 on cpu 0 at 49.782729s (0.001267s ago):
[   49.784060]  krealloc_noprof+0x148/0x360
[   49.784101]  test_krealloc+0x1dc/0x830
[   49.784141]  kunit_try_run_case+0x170/0x3f0
[   49.784182]  kunit_generic_run_threadfn_adapter+0x88/0x100
[   49.784226]  kthread+0x328/0x630
[   49.784261]  ret_from_fork+0x10/0x20
[   49.784301] 
[   49.784359] CPU: 0 UID: 0 PID: 337 Comm: kunit_try_catch Tainted: G    B            N  6.16.0-rc5 #1 PREEMPT 
[   49.784440] Tainted: [B]=BAD_PAGE, [N]=TEST
[   49.784471] Hardware name: linux,dummy-virt (DT)
[   49.784506] ==================================================================

[   49.100760] ==================================================================
[   49.101252] BUG: KFENCE: use-after-free read in test_krealloc+0x6fc/0xbe0
[   49.101252] 
[   49.101640] Use-after-free read at 0x(____ptrval____) (in kfence-#134):
[   49.101902]  test_krealloc+0x6fc/0xbe0
[   49.102142]  kunit_try_run_case+0x1a5/0x480
[   49.102333]  kunit_generic_run_threadfn_adapter+0x85/0xf0
[   49.102549]  kthread+0x337/0x6f0
[   49.102719]  ret_from_fork+0x116/0x1d0
[   49.102897]  ret_from_fork_asm+0x1a/0x30
[   49.103055] 
[   49.103140] kfence-#134: 0x(____ptrval____)-0x(____ptrval____), size=32, cache=kmalloc-32
[   49.103140] 
[   49.103526] allocated by task 354 on cpu 1 at 49.100112s (0.003411s ago):
[   49.103880]  test_alloc+0x364/0x10f0
[   49.104095]  test_krealloc+0xad/0xbe0
[   49.104274]  kunit_try_run_case+0x1a5/0x480
[   49.104432]  kunit_generic_run_threadfn_adapter+0x85/0xf0
[   49.104686]  kthread+0x337/0x6f0
[   49.104837]  ret_from_fork+0x116/0x1d0
[   49.105052]  ret_from_fork_asm+0x1a/0x30
[   49.105267] 
[   49.105361] freed by task 354 on cpu 1 at 49.100376s (0.004983s ago):
[   49.105673]  krealloc_noprof+0x108/0x340
[   49.105873]  test_krealloc+0x226/0xbe0
[   49.106071]  kunit_try_run_case+0x1a5/0x480
[   49.106215]  kunit_generic_run_threadfn_adapter+0x85/0xf0
[   49.106547]  kthread+0x337/0x6f0
[   49.106735]  ret_from_fork+0x116/0x1d0
[   49.106907]  ret_from_fork_asm+0x1a/0x30
[   49.107458] 
[   49.107581] CPU: 1 UID: 0 PID: 354 Comm: kunit_try_catch Tainted: G    B            N  6.16.0-rc5 #1 PREEMPT(voluntary) 
[   49.108353] Tainted: [B]=BAD_PAGE, [N]=TEST
[   49.108645] Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.16.3-debian-1.16.3-2 04/01/2014
[   49.109006] ==================================================================