]> www.infradead.org Git - users/jedix/linux-maple.git/commit
clk: starfive: jh7110-sys: Add notifier for PLL0 clock
authorXingyu Wu <xingyu.wu@starfivetech.com>
Mon, 26 Aug 2024 08:04:29 +0000 (16:04 +0800)
committerStephen Boyd <sboyd@kernel.org>
Thu, 29 Aug 2024 19:24:42 +0000 (12:24 -0700)
commit538d5477b25289ac5d46ca37b9e5b4d685cbe019
treed709583911c34da618bca8ab76ffb62622699b25
parentaa2eb2c4356affa2799efd95a4ee2d239ca630f8
clk: starfive: jh7110-sys: Add notifier for PLL0 clock

Add notifier function for PLL0 clock. In the function, the cpu_root clock
should be operated by saving its current parent and setting a new safe
parent (osc clock) before setting the PLL0 clock rate. After setting PLL0
rate, it should be switched back to the original parent clock.

Fixes: e2c510d6d630 ("riscv: dts: starfive: Add cpu scaling for JH7110 SoC")
Cc: stable@vger.kernel.org
Reviewed-by: Emil Renner Berthing <emil.renner.berthing@canonical.com>
Signed-off-by: Xingyu Wu <xingyu.wu@starfivetech.com>
Link: https://lore.kernel.org/r/20240826080430.179788-2-xingyu.wu@starfivetech.com
Reviewed-by: Hal Feng <hal.feng@starfivetech.com>
Tested-by: Michael Jeanson <mjeanson@efficios.com>
Signed-off-by: Stephen Boyd <sboyd@kernel.org>
drivers/clk/starfive/clk-starfive-jh7110-sys.c
drivers/clk/starfive/clk-starfive-jh71x0.h