Explorar o código

ARM: tegra: clock: Initialize clocks that have no enable

Assume that any clock that has no enable op is always on.

Acked-by: Olof Johansson <olof@lixom.net>
Signed-off-by: Colin Cross <ccross@android.com>
Colin Cross %!s(int64=14) %!d(string=hai) anos
pai
achega
f035530b79
Modificáronse 1 ficheiros con 9 adicións e 0 borrados
  1. 9 0
      arch/arm/mach-tegra/clock.c

+ 9 - 0
arch/arm/mach-tegra/clock.c

@@ -166,6 +166,15 @@ void clk_init(struct clk *c)
 	if (c->ops && c->ops->init)
 		c->ops->init(c);
 
+	if (!c->ops || !c->ops->enable) {
+		c->refcnt++;
+		c->set = 1;
+		if (c->parent)
+			c->state = c->parent->state;
+		else
+			c->state = ON;
+	}
+
 	clk_recalculate_rate(c);
 
 	list_add(&c->node, &clocks);