linux-pm.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] clk: remove unreachable code
@ 2013-01-08 13:03 Rajagopal Venkat
  2013-01-09  5:50 ` Tushar Behera
  2013-01-09  6:29 ` Rajagopal Venkat
  0 siblings, 2 replies; 8+ messages in thread
From: Rajagopal Venkat @ 2013-01-08 13:03 UTC (permalink / raw)
  To: mturquette; +Cc: patches, linaro-dev, linux-pm, linux-kernel, Rajagopal Venkat

while reparenting a clock, NULL check is done for clock in
consideration and its new parent. So re-check is not required.
If done, else part becomes unreachable.

Signed-off-by: Rajagopal Venkat <rajagopal.venkat@linaro.org>
---
 drivers/clk/clk.c |    5 +----
 1 file changed, 1 insertion(+), 4 deletions(-)

diff --git a/drivers/clk/clk.c b/drivers/clk/clk.c
index 251e45d..f896584 100644
--- a/drivers/clk/clk.c
+++ b/drivers/clk/clk.c
@@ -1048,10 +1048,7 @@ void __clk_reparent(struct clk *clk, struct clk *new_parent)
 
 	hlist_del(&clk->child_node);
 
-	if (new_parent)
-		hlist_add_head(&clk->child_node, &new_parent->children);
-	else
-		hlist_add_head(&clk->child_node, &clk_orphan_list);
+	hlist_add_head(&clk->child_node, &new_parent->children);
 
 #ifdef CONFIG_COMMON_CLK_DEBUG
 	if (!inited)
-- 
1.7.10.4


^ permalink raw reply related	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2013-01-18 17:43 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-01-08 13:03 [PATCH] clk: remove unreachable code Rajagopal Venkat
2013-01-09  5:50 ` Tushar Behera
     [not found]   ` <50ED0517.5090907-QSEj5FYQhm4dnm+yROfE0A@public.gmane.org>
2013-01-09  5:58     ` Rajagopal Venkat
2013-01-09  6:29 ` Rajagopal Venkat
2013-01-09  6:35   ` Tushar Behera
     [not found]   ` <1357712988-22317-1-git-send-email-rajagopal.venkat-QSEj5FYQhm4dnm+yROfE0A@public.gmane.org>
2013-01-15 22:45     ` Mike Turquette
2013-01-16 12:45       ` Rajagopal Venkat
     [not found]         ` <CA+Z25wW=g+-Uo2DLpD=0ADjWTh5DKQb5ePPXR1tz0LXH3_b-xg-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2013-01-18 17:43           ` Mike Turquette

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).