Gitweb:     
http://git.kernel.org/git/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=a6f2994042cc2db9e507dc702ed0b5e2cc5890fe
Commit:     a6f2994042cc2db9e507dc702ed0b5e2cc5890fe
Parent:     b2133c8b1e270b4a7c36f70e29be8738d09e850b
Author:     Peter Zijlstra <[EMAIL PROTECTED]>
AuthorDate: Fri Aug 24 20:39:10 2007 +0200
Committer:  Ingo Molnar <[EMAIL PROTECTED]>
CommitDate: Fri Aug 24 20:39:10 2007 +0200

    sched: simplify bonus calculation #1
    
    current code:
    
     delta = min(cfs_rq->sleeper_bonus, (u64)delta_exec);
     delta = calc_delta_mine(delta, curr->load.weight, lw);
     delta = min((u64)delta, cfs_rq->sleeper_bonus);
    
    drop the first min(), because we clip against sleeper_bonus in the 3rd line
    again. That gives:
    
     delta = calc_delta_mine(delta_exec, curr->load.weight, lw);
     delta = min((u64)delta, cfs_rq->sleeper_bonus);
    
    Signed-off-by: Peter Zijlstra <[EMAIL PROTECTED]>
    Signed-off-by: Ingo Molnar <[EMAIL PROTECTED]>
---
 kernel/sched_fair.c |    3 +--
 1 files changed, 1 insertions(+), 2 deletions(-)

diff --git a/kernel/sched_fair.c b/kernel/sched_fair.c
index c578370..5b2d97f 100644
--- a/kernel/sched_fair.c
+++ b/kernel/sched_fair.c
@@ -303,8 +303,7 @@ __update_curr(struct cfs_rq *cfs_rq, struct sched_entity 
*curr)
        delta_mine = calc_delta_mine(delta_exec, curr->load.weight, lw);
 
        if (cfs_rq->sleeper_bonus > sysctl_sched_granularity) {
-               delta = min(cfs_rq->sleeper_bonus, (u64)delta_exec);
-               delta = calc_delta_mine(delta, curr->load.weight, lw);
+               delta = calc_delta_mine(delta_exec, curr->load.weight, lw);
                delta = min((u64)delta, cfs_rq->sleeper_bonus);
                delta = min(delta, (unsigned long)(
                        (long)sysctl_sched_runtime_limit - curr->wait_runtime));
-
To unsubscribe from this list: send the line "unsubscribe git-commits-head" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to