diff options
author | Michael Turquette <mturquette@linaro.org> | 2014-12-11 15:17:15 -0500 |
---|---|---|
committer | Michael Turquette <mturquette@linaro.org> | 2014-12-11 15:17:15 -0500 |
commit | c9b928148eb430bc2beb486d94efd2c3bc439a0c (patch) | |
tree | 9bae414dc6a2e926eef9cec8d7df0480db96271e | |
parent | 74fc23aa40525695e47d6988f9c0a501e39ef01d (diff) | |
parent | c31844ffdbd4e73a16c66e9d7df8ec290ab4b159 (diff) |
Merge tag 'for-v3.19-exynos-clk-2' of git://linuxtv.org/snawrocki/samsung into clk-next
- exynos4415 and exynos audio subsystem clk driver (build
with PM_SLEEP disabled, resource release) fixes
- minor cleanups in drivers/clk/samsung/clk.c (spelling,
includes)
- modification of the exynos4 HDMI PHY clock definition to
model dependency of "sclk_hdmiphy" on the "hdmi" clock
-rw-r--r-- | drivers/clk/samsung/clk-exynos-audss.c | 4 | ||||
-rw-r--r-- | drivers/clk/samsung/clk-exynos4.c | 2 | ||||
-rw-r--r-- | drivers/clk/samsung/clk-exynos4415.c | 6 | ||||
-rw-r--r-- | drivers/clk/samsung/clk.c | 4 | ||||
-rw-r--r-- | drivers/clk/samsung/clk.h | 6 |
5 files changed, 12 insertions, 10 deletions
diff --git a/drivers/clk/samsung/clk-exynos-audss.c b/drivers/clk/samsung/clk-exynos-audss.c index 13eae14c2cc2..b50469faf70c 100644 --- a/drivers/clk/samsung/clk-exynos-audss.c +++ b/drivers/clk/samsung/clk-exynos-audss.c | |||
@@ -210,6 +210,10 @@ static int exynos_audss_clk_remove(struct platform_device *pdev) | |||
210 | { | 210 | { |
211 | int i; | 211 | int i; |
212 | 212 | ||
213 | #ifdef CONFIG_PM_SLEEP | ||
214 | unregister_syscore_ops(&exynos_audss_clk_syscore_ops); | ||
215 | #endif | ||
216 | |||
213 | of_clk_del_provider(pdev->dev.of_node); | 217 | of_clk_del_provider(pdev->dev.of_node); |
214 | 218 | ||
215 | for (i = 0; i < clk_data.clk_num; i++) { | 219 | for (i = 0; i < clk_data.clk_num; i++) { |
diff --git a/drivers/clk/samsung/clk-exynos4.c b/drivers/clk/samsung/clk-exynos4.c index 940f02837b82..88e8c6bbd77f 100644 --- a/drivers/clk/samsung/clk-exynos4.c +++ b/drivers/clk/samsung/clk-exynos4.c | |||
@@ -505,7 +505,7 @@ static struct samsung_fixed_rate_clock exynos4_fixed_rate_ext_clks[] __initdata | |||
505 | /* fixed rate clocks generated inside the soc */ | 505 | /* fixed rate clocks generated inside the soc */ |
506 | static struct samsung_fixed_rate_clock exynos4_fixed_rate_clks[] __initdata = { | 506 | static struct samsung_fixed_rate_clock exynos4_fixed_rate_clks[] __initdata = { |
507 | FRATE(0, "sclk_hdmi24m", NULL, CLK_IS_ROOT, 24000000), | 507 | FRATE(0, "sclk_hdmi24m", NULL, CLK_IS_ROOT, 24000000), |
508 | FRATE(CLK_SCLK_HDMIPHY, "sclk_hdmiphy", NULL, CLK_IS_ROOT, 27000000), | 508 | FRATE(CLK_SCLK_HDMIPHY, "sclk_hdmiphy", "hdmi", 0, 27000000), |
509 | FRATE(0, "sclk_usbphy0", NULL, CLK_IS_ROOT, 48000000), | 509 | FRATE(0, "sclk_usbphy0", NULL, CLK_IS_ROOT, 48000000), |
510 | }; | 510 | }; |
511 | 511 | ||
diff --git a/drivers/clk/samsung/clk-exynos4415.c b/drivers/clk/samsung/clk-exynos4415.c index c7208c7a3add..2123fc251e0f 100644 --- a/drivers/clk/samsung/clk-exynos4415.c +++ b/drivers/clk/samsung/clk-exynos4415.c | |||
@@ -118,12 +118,13 @@ enum exynos4415_plls { | |||
118 | nr_plls, | 118 | nr_plls, |
119 | }; | 119 | }; |
120 | 120 | ||
121 | static struct samsung_clk_provider *exynos4415_ctx; | ||
122 | |||
121 | /* | 123 | /* |
122 | * Support for CMU save/restore across system suspends | 124 | * Support for CMU save/restore across system suspends |
123 | */ | 125 | */ |
124 | #ifdef CONFIG_PM_SLEEP | 126 | #ifdef CONFIG_PM_SLEEP |
125 | static struct samsung_clk_reg_dump *exynos4415_clk_regs; | 127 | static struct samsung_clk_reg_dump *exynos4415_clk_regs; |
126 | static struct samsung_clk_provider *exynos4415_ctx; | ||
127 | 128 | ||
128 | static unsigned long exynos4415_cmu_clk_regs[] __initdata = { | 129 | static unsigned long exynos4415_cmu_clk_regs[] __initdata = { |
129 | SRC_LEFTBUS, | 130 | SRC_LEFTBUS, |
@@ -1031,9 +1032,10 @@ enum exynos4415_dmc_plls { | |||
1031 | nr_dmc_plls, | 1032 | nr_dmc_plls, |
1032 | }; | 1033 | }; |
1033 | 1034 | ||
1035 | static struct samsung_clk_provider *exynos4415_dmc_ctx; | ||
1036 | |||
1034 | #ifdef CONFIG_PM_SLEEP | 1037 | #ifdef CONFIG_PM_SLEEP |
1035 | static struct samsung_clk_reg_dump *exynos4415_dmc_clk_regs; | 1038 | static struct samsung_clk_reg_dump *exynos4415_dmc_clk_regs; |
1036 | static struct samsung_clk_provider *exynos4415_dmc_ctx; | ||
1037 | 1039 | ||
1038 | static unsigned long exynos4415_cmu_dmc_clk_regs[] __initdata = { | 1040 | static unsigned long exynos4415_cmu_dmc_clk_regs[] __initdata = { |
1039 | MPLL_LOCK, | 1041 | MPLL_LOCK, |
diff --git a/drivers/clk/samsung/clk.c b/drivers/clk/samsung/clk.c index dd1f7c977b6b..4bda54095a16 100644 --- a/drivers/clk/samsung/clk.c +++ b/drivers/clk/samsung/clk.c | |||
@@ -11,7 +11,9 @@ | |||
11 | * clock framework for Samsung platforms. | 11 | * clock framework for Samsung platforms. |
12 | */ | 12 | */ |
13 | 13 | ||
14 | #include <linux/of_address.h> | ||
14 | #include <linux/syscore_ops.h> | 15 | #include <linux/syscore_ops.h> |
16 | |||
15 | #include "clk.h" | 17 | #include "clk.h" |
16 | 18 | ||
17 | static LIST_HEAD(clock_reg_cache_list); | 19 | static LIST_HEAD(clock_reg_cache_list); |
@@ -283,7 +285,6 @@ void __init samsung_clk_register_gate(struct samsung_clk_provider *ctx, | |||
283 | * obtain the clock speed of all external fixed clock sources from device | 285 | * obtain the clock speed of all external fixed clock sources from device |
284 | * tree and register it | 286 | * tree and register it |
285 | */ | 287 | */ |
286 | #ifdef CONFIG_OF | ||
287 | void __init samsung_clk_of_register_fixed_ext(struct samsung_clk_provider *ctx, | 288 | void __init samsung_clk_of_register_fixed_ext(struct samsung_clk_provider *ctx, |
288 | struct samsung_fixed_rate_clock *fixed_rate_clk, | 289 | struct samsung_fixed_rate_clock *fixed_rate_clk, |
289 | unsigned int nr_fixed_rate_clk, | 290 | unsigned int nr_fixed_rate_clk, |
@@ -300,7 +301,6 @@ void __init samsung_clk_of_register_fixed_ext(struct samsung_clk_provider *ctx, | |||
300 | } | 301 | } |
301 | samsung_clk_register_fixed_rate(ctx, fixed_rate_clk, nr_fixed_rate_clk); | 302 | samsung_clk_register_fixed_rate(ctx, fixed_rate_clk, nr_fixed_rate_clk); |
302 | } | 303 | } |
303 | #endif | ||
304 | 304 | ||
305 | /* utility function to get the rate of a specified clock */ | 305 | /* utility function to get the rate of a specified clock */ |
306 | unsigned long _get_rate(const char *clk_name) | 306 | unsigned long _get_rate(const char *clk_name) |
diff --git a/drivers/clk/samsung/clk.h b/drivers/clk/samsung/clk.h index 3f471e958cb0..8acabe1f32c4 100644 --- a/drivers/clk/samsung/clk.h +++ b/drivers/clk/samsung/clk.h | |||
@@ -13,19 +13,15 @@ | |||
13 | #ifndef __SAMSUNG_CLK_H | 13 | #ifndef __SAMSUNG_CLK_H |
14 | #define __SAMSUNG_CLK_H | 14 | #define __SAMSUNG_CLK_H |
15 | 15 | ||
16 | #include <linux/clk.h> | ||
17 | #include <linux/clkdev.h> | 16 | #include <linux/clkdev.h> |
18 | #include <linux/io.h> | ||
19 | #include <linux/clk-provider.h> | 17 | #include <linux/clk-provider.h> |
20 | #include <linux/of.h> | ||
21 | #include <linux/of_address.h> | ||
22 | #include "clk-pll.h" | 18 | #include "clk-pll.h" |
23 | 19 | ||
24 | /** | 20 | /** |
25 | * struct samsung_clk_provider: information about clock provider | 21 | * struct samsung_clk_provider: information about clock provider |
26 | * @reg_base: virtual address for the register base. | 22 | * @reg_base: virtual address for the register base. |
27 | * @clk_data: holds clock related data like clk* and number of clocks. | 23 | * @clk_data: holds clock related data like clk* and number of clocks. |
28 | * @lock: maintains exclusion bwtween callbacks for a given clock-provider. | 24 | * @lock: maintains exclusion between callbacks for a given clock-provider. |
29 | */ | 25 | */ |
30 | struct samsung_clk_provider { | 26 | struct samsung_clk_provider { |
31 | void __iomem *reg_base; | 27 | void __iomem *reg_base; |