sched_ext, sched/core: Fix build failure when !FAIR_GROUP_SCHED && EXT_GROUP_SCHED
Subsystems (2)
Tejun Heo
reviewerPATCH 1/1 sched_ext, sched/core: Fix build failure when !FAIR_GROUP_SCHED && EXT_GROUP_SCHED
While collecting SCX related fields in struct task_group into struct scx_task_group, 6e6558a6bc41 ("sched_ext, sched/core: Factor out struct scx_task_group") forgot update tg->scx_weight usage in tg_weight(), which leads to build failure when CONFIG_FAIR_GROUP_SCHED is disabled but CONFIG_EXT_GROUP_SCHED is enabled. Fix it.
---
Peter, I'll apply this to sched_ext/for-6.17-fixes and send it Linus' way. Please let me know for any concerns.
Thanks.
kernel/sched/core.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
kernel/sched/core.c +1 -1
@@ -9551,7 +9551,7 @@ static unsigned long tg_weight(struct task_group *tg)#ifdef CONFIG_FAIR_GROUP_SCHED return scale_load_down (tg->shares);#else -return sched_weight_from_cgroup (tg->scx_weight); +return sched_weight_from_cgroup (tg->scx.weight);#endif }
Quoted 9 lines · Tejun Heo
While collecting SCX related fields in struct
task_groupinto structscx_task_group,6e6558a6bc41("sched_ext, sched/core: Factor out structscx_task_group") forgot updatetg->scx_weightusage intg_weight(), which leads to build failure whenCONFIG_FAIR_GROUP_SCHEDis disabled butCONFIG_EXT_GROUP_SCHEDis enabled. Fix it.Fixes 6e6558a6bc41 ("sched_ext, sched/core: Factor out struct scx_task_group")Reported-by kernel test robot <[email protected]>
Missing SoB line? Apart than that LGTM.
Thanks,
-Andrea
Quoted 22 lines
---
Peter, I'll apply this to sched_ext/for-6.17-fixes and send it Linus' way. Please let me know for any concerns.Thanks.
kernel/sched/core.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)kernel/sched/core.c +1
-1@@ -9551,7 +9551,7 @@ static unsigned long tg_weight(struct task_group *tg)#ifdef CONFIG_FAIR_GROUP_SCHED return scale_load_down (tg->shares);#else -return sched_weight_from_cgroup (tg->scx_weight); +return sched_weight_from_cgroup (tg->scx.weight);#endif }
Tejun Heo
reviewerQuoted 7 lines · Andrea Righi
Quoted 6 lines · Tejun Heo
While collecting SCX related fields in struct
task_groupinto structscx_task_group,6e6558a6bc41("sched_ext, sched/core: Factor out structscx_task_group") forgot updatetg->scx_weightusage intg_weight(), which leads to build failure whenCONFIG_FAIR_GROUP_SCHEDis disabled butCONFIG_EXT_GROUP_SCHEDis enabled. Fix it.
Quoted 5 lines
Quoted 3 lines
Fixes 6e6558a6bc41 ("sched_ext, sched/core: Factor out struct scx_task_group")Reported-by kernel test robot <[email protected]>Missing SoB line? Apart than that LGTM.
Oops, yeah.
Quoted 1 line
Tested-by Andrea Righi <[email protected]>
Applied with the tags added.
Thanks.
Signature · 1 line
tejun