CVE-2025-39941

Source
https://cve.org/CVERecord?id=CVE-2025-39941
Import Source
https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2025-39941.json
JSON Data
https://api.osv.dev/v1/vulns/CVE-2025-39941
Downstream
Published
2025-10-04T07:31:04.080Z
Modified
2026-07-31T03:48:22.883055638Z
Severity
  • 7.8 (High) CVSS_V3 - CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H CVSS Calculator
Summary
zram: fix slot write race condition
Details

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

zram: fix slot write race condition

Parallel concurrent writes to the same zram index result in leaked zsmalloc handles. Schematically we can have something like this:

CPU0 CPU1 zramslotlock() zsfree(handle) zramslotlock() zramslotlock() zsfree(handle) zramslotlock()

compress compress handle = zsmalloc() handle = zsmalloc() zramslotlock zramsethandle(handle) zramslotlock zramslotlock zramsethandle(handle) zramslotlock

Either CPU0 or CPU1 zsmalloc handle will leak because zs_free() is done too early. In fact, we need to reset zram entry right before we set its new handle, all under the same slot lock scope.

Database specific
{
    "osv_generated_from": "https://github.com/CVEProject/cvelistV5/tree/main/cves/2025/39xxx/CVE-2025-39941.json",
    "cna_assigner": "Linux"
}
References

Affected packages

Git / git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git

Affected ranges

Type
GIT
Repo
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
Events
Introduced
71268035f5d734ad6373d953298bd5779985497a
Fixed
ff750e9f2c4d63854c33967d1646b5e89a9a19a2
Fixed
ce4be9e4307c5a60701ff6e0cafa74caffdc54ce

Database specific

source
"https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2025-39941.json"

Linux / Kernel

Package

Name
Kernel

Affected ranges

Type
ECOSYSTEM
Events
Introduced
6.14.0
Fixed
6.16.9

Database specific

source
"https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2025-39941.json"