lkml.org 
[lkml]   [2011]   [Apr]   [7]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    Patch in this message
    /
    Date
    From
    Subject[PATCH]sched: convert wall-time to vruntime for check_preempt_tick
    In check_preempt_tick(), delta is vruntime and ideal_runtime is wall runtime.
    Comparing vruntime and ideal_runtime looks buggy.

    Signed-off-by: Shaohua Li <shaohua.li@intel.com>

    diff --git a/kernel/sched_fair.c b/kernel/sched_fair.c
    index 3f7ec9e..0b76e3a 100644
    --- a/kernel/sched_fair.c
    +++ b/kernel/sched_fair.c
    @@ -1121,7 +1121,7 @@ check_preempt_tick(struct cfs_rq *cfs_rq, struct sched_entity *curr)
    if (delta < 0)
    return;

    - if (delta > ideal_runtime)
    + if (delta > calc_delta_fair(ideal_runtime, curr))
    resched_task(rq_of(cfs_rq)->curr);
    }
    }

    \
     
     \ /
      Last update: 2011-04-07 22:35    [W:0.020 / U:61.844 seconds]
    ©2003-2016 Jasper Spaans. hosted at Digital OceanAdvertise on this site