1#include <asm-generic/vmlinux.lds.h>
2
3OUTPUT_FORMAT(CONFIG_OUTPUT_FORMAT, CONFIG_OUTPUT_FORMAT, CONFIG_OUTPUT_FORMAT)
4
5#undef i386
6
7#include <asm/page_types.h>
8
9#ifdef CONFIG_X86_64
10OUTPUT_ARCH(i386:x86-64)
11ENTRY(startup_64)
12#else
13OUTPUT_ARCH(i386)
14ENTRY(startup_32)
15#endif
16
17SECTIONS
18{
19	/* Be careful parts of head_64.S assume startup_32 is at
20	 * address 0.
21	 */
22	. = 0;
23	.head.text : {
24		_head = . ;
25		HEAD_TEXT
26		_ehead = . ;
27	}
28	.rodata.compressed : {
29		*(.rodata.compressed)
30	}
31	.text :	{
32		_text = .; 	/* Text */
33		*(.text)
34		*(.text.*)
35		_etext = . ;
36	}
37	.rodata : {
38		_rodata = . ;
39		*(.rodata)	 /* read-only data */
40		*(.rodata.*)
41		_erodata = . ;
42	}
43	.data :	{
44		_data = . ;
45		*(.data)
46		*(.data.*)
47		_edata = . ;
48	}
49	. = ALIGN(CONFIG_X86_L1_CACHE_BYTES);
50	.bss : {
51		_bss = . ;
52		*(.bss)
53		*(.bss.*)
54		*(COMMON)
55		. = ALIGN(8);	/* For convenience during zeroing */
56		_ebss = .;
57	}
58#ifdef CONFIG_X86_64
59       . = ALIGN(PAGE_SIZE);
60       .pgtable : {
61		_pgtable = . ;
62		*(.pgtable)
63		_epgtable = . ;
64	}
65#endif
66	_end = .;
67}
68