Security Vulnerability Report
中文
CVE-2025-71299 CVSS 5.5 MEDIUM

CVE-2025-71299

Published: 2026-05-08 14:16:31
Last Modified: 2026-05-14 19:11:57
Source: 416baaa9-dc9f-4396-8d5f-8c081fb06d67

Description

In the Linux kernel, the following vulnerability has been resolved: spi: cadence-quadspi: Parse DT for flashes with the rest of the DT parsing The recent refactoring of where runtime PM is enabled done in commit f1eb4e792bb1 ("spi: spi-cadence-quadspi: Enable pm runtime earlier to avoid imbalance") made the fact that when we do a pm_runtime_disable() in the error paths of probe() we can trigger a runtime disable which in turn results in duplicate clock disables. This is particularly likely to happen when there is missing or broken DT description for the flashes attached to the controller. Early on in the probe function we do a pm_runtime_get_noresume() since the probe function leaves the device in a powered up state but in the error path we can't assume that PM is enabled so we also manually disable everything, including clocks. This means that when runtime PM is active both it and the probe function release the same reference to the main clock for the IP, triggering warnings from the clock subsystem: [ 8.693719] clk:75:7 already disabled [ 8.693791] WARNING: CPU: 1 PID: 185 at /usr/src/kernel/drivers/clk/clk.c:1188 clk_core_disable+0xa0/0xb ... [ 8.694261] clk_core_disable+0xa0/0xb4 (P) [ 8.694272] clk_disable+0x38/0x60 [ 8.694283] cqspi_probe+0x7c8/0xc5c [spi_cadence_quadspi] [ 8.694309] platform_probe+0x5c/0xa4 Dealing with this issue properly is complicated by the fact that we don't know if runtime PM is active so can't tell if it will disable the clocks or not. We can, however, sidestep the issue for the flash descriptions by moving their parsing to when we parse the controller properties which also save us doing a bunch of setup which can never be used so let's do that.

CVSS Details

CVSS Score
5.5
Severity
MEDIUM
CVSS Vector
CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H

Configurations (Affected Products)

cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:* - VULNERABLE
cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:* - VULNERABLE
cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:* - VULNERABLE
cpe:2.3:o:linux:linux_kernel:6.18:-:*:*:*:*:*:* - VULNERABLE
Linux Kernel (包含 commit f1eb4e792bb1 但未包含修复提交的版本)

PoC / Exploit Code

