diff options
| author | Cheng-Yang Chou <yphbchou0911@gmail.com> | 2026-03-23 23:17:33 +0800 |
|---|---|---|
| committer | Tejun Heo <tj@kernel.org> | 2026-03-23 07:45:08 -1000 |
| commit | cb251eae7b0aec8a7924fb27bcb5b0388a3706bc (patch) | |
| tree | 40d9ee858c3007a7707034f1ab746f307c6becd1 /tools/perf/scripts/python/stackcollapse.py | |
| parent | c50dcf533149e313a61d483769eb48682a1b0cdd (diff) | |
tools/sched_ext: Add scx_bpf_sub_dispatch() compat wrapper
Add a transparent compatibility wrapper for the scx_bpf_sub_dispatch()
kfunc in compat.bpf.h. This allows BPF schedulers using the sub-sched
dispatch feature to build and run on older kernels that lack the kfunc.
To avoid requiring code changes in individual schedulers, the
transparent wrapper pattern is used instead of a __COMPAT prefix. The
kfunc is declared with a ___compat suffix, while the static inline
wrapper retains the original scx_bpf_sub_dispatch() name.
When the kfunc is unavailable, the wrapper safely falls back to
returning false. This is acceptable because the dispatch path cannot
do anything useful without underlying sub-sched support anyway.
Tested scx_qmap on v6.14 successfully.
Signed-off-by: Cheng-Yang Chou <yphbchou0911@gmail.com>
Signed-off-by: Tejun Heo <tj@kernel.org>
Diffstat (limited to 'tools/perf/scripts/python/stackcollapse.py')
0 files changed, 0 insertions, 0 deletions
