diff options
Diffstat (limited to 'include/linux/clk-provider.h')
-rw-r--r-- | include/linux/clk-provider.h | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/include/linux/clk-provider.h b/include/linux/clk-provider.h index 1f0285b2f422..73bdb69f0c08 100644 --- a/include/linux/clk-provider.h +++ b/include/linux/clk-provider.h | |||
@@ -12,6 +12,7 @@ | |||
12 | #define __LINUX_CLK_PROVIDER_H | 12 | #define __LINUX_CLK_PROVIDER_H |
13 | 13 | ||
14 | #include <linux/clk.h> | 14 | #include <linux/clk.h> |
15 | #include <linux/io.h> | ||
15 | 16 | ||
16 | #ifdef CONFIG_COMMON_CLK | 17 | #ifdef CONFIG_COMMON_CLK |
17 | 18 | ||
@@ -504,5 +505,21 @@ static inline const char *of_clk_get_parent_name(struct device_node *np, | |||
504 | #define of_clk_init(matches) \ | 505 | #define of_clk_init(matches) \ |
505 | { while (0); } | 506 | { while (0); } |
506 | #endif /* CONFIG_OF */ | 507 | #endif /* CONFIG_OF */ |
508 | |||
509 | /* | ||
510 | * wrap access to peripherals in accessor routines | ||
511 | * for improved portability across platforms | ||
512 | */ | ||
513 | |||
514 | static inline u32 clk_readl(u32 __iomem *reg) | ||
515 | { | ||
516 | return readl(reg); | ||
517 | } | ||
518 | |||
519 | static inline void clk_writel(u32 val, u32 __iomem *reg) | ||
520 | { | ||
521 | writel(val, reg); | ||
522 | } | ||
523 | |||
507 | #endif /* CONFIG_COMMON_CLK */ | 524 | #endif /* CONFIG_COMMON_CLK */ |
508 | #endif /* CLK_PROVIDER_H */ | 525 | #endif /* CLK_PROVIDER_H */ |