Description
In the Linux kernel, the following vulnerability has been resolved: drm/amdgpu: recompute the dw estimate after allocating a new VM update job amdgpu_vm_sdma_update() keeps the number of free dwords of the current job in a local variable. When the job runs out of room it is committed and a new one is allocated, but that local variable is not refreshed and still describes the job which was just submitted. The stale value is then used to decide how many PTEs fit into the new job. If it happens to be copy_pte_num_dw + 7, or one more than that, the result is zero. copy_pte() encodes the transfer size as count * 8 - 1, so a count of zero asks the engine for a 1GB copy starting inside the IB pool. That runs off the end of the pool, faults on the first unmapped GART page above it and hangs the ring. Re-initialize the estimate from the newly allocated job, which is empty and therefore has its full budget available.
Affected products and versions
CVSS vector, explained
CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H
- Attack vector
- Local
- Attack complexity
- Low
- Privileges required
- Regular user
- User interaction
- Not required
- Scope
- Vulnerable component only
- Confidentiality
- High impact
- Integrity
- High impact
- Availability
- High impact
References
- git.kernel.org/stable/c/94611b5aa3b8b94d5465e579c100a506faad5678
- git.kernel.org/stable/c/d7e4ce4f399878bb46817d742387d6ed0a3114fa
- git.kernel.org/stable/c/1871143400c7f459c647867cf544ed937dd50736
- git.kernel.org/stable/c/dc715d660d9255ed016b41a624e5dee69c0840a4
- git.kernel.org/stable/c/ec67981c87d574d584406ce341ab72067590069d
- git.kernel.org/stable/c/a74c7832b11827907de560169c7d4ac94505fd87
Sources: CVE.org (CNA and CISA ADP), CISA KEV, FIRST EPSS. Always check the vendor's official advisory.