Skip to content

Commit f5d6d2d

Browse files
tklauseringomolnar
authored andcommitted
sched/fair: Remove unused but set variable 'rq'
Since commit: 8663e24 ("sched/fair: Reorder cgroup creation code") ... the variable 'rq' in alloc_fair_sched_group() is set but no longer used. Remove it to fix the following GCC warning when building with 'W=1': kernel/sched/fair.c:8842:13: warning: variable ‘rq’ set but not used [-Wunused-but-set-variable] Signed-off-by: Tobias Klauser <tklauser@distanz.ch> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/20161026113704.8981-1-tklauser@distanz.ch Signed-off-by: Ingo Molnar <mingo@kernel.org>
1 parent 9fe68ca commit f5d6d2d

1 file changed

Lines changed: 0 additions & 3 deletions

File tree

kernel/sched/fair.c

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8839,7 +8839,6 @@ int alloc_fair_sched_group(struct task_group *tg, struct task_group *parent)
88398839
{
88408840
struct sched_entity *se;
88418841
struct cfs_rq *cfs_rq;
8842-
struct rq *rq;
88438842
int i;
88448843

88458844
tg->cfs_rq = kzalloc(sizeof(cfs_rq) * nr_cpu_ids, GFP_KERNEL);
@@ -8854,8 +8853,6 @@ int alloc_fair_sched_group(struct task_group *tg, struct task_group *parent)
88548853
init_cfs_bandwidth(tg_cfs_bandwidth(tg));
88558854

88568855
for_each_possible_cpu(i) {
8857-
rq = cpu_rq(i);
8858-
88598856
cfs_rq = kzalloc_node(sizeof(struct cfs_rq),
88608857
GFP_KERNEL, cpu_to_node(i));
88618858
if (!cfs_rq)

0 commit comments

Comments
 (0)