Vulnerability · Published Apr 16, 2025 · Assigned by Linux

CVE-2025-22031PCI/bwctrl: Fix NULL pointer dereference on bus number exhaustion

Medium 5.5

In plain English

A medium-severity null pointer dereference in Linux from Linux. There are no confirmed reports of exploitation so far. The chance it is exploited in the next 30 days is estimated at 0.3% (higher than 17% of all known vulnerabilities). Fixed versions are available - upgrade the affected package.

Severity (CVSS 3.1)5.5Medium
Exploit odds (30 days)0.3%top 83.1% of all CVEs
Exploited in the wildNo reportsCISA SSVC: none
Attack toolingNoneno public tooling known

Official description

In the Linux kernel, the following vulnerability has been resolved: PCI/bwctrl: Fix NULL pointer dereference on bus number exhaustion When BIOS neglects to assign bus numbers to PCI bridges, the kernel attempts to correct that during PCI device enumeration. If it runs out of bus numbers, no pci_bus is allocated and the "subordinate" pointer in the bridge's pci_dev remains NULL. The PCIe bandwidth controller erroneously does not check for a NULL subordinate pointer and dereferences it on probe. Bandwidth control of unusable devices below the bridge is of questionable utility, so simply error out instead. This mirrors what PCIe hotplug does since commit 62e4492c3063 ("PCI: Prevent NULL dereference during pciehp probe"). The PCI core emits a message with KERN_INFO severity if it has run out of bus numbers. PCIe hotplug emits an additional message with KERN_ERR severity to inform the user that hotplug functionality is disabled at the bridge. A similar message for bandwidth control does not seem merited, given that its only purpose so far is to expose an up-to-date link speed in sysfs and throttle the link speed on certain laptops with limited Thermal Design Power. So error out silently. User-visible messages: pci 0000:16:02.0: bridge configuration invalid ([bus 00-00]), reconfiguring [...] pci_bus 0000:45: busn_res: [bus 45-74] end is updated to 74 pci 0000:16:02.0: devices behind bridge are unusable because [bus 45-74] cannot be assigned for them [...] pcieport 0000:16:02.0: pciehp: Hotplug bridge without secondary bus, ignoring [...] BUG: kernel NULL pointer dereference RIP: pcie_update_link_speed pcie_bwnotif_enable pcie_bwnotif_probe pcie_port_probe_service really_probe

Affected packages & fixed versions

EcosystemPackageFixed inAdvisory
Debian:13linuxno fix listedDEBIAN-CVE-2025-22031
Debian:14linux6.16.3-1DEBIAN-CVE-2025-22031
Ubuntu:22.04:LTSlinux-allwinner-5.19no fix listedUBUNTU-CVE-2025-22031
Ubuntu:22.04:LTSlinux-aws-5.19no fix listedUBUNTU-CVE-2025-22031
Ubuntu:22.04:LTSlinux-aws-6.2no fix listedUBUNTU-CVE-2025-22031
Ubuntu:22.04:LTSlinux-aws-6.5no fix listedUBUNTU-CVE-2025-22031
Ubuntu:22.04:LTSlinux-azure-5.19no fix listedUBUNTU-CVE-2025-22031
Ubuntu:22.04:LTSlinux-azure-6.2no fix listedUBUNTU-CVE-2025-22031
Ubuntu:22.04:LTSlinux-azure-6.5no fix listedUBUNTU-CVE-2025-22031
Ubuntu:25.10linux-azure-fdeno fix listedUBUNTU-CVE-2025-22031
Ubuntu:22.04:LTSlinux-azure-fde-5.19no fix listedUBUNTU-CVE-2025-22031
Ubuntu:22.04:LTSlinux-azure-fde-6.2no fix listedUBUNTU-CVE-2025-22031
Ubuntu:22.04:LTSlinux-gcp-5.19no fix listedUBUNTU-CVE-2025-22031
Ubuntu:22.04:LTSlinux-gcp-6.2no fix listedUBUNTU-CVE-2025-22031
Ubuntu:22.04:LTSlinux-gcp-6.5no fix listedUBUNTU-CVE-2025-22031
Ubuntu:22.04:LTSlinux-hwe-5.19no fix listedUBUNTU-CVE-2025-22031
Ubuntu:22.04:LTSlinux-hwe-6.2no fix listedUBUNTU-CVE-2025-22031
Ubuntu:22.04:LTSlinux-hwe-6.5no fix listedUBUNTU-CVE-2025-22031
Ubuntu:22.04:LTSlinux-intel-iot-realtimeno fix listedUBUNTU-CVE-2025-22031
Ubuntu:22.04:LTSlinux-lowlatency-hwe-5.19no fix listedUBUNTU-CVE-2025-22031
Ubuntu:22.04:LTSlinux-lowlatency-hwe-6.2no fix listedUBUNTU-CVE-2025-22031
Ubuntu:22.04:LTSlinux-lowlatency-hwe-6.5no fix listedUBUNTU-CVE-2025-22031
Ubuntu:22.04:LTSlinux-nvidia-6.2no fix listedUBUNTU-CVE-2025-22031
Ubuntu:22.04:LTSlinux-nvidia-6.5no fix listedUBUNTU-CVE-2025-22031
Ubuntu:22.04:LTSlinux-oem-5.17no fix listedUBUNTU-CVE-2025-22031
Ubuntu:22.04:LTSlinux-oem-6.0no fix listedUBUNTU-CVE-2025-22031
Ubuntu:22.04:LTSlinux-oem-6.1no fix listedUBUNTU-CVE-2025-22031
Ubuntu:22.04:LTSlinux-oem-6.5no fix listedUBUNTU-CVE-2025-22031
Ubuntu:22.04:LTSlinux-oracle-6.5no fix listedUBUNTU-CVE-2025-22031
Ubuntu:24.04:LTSlinux-raspi-realtimeno fix listedUBUNTU-CVE-2025-22031
Ubuntu:22.04:LTSlinux-realtimeno fix listedUBUNTU-CVE-2025-22031
Ubuntu:24.04:LTSlinux-realtimeno fix listedUBUNTU-CVE-2025-22031
Ubuntu:22.04:LTSlinux-riscvno fix listedUBUNTU-CVE-2025-22031
Ubuntu:22.04:LTSlinux-riscv-5.19no fix listedUBUNTU-CVE-2025-22031
Ubuntu:22.04:LTSlinux-riscv-6.5no fix listedUBUNTU-CVE-2025-22031
Ubuntu:22.04:LTSlinux-starfive-5.19no fix listedUBUNTU-CVE-2025-22031
Ubuntu:22.04:LTSlinux-starfive-6.2no fix listedUBUNTU-CVE-2025-22031
Ubuntu:22.04:LTSlinux-starfive-6.5no fix listedUBUNTU-CVE-2025-22031

Affected products (as reported)

VendorProductVersions
Linux Linux 665745f274870c921020f610e2c99a3b1613519b – before d93d309013e89631630a12b1770d27e4be78362a665745f274870c921020f610e2c99a3b1613519b – before 1181924af78e5299ddec6e457789c02dd5966559665745f274870c921020f610e2c99a3b1613519b – before 667f053b05f00a007738cd7ed6fa1901de19dc7e
Linux Linux 6.13

Weakness: CWE-476 · Vector: CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H

References