⚠ For Security Research Only
The following code is for security research and authorized testing only.
python
/dts-v1/; / { /* * PoC: Broken Device Tree Description * Description: This snippet represents a Device Tree configuration * that triggers the vulnerability by omitting the required 'flash' * child node or providing invalid properties for the Cadence QSPI controller. * Loading a kernel with this DTB attached to the hardware will trigger * the double clock disable bug. */ soc { #address-cells = <1>; #size-cells = <1>; spi@ff705000 { /* Example base address */ compatible = "cdns,qspi-nor"; reg = <0xff705000 0x1000>, <0xffa00000 0x1000>; interrupts = <0 151 4>; clocks = <&qspi_clk>; cdns,fifo-depth = <128>; cdns,fifo-width = <4>; cdns,trigger-address = <0x00000000>; #address-cells = <1>; #size-cells = <0>; /* Missing or broken flash@0 node here triggers the vulnerability */ }; }; };

References

Raw JSON Data

JSON
{"cve": {"id": "CVE-2025-71299", "sourceIdentifier": "416baaa9-dc9f-4396-8d5f-8c081fb06d67", "published": "2026-05-08T14:16:31.267", "lastModified": "2026-05-14T19:11:57.097", "vulnStatus": "Analyzed", "cveTags": [], "descriptions": [{"lang": "en", "value": "In the Linux kernel, the following vulnerability has been resolved:\n\nspi: cadence-quadspi: Parse DT for flashes with the rest of the DT parsing\n\nThe recent refactoring of where runtime PM is enabled done in commit\nf1eb4e792bb1 (\"spi: spi-cadence-quadspi: Enable pm runtime earlier to\navoid imbalance\") made the fact that when we do a pm_runtime_disable()\nin the error paths of probe() we can trigger a runtime disable which in\nturn results in duplicate clock disables. This is particularly likely\nto happen when there is missing or broken DT description for the flashes\nattached to the controller.\n\nEarly on in the probe function we do a pm_runtime_get_noresume() since\nthe probe function leaves the device in a powered up state but in the\nerror path we can't assume that PM is enabled so we also manually\ndisable everything, including clocks. This means that when runtime PM is\nactive both it and the probe function release the same reference to the\nmain clock for the IP, triggering warnings from the clock subsystem:\n\n[ 8.693719] clk:75:7 already disabled\n[ 8.693791] WARNING: CPU: 1 PID: 185 at /usr/src/kernel/drivers/clk/clk.c:1188 clk_core_disable+0xa0/0xb\n...\n[ 8.694261] clk_core_disable+0xa0/0xb4 (P)\n[ 8.694272] clk_disable+0x38/0x60\n[ 8.694283] cqspi_probe+0x7c8/0xc5c [spi_cadence_quadspi]\n[ 8.694309] platform_probe+0x5c/0xa4\n\nDealing with this issue properly is complicated by the fact that we\ndon't know if runtime PM is active so can't tell if it will disable the\nclocks or not. We can, however, sidestep the issue for the flash\ndescriptions by moving their parsing to when we parse the controller\nproperties which also save us doing a bunch of setup which can never be\nused so let's do that."}], "metrics": {"cvssMetricV31": [{"source": "[email protected]", "type": "Primary", "cvssData": {"version": "3.1", "vectorString": "CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H", "baseScore": 5.5, "baseSeverity": "MEDIUM", "attackVector": "LOCAL", "attackComplexity": "LOW", "privilegesRequired": "LOW", "userInteraction": "NONE", "scope": "UNCHANGED", "confidentialityImpact": "NONE", "integrityImpact": "NONE", "availabilityImpact": "HIGH"}, "exploitabilityScore": 1.8, "impactScore": 3.6}]}, "weaknesses": [{"source": "[email protected]", "type": "Primary", "description": [{"lang": "en", "value": "NVD-CWE-noinfo"}]}], "configurations": [{"nodes": [{"operator": "OR", "negate": false, "cpeMatch": [{"vulnerable": true, "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*", "versionStartIncluding": "6.17.11", "versionEndExcluding": "6.18", "matchCriteriaId": "4F94524C-FCFA-40B0-BFBB-176385BE0D5D"}, {"vulnerable": true, "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*", "versionStartIncluding": "6.18.1", "versionEndExcluding": "6.18.16", "matchCriteriaId": "B9F70427-D920-454E-9E11-B6F08300C161"}, {"vulnerable": true, "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*", "versionStartIncluding": "6.19", "versionEndExcluding": "6.19.6", "matchCriteriaId": "373EEEDA-FAA1-4FB4-B6ED-DB4DD99DBE67"}, {"vulnerable": true, "criteria": "cpe:2.3:o:linux:linux_kernel:6.18:-:*:*:*:*:*:*", "matchCriteriaId": "DCE57113-2223-4308-A0F2-5E6ECFBB3C23"}]}]}], "references": [{"url": "https://git.kernel.org/stable/c/08dca4c8099a41a9fa3be128a793387603f73a17", "source": "416baaa9-dc9f-4396-8d5f-8c081fb06d67", "tags": ["Patch"]}, {"url": "https://git.kernel.org/stable/c/9f0736a4e136a6eb61e0cf530ddc18ab6d816ba3", "source": "416baaa9-dc9f-4396-8d5f-8c081fb06d67", "tags": ["Patch"]}, {"url": "https://git.kernel.org/stable/c/dcaa104ad9c860a6dbd5797919e0ec0b1cd5a57a", "source": "416baaa9-dc9f-4396-8d5f-8c081fb06d67", "tags": ["Patch"]}]}}