]> www.infradead.org Git - users/hch/misc.git/commit
cgroup/rstat: Selftests for niced CPU statistics
authorJoshua Hahn <joshua.hahn6@gmail.com>
Wed, 2 Oct 2024 18:47:17 +0000 (11:47 -0700)
committerTejun Heo <tj@kernel.org>
Tue, 8 Oct 2024 18:50:54 +0000 (08:50 -1000)
commit2e82c0d4562a4b8292af83577b70af888a93d16d
tree569659ecd6a406f52721b2a02cb09f13388f4056
parentaefa398d93d5db7c555be78a605ff015357f127d
cgroup/rstat: Selftests for niced CPU statistics

Creates a cgroup with a single nice CPU hog process running.
fork() is called to generate the nice process because un-nicing is
not possible (see man nice(3)). If fork() was not used to generate
the CPU hog, we would run the rest of the cgroup selftest suite as a
nice process.

Signed-off-by: Joshua Hahn <joshua.hahnjy@gmail.com>
Signed-off-by: Tejun Heo <tj@kernel.org>
tools/testing/selftests/cgroup/test_cpu.c