CVE-2025-39805 Details
Description
In the Linux kernel, the following vulnerability has been resolved: net: macb: fix unregister_netdev call order in macb_remove() When removing a macb device, the driver calls phy_exit() before unregister_netdev(). This leads to a WARN from kernfs: ------------[ cut here ]------------ kernfs: can not remove 'attached_dev', no directory WARNING: CPU: 1 PID: 27146 at fs/kernfs/dir.c:1683 Call trace: kernfs_remove_by_name_ns+0xd8/0xf0 sysfs_remove_link+0x24/0x58 phy_detach+0x5c/0x168 phy_disconnect+0x4c/0x70 phylink_disconnect_phy+0x6c/0xc0 [phylink] macb_close+0x6c/0x170 [macb] ... macb_remove+0x60/0x168 [macb] platform_remove+0x5c/0x80 ... The warning happens because the PHY is being exited while the netdev is still registered. The correct order is to unregister the netdev before shutting down the PHY and cleaning up the MDIO bus. Fix this by moving unregister_netdev() ahead of phy_exit() in macb_remove().
A vulnerability exists in the Linux kernel's handling of MACB (Media Access Controller Bus) devices, specifically in the device removal process. The issue arises because the driver calls 'phy_exit()' to detach the physical layer before 'unregister_netdev()', which leads to a warning from the kernel's filesystem. This warning indicates that the system cannot remove a linked directory because the network device is still registered. The improper order of operations causes the physical layer to be disconnected while the network device is active, disrupting the expected cleanup process. The vulnerability affects the Linux kernel stable tree.
The vulnerability has been addressed by modifying the MACB device removal process to ensure that 'unregister_netdev()' is called before 'phy_exit()'. Users should update to the latest version of the Linux kernel where this fix has been applied.
Metrics
CVSS 4.0 Severity and Vector Strings:
No CVSS 4.0 data is available for this CVE.
CVSS 3.x Severity and Vector Strings:
No data available for CVSS Version 2.0 on this CVE.
No SSVC data is available for this CVE.
References to Advisories, Solutions, and Tools
By selecting these links, you will be leaving this site. These are references gathered from the official CVE record and are not endorsed by Volerion.
Weakness Enumeration
| CWE-ID | CWE Name | Source |
|---|---|---|
| NVD-CWE-noinfo | Insufficient Information to Classify Weakness | [email protected] |
Affected Products
| Product | Versions |
|---|---|
| linux linux kernel | >= 5.18, < 6.12.45 >= 6.13, < 6.16.5 6.17 rc1 6.17 rc2 6.17 rc3 |
CPE
Remediation
| |
Change History
5 change records found show changes
| Date | Action | Recorded By |
|---|---|---|
| Oct 19, 2026 | CVE Translated | [email protected] |
| Jun 17, 2026 | CVE Modified | kernel.org |
| Dec 6, 2025 | CVE Modified | kernel.org |
| Dec 2, 2025 | Initial Analysis | [email protected] |
| Sep 16, 2025 | New CVE Received | kernel.org |