summaryrefslogtreecommitdiff
path: root/rust/helpers/cpu.c
diff options
context:
space:
mode:
authorChristian Loehle <christian.loehle@arm.com>2025-09-03 22:23:10 +0100
committerTejun Heo <tj@kernel.org>2025-09-03 11:50:42 -1000
commit20b158094a1adc9bbfdcc41780059b5cd8866ad8 (patch)
tree201ca03b9e522392ad624488d33496b1a22b61cb /rust/helpers/cpu.c
parente0ca169638be12a0a861e3439e6117c58972cd08 (diff)
sched_ext: Introduce scx_bpf_cpu_curr()
Provide scx_bpf_cpu_curr() as a way for scx schedulers to check the curr task of a remote rq without assuming its lock is held. Many scx schedulers make use of scx_bpf_cpu_rq() to check a remote curr (e.g. to see if it should be preempted). This is problematic because scx_bpf_cpu_rq() provides access to all fields of struct rq, most of which aren't safe to use without holding the associated rq lock. Signed-off-by: Christian Loehle <christian.loehle@arm.com> Acked-by: Andrea Righi <arighi@nvidia.com> Signed-off-by: Tejun Heo <tj@kernel.org>
Diffstat (limited to 'rust/helpers/cpu.c')
0 files changed, 0 insertions, 0 deletions