2 * ld script to make SuperH Linux kernel
3 * Written by Niibe Yutaka
5 #include <asm/thread_info.h>
7 #include <asm-generic/vmlinux.lds.h>
9 #ifdef CONFIG_CPU_LITTLE_ENDIAN
10 OUTPUT_FORMAT("elf32-sh-linux", "elf32-sh-linux", "elf32-sh-linux")
12 OUTPUT_FORMAT("elf32-shbig-linux", "elf32-shbig-linux", "elf32-shbig-linux")
19 . = CONFIG_PAGE_OFFSET + CONFIG_ZERO_PAGE_OFFSET;
21 . = CONFIG_PAGE_OFFSET + CONFIG_MEMORY_START + CONFIG_ZERO_PAGE_OFFSET;
24 _text = .; /* Text and read-only data */
40 . = ALIGN(16); /* Exception table */
41 __start___ex_table = .;
42 __ex_table : { *(__ex_table) }
43 __stop___ex_table = .;
45 _etext = .; /* End of text section */
52 * Code which must be executed uncached and the associated data
56 .uncached.text : { *(.uncached.text) }
57 .uncached.data : { *(.uncached.data) }
60 . = ALIGN(THREAD_SIZE);
64 . = ALIGN(L1_CACHE_BYTES);
65 *(.data.cacheline_aligned)
67 . = ALIGN(L1_CACHE_BYTES);
82 _edata = .; /* End of data section */
84 . = ALIGN(PAGE_SIZE); /* Init code and data */
87 .init.text : { INIT_TEXT }
89 .init.data : { INIT_DATA }
93 .init.setup : { *(.init.setup) }
101 __con_initcall_start = .;
102 .con_initcall.init : { *(.con_initcall.init) }
103 __con_initcall_end = .;
107 #ifdef CONFIG_BLK_DEV_INITRD
108 . = ALIGN(PAGE_SIZE);
109 __initramfs_start = .;
110 .init.ramfs : { *(.init.ramfs) }
116 .machvec.init : { *(.machvec.init) }
122 * .exit.text is discarded at runtime, not link time, to deal with
123 * references from __bug_table
125 .exit.text : { EXIT_TEXT }
126 .exit.data : { EXIT_DATA }
128 . = ALIGN(PAGE_SIZE);
131 __bss_start = .; /* BSS */
136 _ebss = .; /* uClinux MTD sucks */
141 * When something in the kernel is NOT compiled as a module, the
142 * module cleanup code and data are put into these segments. Both
143 * can then be thrown away, as cleanup code is never called unless