xref: /linux-6.15/arch/alpha/kernel/vmlinux.lds.S (revision de078ef5)
1#include <asm-generic/vmlinux.lds.h>
2#include <asm/thread_info.h>
3#include <asm/page.h>
4
5OUTPUT_FORMAT("elf64-alpha")
6OUTPUT_ARCH(alpha)
7ENTRY(__start)
8PHDRS { kernel PT_LOAD; note PT_NOTE; }
9jiffies = jiffies_64;
10SECTIONS
11{
12#ifdef CONFIG_ALPHA_LEGACY_START_ADDRESS
13	. = 0xfffffc0000310000;
14#else
15	. = 0xfffffc0001010000;
16#endif
17
18	_text = .;	/* Text and read-only data */
19	.text : {
20		HEAD_TEXT
21		TEXT_TEXT
22		SCHED_TEXT
23		LOCK_TEXT
24		*(.fixup)
25		*(.gnu.warning)
26	} :kernel
27	_etext = .;	/* End of text section */
28
29	NOTES :kernel :note
30	.dummy : {
31		*(.dummy)
32	} :kernel
33
34	RODATA
35
36	/* Exception table */
37	. = ALIGN(16);
38	__ex_table : {
39		__start___ex_table = .;
40		*(__ex_table)
41		__stop___ex_table = .;
42	}
43
44	/* Will be freed after init */
45	. = ALIGN(PAGE_SIZE);
46	/* Init code and data */
47	__init_begin = .;
48	.init.text : {
49		_sinittext = .;
50		INIT_TEXT
51		_einittext = .;
52	}
53	.init.data : {
54		INIT_DATA
55	}
56
57	. = ALIGN(16);
58	.init.setup : {
59		__setup_start = .;
60		*(.init.setup)
61		__setup_end = .;
62	}
63
64	. = ALIGN(8);
65	.initcall.init : {
66		__initcall_start = .;
67		INITCALLS
68		__initcall_end = .;
69	}
70
71#ifdef CONFIG_BLK_DEV_INITRD
72	. = ALIGN(PAGE_SIZE);
73	.init.ramfs : {
74		__initramfs_start = .;
75		*(.init.ramfs)
76		__initramfs_end = .;
77	}
78#endif
79
80	. = ALIGN(8);
81	.con_initcall.init : {
82		__con_initcall_start = .;
83		*(.con_initcall.init)
84		__con_initcall_end = .;
85	}
86
87	. = ALIGN(8);
88	SECURITY_INIT
89
90	PERCPU(PAGE_SIZE)
91
92	. = ALIGN(2 * PAGE_SIZE);
93	__init_end = .;
94	/* Freed after init ends here */
95
96	/* Note 2 page alignment above.  */
97	.data.init_thread : {
98		*(.data.init_thread)
99	}
100
101	. = ALIGN(PAGE_SIZE);
102	.data.page_aligned : {
103		*(.data.page_aligned)
104	}
105
106	. = ALIGN(64);
107	.data.cacheline_aligned : {
108		*(.data.cacheline_aligned)
109	}
110
111	_data = .;
112	/* Data */
113	.data : {
114		DATA_DATA
115		CONSTRUCTORS
116	}
117
118	.got : {
119		*(.got)
120	}
121	.sdata : {
122		*(.sdata)
123	}
124	_edata = .;	/* End of data section */
125
126	__bss_start = .;
127	.sbss : {
128		*(.sbss)
129		*(.scommon)
130	}
131	.bss : {
132		*(.bss)
133		*(COMMON)
134	}
135	__bss_stop = .;
136	_end = .;
137
138	.mdebug 0 : {
139		*(.mdebug)
140	}
141	.note 0 : {
142		*(.note)
143	}
144
145	STABS_DEBUG
146	DWARF_DEBUG
147
148	DISCARDS
149}
150