CVE-2026-139460

In the Linux kernel, the following vulnerability has been resolved: PCI/P2PDMA: Do not tear down the allocate attribute on registration failure pci_p2pdma_add_resource() installs pci_p2pdma_unmap_mappings() as a devres action with the devres allocated p2p_pgmap as its data, and only then adds the range to the pool: error = devm_add_action_or_reset(&pdev->dev, pci_p2pdma_unmap_mappings, p2p_pgmap); if (error) goto pages_free; p2pdma = rcu_dereference_protected(pdev->p2pdma, 1); error = gen_pool_add_owner(p2pdma->pool, ...); if (error) goto pages_free; The action removes the allocate attribute for the whole device, which tears down existing userspace mappings of every BAR already registered on it. Both failures here get that wrong, in opposite ways. devm_add_action_or_reset() runs the action when it cannot allocate its devres node, so an -ENOMEM while registering a second BAR unmaps the first one. Use devm_add_action() and let the error path unwind only what this call created. gen_pool_add_owner() allocates a chunk and can also fail with -ENOMEM. There the action is registered, and the error path frees p2p_pgmap with devm_kfree() while leaving the action pointing at it. On unbind devres runs the action and pci_p2pdma_unmap_mappings() dereferences p2p_pgmap->mem->owner->kobj, which is freed memory. Give that failure its own label and drop the action with devm_remove_action(), which removes it without running it.

Package Linux Kernel
Published 2026-11-30
Last modified 2026-12-06
Patch available
Yes

Affected versions

Linux kernel versions 6.2 and later are affected. Fixed in 6.12.120, 6.18.65, 7.3.6, 7.4-rc1 and their respective stable series.

Affected from
≥ 6.2
Fixed in
✓ 6.12.120 6.12.x ✓ 6.18.65 6.18.x ✓ 7.3.6 7.3.x ✓ 7.4-rc1

Frequently asked questions

  • What is CVE-2026-139460?

    CVE-2026-139460 is a unscored severity Linux kernel vulnerability . It affects Linux kernel versions from 6.2 onward and has been patched in 6.12.120, 6.18.65, 7.3.6 and others. CVE-2026-139460 has not been confirmed as actively exploited and is not listed in the CISA KEV catalog.

  • Is there a patch available for CVE-2026-139460?

    Yes. CVE-2026-139460 has been patched. Fixed versions include 6.12.120, 6.18.65, 7.3.6 and others. If you are running Linux kernel 6.2 or later up to the fix versions, apply the relevant patch for your kernel branch.

  • Is CVE-2026-139460 actively exploited?

    No. CVE-2026-139460 has not been confirmed as actively exploited. It is not listed in the CISA Known Exploited Vulnerabilities (KEV) catalog.