percpu: kill compile warning in pcpu_populate_chunk()
authorTejun Heo <tj@kernel.org>
Sun, 1 Mar 2009 06:42:36 +0000 (15:42 +0900)
committerTejun Heo <tj@kernel.org>
Sun, 1 Mar 2009 06:42:36 +0000 (15:42 +0900)
Impact: remove compile warning

Mark local variable map_end in pcpu_populate_chunk() with
uninitialized_var().  The variable is always used in tandem with
map_start and guaranteed to be initialized before use but gcc doesn't
understand that.

Signed-off-by: Tejun Heo <tj@kernel.org>
Reported-by: Ingo Molnar <mingo@elte.hu>
mm/percpu.c

index 5954e7a9eb1e49f537fc829a9f31e3e883811ff3..3d0f5456827c0bf77ca4476c0096243cf0ef70b9 100644 (file)
@@ -639,7 +639,7 @@ static int pcpu_populate_chunk(struct pcpu_chunk *chunk, int off, int size)
        int page_start = PFN_DOWN(off);
        int page_end = PFN_UP(off + size);
        int map_start = -1;
-       int map_end;
+       int uninitialized_var(map_end);
        unsigned int cpu;
        int i;