Linux kernel resource leak in CPSW port registration failures
Linux
Affected versions
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
|
Linux
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
|
≥ ed3525eda4c4983fb8509e488de0a351788041ba · < 0a44945b0d3422f5d81b49c97e293f3e21a8c585| No fix yet |
| Linux Linux |
|
|
In the Linux kernel, the following vulnerability has been resolved:
net: cpsw_new: unregister devlink on port registration failure
cpsw_probe() registers devlink before registering the CPSW ports.
If cpsw_register_ports() fails, the error path only unregisters the notifiers and then releases the lower level resources. It does not undo the successful cpsw_register_devlink() call, leaving the devlink instance and its parameters registered after probe has failed.
Add a devlink cleanup label for the path where devlink registration has already succeeded, and use it when port registration fails.
From the CVE record · Linux
The Linux kernel’s cpsw_new driver can leave a devlink instance and its parameters registered if CPSW port registration fails during probe. The input does not describe an attacker action, access requirements, or user interaction.
Engineers running Linux kernels with the cpsw_new driver should check their kernel; affected versions are not specified.