Commit 4fe91d51 authored by Paul Jackson's avatar Paul Jackson Committed by Linus Torvalds

cgroup: fix sparse warning of shadow symbol in cgroup.c

Fix a code warning: symbol 'p' shadows an earlier one

This is a reincarnation of Harvey Harrison's patch:
	cpuset: sparse warnings in cpuset.c

Independently, Cliff Wickman moved the affected code,
from kernel/cpuset.c to kernel/cgroup.c, in his patch:
	cpusets: update_cpumask revision
Signed-off-by: default avatarPaul Jackson <pj@sgi.com>
Cc: Harvey Harrison <harvey.harrison@gmail.com>
Cc: Cliff Wickman <cpw@sgi.com>
Acked-by: default avatarPaul Menage <menage@google.com>
Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
parent 3df91fe3
......@@ -1913,14 +1913,14 @@ int cgroup_scan_tasks(struct cgroup_scanner *scan)
if (heap->size) {
for (i = 0; i < heap->size; i++) {
struct task_struct *p = heap->ptrs[i];
struct task_struct *q = heap->ptrs[i];
if (i == 0) {
latest_time = p->start_time;
latest_task = p;
latest_time = q->start_time;
latest_task = q;
}
/* Process the task per the caller's callback */
scan->process_task(p, scan);
put_task_struct(p);
scan->process_task(q, scan);
put_task_struct(q);
}
/*
* If we had to process any tasks at all, scan again
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment