diff options
author | Stuart Menefy <stuart.menefy@st.com> | 2007-11-30 03:52:53 -0500 |
---|---|---|
committer | Paul Mundt <lethal@linux-sh.org> | 2008-01-27 23:18:59 -0500 |
commit | d02b08f6e8b184ffef349e395210a5e82ff4f4bc (patch) | |
tree | 1dbec9fe6d2315a95855ce5a91f92a2a1fbf5a22 /arch/sh | |
parent | cbaa118ecfd99fc5ed7adbd9c34a30e1c05e3c93 (diff) |
sh: Clean up places that make 29-bit physical assumptions.
Signed-off-by: Stuart Menefy <stuart.menefy@st.com>
Signed-off-by: Paul Mundt <lethal@linux-sh.org>
Diffstat (limited to 'arch/sh')
-rw-r--r-- | arch/sh/boot/compressed/misc_32.c | 5 | ||||
-rw-r--r-- | arch/sh/kernel/setup.c | 4 | ||||
-rw-r--r-- | arch/sh/kernel/vmlinux_32.lds.S | 5 |
3 files changed, 11 insertions, 3 deletions
diff --git a/arch/sh/boot/compressed/misc_32.c b/arch/sh/boot/compressed/misc_32.c index df65e305acf7..adcea31e663e 100644 --- a/arch/sh/boot/compressed/misc_32.c +++ b/arch/sh/boot/compressed/misc_32.c | |||
@@ -230,7 +230,10 @@ long* stack_start = &user_stack[STACK_SIZE]; | |||
230 | void decompress_kernel(void) | 230 | void decompress_kernel(void) |
231 | { | 231 | { |
232 | output_data = 0; | 232 | output_data = 0; |
233 | output_ptr = P2SEGADDR((unsigned long)&_text+PAGE_SIZE); | 233 | output_ptr = PHYSADDR((unsigned long)&_text+PAGE_SIZE); |
234 | #ifdef CONFIG_29BIT | ||
235 | output_ptr |= P2SEG; | ||
236 | #endif | ||
234 | free_mem_ptr = (unsigned long)&_end; | 237 | free_mem_ptr = (unsigned long)&_end; |
235 | free_mem_end_ptr = free_mem_ptr + HEAP_SIZE; | 238 | free_mem_end_ptr = free_mem_ptr + HEAP_SIZE; |
236 | 239 | ||
diff --git a/arch/sh/kernel/setup.c b/arch/sh/kernel/setup.c index 7eb7fdcce0f8..f48ce8e5d0a8 100644 --- a/arch/sh/kernel/setup.c +++ b/arch/sh/kernel/setup.c | |||
@@ -82,7 +82,7 @@ static int __init early_parse_mem(char *p) | |||
82 | { | 82 | { |
83 | unsigned long size; | 83 | unsigned long size; |
84 | 84 | ||
85 | memory_start = (unsigned long)PAGE_OFFSET+__MEMORY_START; | 85 | memory_start = (unsigned long)__va(__MEMORY_START); |
86 | size = memparse(p, &p); | 86 | size = memparse(p, &p); |
87 | 87 | ||
88 | if (size > __MEMORY_SIZE) { | 88 | if (size > __MEMORY_SIZE) { |
@@ -254,7 +254,7 @@ void __init setup_arch(char **cmdline_p) | |||
254 | data_resource.start = virt_to_phys(_etext); | 254 | data_resource.start = virt_to_phys(_etext); |
255 | data_resource.end = virt_to_phys(_edata)-1; | 255 | data_resource.end = virt_to_phys(_edata)-1; |
256 | 256 | ||
257 | memory_start = (unsigned long)PAGE_OFFSET+__MEMORY_START; | 257 | memory_start = (unsigned long)__va(__MEMORY_START); |
258 | if (!memory_end) | 258 | if (!memory_end) |
259 | memory_end = memory_start + __MEMORY_SIZE; | 259 | memory_end = memory_start + __MEMORY_SIZE; |
260 | 260 | ||
diff --git a/arch/sh/kernel/vmlinux_32.lds.S b/arch/sh/kernel/vmlinux_32.lds.S index 50c69c18dced..d549fac6d3e7 100644 --- a/arch/sh/kernel/vmlinux_32.lds.S +++ b/arch/sh/kernel/vmlinux_32.lds.S | |||
@@ -15,7 +15,12 @@ OUTPUT_ARCH(sh) | |||
15 | ENTRY(_start) | 15 | ENTRY(_start) |
16 | SECTIONS | 16 | SECTIONS |
17 | { | 17 | { |
18 | #ifdef CONFIG_32BIT | ||
19 | . = CONFIG_PAGE_OFFSET + CONFIG_ZERO_PAGE_OFFSET; | ||
20 | #else | ||
18 | . = CONFIG_PAGE_OFFSET + CONFIG_MEMORY_START + CONFIG_ZERO_PAGE_OFFSET; | 21 | . = CONFIG_PAGE_OFFSET + CONFIG_MEMORY_START + CONFIG_ZERO_PAGE_OFFSET; |
22 | #endif | ||
23 | |||
19 | _text = .; /* Text and read-only data */ | 24 | _text = .; /* Text and read-only data */ |
20 | 25 | ||
21 | .empty_zero_page : { | 26 | .empty_zero_page : { |