# CVE-2025-40199: page\_pool: Fix PP\_MAGIC\_MASK to avoid crashing on some 32-bit arches

> Archived entry. Full-text search covers entries since 2026-11-10; exact IDs work for all years.

- **Severity:** HIGH 7.8
- **CVSS:** 7.8 (v3.1, CNA) `CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H`
- **CVSS metrics:** Attack vector: Local; Attack complexity: Low; Privileges required: Low; User interaction: None; Scope: Unchanged; Confidentiality impact: High; Integrity impact: High; Availability impact: High
- **Exploited in the wild:** Not in CISA KEV
- **Public exploit / PoC:** None known
- **Remote exploitation:** Not remotely exploitable (local or adjacent access needed)
- **EPSS:** 0.23% (percentile 8, 2026-11-26)
- **Published:** 2025-11-12T21:56:33.510Z
- **Modified:** 2026-10-19T21:10:00.160Z

## Who should check

- Anyone running Linux \>= 4f51fb0d257ff4d406ec27966902de075e3b118e, \< 15b8a5b4cdc16e9a8bb2a548e12a0fd92997605a; \>= ee62ce7a1d909ccba0399680a03c2dee83bcae95, \< f62934cea32c8f7b11b747975d69bf5afe4264cf; \>= ee62ce7a1d909ccba0399680a03c2dee83bcae95, \< 95920c2ed02bde551ab654e9749c2ca7bc3100e0; c30ae60f41f9edd6e1b5cad41cf28ce04dae39e4; \>= 6.12.34, \< 6.12.54; \>= 6.15.3, \< 6.16
- Anyone running Linux 6.16

## Description

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

page\_pool: Fix PP\_MAGIC\_MASK to avoid crashing on some 32-bit arches

Helge reported that the introduction of PP\_MAGIC\_MASK let to crashes on
boot on his 32-bit parisc machine. The cause of this is the mask is set
too wide, so the page\_pool\_page\_is\_pp() incurs false positives which
crashes the machine.

Just disabling the check in page\_pool\_is\_pp() will lead to the page\_pool
code itself malfunctioning; so instead of doing this, this patch changes
the define for PP\_DMA\_INDEX\_BITS to avoid mistaking arbitrary kernel
pointers for page\_pool-tagged pages.

The fix relies on the kernel pointers that alias with the pp\_magic field
always being above PAGE\_OFFSET. With this assumption, we can use the
lowest bit of the value of PAGE\_OFFSET as the upper bound of the
PP\_DMA\_INDEX\_MASK, which should avoid the false positives.

Because we cannot rely on PAGE\_OFFSET always being a compile-time
constant, nor on it always being \>0, we fall back to disabling the
dma\_index storage when there are not enough bits available. This leaves
us in the situation we were in before the patch in the Fixes tag, but
only on a subset of architecture configurations. This seems to be the
best we can do until the transition to page types in complete for
page\_pool pages.

v2:
- Make sure there's at least 8 bits available and that the PAGE\_OFFSET
  bit calculation doesn't wrap

## Affected and fixed versions

- Linux: \>= 4f51fb0d257ff4d406ec27966902de075e3b118e, \< 15b8a5b4cdc16e9a8bb2a548e12a0fd92997605a; \>= ee62ce7a1d909ccba0399680a03c2dee83bcae95, \< f62934cea32c8f7b11b747975d69bf5afe4264cf; \>= ee62ce7a1d909ccba0399680a03c2dee83bcae95, \< 95920c2ed02bde551ab654e9749c2ca7bc3100e0; c30ae60f41f9edd6e1b5cad41cf28ce04dae39e4; \>= 6.12.34, \< 6.12.54; \>= 6.15.3, \< 6.16 (cvelist)
- Linux: 6.16 (cvelist)

## Mitigation

- Upgrade Linux to 6.16 or later.

## Check your systems with an agent

Paste this into a coding agent:

