pinctrl: pinconf-generic: Fix memory leak in pinconf_generic_parse_dt_config()
Linux
Affected versions
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
| No fix yet |
| Linux Linux |
|
|
Linux
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
| No fix yet |
| Linux Linux |
|
|
In the Linux kernel, the following vulnerability has been resolved:
pinctrl: pinconf-generic: Fix memory leak in pinconf_generic_parse_dt_config()
In pinconf_generic_parse_dt_config(), if parse_dt_cfg() fails, it returns directly. This bypasses the cleanup logic and results in a memory leak of the cfg buffer.
Fix this by jumping to the out label on failure, ensuring kfree(cfg) is called before returning.
From the CVE record · Linux
The Linux kernel leaks a cfg buffer if parse_dt_cfg() fails in pinconf_generic_parse_dt_config(), because the failure path skips cleanup. The input does not establish how an attacker could trigger this failure or whether network access, authentication, or user interaction is required.
Engineers running the Linux kernel should check their versions; affected versions are not specified.