aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux
diff options
context:
space:
mode:
authorBenjamin Herrenschmidt <benh@kernel.crashing.org>2014-01-29 00:53:55 -0500
committerBenjamin Herrenschmidt <benh@kernel.crashing.org>2014-01-29 00:53:55 -0500
commite9a371100dfdfa4c9f994059d19d98c9b4fd80af (patch)
tree11e9d240d87834f9da927aaa4027e7dfcbd01eb8 /include/linux
parentd891ea23d5203e5c47439b2a174f86a00b356a6c (diff)
parentbc75059422338197ce487d338ac9c898761e1e61 (diff)
Merge remote-tracking branch 'agust/next' into next
<< Switch mpc512x to the common clock framework and adapt mpc512x drivers to use the new clock driver. Old PPC_CLOCK code is removed entirely since there are no users any more. >>
Diffstat (limited to 'include/linux')
-rw-r--r--include/linux/clk-provider.h16
1 files changed, 16 insertions, 0 deletions
diff --git a/include/linux/clk-provider.h b/include/linux/clk-provider.h
index 999b28ba38f7..f1a098a4450c 100644
--- a/include/linux/clk-provider.h
+++ b/include/linux/clk-provider.h
@@ -542,6 +542,20 @@ static inline const char *of_clk_get_parent_name(struct device_node *np,
542 * for improved portability across platforms 542 * for improved portability across platforms
543 */ 543 */
544 544
545#if IS_ENABLED(CONFIG_PPC)
546
547static inline u32 clk_readl(u32 __iomem *reg)
548{
549 return ioread32be(reg);
550}
551
552static inline void clk_writel(u32 val, u32 __iomem *reg)
553{
554 iowrite32be(val, reg);
555}
556
557#else /* platform dependent I/O accessors */
558
545static inline u32 clk_readl(u32 __iomem *reg) 559static inline u32 clk_readl(u32 __iomem *reg)
546{ 560{
547 return readl(reg); 561 return readl(reg);
@@ -552,5 +566,7 @@ static inline void clk_writel(u32 val, u32 __iomem *reg)
552 writel(val, reg); 566 writel(val, reg);
553} 567}
554 568
569#endif /* platform dependent I/O accessors */
570
555#endif /* CONFIG_COMMON_CLK */ 571#endif /* CONFIG_COMMON_CLK */
556#endif /* CLK_PROVIDER_H */ 572#endif /* CLK_PROVIDER_H */