diff options
author | Will Deacon <will.deacon@arm.com> | 2012-11-08 16:00:16 +0000 |
---|---|---|
committer | Catalin Marinas <catalin.marinas@arm.com> | 2012-11-08 16:06:21 +0000 |
commit | f483a853b0b932a1d75eb27a1dcbd732862260db (patch) | |
tree | 1954e6938eed2c2b20776b1159f001f9df071dd3 /arch/arm64/mm/init.c | |
parent | b3770b3252589240e50f560197a19531979abba2 (diff) | |
download | blackbird-op-linux-f483a853b0b932a1d75eb27a1dcbd732862260db.tar.gz blackbird-op-linux-f483a853b0b932a1d75eb27a1dcbd732862260db.zip |
arm64: mm: fix booting on systems with no memory below 4GB
Booting on a system with all of its memory above the 4GB boundary breaks
for two reasons:
(1) We still try to create a non-empty DMA32 zone
(2) no-bootmem limits allocations to 0xffffffff
This patch fixes these issues for ARM64.
Tested-by: Marc Zyngier <marc.zyngier@arm.com>
Signed-off-by: Will Deacon <will.deacon@arm.com>
Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
Diffstat (limited to 'arch/arm64/mm/init.c')
-rw-r--r-- | arch/arm64/mm/init.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/arch/arm64/mm/init.c b/arch/arm64/mm/init.c index efbf7df05d3f..4cd28931dba9 100644 --- a/arch/arm64/mm/init.c +++ b/arch/arm64/mm/init.c @@ -80,7 +80,7 @@ static void __init zone_sizes_init(unsigned long min, unsigned long max) #ifdef CONFIG_ZONE_DMA32 /* 4GB maximum for 32-bit only capable devices */ max_dma32 = min(max, MAX_DMA32_PFN); - zone_size[ZONE_DMA32] = max_dma32 - min; + zone_size[ZONE_DMA32] = max(min, max_dma32) - min; #endif zone_size[ZONE_NORMAL] = max - max_dma32; |