Add a back pointer from scx_sched_pcpu to scx_sched. This will be used by
the next patch to make scx_bpf_reenqueue_local() sub-sched aware.
Signed-off-by: Tejun Heo <tj@kernel.org>
Reviewed-by: Andrea Righi <arighi@nvidia.com>
for_each_possible_cpu(cpu)
init_dsq(bypass_dsq(sch, cpu), SCX_DSQ_BYPASS, sch);
+ for_each_possible_cpu(cpu)
+ per_cpu_ptr(sch->pcpu, cpu)->sch = sch;
+
sch->helper = kthread_run_worker(0, "sched_ext_helper");
if (IS_ERR(sch->helper)) {
ret = PTR_ERR(sch->helper);
s64 SCX_EV_SUB_BYPASS_DISPATCH;
};
+struct scx_sched;
+
enum scx_sched_pcpu_flags {
SCX_SCHED_PCPU_BYPASSING = 1LLU << 0,
};
};
struct scx_sched_pcpu {
+ struct scx_sched *sch;
u64 flags; /* protected by rq lock */
/*