diff options
Diffstat (limited to 'kernel')
-rw-r--r-- | kernel/sched.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/kernel/sched.c b/kernel/sched.c index ab562ae4007c..de0da71daf77 100644 --- a/kernel/sched.c +++ b/kernel/sched.c | |||
@@ -1872,12 +1872,6 @@ static void set_load_weight(struct task_struct *p) | |||
1872 | p->se.load.inv_weight = prio_to_wmult[p->static_prio - MAX_RT_PRIO]; | 1872 | p->se.load.inv_weight = prio_to_wmult[p->static_prio - MAX_RT_PRIO]; |
1873 | } | 1873 | } |
1874 | 1874 | ||
1875 | static void update_avg(u64 *avg, u64 sample) | ||
1876 | { | ||
1877 | s64 diff = sample - *avg; | ||
1878 | *avg += diff >> 3; | ||
1879 | } | ||
1880 | |||
1881 | static void enqueue_task(struct rq *rq, struct task_struct *p, int flags) | 1875 | static void enqueue_task(struct rq *rq, struct task_struct *p, int flags) |
1882 | { | 1876 | { |
1883 | update_rq_clock(rq); | 1877 | update_rq_clock(rq); |
@@ -2332,6 +2326,12 @@ int select_task_rq(struct rq *rq, struct task_struct *p, int sd_flags, int wake_ | |||
2332 | 2326 | ||
2333 | return cpu; | 2327 | return cpu; |
2334 | } | 2328 | } |
2329 | |||
2330 | static void update_avg(u64 *avg, u64 sample) | ||
2331 | { | ||
2332 | s64 diff = sample - *avg; | ||
2333 | *avg += diff >> 3; | ||
2334 | } | ||
2335 | #endif | 2335 | #endif |
2336 | 2336 | ||
2337 | /*** | 2337 | /*** |