Go to file
JP Kobryn 5da3bfa029 cgroup: use separate rstat trees for each subsystem
Different subsystems may call cgroup_rstat_updated() within the same
cgroup, resulting in a tree of pending updates from multiple subsystems.
When one of these subsystems is flushed via cgroup_rstat_flushed(), all
other subsystems with pending updates on the tree will also be flushed.

Change the paradigm of having a single rstat tree for all subsystems to
having separate trees for each subsystem. This separation allows for
subsystems to perform flushes without the side effects of other subsystems.
As an example, flushing the cpu stats will no longer cause the memory stats
to be flushed and vice versa.

In order to achieve subsystem-specific trees, change the tree node type
from cgroup to cgroup_subsys_state pointer. Then remove those pointers from
the cgroup and instead place them on the css. Finally, change update/flush
functions to make use of the different node type (css). These changes allow
a specific subsystem to be associated with an update or flush. Separate
rstat trees will now exist for each unique subsystem.

Since updating/flushing will now be done at the subsystem level, there is
no longer a need to keep track of updated css nodes at the cgroup level.
The list management of these nodes done within the cgroup (rstat_css_list
and related) has been removed accordingly.

Conditional guards for checking validity of a given css were placed within
css_rstat_updated/flush() to prevent undefined behavior occuring from kfunc
usage in bpf programs. Guards were also placed within css_rstat_init/exit()
in order to help consolidate calls to them. At call sites for all four
functions, the existing guards were removed.

Signed-off-by: JP Kobryn <inwardvessel@gmail.com>
Signed-off-by: Tejun Heo <tj@kernel.org>
2025-05-19 10:28:59 -10:00
Documentation Documentation fix for runtime verifier 2025-03-31 09:56:08 -07:00
LICENSES
arch x86: don't re-generate cpufeaturemasks.h so eagerly 2025-03-31 14:19:55 -07:00
block cgroup: change rstat function signatures from cgroup-based to css-based 2025-04-04 10:06:25 -10:00
certs
crypto This update includes the following changes: 2025-03-29 10:01:55 -07:00
drivers Rust changes for v6.15 2025-03-30 17:03:26 -07:00
fs bpf-next-6.15 2025-03-30 12:43:03 -07:00
include cgroup: use separate rstat trees for each subsystem 2025-05-19 10:28:59 -10:00
init [ Merge note: this pull request depends on you having merged 2025-03-24 22:06:11 -07:00
io_uring for-6.15/io_uring-reg-vec-20250327 2025-03-28 15:07:04 -07:00
ipc treewide: const qualify ctl_tables where applicable 2025-01-28 13:48:37 +01:00
kernel cgroup: use separate rstat trees for each subsystem 2025-05-19 10:28:59 -10:00
lib Rust changes for v6.15 2025-03-30 17:03:26 -07:00
mm cgroup: change rstat function signatures from cgroup-based to css-based 2025-04-04 10:06:25 -10:00
net bpf-next-6.15 2025-03-30 12:43:03 -07:00
rust Rust changes for v6.15 2025-03-30 17:03:26 -07:00
samples Rust changes for v6.15 2025-03-30 17:03:26 -07:00
scripts Rust changes for v6.15 2025-03-30 17:03:26 -07:00
security bpf-next-6.15 2025-03-30 12:43:03 -07:00
sound drm for 6.15-rc1 2025-03-28 17:44:52 -07:00
tools cgroup: use separate rstat trees for each subsystem 2025-05-19 10:28:59 -10:00
usr kbuild: hdrcheck: fix cross build with clang 2025-03-05 04:06:45 +09:00
virt ARM: 2025-03-25 14:22:07 -07:00
.clang-format
.clippy.toml rust: give Clippy the minimum supported Rust version 2025-01-10 00:17:25 +01:00
.cocciconfig
.editorconfig
.get_maintainer.ignore
.gitattributes
.gitignore rust: use host dylib naming convention to support macOS 2025-01-10 01:01:24 +01:00
.mailmap drm for 6.15-rc1 2025-03-28 17:44:52 -07:00
.rustfmt.toml
COPYING
CREDITS drm for 6.15-rc1 2025-03-28 17:44:52 -07:00
Kbuild drm: ensure drm headers are self-contained and pass kernel-doc 2025-02-12 10:44:43 +02:00
Kconfig io_uring: Rename KConfig to Kconfig 2025-02-19 14:53:27 -07:00
MAINTAINERS Rust changes for v6.15 2025-03-30 17:03:26 -07:00
Makefile [ Merge note: this pull request depends on you having merged 2025-03-24 22:06:11 -07:00
README

README

Linux kernel
============

There are several guides for kernel developers and users. These guides can
be rendered in a number of formats, like HTML and PDF. Please read
Documentation/admin-guide/README.rst first.

In order to build the documentation, use ``make htmldocs`` or
``make pdfdocs``.  The formatted documentation can also be read online at:

    https://www.kernel.org/doc/html/latest/

There are various text files in the Documentation/ subdirectory,
several of them using the reStructuredText markup notation.

Please read the Documentation/process/changes.rst file, as it contains the
requirements for building and running the kernel, and information about
the problems which may result by upgrading your kernel.