linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] clk: Deduplicate exit code in clk_set_rate
@ 2013-01-18 16:07 Nestor Ovroy
  2013-01-22 16:38 ` Mike Turquette
  0 siblings, 1 reply; 2+ messages in thread
From: Nestor Ovroy @ 2013-01-18 16:07 UTC (permalink / raw)
  To: linux-arm-kernel

On non-out case 'return ret;' is equivalent to 'return 0;' as the ret
variable is initialized at 0 and never changed.

Signed-off-by: Nestor Ovroy <novroy@riseup.net>
---
 drivers/clk/clk.c |    3 ---
 1 file changed, 3 deletions(-)

diff --git a/drivers/clk/clk.c b/drivers/clk/clk.c
index 251e45d..0e21d7a 100644
--- a/drivers/clk/clk.c
+++ b/drivers/clk/clk.c
@@ -948,13 +948,10 @@ int clk_set_rate(struct clk *clk, unsigned long rate)
 	}
 
 	/* change the rates */
 	clk_change_rate(top);
 
-	mutex_unlock(&prepare_lock);
-
-	return 0;
 out:
 	mutex_unlock(&prepare_lock);
 
 	return ret;
 }
-- 
1.7.10.4

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

* [PATCH] clk: Deduplicate exit code in clk_set_rate
  2013-01-18 16:07 [PATCH] clk: Deduplicate exit code in clk_set_rate Nestor Ovroy
@ 2013-01-22 16:38 ` Mike Turquette
  0 siblings, 0 replies; 2+ messages in thread
From: Mike Turquette @ 2013-01-22 16:38 UTC (permalink / raw)
  To: linux-arm-kernel

Quoting Nestor Ovroy (2013-01-18 08:07:39)
> On non-out case 'return ret;' is equivalent to 'return 0;' as the ret
> variable is initialized at 0 and never changed.
> 
> Signed-off-by: Nestor Ovroy <novroy@riseup.net>

Nestor,

Thanks for the fix.  Taken into clk-next.

Regards,
Mike

> ---
>  drivers/clk/clk.c |    3 ---
>  1 file changed, 3 deletions(-)
> 
> diff --git a/drivers/clk/clk.c b/drivers/clk/clk.c
> index 251e45d..0e21d7a 100644
> --- a/drivers/clk/clk.c
> +++ b/drivers/clk/clk.c
> @@ -948,13 +948,10 @@ int clk_set_rate(struct clk *clk, unsigned long rate)
>         }
>  
>         /* change the rates */
>         clk_change_rate(top);
>  
> -       mutex_unlock(&prepare_lock);
> -
> -       return 0;
>  out:
>         mutex_unlock(&prepare_lock);
>  
>         return ret;
>  }
> -- 
> 1.7.10.4

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

end of thread, other threads:[~2013-01-22 16:38 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-01-18 16:07 [PATCH] clk: Deduplicate exit code in clk_set_rate Nestor Ovroy
2013-01-22 16:38 ` 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).