Skip to contentSkip to conversation

CVE-2026-80626: powerpc/perf: fix preempt count underflow in fsl_emb_pmu_del

DISCUSSION Greg Kroah-Hartman 1 participant 1 message Aug 28

lore
Share & tools
lore
#0 lore raw

From: Greg Kroah-Hartman <[email protected]>

Description
===========

In the Linux kernel, the following vulnerability has been resolved:

powerpc/perf: fix preempt count underflow in fsl_emb_pmu_del

fsl_emb_pmu_del() unconditionally calls put_cpu_var(cpu_hw_events) at the 'out:' label, but only calls the matching get_cpu_var() after the 'i < 0' early-return check. When event->hw.idx is negative the function jumps to 'out:' without having taken get_cpu_var(), and the trailing put_cpu_var() then issues an unmatched preempt_enable(), underflowing preempt_count.

On a CONFIG_PREEMPT=y kernel preempt_count would underflow and eventually present as a 'scheduling while atomic' BUG.

Move put_cpu_var() to pair with get_cpu_var() so the percpu access is correctly bracketed and the 'out:' label only handles perf_pmu_enable.

The Linux kernel CVE team has assigned CVE-2026-80626 to this issue.

Affected and fixed versions
===========================

	Issue introduced in 2.6.34 with commit a11106544f33c104706ae42d27219a409b67478e and fixed in 5.10.261 with commit c0c7722308c5f303117d8bd555290fdf26b098da
	Issue introduced in 2.6.34 with commit a11106544f33c104706ae42d27219a409b67478e and fixed in 5.15.212 with commit 67aeb1eb93d4ffd898a3e74a7f3fe46ee71feb28
	Issue introduced in 2.6.34 with commit a11106544f33c104706ae42d27219a409b67478e and fixed in 6.1.178 with commit 9a515e00b00132b6fc3f1dd62dc5204bbda8cb10
	Issue introduced in 2.6.34 with commit a11106544f33c104706ae42d27219a409b67478e and fixed in 6.6.145 with commit 5397142d60aa29dcf636f5459d960bfc4f97c42a
	Issue introduced in 2.6.34 with commit a11106544f33c104706ae42d27219a409b67478e and fixed in 6.12.97 with commit b89477077c834d94381c7bf07d81193bebefcff9
	Issue introduced in 2.6.34 with commit a11106544f33c104706ae42d27219a409b67478e and fixed in 6.18.40 with commit 73711688479df333acc134e3730fff1acba1843e
	Issue introduced in 2.6.34 with commit a11106544f33c104706ae42d27219a409b67478e and fixed in 7.1.5 with commit b504fd953664c3f4d176ae8cb594adb3fda9d577
	Issue introduced in 2.6.34 with commit a11106544f33c104706ae42d27219a409b67478e and fixed in 7.2 with commit 81e3a86030462824a67d697739cf3f387f4ba350

Please see https://www.kernel.org for a full list of currently supported kernel versions by the kernel community.

Unaffected versions might change over time as fixes are backported to older supported kernel versions. The official CVE entry at

	https://cve.org/CVERecord/?id=CVE-2026-80626

will be updated if fixes are backported, please check that for the most up to date information about this issue.

Affected files
==============

The file(s) affected by this issue are:
arch/powerpc/perf/core-fsl-emb.c

Mitigation
==========

The Linux kernel CVE team recommends that you update to the latest stable kernel version for this, and many other bugfixes. Individual changes are never tested alone, but rather are part of a larger kernel release. Cherry-picking individual commits is not recommended or supported by the Linux kernel community at all. If however, updating to the latest release is impossible, the individual changes to resolve this issue can be found at these commits:

	https://git.kernel.org/stable/c/c0c7722308c5f303117d8bd555290fdf26b098da
	https://git.kernel.org/stable/c/67aeb1eb93d4ffd898a3e74a7f3fe46ee71feb28
	https://git.kernel.org/stable/c/9a515e00b00132b6fc3f1dd62dc5204bbda8cb10
	https://git.kernel.org/stable/c/5397142d60aa29dcf636f5459d960bfc4f97c42a
	https://git.kernel.org/stable/c/b89477077c834d94381c7bf07d81193bebefcff9
	https://git.kernel.org/stable/c/73711688479df333acc134e3730fff1acba1843e
	https://git.kernel.org/stable/c/b504fd953664c3f4d176ae8cb594adb3fda9d577
	https://git.kernel.org/stable/c/81e3a86030462824a67d697739cf3f387f4ba350