# CVE-2025-21820: tty: xilinx_uartps: split sysrq handling

- 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.17%, higher than 5% of CVEs (2026-12-01)
- Published: 2025-02-27T20:04:17.930Z
- Modified: 2026-06-17T08:44:22.597Z
- Weaknesses: CWE-667
- Assigned by: Linux

## Description

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

tty: xilinx_uartps: split sysrq handling

lockdep detects the following circular locking dependency:

CPU 0                      CPU 1
========================== ============================
cdns_uart_isr()            printk()
  uart_port_lock(port)       console_lock()
			     cdns_uart_console_write()
                               if (!port->sysrq)
                                 uart_port_lock(port)
  uart_handle_break()
    port->sysrq = ...
  uart_handle_sysrq_char()
    printk()
      console_lock()

The fixed commit attempts to avoid this situation by only taking the
port lock in cdns_uart_console_write if port->sysrq unset. However, if
(as shown above) cdns_uart_console_write runs before port->sysrq is set,
then it will try to take the port lock anyway. This may result in a
deadlock.

Fix this by splitting sysrq handling into two parts. We use the prepare
helper under the port lock and defer handling until we release the lock.

(As written by CVE List.)

## Affected

- Linux Linux: from 74ea66d4ca061a3cd4c0e924e51b60e924644852 before e22a97700901ba5e8bf8db68056a0d50f9440cae; from 74ea66d4ca061a3cd4c0e924e51b60e924644852 before de5bd24197bd9ee37ec1e379a3d882bbd15c5065; from 74ea66d4ca061a3cd4c0e924e51b60e924644852 before 8ea0e7b3d7b8f2f0fc9db491ff22a0abe120801c; from 74ea66d4ca061a3cd4c0e924e51b60e924644852 before 9b88a7c4584ba67267a051069b8abe44fc9595b2; from 74ea66d4ca061a3cd4c0e924e51b60e924644852 before 4410dba9807a17a93f649a9f5870ceaf30a675a3; from 74ea66d4ca061a3cd4c0e924e51b60e924644852 before b06f388994500297bb91be60ffaf6825ecfd2afe; 4.6 (not affected: before 4.6; from 5.15.179 up to 5.15.*; from 6.1.129 up to 6.1.*; from 6.6.78 up to 6.6.*; from 6.12.14 up to 6.12.*; from 6.13.3 up to 6.13.*; from 6.14 up to *)
- linux linux_kernel: from 4.6 before 6.1.129; from 6.2 before 6.6.78; from 6.7 before 6.12.14; from 6.13 before 6.13.3

## References

- <https://git.kernel.org/stable/c/e22a97700901ba5e8bf8db68056a0d50f9440cae>
- <https://git.kernel.org/stable/c/de5bd24197bd9ee37ec1e379a3d882bbd15c5065> (patch)
- <https://git.kernel.org/stable/c/8ea0e7b3d7b8f2f0fc9db491ff22a0abe120801c> (patch)
- <https://git.kernel.org/stable/c/9b88a7c4584ba67267a051069b8abe44fc9595b2> (patch)
- <https://git.kernel.org/stable/c/4410dba9807a17a93f649a9f5870ceaf30a675a3> (patch)
- <https://git.kernel.org/stable/c/b06f388994500297bb91be60ffaf6825ecfd2afe> (patch)
- <https://lists.debian.org/debian-lts-announce/2025/03/msg00028.html>

## Sources

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

---

Page: https://cve.day/CVE-2025-21820 · Whole record: https://cve.day/CVE-2025-21820.json · Rebuilt by cve.day 2026-11-25T22:58:54.623Z
