diff options
| author | 2026-04-10 07:54:06 -1000 | |
|---|---|---|
| committer | 2026-04-10 07:54:06 -1000 | |
| commit | 9b5501d3c95924198914f3df920faae1594e68d5 (patch) | |
| tree | db801c136f8fe4a65f33cf071db3f6ec289350f1 /include/linux/bcma/ssh:/git@git.zx2c4.com | |
| parent | selftests/sched_ext: Fix wrong DSQ ID in peek_dsq error message (diff) | |
sched_ext: Drop TRACING access to select_cpu kfuncs
The select_cpu kfuncs - scx_bpf_select_cpu_dfl(), scx_bpf_select_cpu_and()
and __scx_bpf_select_cpu_and() - take task_rq_lock() internally. Exposing
them via scx_kfunc_set_idle to BPF_PROG_TYPE_TRACING is unsafe: arbitrary
tracing contexts (kprobes, tracepoints, fentry, LSM) may run with @p's
pi_lock state unknown.
Move them out of scx_kfunc_ids_idle into a new scx_kfunc_ids_select_cpu
set registered only for STRUCT_OPS and SYSCALL.
Extracted from a larger verifier-time kfunc context filter patch
originally written by Juntong Deng.
Original-patch-by: Juntong Deng <juntong.deng@outlook.com>
Cc: Cheng-Yang Chou <yphbchou0911@gmail.com>
Signed-off-by: Tejun Heo <tj@kernel.org>
Reviewed-by: Andrea Righi <arighi@nvidia.com>
Diffstat (limited to 'include/linux/bcma/ssh:/git@git.zx2c4.com')
0 files changed, 0 insertions, 0 deletions
