# CVE-2022-50628: drm/gud: Fix UBSAN warning

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

- **Severity:** UNSCORED
- **Exploited in the wild:** Not in CISA KEV
- **Public exploit / PoC:** None known
- **Remote exploitation:** Unknown
- **EPSS:** 0.27% (percentile 13, 2026-11-26)
- **Published:** 2025-12-08T01:16:43.390Z
- **Modified:** 2026-11-11T23:10:00.263Z

## Who should check

- Anyone running Linux \>= 40e1a70b4aedf2859a1829991b48ef0ebe650bf2, \< 832f861a46039d50536dcfda0a9fb334b48d0f8b; \>= 40e1a70b4aedf2859a1829991b48ef0ebe650bf2, \< e1078b270d218f8d58efb4d78ea25a4d16ba3490; \>= 40e1a70b4aedf2859a1829991b48ef0ebe650bf2, \< 951df98024f7272f85df5044eca7374f5b5b24ef
- Anyone running Linux 5.13

## Description

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

drm/gud: Fix UBSAN warning

UBSAN complains about invalid value for bool:

\[  101.165172\] \[drm\] Initialized gud 1.0.0 20200422 for 2-3.2:1.0 on minor 1
\[  101.213360\] gud 2-3.2:1.0: \[drm\] fb1: guddrmfb frame buffer device
\[  101.213426\] usbcore: registered new interface driver gud
\[  101.989431\] ================================================================================
\[  101.989441\] UBSAN: invalid-load in linux/include/linux/iosys-map.h:253:9
\[  101.989447\] load of value 121 is not a valid value for type '\_Bool'
\[  101.989451\] CPU: 1 PID: 455 Comm: kworker/1:6 Not tainted 5.18.0-rc5-gud-5.18-rc5 \#3
\[  101.989456\] Hardware name: Hewlett-Packard HP EliteBook 820 G1/1991, BIOS L71 Ver. 01.44 04/12/2018
\[  101.989459\] Workqueue: events\_long gud\_flush\_work \[gud\]
\[  101.989471\] Call Trace:
\[  101.989474\]  \<TASK\>
\[  101.989479\]  dump\_stack\_lvl+0x49/0x5f
\[  101.989488\]  dump\_stack+0x10/0x12
\[  101.989493\]  ubsan\_epilogue+0x9/0x3b
\[  101.989498\]  \_\_ubsan\_handle\_load\_invalid\_value.cold+0x44/0x49
\[  101.989504\]  dma\_buf\_vmap.cold+0x38/0x3d
\[  101.989511\]  ? find\_busiest\_group+0x48/0x300
\[  101.989520\]  drm\_gem\_shmem\_vmap+0x76/0x1b0 \[drm\_shmem\_helper\]
\[  101.989528\]  drm\_gem\_shmem\_object\_vmap+0x9/0xb \[drm\_shmem\_helper\]
\[  101.989535\]  drm\_gem\_vmap+0x26/0x60 \[drm\]
\[  101.989594\]  drm\_gem\_fb\_vmap+0x47/0x150 \[drm\_kms\_helper\]
\[  101.989630\]  gud\_prep\_flush+0xc1/0x710 \[gud\]
\[  101.989639\]  ? \_raw\_spin\_lock+0x17/0x40
\[  101.989648\]  gud\_flush\_work+0x1e0/0x430 \[gud\]
\[  101.989653\]  ? \_\_switch\_to+0x11d/0x470
\[  101.989664\]  process\_one\_work+0x21f/0x3f0
\[  101.989673\]  worker\_thread+0x200/0x3e0
\[  101.989679\]  ? rescuer\_thread+0x390/0x390
\[  101.989684\]  kthread+0xfd/0x130
\[  101.989690\]  ? kthread\_complete\_and\_exit+0x20/0x20
\[  101.989696\]  ret\_from\_fork+0x22/0x30
\[  101.989706\]  \</TASK\>
\[  101.989708\] ================================================================================

The source of this warning is in iosys\_map\_clear() called from
dma\_buf\_vmap(). It conditionally sets values based on map-\>is\_iomem. The
iosys\_map variables are allocated uninitialized on the stack leading to
-\>is\_iomem having all kinds of values and not only 0/1.

Fix this by zeroing the iosys\_map variables.

## Affected and fixed versions

- Linux: \>= 40e1a70b4aedf2859a1829991b48ef0ebe650bf2, \< 832f861a46039d50536dcfda0a9fb334b48d0f8b; \>= 40e1a70b4aedf2859a1829991b48ef0ebe650bf2, \< e1078b270d218f8d58efb4d78ea25a4d16ba3490; \>= 40e1a70b4aedf2859a1829991b48ef0ebe650bf2, \< 951df98024f7272f85df5044eca7374f5b5b24ef (cvelist)
- Linux: 5.13 (cvelist)

## Mitigation

- Upgrade Linux to 951df98024f7272f85df5044eca7374f5b5b24ef 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-50628. Work read-only: do not install, upgrade, delete or change anything.

Details: https://flawdb.com/CVE-2022-50628.md
Affected: Linux >= 40e1a70b4aedf2859a1829991b48ef0ebe650bf2, < 832f861a46039d50536dcfda0a9fb334b48d0f8b; >= 40e1a70b4aedf2859a1829991b48ef0ebe650bf2, < e1078b270d218f8d58efb4d78ea25a4d16ba3490; >= 40e1a70b4aedf2859a1829991b48ef0ebe650bf2, < 951df98024f7272f85df5044eca7374f5b5b24ef; Linux 5.13
Fixed in: Linux 832f861a46039d50536dcfda0a9fb334b48d0f8b, Linux 951df98024f7272f85df5044eca7374f5b5b24ef

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-50628 being exploited?

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

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

It has no CVSS score yet. Unknown.

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

Linux \>= 40e1a70b4aedf2859a1829991b48ef0ebe650bf2, \< 832f861a46039d50536dcfda0a9fb334b48d0f8b; \>= 40e1a70b4aedf2859a1829991b48ef0ebe650bf2, \< e1078b270d218f8d58efb4d78ea25a4d16ba3490; \>= 40e1a70b4aedf2859a1829991b48ef0ebe650bf2, \< 951df98024f7272f85df5044eca7374f5b5b24ef; Linux 5.13.

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

Yes. Fixed in Linux 832f861a46039d50536dcfda0a9fb334b48d0f8b, Linux 951df98024f7272f85df5044eca7374f5b5b24ef. Upgrade Linux to 951df98024f7272f85df5044eca7374f5b5b24ef or later.

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

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

- other: <https://git.kernel.org/stable/c/832f861a46039d50536dcfda0a9fb334b48d0f8b>
- other: <https://git.kernel.org/stable/c/e1078b270d218f8d58efb4d78ea25a4d16ba3490>
- other: <https://git.kernel.org/stable/c/951df98024f7272f85df5044eca7374f5b5b24ef>

## 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-50628>

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