ARM: OMAP2+: timer: Remove secure timer for DRA7xx HS devices
authorSuman Anna <s-anna@ti.com>
Mon, 5 Oct 2015 23:28:22 +0000 (18:28 -0500)
committerTony Lindgren <tony@atomide.com>
Mon, 30 Nov 2015 21:18:23 +0000 (13:18 -0800)
Timer 12 on DRA7 SoCs is reserved for secure usage on high-secure (HS)
devices. The timer cannot be used by the kernel on HS devices, but is
available on regular general purpose (GP) devices. This is similar to the
behavior on OMAP3 devices, so extend the logic used in commit ad24bde8f102
("ARM: OMAP3: Dynamically disable secure timer nodes for secure devices")
to remove the secure timer on DRA7xx SoCs at run-time based on the SoC
device type.

Signed-off-by: Suman Anna <s-anna@ti.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
arch/arm/mach-omap2/timer.c

index b18ebbefae09577e20b19e53167aca5ef11b8d86..6c19d1e2029fce33b6fbe49f59a7b5610edb6277 100644 (file)
@@ -194,8 +194,8 @@ static struct device_node * __init omap_get_timer_dt(const struct of_device_id *
 /**
  * omap_dmtimer_init - initialisation function when device tree is used
  *
- * For secure OMAP3 devices, timers with device type "timer-secure" cannot
- * be used by the kernel as they are reserved. Therefore, to prevent the
+ * For secure OMAP3/DRA7xx devices, timers with device type "timer-secure"
+ * cannot be used by the kernel as they are reserved. Therefore, to prevent the
  * kernel registering these devices remove them dynamically from the device
  * tree on boot.
  */
@@ -203,7 +203,7 @@ static void __init omap_dmtimer_init(void)
 {
        struct device_node *np;
 
-       if (!cpu_is_omap34xx())
+       if (!cpu_is_omap34xx() && !soc_is_dra7xx())
                return;
 
        /* If we are a secure device, remove any secure timer nodes */
This page took 0.029495 seconds and 5 git commands to generate.