diff options
Diffstat (limited to 'kernel/sched.c')
-rw-r--r-- | kernel/sched.c | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/kernel/sched.c b/kernel/sched.c index aa8cac4ae547..23583bb93273 100644 --- a/kernel/sched.c +++ b/kernel/sched.c | |||
@@ -804,8 +804,7 @@ static inline void inc_load(struct rq *rq, const struct task_struct *p) | |||
804 | update_load_add(&rq->ls.load, p->se.load.weight); | 804 | update_load_add(&rq->ls.load, p->se.load.weight); |
805 | } | 805 | } |
806 | 806 | ||
807 | static inline void | 807 | static inline void dec_load(struct rq *rq, const struct task_struct *p) |
808 | dec_load(struct rq *rq, const struct task_struct *p, u64 now) | ||
809 | { | 808 | { |
810 | update_curr_load(rq); | 809 | update_curr_load(rq); |
811 | update_load_sub(&rq->ls.load, p->se.load.weight); | 810 | update_load_sub(&rq->ls.load, p->se.load.weight); |
@@ -820,7 +819,7 @@ static void inc_nr_running(struct task_struct *p, struct rq *rq, u64 now) | |||
820 | static void dec_nr_running(struct task_struct *p, struct rq *rq, u64 now) | 819 | static void dec_nr_running(struct task_struct *p, struct rq *rq, u64 now) |
821 | { | 820 | { |
822 | rq->nr_running--; | 821 | rq->nr_running--; |
823 | dec_load(rq, p, now); | 822 | dec_load(rq, p); |
824 | } | 823 | } |
825 | 824 | ||
826 | static void set_load_weight(struct task_struct *p) | 825 | static void set_load_weight(struct task_struct *p) |
@@ -3981,7 +3980,7 @@ void set_user_nice(struct task_struct *p, long nice) | |||
3981 | on_rq = p->se.on_rq; | 3980 | on_rq = p->se.on_rq; |
3982 | if (on_rq) { | 3981 | if (on_rq) { |
3983 | dequeue_task(rq, p, 0, now); | 3982 | dequeue_task(rq, p, 0, now); |
3984 | dec_load(rq, p, now); | 3983 | dec_load(rq, p); |
3985 | } | 3984 | } |
3986 | 3985 | ||
3987 | p->static_prio = NICE_TO_PRIO(nice); | 3986 | p->static_prio = NICE_TO_PRIO(nice); |