blob: d0993594f558b3408317aede57c634c407ea580f [file] [log] [blame]
Linus Torvalds1da177e2005-04-16 15:20:36 -07001/* ld script to make m68k Linux kernel */
2
3#include <asm-generic/vmlinux.lds.h>
Cyrill Gorcunov97d26e72008-07-17 21:16:11 +02004#include <asm/page.h>
Tim Abbott7c5fd562009-09-27 13:57:55 -04005#include <asm/thread_info.h>
Linus Torvalds1da177e2005-04-16 15:20:36 -07006
7OUTPUT_FORMAT("elf32-m68k", "elf32-m68k", "elf32-m68k")
8OUTPUT_ARCH(m68k)
9ENTRY(_start)
10jiffies = jiffies_64 + 4;
11SECTIONS
12{
13 . = 0x1000;
14 _text = .; /* Text and read-only data */
15 .text : {
Tim Abbott6f335ca2009-04-25 22:11:03 -040016 HEAD_TEXT
Sam Ravnborg76647092007-05-13 00:31:33 +020017 TEXT_TEXT
Linus Torvalds1da177e2005-04-16 15:20:36 -070018 SCHED_TEXT
Al Viro198a4102006-01-12 01:06:11 -080019 LOCK_TEXT
Linus Torvalds1da177e2005-04-16 15:20:36 -070020 *(.fixup)
21 *(.gnu.warning)
22 } :text = 0x4e75
23
Roman Zippelfe6d9da2007-08-22 14:01:33 -070024 _etext = .; /* End of text section */
25
Tim Abbott7c5fd562009-09-27 13:57:55 -040026 EXCEPTION_TABLE(16)
Linus Torvalds1da177e2005-04-16 15:20:36 -070027
Steven Rostedta2d063a2011-05-19 21:34:58 -040028 _sdata = .; /* Start of data section */
29
Linus Torvalds1da177e2005-04-16 15:20:36 -070030 RODATA
31
Tim Abbott7c5fd562009-09-27 13:57:55 -040032 RW_DATA_SECTION(16, PAGE_SIZE, THREAD_SIZE)
Linus Torvalds1da177e2005-04-16 15:20:36 -070033
Tim Abbott7c5fd562009-09-27 13:57:55 -040034 BSS_SECTION(0, 0, 0)
Linus Torvalds1da177e2005-04-16 15:20:36 -070035
36 _edata = .; /* End of data section */
37
38 /* will be freed after init */
Cyrill Gorcunov97d26e72008-07-17 21:16:11 +020039 . = ALIGN(PAGE_SIZE); /* Init code and data */
Linus Torvalds1da177e2005-04-16 15:20:36 -070040 __init_begin = .;
Tim Abbott7c5fd562009-09-27 13:57:55 -040041 INIT_TEXT_SECTION(PAGE_SIZE) :data
42 INIT_DATA_SECTION(16)
Roman Zippelfbe9c962007-05-31 00:40:50 -070043 .m68k_fixup : {
44 __start_fixup = .;
45 *(.m68k_fixup)
46 __stop_fixup = .;
47 }
Roman Zippel08a3db92008-10-13 21:58:50 +020048 NOTES
Tim Abbott7c5fd562009-09-27 13:57:55 -040049 .init_end : {
50 /* This ALIGN be in a section so that _end is at the end of the
51 load segment. */
52 . = ALIGN(PAGE_SIZE);
53 __init_end = .;
54 }
Linus Torvalds1da177e2005-04-16 15:20:36 -070055
56 _end = . ;
57
Tim Abbott7c5fd562009-09-27 13:57:55 -040058 STABS_DEBUG
Linus Torvalds1da177e2005-04-16 15:20:36 -070059 .comment 0 : { *(.comment) }
Tejun Heo023bf6f2009-07-09 11:27:40 +090060
61 /* Sections to be discarded */
62 DISCARDS
Linus Torvalds1da177e2005-04-16 15:20:36 -070063}