Skip to content
Heist/ feed
Back to feed
UnratedFix available

power: supply: goldfish: Fix use-after-free in power_supply_changed()

Type: advisorySources: OSV

In the Linux kernel, the following vulnerability has been resolved: power: supply: goldfish: Fix use-after-free in power_supply_changed() Using the `devm_` variant for requesting IRQ _before_ the `devm_` variant for allocating/registering the `power_supply` handle, means that the `power_supply` handle will be deallocated/unregistered _before_ the interrupt handler (since `devm_` naturally deallocates in reverse allocation order). This means that during removal, there is a race condition where an interrupt can fire just _after_ the `power_supply` handle has been freed, *but* just _before_ the corresponding unregistration of the IRQ handler has run. This will lead to the IRQ handler calling `power_supply_changed()` with a freed `power_supply` handle. Which usually crashes the system or otherwise silently corrupts the memory... Note that there is a similar situation which can also happen during `probe()`; the possibility of an interrupt firing _before_ registering the `power_supply` handle. This would then lead to the nasty situation of using the `power_supply` handle *uninitialized* in `power_supply_changed()`. Fix this racy use-after-free by making sure the IRQ is requested _after_ the registration of the `power_supply` handle.

Products
Kernel
Affected versions
Not specified
Fixed versions
5.10.252, 5.15.202, 6.1.165, 6.12.75, 6.18.14, 6.19.4, 6.6.128
CVEs
CVE-2026-45936
Confirmed fixed CVEs
Not specified
Updated in this feed
7 Nov 2026, 11:26 UTC · Revision 1

Source evidence

power: supply: goldfish: Fix use-after-free in power_supply_changed()

core-osv · Original source

Published 27 May 2026, 12:17 UTC

In the Linux kernel, the following vulnerability has been resolved: power: supply: goldfish: Fix use-after-free in power_supply_changed() Using the `devm_` variant for requesting IRQ _before_ the `devm_` variant for allocating/registering the `power_supply` handle, means that the `power_supply` handle will be deallocated/unregistered _before_ the interrupt handler (since `devm_` naturally deallocates in reverse allocation order). This means that during removal, there is a race condition where an interrupt can fire just _after_ the `power_supply` handle has been freed, *but* just _before_ the corresponding unregistration of the IRQ handler has run. This will lead to the IRQ handler calling `power_supply_changed()` with a freed `power_supply` handle. Which usually crashes the system or otherwise silently corrupts the memory... Note that there is a similar situation which can also happen during `probe()`; the possibility of an interrupt firing _before_ registering the `power_supply` handle. This would then lead to the nasty situation of using the `power_supply` handle *uninitialized* in `power_supply_changed()`. Fix this racy use-after-free by making sure the IRQ is requested _after_ the registration of the `power_supply` handle.

osv:CVE-2026-45936

Kernel

Fixed versions: 5.10.252, 5.15.202, 6.1.165, 6.6.128, 6.12.75, 6.18.14, 6.19.4

