# CVE-2022-49335: drm/amdgpu/cs: make commands with 0 chunks illegal behaviour.

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

- **Severity:** MEDIUM 5.5
- **CVSS:** 5.5 (v3.1, CNA) `CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H`
- **CVSS metrics:** Attack vector: Local; Attack complexity: Low; Privileges required: Low; User interaction: None; Scope: Unchanged; Confidentiality impact: None; Integrity impact: None; 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.29% (percentile 14, 2026-11-26)
- **CWE:** CWE-476
- **Published:** 2025-02-26T02:10:54.763Z
- **Modified:** 2026-06-17T05:17:45.130Z

## Who should check

- Anyone running Linux \>= d38ceaf99ed015f2a0b9af3499791bd3a3daae21, \< 8189f44270db1be78169e11eec51a3eeb980bc63; \>= d38ceaf99ed015f2a0b9af3499791bd3a3daae21, \< aa25acbe96692e4bf8482311c293f72d8c6034c0; \>= d38ceaf99ed015f2a0b9af3499791bd3a3daae21, \< 15c3bcc9b5349d40207e5f8d4d799b8b4b7d13b8; \>= d38ceaf99ed015f2a0b9af3499791bd3a3daae21, \< c12984cdb077b9042d2dc20ca18cb16a87bcc774; \>= d38ceaf99ed015f2a0b9af3499791bd3a3daae21, \< be585921f29df5422a39c952d188b418ad48ffab; \>= d38ceaf99ed015f2a0b9af3499791bd3a3daae21, \< 70276460e914d560e96bfc208695a872fe9469c9; \>= d38ceaf99ed015f2a0b9af3499791bd3a3daae21, \< 20b947e5a3c74c5084d661c097517a554989d462; \>= d38ceaf99ed015f2a0b9af3499791bd3a3daae21, \< 7086a23890d255bb5761604e39174b20d06231a4; \>= d38ceaf99ed015f2a0b9af3499791bd3a3daae21, \< 31ab27b14daaa75541a415c6794d6f3567fea44a
- Anyone running Linux 4.2

## Description

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

drm/amdgpu/cs: make commands with 0 chunks illegal behaviour.

Submitting a cs with 0 chunks, causes an oops later, found trying
to execute the wrong userspace driver.

MESA\_LOADER\_DRIVER\_OVERRIDE=v3d glxinfo

