summaryrefslogtreecommitdiff
path: root/arch/sh/mm
diff options
context:
space:
mode:
authorMagnus Damm <damm@opensource.se>2009-12-07 14:11:59 +0000
committerPaul Mundt <lethal@linux-sh.org>2009-12-09 12:40:42 +0900
commitf3a4c00ad35a9f21db82516fdc600cb1be301c23 (patch)
tree7a3ba1a3367e18cb03460e8a8e353d1ba81b6eca /arch/sh/mm
parentf701b3999890b867f87733c146d4cdf9319ead05 (diff)
downloadlinux-3.10-f3a4c00ad35a9f21db82516fdc600cb1be301c23.tar.gz
linux-3.10-f3a4c00ad35a9f21db82516fdc600cb1be301c23.tar.bz2
linux-3.10-f3a4c00ad35a9f21db82516fdc600cb1be301c23.zip
sh: fix size calculation for NUMA node 0
Fix the NUMA size calculation for node 0. Do the same as the UMA version of setup_memory() and use address instead of pfn when calculating the size. Signed-off-by: Magnus Damm <damm@opensource.se> Signed-off-by: Paul Mundt <lethal@linux-sh.org>
Diffstat (limited to 'arch/sh/mm')
-rw-r--r--arch/sh/mm/numa.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/arch/sh/mm/numa.c b/arch/sh/mm/numa.c
index 6c524446c0f..b44e8352667 100644
--- a/arch/sh/mm/numa.c
+++ b/arch/sh/mm/numa.c
@@ -28,7 +28,7 @@ void __init setup_memory(void)
{
unsigned long free_pfn = PFN_UP(__pa(_end));
u64 base = min_low_pfn << PAGE_SHIFT;
- u64 size = (max_low_pfn << PAGE_SHIFT) - min_low_pfn;
+ u64 size = (max_low_pfn << PAGE_SHIFT) - base;
lmb_add(base, size);