[PATCH v2 2/2] clk: sunxi-ng: h616: Register GPU PLL notifier before mux notifier
From: Arun Iyengar via B4 Relay
Date: Mon Nov 16 2026 - 03:45:17 EST
From: Arun Iyengar <aiyengar1990@xxxxxxxxx>
Register the GPU PLL notifier first, so the GPU goes back to the PLL
only after it has re-locked, as required by commit 02ae2bc6febd
("clk: sunxi-ng: Add clk notifier to gate then ungate PLL clocks").
Commit 0ec5e7572ddc ("clk: sunxi-ng: h616: register CPU PLL notifier
before mux notifier") did this for the CPU.
Fixes: eb963d7948ce ("clk: sunxi-ng: h616: Reparent GPU clock during frequency changes")
Signed-off-by: Arun Iyengar <aiyengar1990@xxxxxxxxx>
---
drivers/clk/sunxi-ng/ccu-sun50i-h616.c | 9 ++++++---
1 file changed, 6 insertions(+), 3 deletions(-)
diff --git a/drivers/clk/sunxi-ng/ccu-sun50i-h616.c b/drivers/clk/sunxi-ng/ccu-sun50i-h616.c
index 4037c5f022a8..8f53605eaafa 100644
--- a/drivers/clk/sunxi-ng/ccu-sun50i-h616.c
+++ b/drivers/clk/sunxi-ng/ccu-sun50i-h616.c
@@ -1254,13 +1254,16 @@ static int sun50i_h616_ccu_probe(struct platform_device *pdev)
ccu_mux_notifier_register(pll_cpux_clk.common.hw.clk,
&sun50i_h616_cpu_nb);
+ /*
+ * Re-lock the GPU PLL after any rate changes. Must be registered
+ * before the mux notifier, so GPU goes back to a locked PLL.
+ */
+ ccu_pll_notifier_register(&sun50i_h616_pll_gpu_nb);
+
/* Reparent GPU during GPU PLL rate changes */
ccu_mux_notifier_register(pll_gpu_clk.common.hw.clk,
&sun50i_h616_gpu_nb);
- /* Re-lock the GPU PLL after any rate changes */
- ccu_pll_notifier_register(&sun50i_h616_pll_gpu_nb);
-
return 0;
}
--
2.55.0