aboutsummaryrefslogtreecommitdiff
path: root/arch/sh/mm/init.c
diff options
context:
space:
mode:
authorPaul Mundt <lethal@linux-sh.org>2010-01-21 15:54:31 +0900
committerPaul Mundt <lethal@linux-sh.org>2010-01-21 15:54:31 +0900
commit3125ee72dca25fc2157dcddd07e2d740db921fc4 (patch)
treee6fdcea67ba6ebf9bf485b397f8488b15da1330d /arch/sh/mm/init.c
parent2023b843d7b62d99e7356b872e99abc7d6667e49 (diff)
sh: Track the uncached mapping size.
This provides a variable for tracking the uncached mapping size, and uses it for pretty printing the uncached lowmem range. Beyond this, we'll also be building on top of this for figuring out from where the remainder of P2 becomes usable when constructing unrelated mappings. Signed-off-by: Paul Mundt <lethal@linux-sh.org>
Diffstat (limited to 'arch/sh/mm/init.c')
-rw-r--r--arch/sh/mm/init.c21
1 files changed, 14 insertions, 7 deletions
diff --git a/arch/sh/mm/init.c b/arch/sh/mm/init.c
index f3e23ad075c..a28ff63c17a 100644
--- a/arch/sh/mm/init.c
+++ b/arch/sh/mm/init.c
@@ -27,15 +27,17 @@ pgd_t swapper_pg_dir[PTRS_PER_PGD];
#ifdef CONFIG_SUPERH32
/*
- * Handle trivial transitions between cached and uncached
- * segments, making use of the 1:1 mapping relationship in
- * 512MB lowmem.
- *
* This is the offset of the uncached section from its cached alias.
- * Default value only valid in 29 bit mode, in 32bit mode will be
- * overridden in pmb_init.
+ *
+ * Legacy platforms handle trivial transitions between cached and
+ * uncached segments by making use of the 1:1 mapping relationship in
+ * 512MB lowmem, others via a special uncached mapping.
+ *
+ * Default value only valid in 29 bit mode, in 32bit mode this will be
+ * updated by the early PMB initialization code.
*/
unsigned long cached_to_uncached = P2SEG - P1SEG;
+unsigned long uncached_size = 0x20000000;
#endif
#ifdef CONFIG_MMU
@@ -281,7 +283,8 @@ void __init mem_init(void)
" pkmap : 0x%08lx - 0x%08lx (%4ld kB)\n"
#endif
" vmalloc : 0x%08lx - 0x%08lx (%4ld MB)\n"
- " lowmem : 0x%08lx - 0x%08lx (%4ld MB)\n"
+ " lowmem : 0x%08lx - 0x%08lx (%4ld MB) (cached)\n"
+ " : 0x%08lx - 0x%08lx (%4ld MB) (uncached)\n"
" .init : 0x%08lx - 0x%08lx (%4ld kB)\n"
" .data : 0x%08lx - 0x%08lx (%4ld kB)\n"
" .text : 0x%08lx - 0x%08lx (%4ld kB)\n",
@@ -299,6 +302,10 @@ void __init mem_init(void)
(unsigned long)memory_start, (unsigned long)high_memory,
((unsigned long)high_memory - (unsigned long)memory_start) >> 20,
+ (unsigned long)memory_start + cached_to_uncached,
+ (unsigned long)memory_start + cached_to_uncached + uncached_size,
+ uncached_size >> 20,
+
(unsigned long)&__init_begin, (unsigned long)&__init_end,
((unsigned long)&__init_end -
(unsigned long)&__init_begin) >> 10,