]> git.dujemihanovic.xyz Git - u-boot.git/commitdiff
rockchip: clk: rk3399: remove clk_enable()
authorKever Yang <kever.yang@rock-chips.com>
Wed, 28 Aug 2019 08:23:51 +0000 (16:23 +0800)
committerKever Yang <kever.yang@rock-chips.com>
Wed, 11 Sep 2019 08:16:12 +0000 (16:16 +0800)
There is no real driver for clk enable/disable now, and we actually
don't need it now, remove it so that not waste CPU cycles and code size.

Signed-off-by: Kever Yang <kever.yang@rock-chips.com>
drivers/clk/rockchip/clk_rk3399.c

index d9950c159bd697da9f18cc6f178669b2c10f82df..a273bd1bebe476164a2356a3ed03aba993d3f30b 100644 (file)
@@ -1062,49 +1062,12 @@ static int __maybe_unused rk3399_clk_set_parent(struct clk *clk,
        return -ENOENT;
 }
 
-static int rk3399_clk_enable(struct clk *clk)
-{
-       switch (clk->id) {
-       case HCLK_HOST0:
-       case HCLK_HOST0_ARB:
-       case HCLK_HOST1:
-       case HCLK_HOST1_ARB:
-               return 0;
-
-       case SCLK_MAC:
-       case SCLK_MAC_RX:
-       case SCLK_MAC_TX:
-       case SCLK_MACREF:
-       case SCLK_MACREF_OUT:
-       case ACLK_GMAC:
-       case PCLK_GMAC:
-               /* Required to successfully probe the Designware GMAC driver */
-               return 0;
-
-       case SCLK_USB3OTG0_REF:
-       case SCLK_USB3OTG1_REF:
-       case SCLK_USB3OTG0_SUSPEND:
-       case SCLK_USB3OTG1_SUSPEND:
-       case ACLK_USB3OTG0:
-       case ACLK_USB3OTG1:
-       case ACLK_USB3_RKSOC_AXI_PERF:
-       case ACLK_USB3:
-       case ACLK_USB3_GRF:
-               /* Required to successfully probe the Designware USB3 driver */
-               return 0;
-       }
-
-       debug("%s: unsupported clk %ld\n", __func__, clk->id);
-       return -ENOENT;
-}
-
 static struct clk_ops rk3399_clk_ops = {
        .get_rate = rk3399_clk_get_rate,
        .set_rate = rk3399_clk_set_rate,
 #if CONFIG_IS_ENABLED(OF_CONTROL) && !CONFIG_IS_ENABLED(OF_PLATDATA)
        .set_parent = rk3399_clk_set_parent,
 #endif
-       .enable = rk3399_clk_enable,
 };
 
 #ifdef CONFIG_SPL_BUILD