diff options
| -rw-r--r-- | drivers/clk/sunxi-ng/ccu-sun8i-a33.c | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/drivers/clk/sunxi-ng/ccu-sun8i-a33.c b/drivers/clk/sunxi-ng/ccu-sun8i-a33.c index a7b3c08ed0e2..2c69b631967a 100644 --- a/drivers/clk/sunxi-ng/ccu-sun8i-a33.c +++ b/drivers/clk/sunxi-ng/ccu-sun8i-a33.c | |||
| @@ -752,6 +752,13 @@ static const struct sunxi_ccu_desc sun8i_a33_ccu_desc = { | |||
| 752 | .num_resets = ARRAY_SIZE(sun8i_a33_ccu_resets), | 752 | .num_resets = ARRAY_SIZE(sun8i_a33_ccu_resets), |
| 753 | }; | 753 | }; |
| 754 | 754 | ||
| 755 | static struct ccu_pll_nb sun8i_a33_pll_cpu_nb = { | ||
| 756 | .common = &pll_cpux_clk.common, | ||
| 757 | /* copy from pll_cpux_clk */ | ||
| 758 | .enable = BIT(31), | ||
| 759 | .lock = BIT(28), | ||
| 760 | }; | ||
| 761 | |||
| 755 | static struct ccu_mux_nb sun8i_a33_cpu_nb = { | 762 | static struct ccu_mux_nb sun8i_a33_cpu_nb = { |
| 756 | .common = &cpux_clk.common, | 763 | .common = &cpux_clk.common, |
| 757 | .cm = &cpux_clk.mux, | 764 | .cm = &cpux_clk.mux, |
| @@ -783,6 +790,10 @@ static void __init sun8i_a33_ccu_setup(struct device_node *node) | |||
| 783 | 790 | ||
| 784 | sunxi_ccu_probe(node, reg, &sun8i_a33_ccu_desc); | 791 | sunxi_ccu_probe(node, reg, &sun8i_a33_ccu_desc); |
| 785 | 792 | ||
| 793 | /* Gate then ungate PLL CPU after any rate changes */ | ||
| 794 | ccu_pll_notifier_register(&sun8i_a33_pll_cpu_nb); | ||
| 795 | |||
| 796 | /* Reparent CPU during PLL CPU rate changes */ | ||
| 786 | ccu_mux_notifier_register(pll_cpux_clk.common.hw.clk, | 797 | ccu_mux_notifier_register(pll_cpux_clk.common.hw.clk, |
| 787 | &sun8i_a33_cpu_nb); | 798 | &sun8i_a33_cpu_nb); |
| 788 | } | 799 | } |
