clk: imx: imx8: Simplify clk_imx_acm_detach_pm_domains()
authorChristophe JAILLET <christophe.jaillet@wanadoo.fr>
Thu, 14 Sep 2023 20:31:06 +0000 (22:31 +0200)
committerAbel Vesa <abel.vesa@linaro.org>
Wed, 4 Oct 2023 08:13:59 +0000 (11:13 +0300)
The return value of clk_imx_acm_detach_pm_domains() is never used.
Simplify the code and turn it into a void function.

Reviewed-by: Peng Fan <peng.fan@nxp.com>
Signed-off-by: Christophe JAILLET <christophe.jaillet@wanadoo.fr>
Signed-off-by: Abel Vesa <abel.vesa@linaro.org>
drivers/clk/imx/clk-imx8-acm.c

index c744fb78bb446b4d968638c5b98472cff572fd55..735b08296cc8ec2b700d3458c05b09c2f1f4a55d 100644 (file)
@@ -310,20 +310,18 @@ detach_pm:
  * @dev: deivice pointer
  * @dev_pm: multi power domain for device
  */
-static int clk_imx_acm_detach_pm_domains(struct device *dev,
-                                        struct clk_imx_acm_pm_domains *dev_pm)
+static void clk_imx_acm_detach_pm_domains(struct device *dev,
+                                         struct clk_imx_acm_pm_domains *dev_pm)
 {
        int i;
 
        if (dev_pm->num_domains <= 1)
-               return 0;
+               return;
 
        for (i = 0; i < dev_pm->num_domains; i++) {
                device_link_del(dev_pm->pd_dev_link[i]);
                dev_pm_domain_detach(dev_pm->pd_dev[i], false);
        }
-
-       return 0;
 }
 
 static int imx8_acm_clk_probe(struct platform_device *pdev)