Tim Abbott | 1dc818c | 2009-09-16 16:44:27 -0400 | [diff] [blame] | 1 | #include <asm-generic/vmlinux.lds.h> |
2 | |||||
Linus Torvalds | 51b26ad | 2009-04-26 10:12:47 -0700 | [diff] [blame] | 3 | OUTPUT_FORMAT(CONFIG_OUTPUT_FORMAT, CONFIG_OUTPUT_FORMAT, CONFIG_OUTPUT_FORMAT) |
4 | |||||
Sam Ravnborg | 83c4832 | 2009-04-30 12:03:16 +0200 | [diff] [blame] | 5 | #undef i386 |
6 | |||||
Jan Beulich | 350f8f5 | 2009-11-13 11:54:40 +0000 | [diff] [blame] | 7 | #include <asm/cache.h> |
H. Peter Anvin | 5b11f1c | 2009-05-08 16:20:34 -0700 | [diff] [blame] | 8 | #include <asm/page_types.h> |
9 | |||||
Linus Torvalds | 51b26ad | 2009-04-26 10:12:47 -0700 | [diff] [blame] | 10 | #ifdef CONFIG_X86_64 |
Vivek Goyal | 1ab60e0 | 2007-05-02 19:27:07 +0200 | [diff] [blame] | 11 | OUTPUT_ARCH(i386:x86-64) |
12 | ENTRY(startup_64) | ||||
Linus Torvalds | 51b26ad | 2009-04-26 10:12:47 -0700 | [diff] [blame] | 13 | #else |
14 | OUTPUT_ARCH(i386) | ||||
15 | ENTRY(startup_32) | ||||
16 | #endif | ||||
17 | |||||
Vivek Goyal | 1ab60e0 | 2007-05-02 19:27:07 +0200 | [diff] [blame] | 18 | SECTIONS |
19 | { | ||||
Yinghai Lu | 32ed937 | 2008-02-01 17:49:41 +0100 | [diff] [blame] | 20 | /* Be careful parts of head_64.S assume startup_32 is at |
Ian Campbell | afe0bc6 | 2008-01-30 13:33:37 +0100 | [diff] [blame] | 21 | * address 0. |
Vivek Goyal | 1ab60e0 | 2007-05-02 19:27:07 +0200 | [diff] [blame] | 22 | */ |
23 | . = 0; | ||||
Tim Abbott | 1dc818c | 2009-09-16 16:44:27 -0400 | [diff] [blame] | 24 | .head.text : { |
Vivek Goyal | 1ab60e0 | 2007-05-02 19:27:07 +0200 | [diff] [blame] | 25 | _head = . ; |
Tim Abbott | 1dc818c | 2009-09-16 16:44:27 -0400 | [diff] [blame] | 26 | HEAD_TEXT |
Vivek Goyal | 1ab60e0 | 2007-05-02 19:27:07 +0200 | [diff] [blame] | 27 | _ehead = . ; |
Ian Campbell | 20514e9 | 2008-01-30 13:33:38 +0100 | [diff] [blame] | 28 | } |
29 | .rodata.compressed : { | ||||
30 | *(.rodata.compressed) | ||||
31 | } | ||||
32 | .text : { | ||||
Vivek Goyal | 1ab60e0 | 2007-05-02 19:27:07 +0200 | [diff] [blame] | 33 | _text = .; /* Text */ |
34 | *(.text) | ||||
35 | *(.text.*) | ||||
36 | _etext = . ; | ||||
37 | } | ||||
38 | .rodata : { | ||||
39 | _rodata = . ; | ||||
40 | *(.rodata) /* read-only data */ | ||||
41 | *(.rodata.*) | ||||
42 | _erodata = . ; | ||||
43 | } | ||||
44 | .data : { | ||||
45 | _data = . ; | ||||
46 | *(.data) | ||||
47 | *(.data.*) | ||||
48 | _edata = . ; | ||||
49 | } | ||||
Jan Beulich | 350f8f5 | 2009-11-13 11:54:40 +0000 | [diff] [blame] | 50 | . = ALIGN(L1_CACHE_BYTES); |
Vivek Goyal | 1ab60e0 | 2007-05-02 19:27:07 +0200 | [diff] [blame] | 51 | .bss : { |
52 | _bss = . ; | ||||
53 | *(.bss) | ||||
54 | *(.bss.*) | ||||
55 | *(COMMON) | ||||
H. Peter Anvin | 5b11f1c | 2009-05-08 16:20:34 -0700 | [diff] [blame] | 56 | . = ALIGN(8); /* For convenience during zeroing */ |
Yinghai Lu | 4a9f54c | 2008-04-10 15:06:38 -0700 | [diff] [blame] | 57 | _ebss = .; |
Vivek Goyal | 1ab60e0 | 2007-05-02 19:27:07 +0200 | [diff] [blame] | 58 | } |
H. Peter Anvin | 5b11f1c | 2009-05-08 16:20:34 -0700 | [diff] [blame] | 59 | #ifdef CONFIG_X86_64 |
60 | . = ALIGN(PAGE_SIZE); | ||||
61 | .pgtable : { | ||||
62 | _pgtable = . ; | ||||
63 | *(.pgtable) | ||||
64 | _epgtable = . ; | ||||
65 | } | ||||
66 | #endif | ||||
67 | _end = .; | ||||
Vivek Goyal | 1ab60e0 | 2007-05-02 19:27:07 +0200 | [diff] [blame] | 68 | } |