Commit 2e8b5a09 authored by David Howells's avatar David Howells Committed by Linus Torvalds

MN10300: Fix the vmlinux ldscript

Fix the MN10300 vmlinux ldscript.  It needs to use various macros from
asm-generic/vmlinux.lds.h to correctly include all that it needs to.
Signed-off-by: default avatarDavid Howells <dhowells@redhat.com>
Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
parent eadfe219
...@@ -38,14 +38,10 @@ SECTIONS ...@@ -38,14 +38,10 @@ SECTIONS
_etext = .; /* End of text section */ _etext = .; /* End of text section */
. = ALIGN(16); /* Exception table */ EXCEPTION_TABLE(16)
__start___ex_table = .;
__ex_table : { *(__ex_table) }
__stop___ex_table = .;
BUG_TABLE BUG_TABLE
RODATA RO_DATA(PAGE_SIZE)
/* writeable */ /* writeable */
.data : { /* Data */ .data : { /* Data */
...@@ -53,27 +49,19 @@ SECTIONS ...@@ -53,27 +49,19 @@ SECTIONS
CONSTRUCTORS CONSTRUCTORS
} }
. = ALIGN(PAGE_SIZE); .data_nosave : { NOSAVE_DATA; }
__nosave_begin = .;
.data_nosave : { *(.data.nosave) }
. = ALIGN(PAGE_SIZE);
__nosave_end = .;
. = ALIGN(PAGE_SIZE);
.data.page_aligned : { *(.data.idt) }
. = ALIGN(32); .data.page_aligned : { PAGE_ALIGNED_DATA(PAGE_SIZE); }
.data.cacheline_aligned : { *(.data.cacheline_aligned) } .data.cacheline_aligned : { CACHELINE_ALIGNED_DATA(32); }
/* rarely changed data like cpu maps */ /* rarely changed data like cpu maps */
. = ALIGN(32); . = ALIGN(32);
.data.read_mostly : AT(ADDR(.data.read_mostly)) { .data.read_mostly : AT(ADDR(.data.read_mostly)) {
*(.data.read_mostly) READ_MOSTLY_DATA(32);
_edata = .; /* End of data section */ _edata = .; /* End of data section */
} }
. = ALIGN(THREAD_SIZE); /* init_task */ .data.init_task : { INIT_TASK(THREAD_SIZE); }
.data.init_task : { *(.data.init_task) }
/* might get freed after init */ /* might get freed after init */
. = ALIGN(PAGE_SIZE); . = ALIGN(PAGE_SIZE);
...@@ -88,23 +76,18 @@ SECTIONS ...@@ -88,23 +76,18 @@ SECTIONS
__init_begin = .; __init_begin = .;
.init.text : { .init.text : {
_sinittext = .; _sinittext = .;
*(.init.text) INIT_TEXT;
_einittext = .; _einittext = .;
} }
.init.data : { *(.init.data) } .init.data : { INIT_DATA; }
. = ALIGN(16); .setup.init : { INIT_SETUP(16); }
__setup_start = .;
.setup.init : { KEEP(*(.init.setup)) }
__setup_end = .;
__initcall_start = .; __initcall_start = .;
.initcall.init : { .initcall.init : {
INITCALLS INITCALLS
} }
__initcall_end = .; __initcall_end = .;
__con_initcall_start = .; .con_initcall.init : { CON_INITCALL; }
.con_initcall.init : { *(.con_initcall.init) }
__con_initcall_end = .;
SECURITY_INIT SECURITY_INIT
. = ALIGN(4); . = ALIGN(4);
...@@ -114,28 +97,17 @@ SECTIONS ...@@ -114,28 +97,17 @@ SECTIONS
.altinstr_replacement : { *(.altinstr_replacement) } .altinstr_replacement : { *(.altinstr_replacement) }
/* .exit.text is discard at runtime, not link time, to deal with references /* .exit.text is discard at runtime, not link time, to deal with references
from .altinstructions and .eh_frame */ from .altinstructions and .eh_frame */
.exit.text : { *(.exit.text) } .exit.text : { EXIT_TEXT; }
.exit.data : { *(.exit.data) } .exit.data : { EXIT_DATA; }
#ifdef CONFIG_BLK_DEV_INITRD .init.ramfs : { INIT_RAM_FS; }
. = ALIGN(PAGE_SIZE);
__initramfs_start = .;
.init.ramfs : { *(.init.ramfs) }
__initramfs_end = .;
#endif
PERCPU(32) PERCPU(32)
. = ALIGN(PAGE_SIZE); . = ALIGN(PAGE_SIZE);
__init_end = .; __init_end = .;
/* freed after init ends here */ /* freed after init ends here */
__bss_start = .; /* BSS */ BSS(4)
.bss : {
*(.bss.page_aligned)
*(.bss)
}
. = ALIGN(4);
__bss_stop = .;
_end = . ; _end = . ;
...@@ -145,7 +117,7 @@ SECTIONS ...@@ -145,7 +117,7 @@ SECTIONS
/* Sections to be discarded */ /* Sections to be discarded */
/DISCARD/ : { /DISCARD/ : {
*(.exitcall.exit) EXIT_CALL
} }
STABS_DEBUG STABS_DEBUG
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment