diff options
author | Ingo Molnar <mingo@elte.hu> | 2008-11-24 17:37:12 +0100 |
---|---|---|
committer | Ingo Molnar <mingo@elte.hu> | 2008-11-24 17:37:12 +0100 |
commit | 64b7482de253c10efa2589a6212e3d2093a3efc7 (patch) | |
tree | 0745dd3684cbe9c17b95b601bad3605c22459f41 /kernel | |
parent | 957ad0166e9f76a8561dafa5e14ef5bd3f5e9a3b (diff) | |
parent | 50ee91765e25e7967a7b69cd5cc2bcab85e2eeb8 (diff) |
Merge branch 'sched/rt' into sched/core
Diffstat (limited to 'kernel')
-rw-r--r-- | kernel/sched.c | 2 | ||||
-rw-r--r-- | kernel/sched_rt.c | 7 |
2 files changed, 5 insertions, 4 deletions
diff --git a/kernel/sched.c b/kernel/sched.c index a6085d5166d..338340a3fb8 100644 --- a/kernel/sched.c +++ b/kernel/sched.c @@ -2806,7 +2806,7 @@ static int double_lock_balance(struct rq *this_rq, struct rq *busiest) return ret; } -static void double_unlock_balance(struct rq *this_rq, struct rq *busiest) +static inline void double_unlock_balance(struct rq *this_rq, struct rq *busiest) __releases(busiest->lock) { spin_unlock(&busiest->lock); diff --git a/kernel/sched_rt.c b/kernel/sched_rt.c index d9ba9d5f99d..2bdd4442359 100644 --- a/kernel/sched_rt.c +++ b/kernel/sched_rt.c @@ -537,13 +537,13 @@ static void update_curr_rt(struct rq *rq) for_each_sched_rt_entity(rt_se) { rt_rq = rt_rq_of_se(rt_se); - spin_lock(&rt_rq->rt_runtime_lock); if (sched_rt_runtime(rt_rq) != RUNTIME_INF) { + spin_lock(&rt_rq->rt_runtime_lock); rt_rq->rt_time += delta_exec; if (sched_rt_runtime_exceeded(rt_rq)) resched_task(curr); + spin_unlock(&rt_rq->rt_runtime_lock); } - spin_unlock(&rt_rq->rt_runtime_lock); } } @@ -910,7 +910,8 @@ static void put_prev_task_rt(struct rq *rq, struct task_struct *p) #define RT_MAX_TRIES 3 static int double_lock_balance(struct rq *this_rq, struct rq *busiest); -static void double_unlock_balance(struct rq *this_rq, struct rq *busiest); +static inline void double_unlock_balance(struct rq *this_rq, + struct rq *busiest); static void deactivate_task(struct rq *rq, struct task_struct *p, int sleep); |