CVE-2025-23140 misc: pci_endpoint_test: Avoid issue of interrupts remaining after request_irq error

Medium 5.5 Published Updated

A Linux kernel bug in the PCI endpoint test driver causes a warning and potential resource leak when IRQ request fails, leading to denial of service.

Exploited in the wild
Not known
Login needed
Any signed-in user
Attackable
Local or same network only
Victim action needed
Not needed
Fix
Available

What is CVE-2025-23140?

CVE-2025-23140 is a medium-severity denial of service vulnerability in Debian Debian Linux, published on 1 May 2025. It can only be exploited from the same machine or local network, with no action from the victim.

Official description

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

misc: pci_endpoint_test: Avoid issue of interrupts remaining after request_irq error

After devm_request_irq() fails with error in pci_endpoint_test_request_irq(), the pci_endpoint_test_free_irq_vectors() is called assuming that all IRQs have been released.

However, some requested IRQs remain unreleased, so there are still /proc/irq/* entries remaining, and this results in WARN() with the following message:

remove_proc_entry: removing non-empty directory 'irq/30', leaking at least 'pci-endpoint-test.0' WARNING: CPU: 0 PID: 202 at fs/proc/generic.c:719 remove_proc_entry +0x190/0x19c

To solve this issue, set the number of remaining IRQs to test->num_irqs, and release IRQs in advance by calling pci_endpoint_test_release_irq().

[kwilczynski: commit log]

Which versions are affected by CVE-2025-23140?

It affects 2 products.

Products include Debian Debian Linux, Linux kernel.

How do I fix CVE-2025-23140?

Apply the vendor's patch.

Upgrade, then put limits on request size, rate and nesting depth so one client cannot exhaust the service. More about Denial of service.

Is CVE-2025-23140 being exploited?

There is no known exploitation of CVE-2025-23140 in the wild and no public exploit code.

All Debian Debian Linux vulnerabilities

Sources

Also known as BELL-CVE-2025-23140, DEBIAN-CVE-2025-23140, GHSA-vvgj-gr7g-xwww, ROOT-OS-DEBIAN-12-CVE-2025-23140, ROOT-OS-UBUNTU-2204-CVE-2025-23140, ROOT-OS-UBUNTU-2404-CVE-2025-23140 and 1 more.

Is CVE-2025-23140 in your software?

Upload an SBOM and sbomify checks it against every vulnerability here, every day.

Check your SBOMs for free