CVE-2026-98971
gpio: exar: initialize the ID before registering its cleanup
Fetching some sources has been requested. Reload in about a minute to see them.
Description
In the Linux kernel, the following vulnerability has been resolved: gpio: exar: initialize the ID before registering its cleanup devm_add_action_or_reset() invokes the cleanup action immediately when registering the action fails. gpio_exar_probe() currently stores the allocated ID in exar_gpio only after registering the action, so that failure makes exar_devm_ida_free() release ID 0. If the allocated ID is nonzero, this leaks that ID and can free ID 0 belonging to another device. Store the ID before registering the cleanup action so both the immediate failure path and normal device teardown release the correct allocation.
Affected products and packages
CNA (CVE.org)
| Vendor | Product | Versions |
|---|---|---|
| Linux | Linux | affected: 5300ebb695fa0672589ab191062392f686fca75d … < bf3d841ef12fcbec4458e2750956b738b043a226 affected: 5300ebb695fa0672589ab191062392f686fca75d … < b78c114600ae3df90c083c72c290437b068577c8 affected: 5300ebb695fa0672589ab191062392f686fca75d … < 01318927a9055136c207399eeb36ce07becac179 affected: 5300ebb695fa0672589ab191062392f686fca75d … < f7ec4dbd2a073dd53b6349be1c586fe8580dd6b2 affected: 5300ebb695fa0672589ab191062392f686fca75d … < 4d69e74034b208588636ecc177e0dd43a7696af3 default: unaffected |
| Linux | Linux | affected: 5.11 unaffected: 0 … < 5.11 unaffected: 6.6.160 … <= 6.6.* unaffected: 6.12.113 … <= 6.12.* unaffected: 6.18.57 … <= 6.18.* unaffected: 7.2.11 … <= 7.2.* unaffected: 7.3 … <= * default: affected |
Open-source packages (GitHub Advisory / OSV)
gpio: exar: initialize the ID before registering its cleanup
| Ecosystem | Package | Affected versions | Fixed in |
|---|---|---|---|
| >= 5300ebb695fa0672589ab191062392f686fca75d, < bf3d841ef12fcbec4458e2750956b738b043a226; < b78c114600ae3df90c083c72c290437b068577c8; < 01318927a9055136c207399eeb36ce07becac179; < f7ec4dbd2a073dd53b6349be1c586fe8580dd6b2; < 4d69e74034b208588636ecc177e0dd43a7696af3 | bf3d841ef12fcbec4458e2750956b738b043a226, b78c114600ae3df90c083c72c290437b068577c8, 01318927a9055136c207399eeb36ce07becac179, f7ec4dbd2a073dd53b6349be1c586fe8580dd6b2, 4d69e74034b208588636ecc177e0dd43a7696af3 | ||
| Linux | Kernel | >= 5.11.0, < 6.6.160; >= 6.7.0, < 6.12.113; >= 6.13.0, < 6.18.57; >= 6.19.0, < 7.2.11 | 6.6.160, 6.12.113, 6.18.57, 7.2.11 |
Linux distribution status
References (8)
- https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git OSV
- https://git.kernel.org/stable/c/01318927a9055136c207399eeb36ce07becac179 NVD, CNA, OSV
- https://git.kernel.org/stable/c/4d69e74034b208588636ecc177e0dd43a7696af3 NVD, CNA, OSV
- https://git.kernel.org/stable/c/b78c114600ae3df90c083c72c290437b068577c8 NVD, CNA, OSV
- https://git.kernel.org/stable/c/bf3d841ef12fcbec4458e2750956b738b043a226 NVD, CNA, OSV
- https://git.kernel.org/stable/c/f7ec4dbd2a073dd53b6349be1c586fe8580dd6b2 NVD, CNA, OSV
- https://github.com/CVEProject/cvelistV5/tree/main/cves/2026/98xxx/CVE-2026-98971.json OSV
- https://nvd.nist.gov/vuln/detail/CVE-2026-98971 OSV