regmap: set debugfs_name to NULL after it is freed

Kernel Updated 02 Oct 2025

Summary

31/05/2021
N/A
No i
Unrated
Not published

GSD-2021-1000437: regmap: set debugfs_name to NULL after it is freed. Affects Kernel versions >= 480c5e9c7e4c76c01d5f1f7b73832d7b77e6b427, < d8897f7b2283a500666c85ef06e820df38ed7b52. 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 Devnack Your last release was probably never penetration tested Manual testing by engineers who build software, not an auditor's checklist. Trusted by teams at Swift and Google Talk to Devnack

Background

The regmap package is a component of the Linux Kernel ecosystem. It provides a framework for accessing and manipulating hardware registers in a device-independent manner. The package allows drivers to read from and write to hardware registers using a common API. The debugfs_name variable is used to store the name of the debugfs entry associated with a regmap instance. Debugfs is a virtual file system in Linux that allows developers to add debugging information to their code. The vulnerability in regmap arises from not setting the debugfs_name variable to NULL after it is freed, which can lead to a use-after-free vulnerability.

Vulnerability Detail

The vulnerability in regmap occurs when the debugfs_name variable is not properly handled. After the debugfs_name variable is freed, it is not set to NULL, leaving a dangling pointer. An attacker could potentially exploit this vulnerability by manipulating the freed debugfs_name pointer to execute arbitrary code or cause a denial-of-service condition. The impact and attack plausibility of this vulnerability have not been proven yet. The vulnerability was introduced in Linux Kernel version v5.4.90 and fixed in version v5.4.119.

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 →

Conclusion

The regmap package in the Linux Kernel is vulnerable to a use-after-free vulnerability when the debugfs_name variable is not properly handled. To fix this vulnerability, developers should set the debugfs_name variable to NULL after it is freed. It is recommended to update to the fixed version of the regmap package (v5.4.119 or later) to ensure the vulnerability is patched. For further support on vulnerability remediation, please contact DevNack.com.

See every vulnerability recorded for Kernel →

Share this vulnerability

FAQ

Regmap is a component of the Linux Kernel ecosystem that provides a framework for accessing and manipulating hardware registers in a device-independent manner.

Debugfs is a virtual file system in Linux that allows developers to add debugging information to their code.

A use-after-free vulnerability occurs when a program continues to use a memory reference after it has been freed, leading to potential security issues.

An attacker could potentially exploit this vulnerability by manipulating the freed debugfs_name pointer to execute arbitrary code or cause a denial-of-service condition.

The impact and attack plausibility of this vulnerability have not been proven yet.

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