Skip to content

Commit 3240a77

Browse files
Geoffrey Thomastorvalds
authored andcommitted
sparc: Clean up linker script using new linker script macros.
Signed-off-by: Geoffrey Thomas <geofft@ksplice.com> Signed-off-by: Tim Abbott <tabbott@ksplice.com> Acked-by: Sam Ravnborg <sam@ravnborg.org> Acked-by: David S. Miller <davem@davemloft.net> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
1 parent 9c88b25 commit 3240a77

File tree

1 file changed

+7
-68
lines changed

1 file changed

+7
-68
lines changed

arch/sparc/kernel/vmlinux.lds.S

Lines changed: 7 additions & 68 deletions
Original file line numberDiff line numberDiff line change
@@ -51,70 +51,27 @@ SECTIONS
5151
_etext = .;
5252

5353
RO_DATA(PAGE_SIZE)
54-
.data : {
55-
DATA_DATA
56-
CONSTRUCTORS
57-
}
5854
.data1 : {
5955
*(.data1)
6056
}
61-
. = ALIGN(SMP_CACHE_BYTES);
62-
.data.cacheline_aligned : {
63-
*(.data.cacheline_aligned)
64-
}
65-
. = ALIGN(SMP_CACHE_BYTES);
66-
.data.read_mostly : {
67-
*(.data.read_mostly)
68-
}
57+
RW_DATA_SECTION(SMP_CACHE_BYTES, 0, THREAD_SIZE)
58+
6959
/* End of data section */
7060
_edata = .;
7161

72-
/* init_task */
73-
. = ALIGN(THREAD_SIZE);
74-
.data.init_task : {
75-
*(.data.init_task)
76-
}
7762
.fixup : {
7863
__start___fixup = .;
7964
*(.fixup)
8065
__stop___fixup = .;
8166
}
82-
. = ALIGN(16);
83-
__ex_table : {
84-
__start___ex_table = .;
85-
*(__ex_table)
86-
__stop___ex_table = .;
87-
}
67+
EXCEPTION_TABLE(16)
8868
NOTES
8969

9070
. = ALIGN(PAGE_SIZE);
91-
.init.text : {
92-
__init_begin = .;
93-
_sinittext = .;
94-
INIT_TEXT
95-
_einittext = .;
96-
}
71+
__init_begin = ALIGN(PAGE_SIZE);
72+
INIT_TEXT_SECTION(PAGE_SIZE)
9773
__init_text_end = .;
98-
.init.data : {
99-
INIT_DATA
100-
}
101-
. = ALIGN(16);
102-
.init.setup : {
103-
__setup_start = .;
104-
*(.init.setup)
105-
__setup_end = .;
106-
}
107-
.initcall.init : {
108-
__initcall_start = .;
109-
INITCALLS
110-
__initcall_end = .;
111-
}
112-
.con_initcall.init : {
113-
__con_initcall_start = .;
114-
*(.con_initcall.init)
115-
__con_initcall_end = .;
116-
}
117-
SECURITY_INIT
74+
INIT_DATA_SECTION(16)
11875

11976
. = ALIGN(4);
12077
.tsb_ldquad_phys_patch : {
@@ -146,29 +103,11 @@ SECTIONS
146103
__sun4v_2insn_patch_end = .;
147104
}
148105

149-
#ifdef CONFIG_BLK_DEV_INITRD
150-
. = ALIGN(PAGE_SIZE);
151-
.init.ramfs : {
152-
__initramfs_start = .;
153-
*(.init.ramfs)
154-
__initramfs_end = .;
155-
}
156-
#endif
157-
158106
PERCPU(PAGE_SIZE)
159107

160108
. = ALIGN(PAGE_SIZE);
161109
__init_end = .;
162-
__bss_start = .;
163-
.sbss : {
164-
*(.sbss)
165-
*(.scommon)
166-
}
167-
.bss : {
168-
*(.dynbss)
169-
*(.bss)
170-
*(COMMON)
171-
}
110+
BSS_SECTION(0, 0, 0)
172111
_end = . ;
173112

174113
STABS_DEBUG

0 commit comments

Comments
 (0)