ARM: local timers: Add A15 architected timer support
Add support for the A15 generic timer and clocksource.
As the timer generates interrupts on a different PPI depending
on the execution mode (normal or secure), it is possible to
register two different PPIs.
Signed-off-by: Marc Zyngier <marc.zyngier@arm.com>
Conflicts:
[Integrate to the recent patch which has changes to
local timer registration mechanism.
This fixes the crash seen during hotplug operations
where after a secondary CPU is brought back online,
the clock event device setup was happening as part
of the online notification mechanism which was too
late. With this change in the local timer mechanims,
the clock event device is now setup as part of the
secondary CPU boot initialization making it available
early enough for use.
Update the board file with the appropriate changes in
the argument for timer registration.]
arch/arm/Kconfig
arch/arm/include/asm/arch_timer.h
arch/arm/kernel/arch_timer.c
Change-Id: I0bc80097c145fb2aac2150db0c5dff3c5e215a58
Signed-off-by: Sathish Ambley <sambley@codeaurora.org>
diff --git a/arch/arm/mach-msm/board-dt.c b/arch/arm/mach-msm/board-dt.c
index 51ca29d..3fb6042 100644
--- a/arch/arm/mach-msm/board-dt.c
+++ b/arch/arm/mach-msm/board-dt.c
@@ -27,7 +27,7 @@
static void __init msm_dt_timer_init(void)
{
struct device_node *node;
- struct resource res;
+ struct arch_timer tmr;
int rc;
node = of_find_compatible_node(NULL, NULL, "qcom,msm-qtimer");
@@ -36,11 +36,13 @@
return;
}
- rc = of_irq_to_resource(node, 0, &res);
+ tmr.res[0].start = 0;
+ tmr.res[1].start = 0;
+ rc = of_irq_to_resource(node, 0, tmr.res);
if (rc < 0)
pr_err("interrupt not specified in timer node\n");
else
- arch_timer_register(&res, 1);
+ arch_timer_register(&tmr);
of_node_put(node);
}
@@ -49,16 +51,6 @@
.init = msm_dt_timer_init
};
-int __cpuinit local_timer_setup(struct clock_event_device *evt)
-{
- return 0;
-}
-
-void local_timer_stop(void)
-{
- return;
-}
-
static void __init msm_dt_init_irq(void)
{
if (machine_is_copper())