Commit cd4a05f9df859e7cd2efa96e035444a3decb427a
1 parent
13e9f61235
Exists in
master
and in
39 other branches
MXC: rename mxc_map_io to architecture specific versions
This allows us to have more mapping functions for more than one i.MX architecture in the kernel. As this is the earliest board specific hook we have, also use it to set the cpu type. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Showing 16 changed files with 39 additions and 18 deletions Side-by-side Diff
- arch/arm/mach-mx1/generic.c
- arch/arm/mach-mx1/mx1ads.c
- arch/arm/mach-mx1/scb9328.c
- arch/arm/mach-mx2/generic.c
- arch/arm/mach-mx2/mx27ads.c
- arch/arm/mach-mx2/pcm038.c
- arch/arm/mach-mx3/clock-imx35.c
- arch/arm/mach-mx3/clock.c
- arch/arm/mach-mx3/mm.c
- arch/arm/mach-mx3/mx31ads.c
- arch/arm/mach-mx3/mx31lite.c
- arch/arm/mach-mx3/mx31moboard.c
- arch/arm/mach-mx3/mx31pdk.c
- arch/arm/mach-mx3/pcm037.c
- arch/arm/mach-mx3/pcm043.c
- arch/arm/plat-mxc/include/mach/common.h
arch/arm/mach-mx1/generic.c
arch/arm/mach-mx1/mx1ads.c
... | ... | @@ -198,7 +198,7 @@ |
198 | 198 | .phys_io = IMX_IO_PHYS, |
199 | 199 | .io_pg_offst = (IMX_IO_BASE >> 18) & 0xfffc, |
200 | 200 | .boot_params = PHYS_OFFSET + 0x100, |
201 | - .map_io = mxc_map_io, | |
201 | + .map_io = mx1_map_io, | |
202 | 202 | .init_irq = mxc_init_irq, |
203 | 203 | .timer = &mx1ads_timer, |
204 | 204 | .init_machine = mx1ads_init, |
arch/arm/mach-mx1/scb9328.c
... | ... | @@ -153,7 +153,7 @@ |
153 | 153 | .phys_io = 0x00200000, |
154 | 154 | .io_pg_offst = ((0xe0200000) >> 18) & 0xfffc, |
155 | 155 | .boot_params = 0x08000100, |
156 | - .map_io = mxc_map_io, | |
156 | + .map_io = mx1_map_io, | |
157 | 157 | .init_irq = mxc_init_irq, |
158 | 158 | .timer = &scb9328_timer, |
159 | 159 | .init_machine = scb9328_init, |
arch/arm/mach-mx2/generic.c
... | ... | @@ -69,8 +69,17 @@ |
69 | 69 | * system startup to create static physical to virtual |
70 | 70 | * memory map for the IO modules. |
71 | 71 | */ |
72 | -void __init mxc_map_io(void) | |
72 | +void __init mx21_map_io(void) | |
73 | 73 | { |
74 | + mxc_set_cpu_type(MXC_CPU_MX21); | |
75 | + | |
76 | + iotable_init(mxc_io_desc, ARRAY_SIZE(mxc_io_desc)); | |
77 | +} | |
78 | + | |
79 | +void __init mx27_map_io(void) | |
80 | +{ | |
81 | + mxc_set_cpu_type(MXC_CPU_MX27); | |
82 | + | |
74 | 83 | iotable_init(mxc_io_desc, ARRAY_SIZE(mxc_io_desc)); |
75 | 84 | } |
arch/arm/mach-mx2/mx27ads.c
arch/arm/mach-mx2/pcm038.c
... | ... | @@ -295,7 +295,7 @@ |
295 | 295 | .phys_io = AIPI_BASE_ADDR, |
296 | 296 | .io_pg_offst = ((AIPI_BASE_ADDR_VIRT) >> 18) & 0xfffc, |
297 | 297 | .boot_params = PHYS_OFFSET + 0x100, |
298 | - .map_io = mxc_map_io, | |
298 | + .map_io = mx27_map_io, | |
299 | 299 | .init_irq = mxc_init_irq, |
300 | 300 | .init_machine = pcm038_init, |
301 | 301 | .timer = &pcm038_timer, |
arch/arm/mach-mx3/clock-imx35.c
arch/arm/mach-mx3/clock.c
arch/arm/mach-mx3/mm.c
... | ... | @@ -72,8 +72,17 @@ |
72 | 72 | * system startup to create static physical to virtual memory mappings |
73 | 73 | * for the IO modules. |
74 | 74 | */ |
75 | -void __init mxc_map_io(void) | |
75 | +void __init mx31_map_io(void) | |
76 | 76 | { |
77 | + mxc_set_cpu_type(MXC_CPU_MX31); | |
78 | + | |
79 | + iotable_init(mxc_io_desc, ARRAY_SIZE(mxc_io_desc)); | |
80 | +} | |
81 | + | |
82 | +void __init mx35_map_io(void) | |
83 | +{ | |
84 | + mxc_set_cpu_type(MXC_CPU_MX35); | |
85 | + | |
77 | 86 | iotable_init(mxc_io_desc, ARRAY_SIZE(mxc_io_desc)); |
78 | 87 | } |
79 | 88 |
arch/arm/mach-mx3/mx31ads.c
arch/arm/mach-mx3/mx31lite.c
arch/arm/mach-mx3/mx31moboard.c
... | ... | @@ -117,7 +117,7 @@ |
117 | 117 | .phys_io = AIPS1_BASE_ADDR, |
118 | 118 | .io_pg_offst = ((AIPS1_BASE_ADDR_VIRT) >> 18) & 0xfffc, |
119 | 119 | .boot_params = PHYS_OFFSET + 0x100, |
120 | - .map_io = mxc_map_io, | |
120 | + .map_io = mx31_map_io, | |
121 | 121 | .init_irq = mxc_init_irq, |
122 | 122 | .init_machine = mxc_board_init, |
123 | 123 | .timer = &mx31moboard_timer, |
arch/arm/mach-mx3/mx31pdk.c
... | ... | @@ -84,7 +84,7 @@ |
84 | 84 | .phys_io = AIPS1_BASE_ADDR, |
85 | 85 | .io_pg_offst = ((AIPS1_BASE_ADDR_VIRT) >> 18) & 0xfffc, |
86 | 86 | .boot_params = PHYS_OFFSET + 0x100, |
87 | - .map_io = mxc_map_io, | |
87 | + .map_io = mx31_map_io, | |
88 | 88 | .init_irq = mxc_init_irq, |
89 | 89 | .init_machine = mxc_board_init, |
90 | 90 | .timer = &mx31pdk_timer, |
arch/arm/mach-mx3/pcm037.c
... | ... | @@ -309,7 +309,7 @@ |
309 | 309 | .phys_io = AIPS1_BASE_ADDR, |
310 | 310 | .io_pg_offst = ((AIPS1_BASE_ADDR_VIRT) >> 18) & 0xfffc, |
311 | 311 | .boot_params = PHYS_OFFSET + 0x100, |
312 | - .map_io = mxc_map_io, | |
312 | + .map_io = mx31_map_io, | |
313 | 313 | .init_irq = mxc_init_irq, |
314 | 314 | .init_machine = mxc_board_init, |
315 | 315 | .timer = &pcm037_timer, |
arch/arm/mach-mx3/pcm043.c
... | ... | @@ -244,7 +244,7 @@ |
244 | 244 | .phys_io = AIPS1_BASE_ADDR, |
245 | 245 | .io_pg_offst = ((AIPS1_BASE_ADDR_VIRT) >> 18) & 0xfffc, |
246 | 246 | .boot_params = PHYS_OFFSET + 0x100, |
247 | - .map_io = mxc_map_io, | |
247 | + .map_io = mx35_map_io, | |
248 | 248 | .init_irq = mxc_init_irq, |
249 | 249 | .init_machine = mxc_board_init, |
250 | 250 | .timer = &pcm043_timer, |
arch/arm/plat-mxc/include/mach/common.h
... | ... | @@ -14,7 +14,11 @@ |
14 | 14 | struct platform_device; |
15 | 15 | struct clk; |
16 | 16 | |
17 | -extern void mxc_map_io(void); | |
17 | +extern void mx1_map_io(void); | |
18 | +extern void mx21_map_io(void); | |
19 | +extern void mx27_map_io(void); | |
20 | +extern void mx31_map_io(void); | |
21 | +extern void mx35_map_io(void); | |
18 | 22 | extern void mxc_init_irq(void); |
19 | 23 | extern void mxc_timer_init(struct clk *timer_clk); |
20 | 24 | extern int mx1_clocks_init(unsigned long fref); |