alsa-devel.alsa-project.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] ASoC: atmel: test wrong variable
@ 2010-11-21 17:40 Vasiliy Kulikov
  2010-11-22  7:43 ` Jarkko Nikula
  0 siblings, 1 reply; 6+ messages in thread
From: Vasiliy Kulikov @ 2010-11-21 17:40 UTC (permalink / raw)
  To: kernel-janitors
  Cc: Liam Girdwood, Mark Brown, Jaroslav Kysela, Takashi Iwai,
	Timur Tabi, Jarkko Nikula, Lars-Peter Clausen, alsa-devel,
	linux-kernel

After clk_get() mclk is checked second time instead of pllb check.

Signed-off-by: Vasiliy Kulikov <segoon@openwall.com>
---
 Cannot compile this driver, so it is not tested.

 sound/soc/atmel/sam9g20_wm8731.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/sound/soc/atmel/sam9g20_wm8731.c b/sound/soc/atmel/sam9g20_wm8731.c
index da9c303..68072a2 100644
--- a/sound/soc/atmel/sam9g20_wm8731.c
+++ b/sound/soc/atmel/sam9g20_wm8731.c
@@ -223,7 +223,7 @@ static int __init at91sam9g20ek_init(void)
 	}
 
 	pllb = clk_get(NULL, "pllb");
-	if (IS_ERR(mclk)) {
+	if (IS_ERR(pllb)) {
 		printk(KERN_ERR "ASoC: Failed to get PLLB\n");
 		ret = PTR_ERR(mclk);
 		goto err_mclk;
-- 
1.7.0.4

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

* Re: [PATCH] ASoC: atmel: test wrong variable
  2010-11-21 17:40 [PATCH] ASoC: atmel: test wrong variable Vasiliy Kulikov
@ 2010-11-22  7:43 ` Jarkko Nikula
  2010-11-22 15:59   ` [PATCH v2] " Vasiliy Kulikov
  0 siblings, 1 reply; 6+ messages in thread
From: Jarkko Nikula @ 2010-11-22  7:43 UTC (permalink / raw)
  To: Vasiliy Kulikov
  Cc: alsa-devel, Lars-Peter Clausen, Takashi Iwai, Mark Brown,
	kernel-janitors, linux-kernel, Timur Tabi, Liam Girdwood

On Sun, 21 Nov 2010 20:40:14 +0300
Vasiliy Kulikov <segoon@openwall.com> wrote:

> After clk_get() mclk is checked second time instead of pllb check.
> 
> Signed-off-by: Vasiliy Kulikov <segoon@openwall.com>
> ---
>  Cannot compile this driver, so it is not tested.
> 
>  sound/soc/atmel/sam9g20_wm8731.c |    2 +-
>  1 files changed, 1 insertions(+), 1 deletions(-)
> 
> diff --git a/sound/soc/atmel/sam9g20_wm8731.c b/sound/soc/atmel/sam9g20_wm8731.c
> index da9c303..68072a2 100644
> --- a/sound/soc/atmel/sam9g20_wm8731.c
> +++ b/sound/soc/atmel/sam9g20_wm8731.c
> @@ -223,7 +223,7 @@ static int __init at91sam9g20ek_init(void)
>  	}
>  
>  	pllb = clk_get(NULL, "pllb");
> -	if (IS_ERR(mclk)) {
> +	if (IS_ERR(pllb)) {
>  		printk(KERN_ERR "ASoC: Failed to get PLLB\n");
>  		ret = PTR_ERR(mclk);

Update also PTR_ERR as otherwise we don't return any error code
(mclk is ok at this point but pllb has an error).

-- 
Jarkko

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

* [PATCH v2] ASoC: atmel: test wrong variable
  2010-11-22  7:43 ` Jarkko Nikula
