Re: [PATCH] doc: Add CPU Isolation documentation

From: Waiman Long

Date: Tue Mar 24 2026 - 12:05:27 EST


On 3/24/26 11:38 AM, Sebastian Andrzej Siewior wrote:
On 2025-08-09 11:42:47 [+0200], Frederic Weisbecker wrote:

--- /dev/null
+++ b/Documentation/admin-guide/cpu-isolation.rst
@@ -0,0 +1,338 @@

+CPUSET configuration (cgroup v2)
+--------------------------------
+
+Assuming cgroup v2 is mounted to /sys/fs/cgroup, the following script
+isolates CPU 7 from scheduler domains.
+
+ cd /sys/fs/cgroup
+ # Activate the cpuset subsystem
+ echo +cpuset > cgroup.subtree_control
+ # Create partition to be isolated
+ mkdir test
+ cd test
+ echo +cpuset > cgroup.subtree_control
+ # Isolate CPU 7
+ echo 7 > cpuset.cpus
+ echo "isolated" > cpuset.cpus.partition
while looking at this again, shouldn't you also do
echo 7 > cpuset.cpus.exclusive

to ensure the CPU isn't used somewhere else?

For backport compatibility, the use of cpuset.cpus.exclusive is optional for creating a local partition underneath the cgroup root. The example should still work without setting cpuset.cpus.exclusive.

Cheers,
Longman