Commit fd1ba2965244 ("drivers: clk: Fix using assigned-clocks in the
node of the clock it sets up"), first included in v2020.01-rc2, added
a clock-uclass post_probe() hook that applies clock controllers own
assigned clocks.

Remove the redundant clk_set_defaults() call from the RK3528 clock
driver probe() ops. Also remove the unused sync_kernel field that only
recorded whether assigned clocks had been applied.

Fixes: 5a7a856b132f ("clk: rockchip: Add support for RK3528")
Signed-off-by: Jonas Karlman <[email protected]>
---
 arch/arm/include/asm/arch-rockchip/cru_rk3528.h |  1 -
 drivers/clk/rockchip/clk_rk3528.c               | 16 +---------------
 2 files changed, 1 insertion(+), 16 deletions(-)

diff --git a/arch/arm/include/asm/arch-rockchip/cru_rk3528.h 
b/arch/arm/include/asm/arch-rockchip/cru_rk3528.h
index b4020958a046..64af04b0a97e 100644
--- a/arch/arm/include/asm/arch-rockchip/cru_rk3528.h
+++ b/arch/arm/include/asm/arch-rockchip/cru_rk3528.h
@@ -35,7 +35,6 @@ struct rk3528_clk_priv {
        unsigned long armclk_hz;
        unsigned long armclk_enter_hz;
        unsigned long armclk_init_hz;
-       bool sync_kernel;
 };
 
 struct rk3528_pll {
diff --git a/drivers/clk/rockchip/clk_rk3528.c 
b/drivers/clk/rockchip/clk_rk3528.c
index 976ef0e0a919..ee4284d65d03 100644
--- a/drivers/clk/rockchip/clk_rk3528.c
+++ b/drivers/clk/rockchip/clk_rk3528.c
@@ -1602,8 +1602,6 @@ static int rk3528_clk_init(struct rk3528_clk_priv *priv)
 {
        int ret;
 
-       priv->sync_kernel = false;
-
 #ifdef CONFIG_XPL_BUILD
        /*
         * BOOTROM:
@@ -1684,20 +1682,8 @@ static int rk3528_clk_init(struct rk3528_clk_priv *priv)
 static int rk3528_clk_probe(struct udevice *dev)
 {
        struct rk3528_clk_priv *priv = dev_get_priv(dev);
-       int ret;
-
-       ret = rk3528_clk_init(priv);
-       if (ret)
-               return ret;
 
-       /* Process 'assigned-{clocks/clock-parents/clock-rates}' properties */
-       ret = clk_set_defaults(dev, 1);
-       if (ret)
-               debug("%s clk_set_defaults failed %d\n", __func__, ret);
-       else
-               priv->sync_kernel = true;
-
-       return 0;
+       return rk3528_clk_init(priv);
 }
 
 static int rk3528_clk_ofdata_to_platdata(struct udevice *dev)
-- 
2.55.0

Reply via email to