```text
Check whether anything I run is affected by CVE-2025-40199. Work read-only: do not install, upgrade, delete or change anything.

Details: https://flawdb.com/CVE-2025-40199.md
Affected: Linux >= 4f51fb0d257ff4d406ec27966902de075e3b118e, < 15b8a5b4cdc16e9a8bb2a548e12a0fd92997605a; >= ee62ce7a1d909ccba0399680a03c2dee83bcae95, < f62934cea32c8f7b11b747975d69bf5afe4264cf; >= ee62ce7a1d909ccba0399680a03c2dee83bcae95, < 95920c2ed02bde551ab654e9749c2ca7bc3100e0; c30ae60f41f9edd6e1b5cad41c…
Fixed in: Linux 15b8a5b4cdc16e9a8bb2a548e12a0fd92997605a, Linux 95920c2ed02bde551ab654e9749c2ca7bc3100e0, Linux 6.12.54, Linux 6.16

Steps:
1. Search this machine and project for Linux: dependency manifests and lockfiles, installed packages, container images and running services.
2. For each match, note the installed version and whether it is inside the affected range.
3. Report a table: location, installed version, affected (yes / no / unsure), evidence. If affected, say which fixed version or mitigation from the details link applies, but don't apply it.
```

## FAQ

### Is CVE-2025-40199 being exploited?

There is no confirmed exploitation: CVE-2025-40199 is not in the CISA Known Exploited Vulnerabilities catalog. No public exploit code is known. EPSS estimates a 0.23% chance of exploitation in the next 30 days (as of 2026-11-26).

### How serious is CVE-2025-40199?

High: CVSS 7.8 (v3.1, scored by CNA). Not remotely exploitable (local or adjacent access needed).

### Which versions are affected by CVE-2025-40199?

Linux \>= 4f51fb0d257ff4d406ec27966902de075e3b118e, \< 15b8a5b4cdc16e9a8bb2a548e12a0fd92997605a; \>= ee62ce7a1d909ccba0399680a03c2dee83bcae95, \< f62934cea32c8f7b11b747975d69bf5afe4264cf; \>= ee62ce7a1d909ccba0399680a03c2dee83bcae95, \< 95920c2ed02bde551ab654e9749c2ca7bc3100e0; c30ae60f41f9edd6e1b5cad41cf28ce04dae39e4; \>= 6.12.34, \< 6.12.54; \>= 6.15.3, \< 6.16; Linux 6.16.

### Is there a fix for CVE-2025-40199?

Yes. Fixed in Linux 15b8a5b4cdc16e9a8bb2a548e12a0fd92997605a, Linux 95920c2ed02bde551ab654e9749c2ca7bc3100e0, Linux 6.12.54, Linux 6.16. Upgrade Linux to 6.16 or later.

### How do I check if I'm affected by CVE-2025-40199?

Find where you use the affected software (dependency lockfiles, installed packages, container images, servers) and compare the installed version with the affected range above. The agent prompt on this page does this read-only.

## References

- other: <https://git.kernel.org/stable/c/15b8a5b4cdc16e9a8bb2a548e12a0fd92997605a>
- other: <https://git.kernel.org/stable/c/f62934cea32c8f7b11b747975d69bf5afe4264cf>
- other: <https://git.kernel.org/stable/c/95920c2ed02bde551ab654e9749c2ca7bc3100e0>

## Attribution

- CVE Program: CVE® is a registered trademark of The MITRE Corporation. CVE records © 1999–2026 The MITRE Corporation. <https://www.cve.org/Legal/TermsOfUse>
- NVD: This product uses data from the NVD API but is not endorsed or certified by the NVD. <https://nvd.nist.gov/vuln/detail/CVE-2025-40199>

HTML: <https://flawdb.com/CVE-2025-40199> · JSON: <https://flawdb.com/api/v1/entries/CVE-2025-40199>
