Files
linux/kernel
Tejun Heo f31e89a8f5 sched_ext: Add cmask mask ops
Sub-sched cap code and other upcoming consumers need bulk cmask ops, both
mutating (and/or/copy/andnot) and predicate (subset/intersects/empty).

cmask_walk_op2() walks the intersection of two ranges word by word;
cmask_walk_op1() walks one range. Both are __always_inline and dispatched on
a compile-time-constant op enum, so each public entry collapses to a
specialized loop with the inner switch reduced to one arm.

Two-cmask ops only touch bits in the intersection of the two ranges; bits
outside are left unchanged. scx_cmask_or_racy() and scx_cmask_copy_racy()
mirror the locking forms but read @src word-by-word through data_race();
callers handle ordering with concurrent writers themselves.

v2: Add scx_cmask_empty().

Signed-off-by: Tejun Heo <tj@kernel.org>
Reviewed-by: Andrea Righi <arighi@nvidia.com>
2026-05-20 21:14:46 -10:00
..
2026-05-20 21:14:46 -10:00
2026-03-06 14:31:26 +01:00
2026-03-06 14:31:26 +01:00
2026-03-05 22:16:08 -05:00
2026-03-06 14:31:26 +01:00
2026-01-05 16:43:34 +01:00
2026-03-11 23:14:02 +01:00
2026-03-27 10:19:08 -05:00
2025-10-29 10:29:54 +01:00
2026-01-26 19:07:13 -08:00