diff options
author | Rabin Vincent <rabin.vincent@stericsson.com> | 2010-02-28 23:03:31 -0500 |
---|---|---|
committer | Russell King <rmk+kernel@arm.linux.org.uk> | 2010-03-19 14:29:44 -0400 |
commit | cc2c13342508d52cf08ea81f639b5de69607fd5d (patch) | |
tree | 9dc95cddf0db231f714b583d41872f5682c7fa10 /arch/arm/mach-ux500 | |
parent | 3e3c62ca5395df48319b808379bc9fd487ff3c29 (diff) |
ARM: 5962/1: ux500: move system timer to cpu file
There is nothing board-specific about the system timer, so move it to
the CPU file.
Acked-by: Linus Walleij <linus.walleij@stericsson.com>
Acked-by: Srinidhi Kasagar <srinidhi.kasagar@stericsson.com>
Signed-off-by: Rabin Vincent <rabin.vincent@stericsson.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
Diffstat (limited to 'arch/arm/mach-ux500')
-rw-r--r-- | arch/arm/mach-ux500/board-mop500.c | 18 | ||||
-rw-r--r-- | arch/arm/mach-ux500/cpu-u8500.c | 20 | ||||
-rw-r--r-- | arch/arm/mach-ux500/include/mach/setup.h | 3 |
3 files changed, 23 insertions, 18 deletions
diff --git a/arch/arm/mach-ux500/board-mop500.c b/arch/arm/mach-ux500/board-mop500.c index 803aec1d6728..c2b4a35cf01b 100644 --- a/arch/arm/mach-ux500/board-mop500.c +++ b/arch/arm/mach-ux500/board-mop500.c | |||
@@ -17,11 +17,9 @@ | |||
17 | #include <linux/amba/pl022.h> | 17 | #include <linux/amba/pl022.h> |
18 | #include <linux/spi/spi.h> | 18 | #include <linux/spi/spi.h> |
19 | 19 | ||
20 | #include <asm/localtimer.h> | ||
21 | #include <asm/mach-types.h> | 20 | #include <asm/mach-types.h> |
22 | #include <asm/mach/arch.h> | 21 | #include <asm/mach/arch.h> |
23 | 22 | ||
24 | #include <plat/mtu.h> | ||
25 | #include <plat/i2c.h> | 23 | #include <plat/i2c.h> |
26 | 24 | ||
27 | #include <mach/hardware.h> | 25 | #include <mach/hardware.h> |
@@ -201,22 +199,6 @@ static struct platform_device *platform_devs[] __initdata = { | |||
201 | &i2c_controller3, | 199 | &i2c_controller3, |
202 | }; | 200 | }; |
203 | 201 | ||
204 | static void __init u8500_timer_init(void) | ||
205 | { | ||
206 | #ifdef CONFIG_LOCAL_TIMERS | ||
207 | /* Setup the local timer base */ | ||
208 | twd_base = __io_address(U8500_TWD_BASE); | ||
209 | #endif | ||
210 | /* Setup the MTU base */ | ||
211 | mtu_base = __io_address(U8500_MTU0_BASE); | ||
212 | |||
213 | nmdk_timer_init(); | ||
214 | } | ||
215 | |||
216 | static struct sys_timer u8500_timer = { | ||
217 | .init = u8500_timer_init, | ||
218 | }; | ||
219 | |||
220 | static void __init u8500_init_machine(void) | 202 | static void __init u8500_init_machine(void) |
221 | { | 203 | { |
222 | int i; | 204 | int i; |
diff --git a/arch/arm/mach-ux500/cpu-u8500.c b/arch/arm/mach-ux500/cpu-u8500.c index 397bc1f9ed94..588b0596a635 100644 --- a/arch/arm/mach-ux500/cpu-u8500.c +++ b/arch/arm/mach-ux500/cpu-u8500.c | |||
@@ -14,10 +14,14 @@ | |||
14 | #include <linux/amba/bus.h> | 14 | #include <linux/amba/bus.h> |
15 | #include <linux/irq.h> | 15 | #include <linux/irq.h> |
16 | #include <linux/platform_device.h> | 16 | #include <linux/platform_device.h> |
17 | #include <linux/io.h> | ||
17 | 18 | ||
19 | #include <asm/localtimer.h> | ||
18 | #include <asm/hardware/gic.h> | 20 | #include <asm/hardware/gic.h> |
19 | #include <asm/mach/map.h> | 21 | #include <asm/mach/map.h> |
22 | #include <plat/mtu.h> | ||
20 | #include <mach/hardware.h> | 23 | #include <mach/hardware.h> |
24 | #include <mach/setup.h> | ||
21 | 25 | ||
22 | /* add any platform devices here - TODO */ | 26 | /* add any platform devices here - TODO */ |
23 | static struct platform_device *platform_devs[] __initdata = { | 27 | static struct platform_device *platform_devs[] __initdata = { |
@@ -63,3 +67,19 @@ void __init u8500_init_devices(void) | |||
63 | 67 | ||
64 | return ; | 68 | return ; |
65 | } | 69 | } |
70 | |||
71 | static void __init u8500_timer_init(void) | ||
72 | { | ||
73 | #ifdef CONFIG_LOCAL_TIMERS | ||
74 | /* Setup the local timer base */ | ||
75 | twd_base = __io_address(U8500_TWD_BASE); | ||
76 | #endif | ||
77 | /* Setup the MTU base */ | ||
78 | mtu_base = __io_address(U8500_MTU0_BASE); | ||
79 | |||
80 | nmdk_timer_init(); | ||
81 | } | ||
82 | |||
83 | struct sys_timer u8500_timer = { | ||
84 | .init = u8500_timer_init, | ||
85 | }; | ||
diff --git a/arch/arm/mach-ux500/include/mach/setup.h b/arch/arm/mach-ux500/include/mach/setup.h index cf0ce1687f24..65112bfd7a0c 100644 --- a/arch/arm/mach-ux500/include/mach/setup.h +++ b/arch/arm/mach-ux500/include/mach/setup.h | |||
@@ -20,4 +20,7 @@ extern void u8500_init_irq(void); | |||
20 | /* We re-use nomadik_timer for this platform */ | 20 | /* We re-use nomadik_timer for this platform */ |
21 | extern void nmdk_timer_init(void); | 21 | extern void nmdk_timer_init(void); |
22 | 22 | ||
23 | struct sys_timer; | ||
24 | extern struct sys_timer u8500_timer; | ||
25 | |||
23 | #endif /* __ASM_ARCH_SETUP_H */ | 26 | #endif /* __ASM_ARCH_SETUP_H */ |