diff options
author | Linus Walleij <linus.walleij@linaro.org> | 2013-04-22 11:29:30 +0200 |
---|---|---|
committer | Linus Walleij <linus.walleij@linaro.org> | 2013-06-17 13:54:30 +0200 |
commit | 75a7f3f18e0deee2023351789cc3c393f07220c7 (patch) | |
tree | b74a90f572f10c6c54b90f9eddb2c1419c5d3ff2 /arch/arm/mach-u300/timer.c | |
parent | d134636f370070f0aa43bb4b145ed60c440eff17 (diff) |
ARM: u300: delete all static board data
We have now transferred all the U300 peripherals to the device
tree, so we just select USE_OF, and delete all static board data,
then require that this platform shall be booted using the device
tree and nothing else.
This gets rid of the MMCI (PL180), PL022, and serial PL011
platform data entries and more.
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
Diffstat (limited to 'arch/arm/mach-u300/timer.c')
-rw-r--r-- | arch/arm/mach-u300/timer.c | 38 |
1 files changed, 12 insertions, 26 deletions
diff --git a/arch/arm/mach-u300/timer.c b/arch/arm/mach-u300/timer.c index df1e3b5427b..f3efef0c5db 100644 --- a/arch/arm/mach-u300/timer.c +++ b/arch/arm/mach-u300/timer.c @@ -30,8 +30,6 @@ #include <asm/mach/map.h> #include <asm/mach/time.h> -#include "timer.h" - /* * APP side special timer registers * This timer contains four timers which can fire an interrupt each. @@ -361,12 +359,22 @@ static struct delay_timer u300_delay_timer; /* * This sets up the system timers, clock source and clock event. */ -static void __init u300_timer_setup(void __iomem *base, int irq) +static void __init u300_timer_init_of(struct device_node *np) { + struct resource irq_res; + int irq; struct clk *clk; unsigned long rate; - u300_timer_base = base; + u300_timer_base = of_iomap(np, 0); + if (!u300_timer_base) + panic("could not ioremap system timer\n"); + + /* Get the IRQ for the GP1 timer */ + irq = of_irq_to_resource(np, 2, &irq_res); + if (irq <= 0) + panic("no IRQ for system timer\n"); + pr_info("U300 GP1 timer @ base: %p, IRQ: %d\n", u300_timer_base, irq); /* Clock the interrupt controller */ @@ -433,27 +441,5 @@ static void __init u300_timer_setup(void __iomem *base, int irq) */ } - -void __init u300_timer_init() -{ - u300_timer_setup(U300_TIMER_APP_VBASE, IRQ_U300_TIMER_APP_GP1); -} - -#ifdef CONFIG_OF - -static void __init u300_timer_init_of(struct device_node *np) -{ - void __iomem *base; - struct resource irq_res; - int irq; - - base = of_iomap(np, 0); - /* Get the IRQ for the GP1 timer */ - irq = of_irq_to_resource(np, 2, &irq_res); - u300_timer_setup(base, irq); -} - CLOCKSOURCE_OF_DECLARE(u300_timer, "stericsson,u300-apptimer", u300_timer_init_of); - -#endif |