CVE-2025-21784: drm/amdgpu: bail out when failed to load fw in psp_init_cap_microcode()
Description
===========
In the Linux kernel, the following vulnerability has been resolved:
drm/amdgpu: bail out when failed to load fw in psp_init_cap_microcode()
In function psp_init_cap_microcode(), it should bail out when failed to load firmware, otherwise it may cause invalid memory access.
The Linux kernel CVE team has assigned CVE-2025-21784 to this issue.
Affected and fixed versions
===========================
Issue introduced in 6.3 with commit 07dbfc6b102e25087ec345ef2c2eae21c9856f17 and fixed in 6.6.79 with commit 3f40a7ff39d9f1d283d5aa9b13e2fb16200aff5f Issue introduced in 6.3 with commit 07dbfc6b102e25087ec345ef2c2eae21c9856f17 and fixed in 6.12.16 with commit d1d10bd595539ed82ab59b60249f9bdf0994f678 Issue introduced in 6.3 with commit 07dbfc6b102e25087ec345ef2c2eae21c9856f17 and fixed in 6.13.4 with commit e7eb84384335e2abf960c94ec0f8c5b835283777 Issue introduced in 6.3 with commit 07dbfc6b102e25087ec345ef2c2eae21c9856f17 and fixed in 6.14-rc3 with commit a0a455b4bc7483ad60e8b8a50330c1e05bb7bfcf
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-2025-21784
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:
drivers/gpu/drm/amd/amdgpu/amdgpu_psp.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/3f40a7ff39d9f1d283d5aa9b13e2fb16200aff5f https://git.kernel.org/stable/c/d1d10bd595539ed82ab59b60249f9bdf0994f678 https://git.kernel.org/stable/c/e7eb84384335e2abf960c94ec0f8c5b835283777 https://git.kernel.org/stable/c/a0a455b4bc7483ad60e8b8a50330c1e05bb7bfcf