[PATCH] clk: meson-g12a: fix bit range for fixed sys and hifi pll

From: Da Xue
Date: Thu Aug 14 2025 - 16:10:42 EST


The bit range 17:0 does not match the datasheet for A311D / S905D3.
Change the bit range to 19:0 for FIX and HIFI PLLs to match datasheet.

There's no frac for sys pll so add that as well.

Signed-off-by: Da Xue <da@libre.computer>
---
drivers/clk/meson/g12a.c | 9 +++++++--
1 file changed, 7 insertions(+), 2 deletions(-)

diff --git a/drivers/clk/meson/g12a.c b/drivers/clk/meson/g12a.c
index 66f0e817e416..f78cca619ca5 100644
--- a/drivers/clk/meson/g12a.c
+++ b/drivers/clk/meson/g12a.c
@@ -157,7 +157,7 @@ static struct clk_regmap g12a_fixed_pll_dco = {
.frac = {
.reg_off = HHI_FIX_PLL_CNTL1,
.shift = 0,
- .width = 17,
+ .width = 19,
},
.l = {
.reg_off = HHI_FIX_PLL_CNTL0,
@@ -223,6 +223,11 @@ static struct clk_regmap g12a_sys_pll_dco = {
.shift = 10,
.width = 5,
},
+ .frac = {
+ .reg_off = HHI_SYS_PLL_CNTL1,
+ .shift = 0,
+ .width = 19,
+ },
.l = {
.reg_off = HHI_SYS_PLL_CNTL0,
.shift = 31,
@@ -1901,7 +1906,7 @@ static struct clk_regmap g12a_hifi_pll_dco = {
.frac = {
.reg_off = HHI_HIFI_PLL_CNTL1,
.shift = 0,
- .width = 17,
+ .width = 19,
},
.l = {
.reg_off = HHI_HIFI_PLL_CNTL0,
--
2.47.2