@ 2010-11-22 15:59   ` Vasiliy Kulikov
  2010-11-22 16:04     ` Timur Tabi
                       ` (2 more replies)
  0 siblings, 3 replies; 6+ messages in thread
From: Vasiliy Kulikov @ 2010-11-22 15:59 UTC (permalink / raw)
  To: linux-kernel
  Cc: kernel-janitors, Liam Girdwood, Mark Brown, Jaroslav Kysela,
	Takashi Iwai, Timur Tabi, Lars-Peter Clausen, alsa-devel,
	Jarkko Nikula

After clk_get() mclk is checked second time instead of pllb check.
In patch v1 Jarkko Nikula noticed that PTR_ERR() is also has wrong argument.

Signed-off-by: Vasiliy Kulikov <segoon@openwall.com>
---
 sound/soc/atmel/sam9g20_wm8731.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/sound/soc/atmel/sam9g20_wm8731.c b/sound/soc/atmel/sam9g20_wm8731.c
index da9c303..f16e00c 100644
--- a/sound/soc/atmel/sam9g20_wm8731.c
+++ b/sound/soc/atmel/sam9g20_wm8731.c
@@ -223,9 +223,9 @@ static int __init at91sam9g20ek_init(void)
 	}
 
 	pllb = clk_get(NULL, "pllb");
-	if (IS_ERR(mclk)) {
+	if (IS_ERR(pllb)) {
 		printk(KERN_ERR "ASoC: Failed to get PLLB\n");
-		ret = PTR_ERR(mclk);
+		ret = PTR_ERR(pllb);
 		goto err_mclk;
 	}
 	ret = clk_set_parent(mclk, pllb);
-- 
1.7.0.4

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

* Re: [PATCH v2] ASoC: atmel: test wrong variable
  2010-11-22 15:59   ` [PATCH v2] " Vasiliy Kulikov
@ 2010-11-22 16:04     ` Timur Tabi
  2010-11-22 16:05     ` Liam Girdwood
  2010-11-22 20:27     ` Mark Brown
  2 siblings, 0 replies; 6+ messages in thread
From: Timur Tabi @ 2010-11-22 16:04 UTC (permalink / raw)
  To: Vasiliy Kulikov
  Cc: alsa-devel, Lars-Peter Clausen, Takashi Iwai, Mark Brown,
	kernel-janitors, linux-kernel, Liam, Girdwood

Vasiliy Kulikov wrote:
> After clk_get() mclk is checked second time instead of pllb check.
> In patch v1 Jarkko Nikula noticed that PTR_ERR() is also has wrong argument.
> 
> Signed-off-by: Vasiliy Kulikov <segoon@openwall.com>

Why am I'm being cc'd on Atmel driver patches?  I've done no work on these drivers.

-- 
Timur Tabi
Linux kernel developer at Freescale

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

* Re: [PATCH v2] ASoC: atmel: test wrong variable
  2010-11-22 15:59   ` [PATCH v2] " Vasiliy Kulikov
  2010-11-22 16:04     ` Timur Tabi
@ 2010-11-22 16:05     ` Liam Girdwood
  2010-11-22 20:27     ` Mark Brown
  2 siblings, 0 replies; 6+ messages in thread
From: Liam Girdwood @ 2010-11-22 16:05 UTC (permalink / raw)
  To: Vasiliy Kulikov
  Cc: alsa-devel, Lars-Peter Clausen, Takashi Iwai, Brown,
	kernel-janitors, linux-kernel, Mark, Timur Tabi

On Mon, 2010-11-22 at 18:59 +0300, Vasiliy Kulikov wrote:
> After clk_get() mclk is checked second time instead of pllb check.
> In patch v1 Jarkko Nikula noticed that PTR_ERR() is also has wrong argument.
> 
> Signed-off-by: Vasiliy Kulikov <segoon@openwall.com>

Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
-- 
Freelance Developer, SlimLogic Ltd
ASoC and Voltage Regulator Maintainer.
http://www.slimlogic.co.uk

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

* Re: [PATCH v2] ASoC: atmel: test wrong variable
  2010-11-22 15:59   ` [PATCH v2] " Vasiliy Kulikov
  2010-11-22 16:04     ` Timur Tabi
  2010-11-22 16:05     ` Liam Girdwood
@ 2010-11-22 20:27     ` Mark Brown
  2 siblings, 0 replies; 6+ messages in thread
From: Mark Brown @ 2010-11-22 20:27 UTC (permalink / raw)
  To: Vasiliy Kulikov
  Cc: alsa-devel, Lars-Peter Clausen, Takashi Iwai, kernel-janitors,
	linux-kernel, Timur Tabi, Liam Girdwood

On Mon, Nov 22, 2010 at 06:59:13PM +0300, Vasiliy Kulikov wrote:
> After clk_get() mclk is checked second time instead of pllb check.
> In patch v1 Jarkko Nikula noticed that PTR_ERR() is also has wrong argument.
> 
> Signed-off-by: Vasiliy Kulikov <segoon@openwall.com>

Applied, thanks.

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

end of thread, other threads:[~2010-11-22 20:27 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-11-21 17:40 [PATCH] ASoC: atmel: test wrong variable Vasiliy Kulikov
2010-11-22  7:43 ` Jarkko Nikula
2010-11-22 15:59   ` [PATCH v2] " Vasiliy Kulikov
2010-11-22 16:04     ` Timur Tabi
2010-11-22 16:05     ` Liam Girdwood
2010-11-22 20:27     ` Mark Brown

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).