# CVE-2025-40347: net: enetc: fix the deadlock of enetc_mdio_lock

- Severity: High 7.5 (CVSS:3.1, scored by Linux) `CVSS:3.1/AV:N/AC:L/PR:N/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.57%, higher than 48% of CVEs (2026-12-01)
- Published: 2025-12-16T13:30:21.539Z
- Modified: 2026-10-14T13:10:00.187Z
- Assigned by: Linux

## Description

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

net: enetc: fix the deadlock of enetc_mdio_lock

After applying the workaround for err050089, the LS1028A platform
experiences RCU stalls on RT kernel. This issue is caused by the
recursive acquisition of the read lock enetc_mdio_lock. Here list some
of the call stacks identified under the enetc_poll path that may lead to
a deadlock:

enetc_poll
  -> enetc_lock_mdio
  -> enetc_clean_rx_ring OR napi_complete_done
     -> napi_gro_receive
        -> enetc_start_xmit
           -> enetc_lock_mdio
           -> enetc_map_tx_buffs
           -> enetc_unlock_mdio
  -> enetc_unlock_mdio

After enetc_poll acquires the read lock, a higher-priority writer attempts
to acquire the lock, causing preemption. The writer detects that a
read lock is already held and is scheduled out. However, readers under
enetc_poll cannot acquire the read lock again because a writer is already
waiting, leading to a thread hang.

Currently, the deadlock is avoided by adjusting enetc_lock_mdio to prevent
recursive lock acquisition.

(As written by CVE List.)

## Affected

- Linux Linux: from 6d36ecdbc4410e61a0e02adc5d3abeee22a8ffd3 before a649161526736f48bcc592e3a412e5bcd7dd9e24; from 6d36ecdbc4410e61a0e02adc5d3abeee22a8ffd3 before 2781ca82ce8cad263d80b617addb727e6a84c9e5; from 6d36ecdbc4410e61a0e02adc5d3abeee22a8ffd3 before 1f92f5bd057a4fad9dab6af17963cdd21e5da6ed; from 6d36ecdbc4410e61a0e02adc5d3abeee22a8ffd3 before 2e55a49dc3b2a6b23329e4fbbd8a5feb20e220aa; from 6d36ecdbc4410e61a0e02adc5d3abeee22a8ffd3 before 50bd33f6b3922a6b760aa30d409cae891cec8fb5; bf9c564716a13dde6a990d3b02c27cd6e39608bf; ff966263f5f9fdf9740f03fed0762ce73c230a6a; from 5.10.24 before 5.11; from 5.11.7 before 5.12; 5.12 (not affected: before 5.12; from 6.1.175 up to 6.1.*; from 6.6.115 up to 6.6.*; from 6.12.56 up to 6.12.*; from 6.17.6 up to 6.17.*; from 6.18 up to *)

## References

- <https://git.kernel.org/stable/c/a649161526736f48bcc592e3a412e5bcd7dd9e24>
- <https://git.kernel.org/stable/c/2781ca82ce8cad263d80b617addb727e6a84c9e5>
- <https://git.kernel.org/stable/c/1f92f5bd057a4fad9dab6af17963cdd21e5da6ed>
- <https://git.kernel.org/stable/c/2e55a49dc3b2a6b23329e4fbbd8a5feb20e220aa>
- <https://git.kernel.org/stable/c/50bd33f6b3922a6b760aa30d409cae891cec8fb5>

## Sources

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

---

Page: https://cve.day/CVE-2025-40347 · Whole record: https://cve.day/CVE-2025-40347.json · Rebuilt by cve.day 2026-11-25T22:59:09.468Z
