Commit 7e92cf43 authored by Tejun Heo's avatar Tejun Heo
Browse files

sched_ext: Fix sub_detach op check to test the parent's ops



sub_detach is the parent's op called to notify the parent that a child
is detaching. Test parent->ops.sub_detach instead of sch->ops.sub_detach.

Fixes: ebeca1f9 ("sched_ext: Introduce cgroup sub-sched support")
Signed-off-by: default avatarTejun Heo <tj@kernel.org>
Reviewed-by: default avatarAndrea Righi <arighi@nvidia.com>
parent 98059335
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -5438,7 +5438,7 @@ static void scx_sub_disable(struct scx_sched *sch)
	 */
	wake_up_all(&scx_unlink_waitq);

	if (sch->ops.sub_detach && sch->sub_attached) {
	if (parent->ops.sub_detach && sch->sub_attached) {
		struct scx_sub_detach_args sub_detach_args = {
			.ops = &sch->ops,
			.cgroup_path = sch->cgrp_path,