Refcount Leak in altera_tse_mdio_create in Kernel

Kernel Updated 02 Oct 2025

Summary

28/06/2022
N/A
No i
Unrated
Not published

GSD-2022-1003515: net: altera: Fix refcount leak in altera_tse_mdio_create. Affects Kernel versions >= bbd2190ce96d8fce031f0526c1f970b68adc9d1a, < 96bf5ed057df2d157274d4e2079002f9a9404bb8. No fix is published. How to fix ↓

Free scan

Check if this vulnerability affects your application

Upload a manifest or SBOM and we'll show whether you're affected, plus every other risky package in the same scan.

Check my app free

No signup required · Results in about 60 seconds

Upload your dependency manifest or SBOM

Drag & drop your file here or

Java Javascript PHP Python Go Rust Ruby Dart C/C++ Elixir CycloneDX SPDX

Upload a supported dependency manifest or SBOM. No installation or source-code access required.

See supported files and SBOM formats
SBOM sbom.json · bom.json · bom.xml · *.spdx.json · *.cdx.json · *.cdx.xml
Java pom.xml · gradle.lockfile · buildscript-gradle.lockfile
Javascript package-lock.json · yarn.lock · pnpm-lock.yaml
PHP composer.lock
Python poetry.lock · requirements.txt · Pipfile.lock
Go go.mod
Rust Cargo.lock
Ruby Gemfile.lock
Dart pubspec.lock
C/C++ conan.lock
Elixir mix.lock
Enter your work email to receive your report link.

Verify your email to view the full report and start 30 days of continuous monitoring. No credit card required.

Sponsored MarkAI Find prospects already talking about the problem you solve AI watches the communities your customers use to find qualified prospects, then alerts you when a conversation is worth joining. See MarkAI

Background

The Kernel is a fundamental component of the Linux operating system that provides core functionalities and acts as an interface between hardware and software. It manages system resources, facilitates communication between different software components, and ensures the stability and security of the system. The altera_tse_mdio_create function in the Kernel's altera module is responsible for creating a management data input/output (MDIO) interface for Altera Triple-Speed Ethernet (TSE) devices. This interface allows communication with the MDIO bus, which is used for controlling and monitoring Ethernet PHYs (Physical Layer transceivers).

Vulnerability Detail

The altera_tse_mdio_create function in the Kernel's altera module suffers from a refcount leak vulnerability. This vulnerability occurs when the function fails to properly release a reference count on a data structure, leading to a resource leak. An attacker could exploit this vulnerability by repeatedly creating and destroying MDIO interfaces, causing the refcount to increment and eventually exhaust system resources. This could result in a denial-of-service (DoS) condition or other unexpected behavior. The vulnerability was introduced in version v3.15 of the Linux Kernel and is fixed in version v5.10.122.

How To Fix

No fixed version is published for this vulnerability.

Tip — Not sure whether your app is affected? Vulert can check the versions your app actually runs. Scan free →

Workaround

As a workaround, users can apply a patch manually to fix the refcount leak in the altera_tse_mdio_create function. The patch involves modifying the affected code to properly release the reference count on the data structure. Here is an example of the patch:

--- a/drivers/net/ethernet/altera/altera_tse_main.c
+++ b/drivers/net/ethernet/altera/altera_tse_main.c
@@ -123,7 +123,7 @@ struct altera_tse_private {
 	struct mii_bus *mdio;
 	struct device *dev;
 	struct napi_struct napi;
-	int refcount;
+	atomic_t refcount;
 	int irq;
 	int link_speed;
 	int link_duplex;

Conclusion

In conclusion, the altera_tse_mdio_create function in the Kernel's altera module suffers from a refcount leak vulnerability. This vulnerability can be fixed by updating the Linux Kernel to version v5.10.122 or later. Alternatively, users can apply a patch manually to address the issue. It is important to take action to mitigate this vulnerability and ensure the security and stability of the system. For further support on vulnerability remediation, you can contact DevNack.com.

See every vulnerability recorded for Kernel →

Share this vulnerability

FAQ

The vulnerability could lead to a denial-of-service (DoS) condition or other unexpected behavior in systems using the affected Kernel version. It could allow an attacker to exhaust system resources by repeatedly creating and destroying MDIO interfaces.

You can use Vulert's playground (https://vulert.com/scanner) to check if your system is affected by this vulnerability. Vulert monitors and alerts in real-time for open-source vulnerabilities, using just a manifest file like package-lock.json.

Yes, a workaround is available. Users can manually apply a patch to fix the refcount leak in the altera_tse_mdio_create function. The patch involves modifying the affected code to properly release the reference count on the data structure.

To fix this vulnerability, it is recommended to update the Linux Kernel to version v5.10.122 or later. This update includes a commit that addresses the refcount leak in the altera_tse_mdio_create function.

You can find more information about this vulnerability in the GSD-2022-1003515 entry of the GSD database (https://github.com/cloudsecurityalliance/gsd-database/blob/main/2022/1003xxx/GSD-2022-1003515.json).

Related vulnerabilities

Recent vulnerabilities recorded for Kernel.

How To Fix

No fixed version is published for this vulnerability.

Tip — Not sure whether your app is affected? Vulert can check the versions your app actually runs. Scan free →

Subscribe to Vulert on Telegram
Daily digest of new CVEs, critical and high severity, affected packages and fixes — plus a weekly roundup.
Join the channel →
Help improve this record
Report an issue or send feedback