Hay
Date
May 29, 2025, 7:10 a.m.

Environment
qemu-arm64
qemu-x86_64

[   27.484611] ==================================================================
[   27.484852] BUG: KFENCE: use-after-free read in test_use_after_free_read+0x114/0x248
[   27.484852] 
[   27.485088] Use-after-free read at 0x000000000d181f01 (in kfence-#119):
[   27.485476]  test_use_after_free_read+0x114/0x248
[   27.485634]  kunit_try_run_case+0x170/0x3f0
[   27.485742]  kunit_generic_run_threadfn_adapter+0x88/0x100
[   27.486674]  kthread+0x328/0x630
[   27.486803]  ret_from_fork+0x10/0x20
[   27.486926] 
[   27.486989] kfence-#119: 0x000000000d181f01-0x00000000b6c70eb9, size=32, cache=kmalloc-32
[   27.486989] 
[   27.487825] allocated by task 295 on cpu 1 at 27.483662s (0.004064s ago):
[   27.488909]  test_alloc+0x29c/0x628
[   27.489037]  test_use_after_free_read+0xd0/0x248
[   27.489585]  kunit_try_run_case+0x170/0x3f0
[   27.490099]  kunit_generic_run_threadfn_adapter+0x88/0x100
[   27.490984]  kthread+0x328/0x630
[   27.491299]  ret_from_fork+0x10/0x20
[   27.491490] 
[   27.492823] freed by task 295 on cpu 1 at 27.483803s (0.008717s ago):
[   27.493106]  test_use_after_free_read+0x1c0/0x248
[   27.493223]  kunit_try_run_case+0x170/0x3f0
[   27.493320]  kunit_generic_run_threadfn_adapter+0x88/0x100
[   27.493449]  kthread+0x328/0x630
[   27.493539]  ret_from_fork+0x10/0x20
[   27.494441] 
[   27.495291] CPU: 1 UID: 0 PID: 295 Comm: kunit_try_catch Tainted: G    B            N  6.15.0-next-20250529 #1 PREEMPT 
[   27.496079] Tainted: [B]=BAD_PAGE, [N]=TEST
[   27.496413] Hardware name: linux,dummy-virt (DT)
[   27.496504] ==================================================================
[   27.589789] ==================================================================
[   27.590256] BUG: KFENCE: use-after-free read in test_use_after_free_read+0x114/0x248
[   27.590256] 
[   27.590485] Use-after-free read at 0x00000000d66fab2b (in kfence-#120):
[   27.590649]  test_use_after_free_read+0x114/0x248
[   27.590906]  kunit_try_run_case+0x170/0x3f0
[   27.591236]  kunit_generic_run_threadfn_adapter+0x88/0x100
[   27.591463]  kthread+0x328/0x630
[   27.591575]  ret_from_fork+0x10/0x20
[   27.591672] 
[   27.591760] kfence-#120: 0x00000000d66fab2b-0x0000000001f9cdaa, size=32, cache=test
[   27.591760] 
[   27.591878] allocated by task 297 on cpu 1 at 27.589020s (0.002850s ago):
[   27.592042]  test_alloc+0x230/0x628
[   27.592148]  test_use_after_free_read+0xd0/0x248
[   27.592254]  kunit_try_run_case+0x170/0x3f0
[   27.592337]  kunit_generic_run_threadfn_adapter+0x88/0x100
[   27.592690]  kthread+0x328/0x630
[   27.592836]  ret_from_fork+0x10/0x20
[   27.592986] 
[   27.593045] freed by task 297 on cpu 1 at 27.589283s (0.003754s ago):
[   27.593366]  test_use_after_free_read+0xf0/0x248
[   27.593538]  kunit_try_run_case+0x170/0x3f0
[   27.593660]  kunit_generic_run_threadfn_adapter+0x88/0x100
[   27.593780]  kthread+0x328/0x630
[   27.593909]  ret_from_fork+0x10/0x20
[   27.594029] 
[   27.594153] CPU: 1 UID: 0 PID: 297 Comm: kunit_try_catch Tainted: G    B            N  6.15.0-next-20250529 #1 PREEMPT 
[   27.594947] Tainted: [B]=BAD_PAGE, [N]=TEST
[   27.595018] Hardware name: linux,dummy-virt (DT)
[   27.595066] ==================================================================


[   16.474146] ==================================================================
[   16.474557] BUG: KFENCE: use-after-free read in test_use_after_free_read+0x129/0x270
[   16.474557] 
[   16.474995] Use-after-free read at 0x(____ptrval____) (in kfence-#72):
[   16.475296]  test_use_after_free_read+0x129/0x270
[   16.475539]  kunit_try_run_case+0x1a5/0x480
[   16.475713]  kunit_generic_run_threadfn_adapter+0x85/0xf0
[   16.476160]  kthread+0x337/0x6f0
[   16.476299]  ret_from_fork+0x116/0x1d0
[   16.476461]  ret_from_fork_asm+0x1a/0x30
[   16.476675] 
[   16.476789] kfence-#72: 0x(____ptrval____)-0x(____ptrval____), size=32, cache=test
[   16.476789] 
[   16.477106] allocated by task 314 on cpu 0 at 16.474036s (0.003068s ago):
[   16.477440]  test_alloc+0x2a6/0x10f0
[   16.477647]  test_use_after_free_read+0xdc/0x270
[   16.477910]  kunit_try_run_case+0x1a5/0x480
[   16.478062]  kunit_generic_run_threadfn_adapter+0x85/0xf0
[   16.478304]  kthread+0x337/0x6f0
[   16.478478]  ret_from_fork+0x116/0x1d0
[   16.478690]  ret_from_fork_asm+0x1a/0x30
[   16.478887] 
[   16.478989] freed by task 314 on cpu 0 at 16.474081s (0.004906s ago):
[   16.479256]  test_use_after_free_read+0xfb/0x270
[   16.479451]  kunit_try_run_case+0x1a5/0x480
[   16.479676]  kunit_generic_run_threadfn_adapter+0x85/0xf0
[   16.480134]  kthread+0x337/0x6f0
[   16.480279]  ret_from_fork+0x116/0x1d0
[   16.480464]  ret_from_fork_asm+0x1a/0x30
[   16.480621] 
[   16.480720] CPU: 0 UID: 0 PID: 314 Comm: kunit_try_catch Tainted: G    B            N  6.15.0-next-20250529 #1 PREEMPT(voluntary) 
[   16.481236] Tainted: [B]=BAD_PAGE, [N]=TEST
[   16.481384] Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.16.3-debian-1.16.3-2 04/01/2014
[   16.481672] ==================================================================
[   16.370303] ==================================================================
[   16.370769] BUG: KFENCE: use-after-free read in test_use_after_free_read+0x129/0x270
[   16.370769] 
[   16.371290] Use-after-free read at 0x(____ptrval____) (in kfence-#71):
[   16.371555]  test_use_after_free_read+0x129/0x270
[   16.371919]  kunit_try_run_case+0x1a5/0x480
[   16.372168]  kunit_generic_run_threadfn_adapter+0x85/0xf0
[   16.372392]  kthread+0x337/0x6f0
[   16.372570]  ret_from_fork+0x116/0x1d0
[   16.372723]  ret_from_fork_asm+0x1a/0x30
[   16.373177] 
[   16.373385] kfence-#71: 0x(____ptrval____)-0x(____ptrval____), size=32, cache=kmalloc-32
[   16.373385] 
[   16.373841] allocated by task 312 on cpu 0 at 16.370084s (0.003755s ago):
[   16.374090]  test_alloc+0x364/0x10f0
[   16.374227]  test_use_after_free_read+0xdc/0x270
[   16.374501]  kunit_try_run_case+0x1a5/0x480
[   16.374930]  kunit_generic_run_threadfn_adapter+0x85/0xf0
[   16.375224]  kthread+0x337/0x6f0
[   16.375348]  ret_from_fork+0x116/0x1d0
[   16.375678]  ret_from_fork_asm+0x1a/0x30
[   16.376005] 
[   16.376109] freed by task 312 on cpu 0 at 16.370150s (0.005956s ago):
[   16.376461]  test_use_after_free_read+0x1e7/0x270
[   16.376667]  kunit_try_run_case+0x1a5/0x480
[   16.377007]  kunit_generic_run_threadfn_adapter+0x85/0xf0
[   16.377341]  kthread+0x337/0x6f0
[   16.377524]  ret_from_fork+0x116/0x1d0
[   16.377695]  ret_from_fork_asm+0x1a/0x30
[   16.378002] 
[   16.378195] CPU: 0 UID: 0 PID: 312 Comm: kunit_try_catch Tainted: G    B            N  6.15.0-next-20250529 #1 PREEMPT(voluntary) 
[   16.378756] Tainted: [B]=BAD_PAGE, [N]=TEST
[   16.379010] Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.16.3-debian-1.16.3-2 04/01/2014
[   16.379456] ==================================================================