Re: [Patch 4/4] sched: Improve fairness of cpu bandwidthallocation for task groups
From: Ingo Molnar
Date: Mon Nov 26 2007 - 15:29:01 EST
* Srivatsa Vaddagiri <vatsa@xxxxxxxxxxxxxxxxxx> wrote:
> + /* we don't want this thread's execution to be limited by the shares
> + * assigned to default group (init_task_group). Hence make it run
> + * as a RT task.
> + */
> + schedparm.sched_priority = 0; /* run at the lowest RT prio */
> + ret = sched_setscheduler(current, SCHED_RR, &schedparm);
> + if (ret)
> + printk(KERN_ERR "Couldn't set SCHED_RR policy for load balance"
> + "monitor thread (error = %d) \n", ret);
the first SCHED_RR priority is 1, not 0 - so this call will always fail.
> + lock_cpu_hotplug(); /* Prevent cpus going down or coming up */
> + lock_doms_cur(); /* lockout changes to doms_cur[] array */
please put comments in front of the line like we do in most of sched.c.
> + rcu_read_lock(); /* to walk rq->sd chain on various cpus and to
> + * walk task group list in rebalance_shares().
> + */
the proper comment format is in front of the line and in:
/*
* Comment.
*/
Ingo
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/