diff options
author | Steven Rostedt (Red Hat) <rostedt@goodmis.org> | 2014-07-09 08:39:51 -0400 |
---|---|---|
committer | Steven Rostedt <rostedt@goodmis.org> | 2014-07-09 08:39:51 -0400 |
commit | 04bea4b9a4e410a540843933243be26de1592135 (patch) | |
tree | 8731f2550254fa7e5be8eff9233a6d0a69edb44b /kernel/sched | |
parent | e198cf1ad2f9ccedd005789a740d0eb5b3942447 (diff) | |
parent | 8097be3bc58315b14498000585299e3c06fb13ce (diff) | |
download | linux-rt-04bea4b9a4e410a540843933243be26de1592135.tar.gz |
Merge tag 'v3.12.24' into v3.12-rt
This is the 3.12.24 stable release
Conflicts:
include/linux/irqdesc.h
Diffstat (limited to 'kernel/sched')
-rw-r--r-- | kernel/sched/fair.c | 15 |
1 files changed, 7 insertions, 8 deletions
diff --git a/kernel/sched/fair.c b/kernel/sched/fair.c index 0af144820eb9..773c5db90d3a 100644 --- a/kernel/sched/fair.c +++ b/kernel/sched/fair.c @@ -1579,13 +1579,7 @@ static inline void enqueue_entity_load_avg(struct cfs_rq *cfs_rq, } wakeup = 0; } else { - /* - * Task re-woke on same cpu (or else migrate_task_rq_fair() - * would have made count negative); we must be careful to avoid - * double-accounting blocked time after synchronizing decays. - */ - se->avg.last_runnable_update += __synchronize_entity_decay(se) - << 20; + __synchronize_entity_decay(se); } /* migrated tasks did not contribute to our blocked load */ @@ -4410,6 +4404,7 @@ static unsigned long scale_rt_power(int cpu) { struct rq *rq = cpu_rq(cpu); u64 total, available, age_stamp, avg; + s64 delta; /* * Since we're reading these variables without serialization make sure @@ -4418,7 +4413,11 @@ static unsigned long scale_rt_power(int cpu) age_stamp = ACCESS_ONCE(rq->age_stamp); avg = ACCESS_ONCE(rq->rt_avg); - total = sched_avg_period() + (rq_clock(rq) - age_stamp); + delta = rq_clock(rq) - age_stamp; + if (unlikely(delta < 0)) + delta = 0; + + total = sched_avg_period() + delta; if (unlikely(total < avg)) { /* Ensures that power won't end up being negative */ |