sched/fair: Fix se_is_idle() for !FAIR_GROUP_SCHED
PATCH 1/1 sched/fair: Fix se_is_idle() for !FAIR_GROUP_SCHED
se_is_idle() unconditionally returns 0 for !FAIR_GROUP_SCHED.
Check whether the task is SCHED_IDLE instead so buddies aren't set for such tasks, as was the behavior before 304000390f88.
--- kernel/sched/fair.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
kernel/sched/fair.c +1 -1
@@ -497,7 +497,7 @@ static int cfs_rq_is_idle(struct cfs_rq *cfs_rq)static int se_is_idle (struct sched_entity *se) { -return 0 ; +return task_has_idle_policy (task_of (se)); }#endif /* CONFIG_FAIR_GROUP_SCHED */
base-commit: ac08b1c68d1b1ed3cebb218fc3ea2c07484eb07d
Signature · 1 line
2.32.0
Quoted 8 lines · Daniel Jordan
se_is_idle()unconditionally returns 0 for !FAIR_GROUP_SCHED.Check whether the task is
SCHED_IDLEinstead so buddies aren't set for such tasks, as was the behavior before304000390f88.Fixes 304000390f88 ("sched: Cgroup SCHED_IDLE support")Signed-off-by Daniel Jordan <[email protected]>
Thanks!
Quoted 22 lines
--- kernel/sched/fair.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)kernel/sched/fair.c +1
-1@@ -497,7 +497,7 @@ static int cfs_rq_is_idle(struct cfs_rq *cfs_rq)static int se_is_idle (struct sched_entity *se) { -return 0 ; +return task_has_idle_policy (task_of (se)); }#endif /* CONFIG_FAIR_GROUP_SCHED */ base-commit:
ac08b1c68d1b1ed3cebb218fc3ea2c07484eb07d--
2.32.0
Quoted 8 lines · Daniel Jordan
se_is_idle()unconditionally returns 0 for !FAIR_GROUP_SCHED.Check whether the task is
SCHED_IDLEinstead so buddies aren't set for such tasks, as was the behavior before304000390f88.Fixes 304000390f88 ("sched: Cgroup SCHED_IDLE support")Signed-off-by Daniel Jordan <[email protected]>
Quoted 22 lines
--- kernel/sched/fair.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)kernel/sched/fair.c +1
-1@@ -497,7 +497,7 @@ static int cfs_rq_is_idle(struct cfs_rq *cfs_rq)static int se_is_idle (struct sched_entity *se) { -return 0 ; +return task_has_idle_policy (task_of (se)); }#endif /* CONFIG_FAIR_GROUP_SCHED */ base-commit:
ac08b1c68d1b1ed3cebb218fc3ea2c07484eb07d--
2.32.0