CVE-2026-31745
JSON

7.8high

reset: gpio: fix double free in reset_add_gpio_aux_device() error path

Severity
7.8high CVSS:3.1 by NVD
Exploit likelihood
0.13% (higher than 2% of CVEs; EPSS, by FIRST)
Published
Last changed
Assigned by
Linux

Description

In the Linux kernel, the following vulnerability has been resolved: reset: gpio: fix double free in reset_add_gpio_aux_device() error path When __auxiliary_device_add() fails, reset_add_gpio_aux_device() calls auxiliary_device_uninit(adev). The device release callback reset_gpio_aux_device_release() frees adev, but the current error path then calls kfree(adev) again, causing a double free. Keep kfree(adev) for the auxiliary_device_init() failure path, but avoid freeing adev after auxiliary_device_uninit().

Affected

Product or packageVersionsReported by
Linux Linuxfrom 5fc4e4cf7a2268b5f73700fd1e8d02159f2417d8 before 1de465753220deb41569cf2add87bbb0673731db, from 5fc4e4cf7a2268b5f73700fd1e8d02159f2417d8 before fbffb8c7c7bb4d38e9f65e0bee446685011de5d8, 6.19
Not affected: before 6.19, from 6.19.12 up to 6.19.*, from 7.0 up to *
CVE List
linux linux_kernelfrom 6.19 before 6.19.12, 7.0NVD

Classification

What each source says

CVE List

In the Linux kernel, the following vulnerability has been resolved: reset: gpio: fix double free in reset_add_gpio_aux_device() error path When __auxiliary_device_add() fails, reset_add_gpio_aux_device() calls auxiliary_device_uninit(adev). The device release callback reset_gpio_aux_device_release() frees adev, but the current error path then calls kfree(adev) again, causing a double free. Keep kfree(adev) for the auxiliary_device_init() failure path, but avoid freeing adev after auxiliary_device_uninit().

NVD (es)

En el kernel de Linux, la siguiente vulnerabilidad ha sido resuelta: reset: gpio: corregir doble liberación en la ruta de error de reset_add_gpio_aux_device() Cuando __auxiliary_device_add() falla, reset_add_gpio_aux_device() llama a auxiliary_device_uninit(adev). La función de devolución de llamada de liberación del dispositivo reset_gpio_aux_device_release() libera adev, pero la ruta de error actual luego llama a kfree(adev) de nuevo, causando una doble liberación. Mantener kfree(adev) para la ruta de fallo de auxiliary_device_init(), pero evitar liberar adev después de auxiliary_device_uninit().

References

Sources

SourceRecordLicence
CVE ListCVE-2026-31745 changed 2026-05-11CVE Terms of Use
NVDCVE-2026-31745 changed 2026-11-11Public domain