CVE-2025-38354

Source
https://nvd.nist.gov/vuln/detail/CVE-2025-38354
Import Source
https://storage.googleapis.com/osv-test-cve-osv-conversion/osv-output/CVE-2025-38354.json
JSON Data
https://api.test.osv.dev/v1/vulns/CVE-2025-38354
Downstream
Related
Published
2025-07-25T12:47:26.087Z
Modified
2025-11-28T02:35:16.976015Z
Summary
drm/msm/gpu: Fix crash when throttling GPU immediately during boot
Details

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

drm/msm/gpu: Fix crash when throttling GPU immediately during boot

There is a small chance that the GPU is already hot during boot. In that case, the call to ofdevfreqcooling_register() will immediately try to apply devfreq cooling, as seen in the following crash:

Unable to handle kernel paging request at virtual address 0000000000014110 pc : a6xxgpubusy+0x1c/0x58 [msm] lr : msmdevfreqgetdevstatus+0xbc/0x140 [msm] Call trace: a6xxgpubusy+0x1c/0x58 [msm] (P) devfreqsimpleondemandfunc+0x3c/0x150 devfrequpdatetarget+0x44/0xd8 qosmaxnotifiercall+0x30/0x84 blockingnotifiercallchain+0x6c/0xa0 pmqosupdatetarget+0xd0/0x110 freqqosapply+0x3c/0x74 applyconstraint+0x88/0x148 _devpmqosupdaterequest+0x7c/0xcc devpmqosupdaterequest+0x38/0x5c devfreqcoolingsetcurstate+0x98/0xf0 _thermalcdevupdate+0x64/0xb4 thermalcdevupdate+0x4c/0x58 stepwisemanage+0x1f0/0x318 _thermalzonedeviceupdate+0x278/0x424 _thermalcoolingdeviceregister+0x2bc/0x308 thermalofcoolingdeviceregister+0x10/0x1c ofdevfreqcoolingregisterpower+0x240/0x2bc ofdevfreqcoolingregister+0x14/0x20 msmdevfreqinit+0xc4/0x1a0 [msm] msmgpuinit+0x304/0x574 [msm] adrenogpuinit+0x1c4/0x2e0 [msm] a6xxgpuinit+0x5c8/0x9c8 [msm] adreno_bind+0x2a8/0x33c [msm] ...

At this point we haven't initialized the GMU at all yet, so we cannot read the GMU registers inside a6xxgpubusy(). A similar issue was fixed before in commit 6694482a70e9 ("drm/msm: Avoid unclocked GMU register access in 6xx gpubusy"): msmdevfreqinit() does call devfreqsuspenddevice(), but unlike msmdevfreqsuspend(), it doesn't set the df->suspended flag accordingly. This means the df->suspended flag does not match the actual devfreq state after initialization and msmdevfreqgetdev_status() will end up accessing GMU registers, causing the crash.

Fix this by setting df->suspended correctly during initialization.

Patchwork: https://patchwork.freedesktop.org/patch/650772/

Database specific
{
    "cna_assigner": "Linux",
    "osv_generated_from": "https://github.com/CVEProject/cvelistV5/tree/main/cves/2025/38xxx/CVE-2025-38354.json"
}
References

Affected packages

Git / git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git

Affected ranges

Type
GIT
Repo
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
Events
Introduced
6694482a70e9536efbf2ac233cbf0c302d6e2dae
Fixed
ae2015b0dbc0eea7aaf022194371f451f784d994
Fixed
7946a10f8da75abc494e4bb80243e153e93e459a
Fixed
1847ea44e3bdf7da8ff4158bc01b43a2e46394bd
Fixed
a6f673cc9488fd722c601fe020601dba14db21b2
Fixed
b71717735be48d7743a34897e9e44a0b53e30c0e
Type
GIT
Repo
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
Events
Introduced
0 Unknown introduced commit / All previous commits are affected
Last affected
1f6c087dd6a915f1c3471f0f0f696847fc8c592f
Last affected
9c8b3f05fb18fba12f3fca80a378c9b8f3d04cd6

Linux / Kernel

Package

Name
Kernel

Affected ranges

Type
ECOSYSTEM
Events
Introduced
6.0.0
Fixed
6.1.143
Type
ECOSYSTEM
Events
Introduced
6.2.0
Fixed
6.6.96
Type
ECOSYSTEM
Events
Introduced
6.7.0
Fixed
6.12.36
Type
ECOSYSTEM
Events
Introduced
6.13.0
Fixed
6.15.5