mirror of
https://github.com/torvalds/linux.git
synced 2026-06-07 14:04:54 +02:00
openrisc: mm/init.c: remove unused memblock_region variable in map_ram()
commit4eff124347upstream. Kernel test robot reports: cppcheck possible warnings: (new ones prefixed by >>, may not real problems) >> arch/openrisc/mm/init.c:125:10: warning: Uninitialized variable: region [uninitvar] region->base, region->base + region->size); ^ Replace usage of memblock_region fields with 'start' and 'end' variables that are initialized in for_each_mem_range() and remove the declaration of region. Fixes:b10d6bca87("arch, drivers: replace for_each_membock() with for_each_mem_range()") Reported-by: kernel test robot <lkp@intel.com> Signed-off-by: Mike Rapoport <rppt@linux.ibm.com> Signed-off-by: Stafford Horne <shorne@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
parent
585d8425e5
commit
d5c4605e9e
|
|
@ -76,7 +76,6 @@ static void __init map_ram(void)
|
||||||
/* These mark extents of read-only kernel pages...
|
/* These mark extents of read-only kernel pages...
|
||||||
* ...from vmlinux.lds.S
|
* ...from vmlinux.lds.S
|
||||||
*/
|
*/
|
||||||
struct memblock_region *region;
|
|
||||||
|
|
||||||
v = PAGE_OFFSET;
|
v = PAGE_OFFSET;
|
||||||
|
|
||||||
|
|
@ -122,7 +121,7 @@ static void __init map_ram(void)
|
||||||
}
|
}
|
||||||
|
|
||||||
printk(KERN_INFO "%s: Memory: 0x%x-0x%x\n", __func__,
|
printk(KERN_INFO "%s: Memory: 0x%x-0x%x\n", __func__,
|
||||||
region->base, region->base + region->size);
|
start, end);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue
Block a user