CVE-2026-31475

ASoC: sma1307: fix double free of devm_kzalloc() memory

7.8 high EPSS 0.18%

Published 22 Apr 2026 Updated 5 Aug 2026 CNA: Linux

Check your servers for CVE-2026-31475

The Vulnpocalypse collector sends the package list of each Linux server and of its container images once a day. Vulnpocalypse shows every server where CVE-2026-31475 affects the running kernel, with the command that installs the fix. The free plan covers one server and one domain and does not need a credit card.

Check my servers

Description

In the Linux kernel, the following vulnerability has been resolved:

ASoC: sma1307: fix double free of devm_kzalloc() memory

A previous change added NULL checks and cleanup for allocation failures in sma1307_setting_loaded().

However, the cleanup for mode_set entries is wrong. Those entries are allocated with devm_kzalloc(), so they are device-managed resources and must not be freed with kfree(). Manually freeing them in the error path can lead to a double free when devres later releases the same memory.

Drop the manual kfree() loop and let devres handle the cleanup.

Severity (CVSS)

7.8 high CVSS 3.1 from Linux (CNA)
CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H
Attack vector
local: the attacker needs local access, or a user has to open a prepared file
Attack complexity
low: an attack works without special conditions
Privileges required
low: the attacker needs an ordinary user account
User interaction
none: nobody has to click or open anything
Scope
unchanged: the damage stays inside the vulnerable component
Impact
confidentiality high, integrity high, availability high: what an attacker can read (confidentiality), change (integrity) or stop (availability)

Exploitation

EPSS 0.18%: the probability of exploitation activity in the next 30 days, from the EPSS model of FIRST. The score is higher than 4.45% of all scored CVEs. Scores of 30 Nov 2026.

Affected products

As the CNA lists them.

ProductVersions
Linux
affected from 0ec6bd16705fe21d6429d6b8f7981eae2142bba8, before d472d1a52985211b92883bb64bbe710b45980190
affected from 0ec6bd16705fe21d6429d6b8f7981eae2142bba8, before 1a82c3272626db9006f4c2cad3adf2916417aed6
affected from 0ec6bd16705fe21d6429d6b8f7981eae2142bba8, before fe757092d2329c397ecb32f2bf68a5b1c4bd9193
affected f8434b8ba437d3f6cbcd9ffe8405bd16ed28fc5c
affected from 6.14.9, before 6.15
Other versions: unaffected
Linux
affected 6.15
unaffected before 6.15
unaffected from 6.18.21 up to and including 6.18.*
unaffected from 6.19.11 up to and including 6.19.*
unaffected 7.0 and later
Other versions: affected

Is my server affected?

This CVE is in the Linux kernel. Compare the running kernel with the fixed kernel version of your distribution, and reboot after a kernel update:

uname -r
# Debian, Ubuntu: does the changelog of the running kernel name the CVE?
zgrep -l CVE-2026-31475 /usr/share/doc/linux-image-$(uname -r)/changelog.Debian.gz
# RHEL, Rocky, Alma
rpm -q --changelog kernel | grep CVE-2026-31475

With Trivy, on the host and for a container image. When a package is affected, it prints the installed and the fixed version:

trivy rootfs --scanners vuln / | grep CVE-2026-31475
trivy image --scanners vuln IMAGE | grep CVE-2026-31475

Vulnpocalypse makes this comparison every day for the package lists of your servers and container images, including language packages (npm, PyPI, Go, Maven and others), and sends the command that installs the fix. Start free with one server and one domain or read how to install the collector.

References

Other references

Source: the record CVE-2026-31475 of the CVE List (CVE Program), CVE Terms of Use; EPSS of FIRST. The text of the record is shown as published. Data sources and licences.