[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <1421943207-5180-2-git-send-email-tomeu.vizoso@collabora.com>
Date: Thu, 22 Jan 2015 17:13:11 +0100
From: Tomeu Vizoso <tomeu.vizoso@...labora.com>
To: linux-kernel@...r.kernel.org,
Mike Turquette <mturquette@...aro.org>,
Stephen Boyd <sboyd@...eaurora.org>
Cc: Javier Martinez Canillas <javier.martinez@...labora.co.uk>,
Tomeu Vizoso <tomeu.vizoso@...labora.com>
Subject: [PATCH v12 1/6] clk: Remove unneeded NULL checks
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@...labora.com>
Reviewed-by: Stephen Boyd <sboyd@...eaurora.org>
---
drivers/clk/clk.c | 9 ---------
1 file changed, 9 deletions(-)
diff --git a/drivers/clk/clk.c b/drivers/clk/clk.c
index f4963b7..97f3425 100644
--- a/drivers/clk/clk.c
+++ b/drivers/clk/clk.c
@@ -432,9 +432,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);
@@ -458,9 +455,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);
@@ -486,9 +480,6 @@ static void clk_disable_unused_subtree(struct clk *clk)
unlock_out:
clk_enable_unlock(flags);
-
-out:
- return;
}
static bool clk_ignore_unused;
--
1.9.3
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists