linux-sh.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 02/07] sh: CPG MSTP ioremap() prototype hack
@ 2011-12-06 16:52 Magnus Damm
  0 siblings, 0 replies; only message in thread
From: Magnus Damm @ 2011-12-06 16:52 UTC (permalink / raw)
  To: linux-sh

From: Magnus Damm <damm@opensource.se>

Hack to use the cookie returned from ioremap(). Will be rewritten
and submitted separately in the near future. Needed by the r8a7779
clock code since entity mapping is out of the question.

Not-yet-signed-off-by: Magnus Damm <damm@opensource.se>
---

 drivers/sh/clk/cpg.c |    4 ++++
 1 file changed, 4 insertions(+)

--- 0001/drivers/sh/clk/cpg.c
+++ work/drivers/sh/clk/cpg.c	2011-12-07 00:32:11.000000000 +0900
@@ -42,6 +42,10 @@ int __init sh_clk_mstp32_register(struct
 		clkp = clks + k;
 		clkp->ops = &sh_clk_mstp32_clk_ops;
 		ret |= clk_register(clkp);
+		if (!ret && clkp->mapping->base) {
+			clkp->enable_reg -= clkp->mapping->phys;
+			clkp->enable_reg += (unsigned long)clkp->mapping->base;
+		}
 	}
 
 	return ret;

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2011-12-06 16:52 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-12-06 16:52 [PATCH 02/07] sh: CPG MSTP ioremap() prototype hack Magnus Damm

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).