DORMANTno replies REVIEWED: 1 (0M)

1 review trailer.

[PATCH 2/2] clocksource/mtu-nomadik: use apb_pclk

From: Linus Walleij <hidden>
Date: 2012-11-15 13:55:38
Subsystem: clocksource, clockevent drivers, the rest · Maintainers: Daniel Lezcano, Thomas Gleixner, Linus Torvalds

From: Ulf Hansson <redacted>

After improving the clock tree we need to make sure the the
MTU timer explicitly grabs and enables it silicon clock
(pclk).

Signed-off-by: Ulf Hansson <redacted>
Acked-by: Mike Turquette <redacted>
Signed-off-by: Linus Walleij <redacted>
---
This version of the patch is based upon the ux500
SPARSE_IRQ commit and is intended to be merged after [1/2]
so as to avoid conflicts between the clk and ARM SoC trees.
---
 drivers/clocksource/nomadik-mtu.c | 8 +++++++-
 1 file changed, 7 insertions(+), 1 deletion(-)
diff --git a/drivers/clocksource/nomadik-mtu.c b/drivers/clocksource/nomadik-mtu.c
index 23c780b..8914c3c 100644
--- a/drivers/clocksource/nomadik-mtu.c
+++ b/drivers/clocksource/nomadik-mtu.c
@@ -177,9 +177,15 @@ void nmdk_clksrc_reset(void)
 void __init nmdk_timer_init(void __iomem *base, int irq)
 {
 	unsigned long rate;
-	struct clk *clk0;
+	struct clk *clk0, *pclk0;
 
 	mtu_base = base;
+
+	pclk0 = clk_get_sys("mtu0", "apb_pclk");
+	BUG_ON(IS_ERR(pclk0));
+	BUG_ON(clk_prepare(pclk0) < 0);
+	BUG_ON(clk_enable(pclk0) < 0);
+
 	clk0 = clk_get_sys("mtu0", NULL);
 	BUG_ON(IS_ERR(clk0));
 	BUG_ON(clk_prepare(clk0) < 0);
-- 
1.7.11.3
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help