# CVE-2025-39915: net: phy: transfer phy\_config\_inband() locking responsibility to phylink

> 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.15% (percentile 2, 2026-11-28)
- **CWE:** CWE-667
- **Published:** 2025-10-01T07:44:37.884Z
- **Modified:** 2026-10-19T21:10:00.160Z

## Who should check

- Anyone running Linux \>= 5fd0f1a02e750e2db4038dee60edea669ce5aab1, \< 052ac41c379c8b87629808be612a482b2d0ae283; \>= 5fd0f1a02e750e2db4038dee60edea669ce5aab1, \< e2a10daba84968f6b5777d150985fd7d6abc9c84
- Anyone running Linux 6.14

## Description

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

net: phy: transfer phy\_config\_inband() locking responsibility to phylink

Problem description
===================

Lockdep reports a possible circular locking dependency (AB/BA) between
&pl-\>state\_mutex and &phy-\>lock, as follows.

phylink\_resolve() // acquires &pl-\>state\_mutex
-\> phylink\_major\_config()
   -\> phy\_config\_inband() // acquires &pl-\>phydev-\>lock

whereas all the other call sites where &pl-\>state\_mutex and
&pl-\>phydev-\>lock have the locking scheme reversed. Everywhere else,
&pl-\>phydev-\>lock is acquired at the top level, and &pl-\>state\_mutex at
the lower level. A clear example is phylink\_bringup\_phy().

The outlier is the newly introduced phy\_config\_inband() and the existing
lock order is the correct one. To understand why it cannot be the other
way around, it is sufficient to consider phylink\_phy\_change(), phylink's
callback from the PHY device's phy-\>phy\_link\_change() virtual method,
invoked by the PHY state machine.

phy\_link\_up() and phy\_link\_down(), the (indirect) callers of
phylink\_phy\_change(), are called with &phydev-\>lock acquired.
Then phylink\_phy\_change() acquires its own &pl-\>state\_mutex, to
serialize changes made to its pl-\>phy\_state and pl-\>link\_config.
So all other instances of &pl-\>state\_mutex and &phydev-\>lock must be
consistent with this order.

Problem impact
==============

I think the kernel runs a serious deadlock risk if an existing
phylink\_resolve() thread, which results in a phy\_config\_inband() call,
is concurrent with a phy\_link\_up() or phy\_link\_down() call, which will
deadlock on &pl-\>state\_mutex in phylink\_phy\_change(). Practically
speaking, the impact may be limited by the slow speed of the medium
auto-negotiation protocol, which makes it unlikely for the current state
to still be unresolved when a new one is detected, but I think the
problem is there. Nonetheless, the problem was discovered using lockdep.

Proposed solution
=================

Practically speaking, the phy\_config\_inband() requirement of having
phydev-\>lock acquired must transfer to the caller (phylink is the only
caller). There, it must bubble up until immediately before
&pl-\>state\_mutex is acquired, for the cases where that takes place.

Solution details, considerations, notes
=======================================

This is the phy\_config\_inband() call graph:

                          sfp\_upstream\_ops :: connect\_phy()
                          \|
                          v
                          phylink\_sfp\_connect\_phy()
                          \|
                          v
                          phylink\_sfp\_config\_phy()
                          \|
                          \|   sfp\_upstream\_ops :: module\_insert()
                          \|   \|
                          \|   v
                          \|   phylink\_sfp\_module\_insert()
                          \|   \|
                          \|   \|   sfp\_upstream\_ops :: module\_start()
                          \|   \|   \|
                          \|   \|   v
                          \|   \|   phylink\_sfp\_module\_start()
                          \|   \|   \|
                          \|   v   v
                          \|   phylink\_sfp\_config\_optical()
 phylink\_start()          \|   \|
   \|   phylink\_resume()   v   v
   \|   \|  phylink\_sfp\_set\_config()
   \|   \|  \|
   v   v  v
 phylink\_mac\_initial\_config()
   \|   phylink\_resolve()
   \|   \|  phylink\_ethtool\_ksettings\_set()
   v   v  v
   phylink\_major\_config()
            \|
            v
    phy\_config\_inband()

phylink\_major\_config() caller \#1, phylink\_mac\_initial\_config(), does not
acquire &pl-\>state\_mutex nor do its callers. It must acquire
&pl-\>phydev-\>lock prior to calling phylink\_major\_config().

phylink\_major\_config() caller \#2, phylink\_resolve() acquires
&pl-\>state\_mutex, thus also needs to acquire &pl-\>phydev-\>lock.

phylink\_major\_config() caller \#3, phylink\_ethtool\_ksettings\_set(), is
completely uninteresting, because it only call
---truncated---

## Affected and fixed versions

- Linux: \>= 5fd0f1a02e750e2db4038dee60edea669ce5aab1, \< 052ac41c379c8b87629808be612a482b2d0ae283; \>= 5fd0f1a02e750e2db4038dee60edea669ce5aab1, \< e2a10daba84968f6b5777d150985fd7d6abc9c84 (cvelist)
- Linux: 6.14 (cvelist)

## Mitigation

- No fix listed yet: follow the vendor advisory.

## Check your systems with an agent

Paste this into a coding agent:

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

Details: https://flawdb.com/CVE-2025-39915.md
Affected: Linux >= 5fd0f1a02e750e2db4038dee60edea669ce5aab1, < 052ac41c379c8b87629808be612a482b2d0ae283; >= 5fd0f1a02e750e2db4038dee60edea669ce5aab1, < e2a10daba84968f6b5777d150985fd7d6abc9c84; Linux 6.14
Fixed in: Linux 052ac41c379c8b87629808be612a482b2d0ae283

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-2025-39915 being exploited?

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

### How serious is CVE-2025-39915?

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

### Which versions are affected by CVE-2025-39915?

Linux \>= 5fd0f1a02e750e2db4038dee60edea669ce5aab1, \< 052ac41c379c8b87629808be612a482b2d0ae283; \>= 5fd0f1a02e750e2db4038dee60edea669ce5aab1, \< e2a10daba84968f6b5777d150985fd7d6abc9c84; Linux 6.14.

### Is there a fix for CVE-2025-39915?

Yes. Fixed in Linux 052ac41c379c8b87629808be612a482b2d0ae283. No fix listed yet: follow the vendor advisory.

### How do I check if I'm affected by CVE-2025-39915?

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/052ac41c379c8b87629808be612a482b2d0ae283>
- patch: <https://git.kernel.org/stable/c/e2a10daba84968f6b5777d150985fd7d6abc9c84>

## 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-2025-39915>

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