Hi,
Dhaval poked me that he (and others) didn't like the weight interface we
currently have for task groups. I concurr and dusted off these old patches.
--
* Peter Zijlstra <[email protected]> wrote:
> Hi,
>
> Dhaval poked me that he (and others) didn't like the weight interface
> we currently have for task groups. I concurr and dusted off these old
> patches.
applied to tip/sched/core, thanks Peter!
Ingo
> applied to tip/sched/core, thanks Peter!
>
Also needs this to build,
sched: Fix compile errors introduced by new group scheduler interface
commit e642daa433a5ea1599965576dcea70dcc0a36608 introduces
kernel/sched.c: In function ‘cpu_nice_write’:
kernel/sched.c:8505: error: implicit declaration of function ‘sched_group_set_nice’
kernel/sched.c:8505: error: implicit declaration of function ‘cgroup_tg’
kernel/sched.c: In function ‘cpu_nice_read’:
kernel/sched.c:8510: error: implicit declaration of function ‘sched_group_nice’
kernel/sched.c: At top level:
kernel/sched.c:8822: error: static declaration of ‘sched_group_set_nice’ follows non-static declaration
kernel/sched.c:8505: error: previous implicit declaration of ‘sched_group_set_nice’ was here
kernel/sched.c:8833: error: static declaration of ‘sched_group_nice’ follows non-static declaration
kernel/sched.c:8510: error: previous implicit declaration of ‘sched_group_nice’ was here
kernel/sched.c:9103: error: conflicting types for ‘cgroup_tg’
kernel/sched.c:8505: error: previous implicit declaration of ‘cgroup_tg’ was here
make[1]: *** [kernel/sched.o] Error 1
make: *** [kernel/sched.o] Error 2
Fix those.
Signed-off-by: Dhaval Giani <[email protected]>
---
kernel/sched.c | 20 +++++++++++---------
1 file changed, 11 insertions(+), 9 deletions(-)
Index: linux-2.6/kernel/sched.c
===================================================================
--- linux-2.6.orig/kernel/sched.c 2008-12-12 16:18:54.000000000 +0530
+++ linux-2.6/kernel/sched.c 2008-12-12 16:21:36.000000000 +0530
@@ -8499,16 +8499,7 @@ static inline void unregister_fair_sched
list_del_rcu(&tg->cfs_rq[cpu]->leaf_cfs_rq_list);
}
-static int cpu_nice_write(struct cgroup *cgrp, struct cftype *cftype,
- s64 niceval)
-{
- return sched_group_set_nice(cgroup_tg(cgrp), niceval);
-}
-static s64 cpu_nice_read(struct cgroup *cgrp, struct cftype *cftype)
-{
- return sched_group_nice(cgroup_tg(cgrp));
-}
#else /* !CONFG_FAIR_GROUP_SCHED */
static inline void free_fair_sched_group(struct task_group *tg)
{
@@ -9169,6 +9160,17 @@ static u64 cpu_weight_read_u64(struct cg
return (u64) tg->weight;
}
+
+static int cpu_nice_write(struct cgroup *cgrp, struct cftype *cftype,
+ s64 niceval)
+{
+ return sched_group_set_nice(cgroup_tg(cgrp), niceval);
+}
+
+static s64 cpu_nice_read(struct cgroup *cgrp, struct cftype *cftype)
+{
+ return sched_group_nice(cgroup_tg(cgrp));
+}
#endif /* CONFIG_FAIR_GROUP_SCHED */
#ifdef CONFIG_RT_GROUP_SCHED
--
regards,
Dhaval
On Wed, Dec 10, 2008 at 08:40:48PM +0100, Peter Zijlstra wrote:
> Hi,
>
> Dhaval poked me that he (and others) didn't like the weight interface we
> currently have for task groups. I concurr and dusted off these old patches.
>
/me wonders what happened to these patches?
>
> --
--
regards,
Dhaval