diff options
Diffstat (limited to 'arch')
-rw-r--r-- | arch/arm/boot/dts/omap4.dtsi | 6 | ||||
-rw-r--r-- | arch/arm/mach-omap2/timer.c | 6 |
2 files changed, 12 insertions, 0 deletions
diff --git a/arch/arm/boot/dts/omap4.dtsi b/arch/arm/boot/dts/omap4.dtsi index cb18d2a2971c..2b670ab86eae 100644 --- a/arch/arm/boot/dts/omap4.dtsi +++ b/arch/arm/boot/dts/omap4.dtsi | |||
@@ -45,6 +45,12 @@ | |||
45 | cache-level = <2>; | 45 | cache-level = <2>; |
46 | }; | 46 | }; |
47 | 47 | ||
48 | local-timer@0x48240600 { | ||
49 | compatible = "arm,cortex-a9-twd-timer"; | ||
50 | reg = <0x48240600 0x20>; | ||
51 | interrupts = <1 13 0x304>; | ||
52 | }; | ||
53 | |||
48 | /* | 54 | /* |
49 | * The soc node represents the soc top level view. It is uses for IPs | 55 | * The soc node represents the soc top level view. It is uses for IPs |
50 | * that are not memory mapped in the MPU view or for the MPU itself. | 56 | * that are not memory mapped in the MPU view or for the MPU itself. |
diff --git a/arch/arm/mach-omap2/timer.c b/arch/arm/mach-omap2/timer.c index 2ff6d41ec6c6..31f9c936125f 100644 --- a/arch/arm/mach-omap2/timer.c +++ b/arch/arm/mach-omap2/timer.c | |||
@@ -36,6 +36,7 @@ | |||
36 | #include <linux/clocksource.h> | 36 | #include <linux/clocksource.h> |
37 | #include <linux/clockchips.h> | 37 | #include <linux/clockchips.h> |
38 | #include <linux/slab.h> | 38 | #include <linux/slab.h> |
39 | #include <linux/of.h> | ||
39 | 40 | ||
40 | #include <asm/mach/time.h> | 41 | #include <asm/mach/time.h> |
41 | #include <plat/dmtimer.h> | 42 | #include <plat/dmtimer.h> |
@@ -386,6 +387,11 @@ static void __init omap4_timer_init(void) | |||
386 | if (omap_rev() != OMAP4430_REV_ES1_0) { | 387 | if (omap_rev() != OMAP4430_REV_ES1_0) { |
387 | int err; | 388 | int err; |
388 | 389 | ||
390 | if (of_have_populated_dt()) { | ||
391 | twd_local_timer_of_register(); | ||
392 | return; | ||
393 | } | ||
394 | |||
389 | err = twd_local_timer_register(&twd_local_timer); | 395 | err = twd_local_timer_register(&twd_local_timer); |
390 | if (err) | 396 | if (err) |
391 | pr_err("twd_local_timer_register failed %d\n", err); | 397 | pr_err("twd_local_timer_register failed %d\n", err); |