diff options
author | Ingo Molnar <mingo@elte.hu> | 2007-10-15 11:00:11 -0400 |
---|---|---|
committer | Ingo Molnar <mingo@elte.hu> | 2007-10-15 11:00:11 -0400 |
commit | 57cb499df26d80ec11cd49e56d20835334ac4ab9 (patch) | |
tree | 1affcb6b68f5428e7c96121fec806d1074b0c1a2 /kernel/sched_fair.c | |
parent | 2ddbf952508fb9911036c484a87f6351106b917c (diff) |
sched: remove set_leftmost()
Lee Schermerhorn noticed that set_leftmost() contains dead code,
remove this.
Reported-by: Lee Schermerhorn <Lee.Schermerhorn@hp.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Reviewed-by: Thomas Gleixner <tglx@linutronix.de>
Diffstat (limited to 'kernel/sched_fair.c')
-rw-r--r-- | kernel/sched_fair.c | 14 |
1 files changed, 2 insertions, 12 deletions
diff --git a/kernel/sched_fair.c b/kernel/sched_fair.c index 91664d665c0f..48c69211888f 100644 --- a/kernel/sched_fair.c +++ b/kernel/sched_fair.c | |||
@@ -124,16 +124,6 @@ max_vruntime(u64 min_vruntime, u64 vruntime) | |||
124 | return min_vruntime; | 124 | return min_vruntime; |
125 | } | 125 | } |
126 | 126 | ||
127 | static inline void | ||
128 | set_leftmost(struct cfs_rq *cfs_rq, struct rb_node *leftmost) | ||
129 | { | ||
130 | struct sched_entity *se; | ||
131 | |||
132 | cfs_rq->rb_leftmost = leftmost; | ||
133 | if (leftmost) | ||
134 | se = rb_entry(leftmost, struct sched_entity, run_node); | ||
135 | } | ||
136 | |||
137 | static inline s64 | 127 | static inline s64 |
138 | entity_key(struct cfs_rq *cfs_rq, struct sched_entity *se) | 128 | entity_key(struct cfs_rq *cfs_rq, struct sched_entity *se) |
139 | { | 129 | { |
@@ -175,7 +165,7 @@ __enqueue_entity(struct cfs_rq *cfs_rq, struct sched_entity *se) | |||
175 | * used): | 165 | * used): |
176 | */ | 166 | */ |
177 | if (leftmost) | 167 | if (leftmost) |
178 | set_leftmost(cfs_rq, &se->run_node); | 168 | cfs_rq->rb_leftmost = &se->run_node; |
179 | 169 | ||
180 | rb_link_node(&se->run_node, parent, link); | 170 | rb_link_node(&se->run_node, parent, link); |
181 | rb_insert_color(&se->run_node, &cfs_rq->tasks_timeline); | 171 | rb_insert_color(&se->run_node, &cfs_rq->tasks_timeline); |
@@ -185,7 +175,7 @@ static void | |||
185 | __dequeue_entity(struct cfs_rq *cfs_rq, struct sched_entity *se) | 175 | __dequeue_entity(struct cfs_rq *cfs_rq, struct sched_entity *se) |
186 | { | 176 | { |
187 | if (cfs_rq->rb_leftmost == &se->run_node) | 177 | if (cfs_rq->rb_leftmost == &se->run_node) |
188 | set_leftmost(cfs_rq, rb_next(&se->run_node)); | 178 | cfs_rq->rb_leftmost = rb_next(&se->run_node); |
189 | 179 | ||
190 | rb_erase(&se->run_node, &cfs_rq->tasks_timeline); | 180 | rb_erase(&se->run_node, &cfs_rq->tasks_timeline); |
191 | } | 181 | } |