]> git.karo-electronics.de Git - linux-beck.git/commitdiff
clk: imx: Replace clk error check with imx_check_clocks()
authorBai Ping <b51503@freescale.com>
Thu, 26 Nov 2015 02:18:43 +0000 (10:18 +0800)
committerShawn Guo <shawnguo@kernel.org>
Wed, 2 Dec 2015 06:10:25 +0000 (14:10 +0800)
As we already have a 'imx_check_clocks' to do the clock error
check, so cleanup the error check code.

Signed-off-by: Bai Ping <b51503@freescale.com>
Acked-by: Stephen Boyd <sboyd@codeaurora.org>
Signed-off-by: Shawn Guo <shawnguo@kernel.org>
drivers/clk/imx/clk-imx6ul.c
drivers/clk/imx/clk-imx7d.c

index 01718d05e95221eaf8a96e4b69bb994275ad82da..08692d74b8847d0dfb2bb09f9b006a902425f335 100644 (file)
@@ -399,9 +399,7 @@ static void __init imx6ul_clocks_init(struct device_node *ccm_node)
        /* mask handshake of mmdc */
        writel_relaxed(BM_CCM_CCDR_MMDC_CH0_MASK, base + CCDR);
 
-       for (i = 0; i < ARRAY_SIZE(clks); i++)
-               if (IS_ERR(clks[i]))
-                       pr_err("i.MX6UL clk %d: register failed with %ld\n", i, PTR_ERR(clks[i]));
+       imx_check_clocks(clks, ARRAY_SIZE(clks));
 
        clk_data.clks = clks;
        clk_data.clk_num = ARRAY_SIZE(clks);
index 581b428d3133bbf0028016140a52eaf1fde53a03..fbb6a8c8653dcb1045640dd178eef02669ab9950 100644 (file)
@@ -839,10 +839,7 @@ static void __init imx7d_clocks_init(struct device_node *ccm_node)
                                         clks[IMX7D_PLL_ARM_MAIN_CLK],
                                         clks[IMX7D_PLL_SYS_MAIN_CLK]);
 
-       for (i = 0; i < ARRAY_SIZE(clks); i++)
-               if (IS_ERR(clks[i]))
-                       pr_err("i.MX7D clk %d: register failed with %ld\n",
-                                       i, PTR_ERR(clks[i]));
+       imx_check_clocks(clks, ARRAY_SIZE(clks));
 
        clk_data.clks = clks;
        clk_data.clk_num = ARRAY_SIZE(clks);