\[172536.665184\] BUG: kernel NULL pointer dereference, address: 00000000000001d8
\[172536.665188\] \#PF: supervisor read access in kernel mode
\[172536.665189\] \#PF: error\_code(0x0000) - not-present page
\[172536.665191\] PGD 6712a0067 P4D 6712a0067 PUD 5af9ff067 PMD 0
\[172536.665195\] Oops: 0000 \[\#1\] SMP NOPTI
\[172536.665197\] CPU: 7 PID: 2769838 Comm: glxinfo Tainted: P           O      5.10.81 \#1-NixOS
\[172536.665199\] Hardware name: To be filled by O.E.M. To be filled by O.E.M./CROSSHAIR V FORMULA-Z, BIOS 2201 03/23/2015
\[172536.665272\] RIP: 0010:amdgpu\_cs\_ioctl+0x96/0x1ce0 \[amdgpu\]
\[172536.665274\] Code: 75 18 00 00 4c 8b b2 88 00 00 00 8b 46 08 48 89 54 24 68 49 89 f7 4c 89 5c 24 60 31 d2 4c 89 74 24 30 85 c0 0f 85 c0 01 00 00 \<48\> 83 ba d8 01 00 00 00 48 8b b4 24 90 00 00 00 74 16 48 8b 46 10
\[172536.665276\] RSP: 0018:ffffb47c0e81bbe0 EFLAGS: 00010246
\[172536.665277\] RAX: 0000000000000000 RBX: 0000000000000000 RCX: 0000000000000000
\[172536.665278\] RDX: 0000000000000000 RSI: ffffb47c0e81be28 RDI: ffffb47c0e81bd68
\[172536.665279\] RBP: ffff936524080010 R08: 0000000000000000 R09: ffffb47c0e81be38
\[172536.665281\] R10: ffff936524080010 R11: ffff936524080000 R12: ffffb47c0e81bc40
\[172536.665282\] R13: ffffb47c0e81be28 R14: ffff9367bc410000 R15: ffffb47c0e81be28
\[172536.665283\] FS:  00007fe35e05d740(0000) GS:ffff936c1edc0000(0000) knlGS:0000000000000000
\[172536.665284\] CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
\[172536.665286\] CR2: 00000000000001d8 CR3: 0000000532e46000 CR4: 00000000000406e0
\[172536.665287\] Call Trace:
\[172536.665322\]  ? amdgpu\_cs\_find\_mapping+0x110/0x110 \[amdgpu\]
\[172536.665332\]  drm\_ioctl\_kernel+0xaa/0xf0 \[drm\]
\[172536.665338\]  drm\_ioctl+0x201/0x3b0 \[drm\]
\[172536.665369\]  ? amdgpu\_cs\_find\_mapping+0x110/0x110 \[amdgpu\]
\[172536.665372\]  ? selinux\_file\_ioctl+0x135/0x230
\[172536.665399\]  amdgpu\_drm\_ioctl+0x49/0x80 \[amdgpu\]
\[172536.665403\]  \_\_x64\_sys\_ioctl+0x83/0xb0
\[172536.665406\]  do\_syscall\_64+0x33/0x40
\[172536.665409\]  entry\_SYSCALL\_64\_after\_hwframe+0x44/0xa9

Bug: https://gitlab.freedesktop.org/drm/amd/-/issues/2018

## Affected and fixed versions

- Linux: \>= d38ceaf99ed015f2a0b9af3499791bd3a3daae21, \< 8189f44270db1be78169e11eec51a3eeb980bc63; \>= d38ceaf99ed015f2a0b9af3499791bd3a3daae21, \< aa25acbe96692e4bf8482311c293f72d8c6034c0; \>= d38ceaf99ed015f2a0b9af3499791bd3a3daae21, \< 15c3bcc9b5349d40207e5f8d4d799b8b4b7d13b8; \>= d38ceaf99ed015f2a0b9af3499791bd3a3daae21, \< c12984cdb077b9042d2dc20ca18cb16a87bcc774; \>= d38ceaf99ed015f2a0b9af3499791bd3a3daae21, \< be585921f29df5422a39c952d188b418ad48ffab; \>= d38ceaf99ed015f2a0b9af3499791bd3a3daae21, \< 70276460e914d560e96bfc208695a872fe9469c9; \>= d38ceaf99ed015f2a0b9af3499791bd3a3daae21, \< 20b947e5a3c74c5084d661c097517a554989d462; \>= d38ceaf99ed015f2a0b9af3499791bd3a3daae21, \< 7086a23890d255bb5761604e39174b20d06231a4; \>= d38ceaf99ed015f2a0b9af3499791bd3a3daae21, \< 31ab27b14daaa75541a415c6794d6f3567fea44a (cvelist)
- Linux: 4.2 (cvelist)

## Mitigation

- Upgrade Linux to 31ab27b14daaa75541a415c6794d6f3567fea44a or later.

## Check your systems with an agent

Paste this into a coding agent:

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

Details: https://flawdb.com/CVE-2022-49335.md
Affected: Linux >= d38ceaf99ed015f2a0b9af3499791bd3a3daae21, < 8189f44270db1be78169e11eec51a3eeb980bc63; >= d38ceaf99ed015f2a0b9af3499791bd3a3daae21, < aa25acbe96692e4bf8482311c293f72d8c6034c0; >= d38ceaf99ed015f2a0b9af3499791bd3a3daae21, < 15c3bcc9b5349d40207e5f8d4d799b8b4b7d13b8; >= d38ceaf99ed015f2a0b9af3…
Fixed in: Linux 8189f44270db1be78169e11eec51a3eeb980bc63, Linux 15c3bcc9b5349d40207e5f8d4d799b8b4b7d13b8, Linux 70276460e914d560e96bfc208695a872fe9469c9, Linux 20b947e5a3c74c5084d661c097517a554989d462, Linux 7086a23890d255bb5761604e39174b20d06231a4, Linux 31ab27b14daaa75541a415c6794d6f3567fea44a

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-2022-49335 being exploited?

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

### How serious is CVE-2022-49335?

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

### Which versions are affected by CVE-2022-49335?

Linux \>= d38ceaf99ed015f2a0b9af3499791bd3a3daae21, \< 8189f44270db1be78169e11eec51a3eeb980bc63; \>= d38ceaf99ed015f2a0b9af3499791bd3a3daae21, \< aa25acbe96692e4bf8482311c293f72d8c6034c0; \>= d38ceaf99ed015f2a0b9af3499791bd3a3daae21, \< 15c3bcc9b5349d40207e5f8d4d799b8b4b7d13b8; \>= d38ceaf99ed015f2a0b9af3499791bd3a3daae21, \< c12984cdb077b9042d2dc20ca18cb16a87bcc774; \>= d38ceaf99ed015f2a0b9af3499791bd3a3daae21, \< be585921f29df5422a39c952d188b418ad48ffab; \>= d38ceaf99ed015f2a0b9af3499791bd3a3daae21, \< 70276460e914d560e96bfc208695a872fe9469c9; \>= d38ceaf99ed015f2a0b9af3499791bd3a3daae21, \< 20b947e5a3c74c5084d661c097517a554989d462; \>= d38ceaf99ed015f2a0b9af3499791bd3a3daae21, \< 7086a23890d255bb5761604e39174b20d06231a4; \>= d38ceaf99ed015f2a0b9af3499791bd3a3daae21, \< 31ab27b14daaa75541a415c6794d6f3567fea44a; Linux 4.2.

### Is there a fix for CVE-2022-49335?

Yes. Fixed in Linux 8189f44270db1be78169e11eec51a3eeb980bc63, Linux 15c3bcc9b5349d40207e5f8d4d799b8b4b7d13b8, Linux 70276460e914d560e96bfc208695a872fe9469c9, Linux 20b947e5a3c74c5084d661c097517a554989d462, Linux 7086a23890d255bb5761604e39174b20d06231a4, Linux 31ab27b14daaa75541a415c6794d6f3567fea44a. Upgrade Linux to 31ab27b14daaa75541a415c6794d6f3567fea44a or later.

### How do I check if I'm affected by CVE-2022-49335?

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

- patch: <https://git.kernel.org/stable/c/8189f44270db1be78169e11eec51a3eeb980bc63>
- patch: <https://git.kernel.org/stable/c/aa25acbe96692e4bf8482311c293f72d8c6034c0>
- patch: <https://git.kernel.org/stable/c/15c3bcc9b5349d40207e5f8d4d799b8b4b7d13b8>
- patch: <https://git.kernel.org/stable/c/c12984cdb077b9042d2dc20ca18cb16a87bcc774>
- patch: <https://git.kernel.org/stable/c/be585921f29df5422a39c952d188b418ad48ffab>
- patch: <https://git.kernel.org/stable/c/70276460e914d560e96bfc208695a872fe9469c9>
- patch: <https://git.kernel.org/stable/c/20b947e5a3c74c5084d661c097517a554989d462>
- patch: <https://git.kernel.org/stable/c/7086a23890d255bb5761604e39174b20d06231a4>
- patch: <https://git.kernel.org/stable/c/31ab27b14daaa75541a415c6794d6f3567fea44a>

## 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-2022-49335>

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