clk: Remove unneeded NULL checks
authorTomeu Vizoso <tomeu.vizoso@collabora.com>
Fri, 23 Jan 2015 11:03:28 +0000 (12:03 +0100)
committerMichael Turquette <mturquette@linaro.org>
Wed, 28 Jan 2015 18:40:18 +0000 (10:40 -0800)
As clk_unprepare_unused_subtree and clk_disable_unused_subtree are
always called with a valid struct clk.

Signed-off-by: Tomeu Vizoso <tomeu.vizoso@collabora.com>
Reviewed-by: Stephen Boyd <sboyd@codeaurora.org>
Signed-off-by: Michael Turquette <mturquette@linaro.org>
drivers/clk/clk.c

index aa8a9d2d0b73efb62ec1a4ecad23de93a8e42a0d..05986e389bf8a88a0632db3807057a5123d6cbe7 100644 (file)
@@ -428,9 +428,6 @@ static void clk_unprepare_unused_subtree(struct clk *clk)
 {
        struct clk *child;
 
-       if (!clk)
-               return;
-
        hlist_for_each_entry(child, &clk->children, child_node)
                clk_unprepare_unused_subtree(child);
 
@@ -454,9 +451,6 @@ static void clk_disable_unused_subtree(struct clk *clk)
        struct clk *child;
        unsigned long flags;
 
-       if (!clk)
-               goto out;
-
        hlist_for_each_entry(child, &clk->children, child_node)
                clk_disable_unused_subtree(child);
 
@@ -482,9 +476,6 @@ static void clk_disable_unused_subtree(struct clk *clk)
 
 unlock_out:
        clk_enable_unlock(flags);
-
-out:
-       return;
 }
 
 static bool clk_ignore_unused;
This page took 0.036422 seconds and 5 git commands to generate.