Skip to content

Commit 7038220

Browse files
dhowellsLinus Torvalds
authored andcommitted
FRV: permit the memory to be located elsewhere in NOMMU mode
Permit the memory to be located somewhere other than address 0xC0000000 in NOMMU mode. The configuration options are already present, it just requires wiring up in the linker script. Note that only a limited set of locations of runtime addresses are available because of the way the CPU protection registers work. Signed-off-by: David Howells <dhowells@redhat.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
1 parent e114e47 commit 7038220

2 files changed

Lines changed: 10 additions & 1 deletion

File tree

‎arch/frv/Kconfig‎

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -138,6 +138,15 @@ config UCPAGE_OFFSET_C0000000
138138

139139
endchoice
140140

141+
config PAGE_OFFSET
142+
hex
143+
default 0x20000000 if UCPAGE_OFFSET_20000000
144+
default 0x40000000 if UCPAGE_OFFSET_40000000
145+
default 0x60000000 if UCPAGE_OFFSET_60000000
146+
default 0x80000000 if UCPAGE_OFFSET_80000000
147+
default 0xA0000000 if UCPAGE_OFFSET_A0000000
148+
default 0xC0000000
149+
141150
config PROTECT_KERNEL
142151
bool "Protect core kernel against userspace"
143152
depends on !MMU

‎arch/frv/kernel/vmlinux.lds.S‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ ENTRY(_start)
1313

1414
jiffies = jiffies_64 + 4;
1515

16-
__page_offset = 0xc0000000; /* start of area covered by struct pages */
16+
__page_offset = CONFIG_PAGE_OFFSET; /* start of area covered by struct pages */
1717
__kernel_image_start = __page_offset; /* address at which kernel image resides */
1818

1919
SECTIONS

0 commit comments

Comments
 (0)