diff options
author | Jesper Nilsson <jesper.nilsson@axis.com> | 2008-10-22 17:57:53 -0400 |
---|---|---|
committer | Jesper Nilsson <jesper.nilsson@axis.com> | 2008-10-31 18:37:57 -0400 |
commit | c5ec6fb08d7806cf1a9e4fceed15f5d4a69f885e (patch) | |
tree | e3a1dca7bb4ea58907c067f592ce45391222ffc4 /arch/cris/arch-v32 | |
parent | 0365f707c99bf940a51c2a3ffc19f3ade2f700d4 (diff) |
[CRIS] Remove links from CRIS build
Remove the links to architecture and machine dependent directories
(boot, lib, drivers, arch, mach)
The links were created and used mostly from the arch/cris/Makefile,
so why not dispense with them altogether?
Changed $(ARCH) to "cris" in Makefile, it is easier to read this way.
The CRISv32 head.S common files for the kernel and compressed images
needed to be modified to use ifdefs instead of using the now removed
mach link. Since there are only two versions, this is not a huge loss
in readability.
The link to vmlinux.lds.S is also replaced with a merged version
which uses ifdefs to select the correct layout.
System.map before and after are identical.
Signed-off-by: Jesper Nilsson <jesper.nilsson@axis.com>
Acked-by: Sam Ravnborg <sam@ravnborg.org>
Diffstat (limited to 'arch/cris/arch-v32')
-rw-r--r-- | arch/cris/arch-v32/boot/compressed/head.S | 16 | ||||
-rw-r--r-- | arch/cris/arch-v32/kernel/head.S | 20 | ||||
-rw-r--r-- | arch/cris/arch-v32/vmlinux.lds.S | 133 |
3 files changed, 31 insertions, 138 deletions
diff --git a/arch/cris/arch-v32/boot/compressed/head.S b/arch/cris/arch-v32/boot/compressed/head.S index ea3012993b0..a4a65c5c669 100644 --- a/arch/cris/arch-v32/boot/compressed/head.S +++ b/arch/cris/arch-v32/boot/compressed/head.S | |||
@@ -28,7 +28,13 @@ _start: | |||
28 | beq dram_init_finished | 28 | beq dram_init_finished |
29 | nop | 29 | nop |
30 | 30 | ||
31 | #include "../../mach/dram_init.S" | 31 | #if defined CONFIG_ETRAXFS |
32 | #include "../../mach-fs/dram_init.S" | ||
33 | #elif defined CONFIG_CRIS_MACH_ARTPEC3 | ||
34 | #include "../../mach-a3/dram_init.S" | ||
35 | #else | ||
36 | #error Only ETRAXFS and ARTPEC-3 supported! | ||
37 | #endif | ||
32 | 38 | ||
33 | dram_init_finished: | 39 | dram_init_finished: |
34 | 40 | ||
@@ -130,4 +136,10 @@ _cmd_line_addr: | |||
130 | _boot_source: | 136 | _boot_source: |
131 | .dword 0 | 137 | .dword 0 |
132 | 138 | ||
133 | #include "../../mach/hw_settings.S" | 139 | #if defined CONFIG_ETRAXFS |
140 | #include "../../mach-fs/hw_settings.S" | ||
141 | #elif defined CONFIG_CRIS_MACH_ARTPEC3 | ||
142 | #include "../../mach-a3/hw_settings.S" | ||
143 | #else | ||
144 | #error Only ETRAXFS and ARTPEC-3 supported! | ||
145 | #endif | ||
diff --git a/arch/cris/arch-v32/kernel/head.S b/arch/cris/arch-v32/kernel/head.S index f902d87fb5d..3db478eb515 100644 --- a/arch/cris/arch-v32/kernel/head.S +++ b/arch/cris/arch-v32/kernel/head.S | |||
@@ -10,8 +10,9 @@ | |||
10 | * The macros found in mmu_defs_asm.h uses the ## concatenation operator, so | 10 | * The macros found in mmu_defs_asm.h uses the ## concatenation operator, so |
11 | * -traditional must not be used when assembling this file. | 11 | * -traditional must not be used when assembling this file. |
12 | */ | 12 | */ |
13 | #include <hwregs/reg_rdwr.h> | 13 | #include <linux/autoconf.h> |
14 | #include <arch/memmap.h> | 14 | #include <arch/memmap.h> |
15 | #include <hwregs/reg_rdwr.h> | ||
15 | #include <hwregs/intr_vect.h> | 16 | #include <hwregs/intr_vect.h> |
16 | #include <hwregs/asm/mmu_defs_asm.h> | 17 | #include <hwregs/asm/mmu_defs_asm.h> |
17 | #include <hwregs/asm/reg_map_asm.h> | 18 | #include <hwregs/asm/reg_map_asm.h> |
@@ -217,7 +218,14 @@ _inflash: | |||
217 | beq _dram_initialized | 218 | beq _dram_initialized |
218 | nop | 219 | nop |
219 | 220 | ||
220 | #include "../mach/dram_init.S" | 221 | #if defined CONFIG_ETRAXFS |
222 | #include "../mach-fs/dram_init.S" | ||
223 | #elif defined CONFIG_CRIS_MACH_ARTPEC3 | ||
224 | #include "../mach-a3/dram_init.S" | ||
225 | #else | ||
226 | #error Only ETRAXFS and ARTPEC-3 supported! | ||
227 | #endif | ||
228 | |||
221 | 229 | ||
222 | _dram_initialized: | 230 | _dram_initialized: |
223 | ;; Copy the text and data section to DRAM. This depends on that the | 231 | ;; Copy the text and data section to DRAM. This depends on that the |
@@ -472,4 +480,10 @@ swapper_pg_dir = 0xc0002000 | |||
472 | 480 | ||
473 | .section ".init.data", "aw" | 481 | .section ".init.data", "aw" |
474 | 482 | ||
475 | #include "../mach/hw_settings.S" | 483 | #if defined CONFIG_ETRAXFS |
484 | #include "../mach-fs/hw_settings.S" | ||
485 | #elif defined CONFIG_CRIS_MACH_ARTPEC3 | ||
486 | #include "../mach-a3/hw_settings.S" | ||
487 | #else | ||
488 | #error Only ETRAXFS and ARTPEC-3 supported! | ||
489 | #endif | ||
diff --git a/arch/cris/arch-v32/vmlinux.lds.S b/arch/cris/arch-v32/vmlinux.lds.S deleted file mode 100644 index d5f28e40717..00000000000 --- a/arch/cris/arch-v32/vmlinux.lds.S +++ /dev/null | |||
@@ -1,133 +0,0 @@ | |||
1 | /* ld script to make the Linux/CRIS kernel | ||
2 | * Authors: Bjorn Wesen (bjornw@axis.com) | ||
3 | * | ||
4 | * It is VERY DANGEROUS to fiddle around with the symbols in this | ||
5 | * script. It is for example quite vital that all generated sections | ||
6 | * that are used are actually named here, otherwise the linker will | ||
7 | * put them at the end, where the init stuff is which is FREED after | ||
8 | * the kernel has booted. | ||
9 | */ | ||
10 | |||
11 | #include <asm-generic/vmlinux.lds.h> | ||
12 | #include <asm/page.h> | ||
13 | |||
14 | #ifdef CONFIG_ETRAX_VMEM_SIZE | ||
15 | #define __CONFIG_ETRAX_VMEM_SIZE CONFIG_ETRAX_VMEM_SIZE | ||
16 | #else | ||
17 | #define __CONFIG_ETRAX_VMEM_SIZE 0 | ||
18 | #endif | ||
19 | |||
20 | jiffies = jiffies_64; | ||
21 | SECTIONS | ||
22 | { | ||
23 | . = DRAM_VIRTUAL_BASE; | ||
24 | dram_start = .; | ||
25 | ebp_start = .; | ||
26 | |||
27 | /* The boot section is only necessary until the VCS top */ | ||
28 | /* level testbench includes both flash and DRAM. */ | ||
29 | .boot : { *(.boot) } | ||
30 | |||
31 | /* See head.S and pages reserved at the start. */ | ||
32 | . = DRAM_VIRTUAL_BASE + 0x4000; | ||
33 | |||
34 | _text = .; /* Text and read-only data. */ | ||
35 | text_start = .; /* Lots of aliases. */ | ||
36 | _stext = .; | ||
37 | __stext = .; | ||
38 | .text : { | ||
39 | TEXT_TEXT | ||
40 | SCHED_TEXT | ||
41 | LOCK_TEXT | ||
42 | *(.fixup) | ||
43 | *(.text.__*) | ||
44 | } | ||
45 | |||
46 | _etext = . ; /* End of text section. */ | ||
47 | __etext = .; | ||
48 | |||
49 | . = ALIGN(4); /* Exception table. */ | ||
50 | __start___ex_table = .; | ||
51 | __ex_table : { *(__ex_table) } | ||
52 | __stop___ex_table = .; | ||
53 | |||
54 | RODATA | ||
55 | |||
56 | . = ALIGN (4); | ||
57 | ___data_start = . ; | ||
58 | __Sdata = . ; | ||
59 | .data : { /* Data */ | ||
60 | DATA_DATA | ||
61 | } | ||
62 | __edata = . ; /* End of data section. */ | ||
63 | _edata = . ; | ||
64 | |||
65 | . = ALIGN(PAGE_SIZE); /* init_task and stack, must be aligned. */ | ||
66 | .data.init_task : { *(.data.init_task) } | ||
67 | |||
68 | . = ALIGN(PAGE_SIZE); /* Init code and data. */ | ||
69 | __init_begin = .; | ||
70 | .init.text : { | ||
71 | _sinittext = .; | ||
72 | INIT_TEXT | ||
73 | _einittext = .; | ||
74 | } | ||
75 | .init.data : { INIT_DATA } | ||
76 | . = ALIGN(16); | ||
77 | __setup_start = .; | ||
78 | .init.setup : { *(.init.setup) } | ||
79 | __setup_end = .; | ||
80 | __start___param = .; | ||
81 | __param : { *(__param) } | ||
82 | __stop___param = .; | ||
83 | .initcall.init : { | ||
84 | __initcall_start = .; | ||
85 | INITCALLS | ||
86 | __initcall_end = .; | ||
87 | } | ||
88 | |||
89 | .con_initcall.init : { | ||
90 | __con_initcall_start = .; | ||
91 | *(.con_initcall.init) | ||
92 | __con_initcall_end = .; | ||
93 | } | ||
94 | SECURITY_INIT | ||
95 | |||
96 | __vmlinux_end = .; /* Last address of the physical file. */ | ||
97 | PERCPU(PAGE_SIZE) | ||
98 | |||
99 | .init.ramfs : { | ||
100 | __initramfs_start = .; | ||
101 | *(.init.ramfs) | ||
102 | __initramfs_end = .; | ||
103 | } | ||
104 | |||
105 | /* | ||
106 | * We fill to the next page, so we can discard all init | ||
107 | * pages without needing to consider what payload might be | ||
108 | * appended to the kernel image. | ||
109 | */ | ||
110 | . = ALIGN (PAGE_SIZE); | ||
111 | |||
112 | __init_end = .; | ||
113 | |||
114 | __data_end = . ; /* Move to _edata? */ | ||
115 | __bss_start = .; /* BSS. */ | ||
116 | .bss : { | ||
117 | *(COMMON) | ||
118 | *(.bss) | ||
119 | } | ||
120 | |||
121 | . = ALIGN (0x20); | ||
122 | _end = .; | ||
123 | __end = .; | ||
124 | |||
125 | /* Sections to be discarded */ | ||
126 | /DISCARD/ : { | ||
127 | EXIT_TEXT | ||
128 | EXIT_DATA | ||
129 | *(.exitcall.exit) | ||
130 | } | ||
131 | |||
132 | dram_end = dram_start + (CONFIG_ETRAX_DRAM_SIZE - __CONFIG_ETRAX_VMEM_SIZE)*1024*1024; | ||
133 | } | ||