CVE-2026-53067: PCI: endpoint: pci-ep-msi: Fix error unwind and prevent double alloc
From: Greg Kroah-Hartman <[email protected]>
Description
===========
In the Linux kernel, the following vulnerability has been resolved:
PCI: endpoint: pci-ep-msi: Fix error unwind and prevent double alloc
pci_epf_alloc_doorbell() stores the allocated doorbell message array in epf->db_msg/epf->num_db before requesting MSI vectors. If MSI allocation fails, the array is freed but the EPF state may still point to freed memory.
Clear epf->db_msg and epf->num_db on the MSI allocation failure path so that later cleanup cannot double-free the array and callers can retry allocation.
Also return -EBUSY when doorbells have already been allocated to prevent leaking or overwriting an existing allocation.
The Linux kernel CVE team has assigned CVE-2026-53067 to this issue.
Affected and fixed versions
===========================
Issue introduced in 6.17 with commit 1c3b002c6bf684b445a7107609979bca5f21bc03 and fixed in 6.18.33 with commit 175717cfc06cab79f84cd037d66dda1b8564cd9e Issue introduced in 6.17 with commit 1c3b002c6bf684b445a7107609979bca5f21bc03 and fixed in 7.0.10 with commit 3c25587fbf8797b92090b064a6d239a873e55fb1 Issue introduced in 6.17 with commit 1c3b002c6bf684b445a7107609979bca5f21bc03 and fixed in 7.1 with commit 1cba96c0a795124c3229293ed7b5b5765e66f259
Please see https://www.kernel.org for a full list of currently supported kernel versions by the kernel community.
Unaffected versions might change over time as fixes are backported to older supported kernel versions. The official CVE entry at
https://cve.org/CVERecord/?id=CVE-2026-53067
will be updated if fixes are backported, please check that for the most up to date information about this issue.
Affected files
==============
The file(s) affected by this issue are:
drivers/pci/endpoint/pci-ep-msi.c
Mitigation
==========
The Linux kernel CVE team recommends that you update to the latest stable kernel version for this, and many other bugfixes. Individual changes are never tested alone, but rather are part of a larger kernel release. Cherry-picking individual commits is not recommended or supported by the Linux kernel community at all. If however, updating to the latest release is impossible, the individual changes to resolve this issue can be found at these commits:
https://git.kernel.org/stable/c/175717cfc06cab79f84cd037d66dda1b8564cd9e https://git.kernel.org/stable/c/3c25587fbf8797b92090b064a6d239a873e55fb1 https://git.kernel.org/stable/c/1cba96c0a795124c3229293ed7b5b5765e66f259