blob: 01f809617e5e708df97764794de91b3a6bad8c81 [file] [log] [blame]
Linus Torvalds1da177e2005-04-16 15:20:36 -07001/* ld script to make UltraLinux kernel */
2
Sam Ravnborg4096b462007-05-29 21:29:00 +02003#include <asm/page.h>
Linus Torvalds1da177e2005-04-16 15:20:36 -07004#include <asm-generic/vmlinux.lds.h>
5
6OUTPUT_FORMAT("elf64-sparc", "elf64-sparc", "elf64-sparc")
7OUTPUT_ARCH(sparc:v9a)
8ENTRY(_start)
9
10jiffies = jiffies_64;
11SECTIONS
12{
Sam Ravnborg72be7e52007-09-17 19:02:57 -070013 swapper_low_pmd_dir = 0x0000000000402000;
14 . = 0x4000;
15 .text 0x0000000000404000 : {
16 _text = .;
17 TEXT_TEXT
18 SCHED_TEXT
19 LOCK_TEXT
20 KPROBES_TEXT
21 *(.gnu.warning)
22 } = 0
23 _etext = .;
24 PROVIDE (etext = .);
Linus Torvalds1da177e2005-04-16 15:20:36 -070025
Sam Ravnborg72be7e52007-09-17 19:02:57 -070026 RO_DATA(PAGE_SIZE)
27 .data : {
28 DATA_DATA
29 CONSTRUCTORS
30 }
31 .data1 : {
32 *(.data1)
33 }
34 . = ALIGN(64);
35 .data.cacheline_aligned : {
36 *(.data.cacheline_aligned)
37 }
38 . = ALIGN(64);
39 .data.read_mostly : {
40 *(.data.read_mostly)
41 }
42 _edata = .;
43 PROVIDE (edata = .);
44 .fixup : {
45 *(.fixup)
46 }
47 . = ALIGN(16);
48 __ex_table : {
49 __start___ex_table = .;
50 *(__ex_table)
51 __stop___ex_table = .;
52 }
53 NOTES
Linus Torvalds1da177e2005-04-16 15:20:36 -070054
Sam Ravnborg72be7e52007-09-17 19:02:57 -070055 . = ALIGN(PAGE_SIZE);
56 .init.text : {
57 __init_begin = .;
58 _sinittext = .;
Sam Ravnborg01ba2bd2008-01-20 14:15:03 +010059 INIT_TEXT
Sam Ravnborg72be7e52007-09-17 19:02:57 -070060 _einittext = .;
61 }
62 .init.data : {
Sam Ravnborg01ba2bd2008-01-20 14:15:03 +010063 INIT_DATA
Sam Ravnborg72be7e52007-09-17 19:02:57 -070064 }
65 . = ALIGN(16);
66 .init.setup : {
67 __setup_start = .;
68 *(.init.setup)
69 __setup_end = .;
70 }
71 .initcall.init : {
72 __initcall_start = .;
73 INITCALLS
74 __initcall_end = .;
75 }
76 .con_initcall.init : {
77 __con_initcall_start = .;
78 *(.con_initcall.init)
79 __con_initcall_end = .;
80 }
81 SECURITY_INIT
Linus Torvalds1da177e2005-04-16 15:20:36 -070082
Sam Ravnborg72be7e52007-09-17 19:02:57 -070083 . = ALIGN(4);
84 .tsb_ldquad_phys_patch : {
85 __tsb_ldquad_phys_patch = .;
86 *(.tsb_ldquad_phys_patch)
87 __tsb_ldquad_phys_patch_end = .;
88 }
Linus Torvalds1da177e2005-04-16 15:20:36 -070089
Sam Ravnborg72be7e52007-09-17 19:02:57 -070090 .tsb_phys_patch : {
91 __tsb_phys_patch = .;
92 *(.tsb_phys_patch)
93 __tsb_phys_patch_end = .;
94 }
David S. Miller0c0d3452007-07-22 19:19:05 -070095
Sam Ravnborg72be7e52007-09-17 19:02:57 -070096 .cpuid_patch : {
97 __cpuid_patch = .;
98 *(.cpuid_patch)
99 __cpuid_patch_end = .;
100 }
101
102 .sun4v_1insn_patch : {
103 __sun4v_1insn_patch = .;
104 *(.sun4v_1insn_patch)
105 __sun4v_1insn_patch_end = .;
106 }
107 .sun4v_2insn_patch : {
108 __sun4v_2insn_patch = .;
109 *(.sun4v_2insn_patch)
110 __sun4v_2insn_patch_end = .;
111 }
Jean-Paul Saman67d38222007-02-10 01:44:44 -0800112
113#ifdef CONFIG_BLK_DEV_INITRD
Sam Ravnborg72be7e52007-09-17 19:02:57 -0700114 . = ALIGN(PAGE_SIZE);
115 .init.ramfs : {
116 __initramfs_start = .;
117 *(.init.ramfs)
118 __initramfs_end = .;
119 }
Jean-Paul Saman67d38222007-02-10 01:44:44 -0800120#endif
121
Sam Ravnborg72be7e52007-09-17 19:02:57 -0700122 PERCPU(PAGE_SIZE)
Fenghua Yu5fb7dc32007-07-19 01:48:12 -0700123
Sam Ravnborg72be7e52007-09-17 19:02:57 -0700124 . = ALIGN(PAGE_SIZE);
125 __init_end = .;
126 __bss_start = .;
127 .sbss : {
128 *(.sbss)
129 *(.scommon)
130 }
131 .bss : {
132 *(.dynbss)
133 *(.bss)
134 *(COMMON)
135 }
136 _end = . ;
137 PROVIDE (end = .);
David S. Millerd5784b52005-12-28 13:22:54 -0800138
Sam Ravnborg72be7e52007-09-17 19:02:57 -0700139 /DISCARD/ : {
Sam Ravnborg01ba2bd2008-01-20 14:15:03 +0100140 EXIT_TEXT
141 EXIT_DATA
Sam Ravnborg72be7e52007-09-17 19:02:57 -0700142 *(.exitcall.exit)
143 }
David S. Millerd5784b52005-12-28 13:22:54 -0800144
Sam Ravnborg72be7e52007-09-17 19:02:57 -0700145 STABS_DEBUG
146 DWARF_DEBUG
Linus Torvalds1da177e2005-04-16 15:20:36 -0700147}