CVE-2026-98477: perf/core: Fix NULL pmu_ctx passed to pmu->sched_task()
In the Linux kernel, the following vulnerability has been resolved:
perf/core: Fix NULL pmuctx passed to pmu->schedtask()
perfpmuschedtask() returns early when cpuctx->taskctx is set, and cpc->taskepc is only non-NULL while a task context is scheduled in on this CPU. perfpmuschedtask() therefore always passes NULL:
Unable to handle kernel NULL pointer dereference at virtual address 00 pc : armv8pmuschedtask+0x14/0x50 Call trace: armv8pmuschedtask+0x14/0x50 (P) perfpmuschedtask+0xac/0x108 perfeventtaskschedout+0x6c/0xe0
Pass &cpc->epc instead, the CPU-wide context for this PMU, which the function already dereferences a few lines up to find pmu.
armv8pmuschedtask() is the only in-tree implementation that dereferences the argument, and it only reads ->pmu, so the oops needs BRBE, added in v6.17.
Affected Software
Remediation
Recommended actions to resolve this vulnerability, in priority order.
- Upgrade
Upgrade
ubuntu/linux-hwe-7.0to a version that resolves this vulnerability.Fixed in 7.0.0-42.42~24.04.1 - Upgrade
Upgrade
ubuntu/linux-riscv-7.0to a version that resolves this vulnerability.Fixed in 7.0.0-42.42.1~24.04.1 - Upgrade
Upgrade
ubuntu/linuxto a version that resolves this vulnerability.Fixed in 7.0.0-42.42 - Upgrade
Upgrade
ubuntu/linux-awsto a version that resolves this vulnerability.Fixed in 7.0.0-1016.17 - Upgrade
Upgrade
ubuntu/linux-gcpto a version that resolves this vulnerability.Fixed in 7.0.0-1016.18 - Upgrade
Upgrade
ubuntu/linux-ibmto a version that resolves this vulnerability.Fixed in 7.0.0-1017.17 - Upgrade
Upgrade
ubuntu/linux-oem-7.0to a version that resolves this vulnerability.Fixed in 7.0.0-1017.17 - Upgrade
Upgrade
ubuntu/linux-oracleto a version that resolves this vulnerability.Fixed in 7.0.0-1015.16 - Upgrade
Upgrade
ubuntu/linux-riscvto a version that resolves this vulnerability.Fixed in 7.0.0-42.42.1
Event History
Frequently Asked Questions
Which systems are exposed to the kernel oops?
The oops requires BRBE support and affects the ARMv8 PMU scheduling path. The described dereference is in armv8pmu_sched_task(), the only in-tree implementation noted as dereferencing the affected argument.
What condition triggers the NULL pointer dereference?
It occurs during perf event task scheduling when __perf_pmu_sched_task() passes a NULL PMU context to the PMU sched_task callback. The NULL value results from using cpc->task_epc, which is non-NULL only while a task context is scheduled on that CPU.
What is the relevant remediation?
Apply a kernel update containing the fix that passes the CPU-wide context, &cpc->epc, to the PMU callback instead of the task context pointer. The provided stable-kernel references identify commits carrying this correction.