Skip to contentSkip to conversation

CVE-2026-93795: blk-cgroup: fix leaks and online flag on radix_tree_insert failure

DISCUSSION Greg Kroah-Hartman 1 participant 1 message Sep 24

lore
Share & tools
lore
#0 lore raw

From: Greg Kroah-Hartman <[email protected]>

Description
===========

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

blk-cgroup: fix leaks and online flag on radix_tree_insert failure

When radix_tree_insert() fails in blkg_create(), the error path has two issues:

1. blkg->online is set to true unconditionally, even when the blkg was never fully inserted. Move the assignment inside the success block.

2. The error path calls blkg_put() without first calling percpu_ref_kill(). Because the refcount is still in percpu mode, percpu_ref_put() only does this_cpu_sub() without checking for zero, so blkg_release() is never triggered. This permanently leaks the blkg memory, its percpu iostat, policy data, the parent blkg reference, and the cgroup css reference — the latter preventing the cgroup from ever being destroyed.

Fix by replacing blkg_put() with percpu_ref_kill(), matching the pattern used in blkg_destroy().

The Linux kernel CVE team has assigned CVE-2026-93795 to this issue.

Affected and fixed versions
===========================

	Fixed in 6.12.111 with commit 6e85f02d45b5977c0326a8d854c6db878aa6b34a
	Fixed in 6.18.53 with commit 4c0d150fb98ea40760611979f4e664c244b20966
	Fixed in 7.2 with commit dbbca20764382b4d411ec2918f4e278ffe547acc

Please see https://www.kernel.org for a full list of currently supported kernel versions by the kernel community.

Unaffected versions might change over time as fixes are backported to older supported kernel versions. The official CVE entry at

	https://cve.org/CVERecord/?id=CVE-2026-93795

will be updated if fixes are backported, please check that for the most up to date information about this issue.

Affected files
==============

The file(s) affected by this issue are:
block/blk-cgroup.c

Mitigation
==========

The Linux kernel CVE team recommends that you update to the latest stable kernel version for this, and many other bugfixes. Individual changes are never tested alone, but rather are part of a larger kernel release. Cherry-picking individual commits is not recommended or supported by the Linux kernel community at all. If however, updating to the latest release is impossible, the individual changes to resolve this issue can be found at these commits:

	https://git.kernel.org/stable/c/6e85f02d45b5977c0326a8d854c6db878aa6b34a
	https://git.kernel.org/stable/c/4c0d150fb98ea40760611979f4e664c244b20966
	https://git.kernel.org/stable/c/dbbca20764382b4d411ec2918f4e278ffe547acc