CVE-2026-139503: PCI/AER: Fix struct pci_dev reference leak in aer_process_err_devices()

Published Nov 30, 2026
·
Updated

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

PCI/AER: Fix struct pcidev reference leak in aerprocesserrdevices()

When an AER error occurs, candidate error-source devices are added to einfo->dev[] by adderrordevice(), which takes a reference with pcidevget().

A device can be recorded without any error status being present: the Requester ID fast path in iserrorsource(),

if (einfo->id == pcidevid(dev)) return true;

matches purely on the ID reported by the Root Port and returns true without reading the device's AER status registers.

In aerprocesserrdevices(), handleerrorsource() is called only if aergetdeviceerrorinfo() returns non-zero, i.e. only if an unmasked error status bit is actually set. It returns 0 if the device has become inaccessible (status and mask both read as all ones, so status & ~mask == 0) or if no unmasked status bit is set.

Because handleerrorsource() was responsible for calling pcidevput(), skipping it permanently leaks the reference taken in adderrordevice().

Decouple reference lifetime from error handling by moving pcidevput() out of handleerrorsource() and into the aerprocesserrdevices() loop, so every recorded device is put exactly once.

handleerrorsource() is static and aerprocesserrdevices() is its only caller, so no other path is affected.

Affected Software

1 affected component
Linux Linux kernel

Remediation

Recommended actions to resolve this vulnerability, in priority order.

  1. Compensating control

    Move pci_dev_put() out of handle_error_source() and into the aer_process_err_devices() loop so every device recorded by add_error_device() is put exactly once, including when handle_error_source() is skipped.

Event History

Nov 30, 2026
CVE Published
via MITRE·01:35 PM
Data Sourced
via MITRE·01:35 PM
Description

Contact

SecAlerts Pty Ltd.
132 Wickham Terrace
Fortitude Valley,
QLD 4006, Australia
info@secalerts.co
By using SecAlerts services, you agree to our services end-user license agreement. This website is safeguarded by reCAPTCHA and governed by the Google Privacy Policy and Terms of Service. All names, logos, and brands of products are owned by their respective owners, and any usage of these names, logos, and brands for identification purposes only does not imply endorsement. If you possess any content that requires removal, please get in touch with us.
© 2026 SecAlerts Pty Ltd.
ABN: 70 645 966 203, ACN: 645 966 203