# CVE-2022-50036: drm/sun4i: dsi: Prevent underflow when computing packet sizes

- Severity: Medium 5.5 (CVSS:3.1, scored by NVD) `CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H`
- Known to be exploited: not in CISA's catalogue, which lists only what CISA has confirmed
- Likelihood of exploitation in the next 30 days (EPSS): 0.20%, higher than 10% of CVEs (2026-12-01)
- Published: 2025-06-18T11:01:37.844Z
- Modified: 2026-06-17T05:22:36.670Z
- Weaknesses: CWE-191
- Assigned by: Linux

## Description

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

drm/sun4i: dsi: Prevent underflow when computing packet sizes

Currently, the packet overhead is subtracted using unsigned arithmetic.
With a short sync pulse, this could underflow and wrap around to near
the maximal u16 value. Fix this by using signed subtraction. The call to
max() will correctly handle any negative numbers that are produced.

Apply the same fix to the other timings, even though those subtractions
are less likely to underflow.

(As written by CVE List.)

## Affected

- Linux Linux: from 133add5b5ad42b7bb5fcd59d681aef6475d08600 before a1e7908f78f5a7f53f8cd83c7dcdfec974c95f26; from 133add5b5ad42b7bb5fcd59d681aef6475d08600 before 98e28de472ef248352f04f87e29e634ebb0ec240; from 133add5b5ad42b7bb5fcd59d681aef6475d08600 before fb837f5b83461624e525727a8f4add14b201147e; from 133add5b5ad42b7bb5fcd59d681aef6475d08600 before 82a1356a933d8443139f8886f11b63c974a09a67; 4.18 (not affected: before 4.18; from 5.10.138 up to 5.10.*; from 5.15.63 up to 5.15.*; from 5.19.4 up to 5.19.*; from 6.0 up to *)
- linux linux_kernel: from 4.18 before 5.10.138; from 5.11 before 5.15.63; from 5.16 before 5.19.4; 6.0

## References

- <https://git.kernel.org/stable/c/a1e7908f78f5a7f53f8cd83c7dcdfec974c95f26> (patch)
- <https://git.kernel.org/stable/c/98e28de472ef248352f04f87e29e634ebb0ec240> (patch)
- <https://git.kernel.org/stable/c/fb837f5b83461624e525727a8f4add14b201147e> (patch)
- <https://git.kernel.org/stable/c/82a1356a933d8443139f8886f11b63c974a09a67> (patch)

## Sources

- CVE List: [CVE-2022-50036](https://www.cve.org/CVERecord?id=CVE-2022-50036), CVE Terms of Use, modified 2026-05-11
- NVD: [CVE-2022-50036](https://nvd.nist.gov/vuln/detail/CVE-2022-50036), Public domain, modified 2026-06-17

---

Page: https://cve.day/CVE-2022-50036 · Whole record: https://cve.day/CVE-2022-50036.json · Rebuilt by cve.day 2026-11-25T22:58:21.020Z
