diff options
| author | Tejun Heo <tj@kernel.org> | 2026-05-22 07:06:01 -1000 |
|---|---|---|
| committer | Tejun Heo <tj@kernel.org> | 2026-05-25 09:44:07 -1000 |
| commit | abdc2516f100d8f9e637a49e4fdfd2d09a318680 (patch) | |
| tree | 65641f72ea7535bdabddb600bdea3b8fee8d7a79 /include | |
| parent | 9eca087deb0b35f3170109a9630a6c5c06c2e222 (diff) | |
sched_ext: Convert ops.set_cmask() to arena-resident cmask
ops_cid.set_cmask() expects a cmask. The kernel couldn't write into the
arena, so it translated cpumask -> cmask in kernel memory and passed the
result as a trusted pointer. The BPF cmask helpers all operate on arena
cmasks though, so the BPF side had to word-by-word probe-read the kernel
cmask into an arena cmask via cmask_copy_from_kernel() before any helper
could touch it. It works, but is clumsy.
With direct kernel-side arena access now in place, build the cmask in the
arena. The kernel writes to it through the kern_va side of the dual mapping.
BPF directly dereferences it via an __arena pointer like any other arena
struct.
Signed-off-by: Tejun Heo <tj@kernel.org>
Reviewed-by: Emil Tsalapatis <emil@etsalapatis.com>
Diffstat (limited to 'include')
0 files changed, 0 insertions, 0 deletions