Complete source record
{
  "id": "21ae5f519bc0aa2521e19b30502f4912df418d1b70371b1aef6ad8e161c8fe42",
  "url": "https://osv.dev/vulnerability/CVE-2026-45936",
  "method": "structured",
  "payload": {
    "kind": "advisory",
    "title": "power: supply: goldfish: Fix use-after-free in power_supply_changed()",
    "summary": "In the Linux kernel, the following vulnerability has been resolved: power: supply: goldfish: Fix use-after-free in power_supply_changed() Using the `devm_` variant for requesting IRQ _before_ the `devm_` variant for allocating/registering the `power_supply` handle, means that the `power_supply` handle will be deallocated/unregistered _before_ the interrupt handler (since `devm_` naturally deallocates in reverse allocation order). This means that during removal, there is a race condition where an interrupt can fire just _after_ the `power_supply` handle has been freed, *but* just _before_ the corresponding unregistration of the IRQ handler has run. This will lead to the IRQ handler calling `power_supply_changed()` with a freed `power_supply` handle. Which usually crashes the system or otherwise silently corrupts the memory... Note that there is a similar situation which can also happen during `probe()`; the possibility of an interrupt firing _before_ registering the `power_supply` handle. This would then lead to the nasty situation of using the `power_supply` handle *uninitialized* in `power_supply_changed()`. Fix this racy use-after-free by making sure the IRQ is requested _after_ the registration of the `power_supply` handle.",
    "evidence": "osv:CVE-2026-45936",
    "products": [
      {
        "name": {
          "value": "Kernel",
          "evidence": "/affected/1/package/name"
        },
        "prerequisites": [],
        "fixed_versions": [
          {
            "value": "5.10.252",
            "evidence": "/affected/1/ranges"
          },
          {
            "value": "5.15.202",
            "evidence": "/affected/1/ranges"
          },
          {
            "value": "6.1.165",
            "evidence": "/affected/1/ranges"
          },
          {
            "value": "6.6.128",
            "evidence": "/affected/1/ranges"
          },
          {
            "value": "6.12.75",
            "evidence": "/affected/1/ranges"
          },
          {
            "value": "6.18.14",
            "evidence": "/affected/1/ranges"
          },
          {
            "value": "6.19.4",
            "evidence": "/affected/1/ranges"
          }
        ],
        "affected_versions": []
      }
    ],
    "severity": "unknown",
    "structured": {
      "id": "CVE-2026-45936",
      "aliases": [
        "CVE-2026-45936"
      ],
      "affected": [
        {
          "ranges": [
            {
              "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
              "type": "GIT",
              "events": [
                {
                  "introduced": "84d7b768748943db2bb658b43931fdab04c224cc"
                },
                {
                  "fixed": "589d4fe56713c6344cd9f8939f9c7621c85f0966"
                },
                {
                  "fixed": "bad8b61eb5059acd88349680e47839342dc89e94"
                },
                {
                  "fixed": "33751e28842bf5aee5ef7b2b8d5e456a069095cb"
                },
                {
                  "fixed": "77ea437faa4c06362e3ecfd2d7264eaa7ac1e82c"
                },
                {
                  "fixed": "4350505e82b4f972ddb788e1c712c557c38859d0"
                },
                {
                  "fixed": "8c89aade8335e26a6a7dcda18992d15f51943927"
                },
                {
                  "fixed": "0b29ffe4090a3fc7a7649de20e1eb1e53adddac7"
                },
                {
                  "fixed": "b2ce982e2e0c888dc55c888ad0e20ea04daf2e6b"
                }
              ]
            }
          ],
          "database_specific": {
            "source": "https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2026-45936.json"
          }
        },
        {
          "ranges": [
            {
              "type": "ECOSYSTEM",
              "events": [
                {
                  "introduced": "3.9.0"
                },
                {
                  "fixed": "5.10.252"
                }
              ]
            },
            {
              "type": "ECOSYSTEM",
              "events": [
                {
                  "introduced": "5.11.0"
                },
                {
                  "fixed": "5.15.202"
                }
              ]
            },
            {
              "type": "ECOSYSTEM",
              "events": [
                {
                  "introduced": "5.16.0"
                },
                {
                  "fixed": "6.1.165"
                }
              ]
            },
            {
              "type": "ECOSYSTEM",
              "events": [
                {
                  "introduced": "6.2.0"
                },
                {
                  "fixed": "6.6.128"
                }
              ]
            },
            {
              "type": "ECOSYSTEM",
              "events": [
                {
                  "introduced": "6.7.0"
                },
                {
                  "fixed": "6.12.75"
                }
              ]
            },
            {
              "type": "ECOSYSTEM",
              "events": [
                {
                  "introduced": "6.13.0"
                },
                {
                  "fixed": "6.18.14"
                }
              ]
            },
            {
              "type": "ECOSYSTEM",
              "events": [
                {
                  "introduced": "6.19.0"
                },
                {
                  "fixed": "6.19.4"
                }
              ]
            }
          ],
          "package": {
            "name": "Kernel",
            "ecosystem": "Linux"
          },
          "database_specific": {
            "source": "https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2026-45936.json"
          }
        }
      ],
      "modified": "2026-10-28T02:30:50.894976710Z",
      "provider": "osv",
      "references": [
        "https://git.kernel.org/stable/c/0b29ffe4090a3fc7a7649de20e1eb1e53adddac7",
        "https://git.kernel.org/stable/c/33751e28842bf5aee5ef7b2b8d5e456a069095cb",
        "https://git.kernel.org/stable/c/4350505e82b4f972ddb788e1c712c557c38859d0",
        "https://git.kernel.org/stable/c/589d4fe56713c6344cd9f8939f9c7621c85f0966",
        "https://git.kernel.org/stable/c/77ea437faa4c06362e3ecfd2d7264eaa7ac1e82c",
        "https://git.kernel.org/stable/c/8c89aade8335e26a6a7dcda18992d15f51943927",
        "https://git.kernel.org/stable/c/b2ce982e2e0c888dc55c888ad0e20ea04daf2e6b",
        "https://git.kernel.org/stable/c/bad8b61eb5059acd88349680e47839342dc89e94",
        "https://github.com/CVEProject/cvelistV5/tree/main/cves/2026/45xxx/CVE-2026-45936.json",
        "https://nvd.nist.gov/vuln/detail/CVE-2026-45936",
        "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git"
      ],
      "provider_metadata": {
        "cna_assigner": "Linux",
        "osv_generated_from": "https://github.com/CVEProject/cvelistV5/tree/main/cves/2026/45xxx/CVE-2026-45936.json"
      }
    },
    "related_cves": [
      {
        "value": "CVE-2026-45936",
        "evidence": "/id"
      }
    ],
    "security_relevant": true,
    "severity_evidence": null
  },
  "source_id": "core-osv",
  "document_id": 519131,
  "published_at": "2026-05-27T12:17:53.451+00:00"
}