Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 1 | /* ld script to make m68k Linux kernel */ |
| 2 | |
| 3 | #include <asm-generic/vmlinux.lds.h> |
Cyrill Gorcunov | 97d26e7 | 2008-07-17 21:16:11 +0200 | [diff] [blame] | 4 | #include <asm/page.h> |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 5 | |
| 6 | OUTPUT_FORMAT("elf32-m68k", "elf32-m68k", "elf32-m68k") |
| 7 | OUTPUT_ARCH(m68k) |
| 8 | ENTRY(_start) |
| 9 | jiffies = jiffies_64 + 4; |
| 10 | SECTIONS |
| 11 | { |
| 12 | . = 0x1000; |
| 13 | _text = .; /* Text and read-only data */ |
| 14 | .text : { |
Tim Abbott | 6f335ca | 2009-04-25 22:11:03 -0400 | [diff] [blame] | 15 | HEAD_TEXT |
Sam Ravnborg | 7664709 | 2007-05-13 00:31:33 +0200 | [diff] [blame] | 16 | TEXT_TEXT |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 17 | SCHED_TEXT |
Al Viro | 198a410 | 2006-01-12 01:06:11 -0800 | [diff] [blame] | 18 | LOCK_TEXT |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 19 | *(.fixup) |
| 20 | *(.gnu.warning) |
| 21 | } :text = 0x4e75 |
| 22 | |
Roman Zippel | fe6d9da | 2007-08-22 14:01:33 -0700 | [diff] [blame] | 23 | _etext = .; /* End of text section */ |
| 24 | |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 25 | . = ALIGN(16); /* Exception table */ |
| 26 | __start___ex_table = .; |
| 27 | __ex_table : { *(__ex_table) } |
| 28 | __stop___ex_table = .; |
| 29 | |
| 30 | RODATA |
| 31 | |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 32 | .data : { /* Data */ |
Sam Ravnborg | ca96725 | 2007-05-17 13:38:44 +0200 | [diff] [blame] | 33 | DATA_DATA |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 34 | CONSTRUCTORS |
| 35 | } |
| 36 | |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 37 | . = ALIGN(16); |
Roman Zippel | 68abcee | 2008-10-13 21:58:49 +0200 | [diff] [blame] | 38 | .data.cacheline_aligned : { *(.data.cacheline_aligned) } |
| 39 | |
| 40 | .bss : { *(.bss) } /* BSS */ |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 41 | |
| 42 | _edata = .; /* End of data section */ |
| 43 | |
| 44 | /* will be freed after init */ |
Cyrill Gorcunov | 97d26e7 | 2008-07-17 21:16:11 +0200 | [diff] [blame] | 45 | . = ALIGN(PAGE_SIZE); /* Init code and data */ |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 46 | __init_begin = .; |
| 47 | .init.text : { |
| 48 | _sinittext = .; |
Sam Ravnborg | 01ba2bd | 2008-01-20 14:15:03 +0100 | [diff] [blame] | 49 | INIT_TEXT |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 50 | _einittext = .; |
Roman Zippel | 68abcee | 2008-10-13 21:58:49 +0200 | [diff] [blame] | 51 | } :data |
Sam Ravnborg | 01ba2bd | 2008-01-20 14:15:03 +0100 | [diff] [blame] | 52 | .init.data : { INIT_DATA } |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 53 | . = ALIGN(16); |
| 54 | __setup_start = .; |
| 55 | .init.setup : { *(.init.setup) } |
| 56 | __setup_end = .; |
| 57 | __initcall_start = .; |
| 58 | .initcall.init : { |
Geert Uytterhoeven | 5fdb51a | 2006-10-29 11:21:51 +0100 | [diff] [blame] | 59 | INITCALLS |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 60 | } |
| 61 | __initcall_end = .; |
| 62 | __con_initcall_start = .; |
| 63 | .con_initcall.init : { *(.con_initcall.init) } |
| 64 | __con_initcall_end = .; |
Roman Zippel | fbe9c96 | 2007-05-31 00:40:50 -0700 | [diff] [blame] | 65 | .m68k_fixup : { |
| 66 | __start_fixup = .; |
| 67 | *(.m68k_fixup) |
| 68 | __stop_fixup = .; |
| 69 | } |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 70 | SECURITY_INIT |
Jean-Paul Saman | 67d3822 | 2007-02-10 01:44:44 -0800 | [diff] [blame] | 71 | #ifdef CONFIG_BLK_DEV_INITRD |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 72 | . = ALIGN(8192); |
| 73 | __initramfs_start = .; |
| 74 | .init.ramfs : { *(.init.ramfs) } |
| 75 | __initramfs_end = .; |
Jean-Paul Saman | 67d3822 | 2007-02-10 01:44:44 -0800 | [diff] [blame] | 76 | #endif |
Roman Zippel | 08a3db9 | 2008-10-13 21:58:50 +0200 | [diff] [blame] | 77 | NOTES |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 78 | . = ALIGN(8192); |
| 79 | __init_end = .; |
| 80 | |
| 81 | .data.init_task : { *(.data.init_task) } /* The initial task and kernel stack */ |
| 82 | |
| 83 | _end = . ; |
| 84 | |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 85 | /* Stabs debugging sections. */ |
| 86 | .stab 0 : { *(.stab) } |
| 87 | .stabstr 0 : { *(.stabstr) } |
| 88 | .stab.excl 0 : { *(.stab.excl) } |
| 89 | .stab.exclstr 0 : { *(.stab.exclstr) } |
| 90 | .stab.index 0 : { *(.stab.index) } |
| 91 | .stab.indexstr 0 : { *(.stab.indexstr) } |
| 92 | .comment 0 : { *(.comment) } |
Tejun Heo | 023bf6f | 2009-07-09 11:27:40 +0900 | [diff] [blame^] | 93 | |
| 94 | /* Sections to be discarded */ |
| 95 | DISCARDS |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 96 | } |