Skip to content

Commit 84a6fcb

Browse files
haukeralfbaechle
authored andcommitted
MIPS: BCM47xx: Fix 128MB RAM support
Ignoring the last page when ddr size is 128M. Cached accesses to last page is causing the processor to prefetch using address above 128M stepping out of the DDR address space. Signed-off-by: Hauke Mehrtens <[email protected]> Cc: [email protected] Patchwork: http://patchwork.linux-mips.org/patch/981/ Signed-off-by: Ralf Baechle <[email protected]>
1 parent 52ab320 commit 84a6fcb

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

arch/mips/bcm47xx/prom.c

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -141,6 +141,14 @@ static __init void prom_init_mem(void)
141141
break;
142142
}
143143

144+
/* Ignoring the last page when ddr size is 128M. Cached
145+
* accesses to last page is causing the processor to prefetch
146+
* using address above 128M stepping out of the ddr address
147+
* space.
148+
*/
149+
if (mem == 0x8000000)
150+
mem -= 0x1000;
151+
144152
add_memory_region(0, mem, BOOT_MEM_RAM);
145153
}
146154

0 commit comments

Comments
 (0)