[PATCH OLK-6.6] init/Kconfig: Add SMP to the dependencies of QOS_SCHED

From: Xia Fukun <xiafukun@huawei.com> hulk inclusion category: bugfix bugzilla: https://gitee.com/openeuler/kernel/issues/I8MF4R -------------------------------- After CONFIG_SMP is disabled during kernel compilation, CONFIG_QOS_SCHED is not disabled. As a result, the following error occurs: kernel/sched/fair.c: In function ‘check_qos_cfs_rq’: kernel/sched/fair.c:7324:4: error: implicit declaration of function ‘sched_idle_cpu’; did you mean ‘sched_idle_rq’? [-Werror=implicit-function-declaration] 7324 | !sched_idle_cpu(smp_processor_id()) && | ^~~~~~~~~~~~~~ ./include/linux/compiler.h:78:42: note: in definition of macro ‘unlikely’ 78 | # define unlikely(x) __builtin_expect(!!(x), 0) | ^ CC mm/highmem.o kernel/sched/fair.c: In function ‘pick_next_task_fair’: kernel/sched/fair.c:7599:43: error: ‘struct rq’ has no member named ‘online’ 7599 | if (cfs_rq->idle_h_nr_running != 0 && rq->online) | ^~ AR arch/x86/mm/pat/built-in.a CC kernel/sched/stats.o kernel/sched/fair.c:7790:7: error: ‘struct rq’ has no member named ‘idle_stamp’; did you mean ‘idle_state’? 7790 | rq->idle_stamp = 0; | ^~~~~~~~~~ | idle_state This is because the definitions of the corresponding functions and variables depend on the SMP configuration. So add SMP to the dependencies of QOS_SCHED. Fixes: fcf53ace7925 ("sched: Enable qos scheduler config") Signed-off-by: Xia Fukun <xiafukun@huawei.com> Signed-off-by: Wenyu Huang <huangwenyu5@huawei.com> Signed-off-by: Liu Kai <liukai284@huawei.com> --- init/Kconfig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/init/Kconfig b/init/Kconfig index 4c566c4bbfa4..22d9ac8ca08f 100644 --- a/init/Kconfig +++ b/init/Kconfig @@ -1072,12 +1072,12 @@ config QOS_SCHED bool "Qos task scheduling" depends on CGROUP_SCHED depends on CFS_BANDWIDTH + depends on SMP default n help This option enable qos scheduler, and support co-location online services (Latency Sensitive) and offline tasks. colocation can effectively improve the resource utilization. - If in doubt, say N. config QOS_SCHED_SMT_EXPELLER -- 2.34.1

反馈: 您发送到kernel@openeuler.org的补丁/补丁集,已成功转换为PR! PR链接地址: https://gitee.com/openeuler/kernel/pulls/16085 邮件列表地址:https://mailweb.openeuler.org/archives/list/kernel@openeuler.org/message/TVS... FeedBack: The patch(es) which you have sent to kernel@openeuler.org mailing list has been converted to a pull request successfully! Pull request link: https://gitee.com/openeuler/kernel/pulls/16085 Mailing list address: https://mailweb.openeuler.org/archives/list/kernel@openeuler.org/message/TVS...
participants (2)
-
Liu Kai
-
patchwork bot