linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] davinci: vpfe: fix error path in probe
@ 2013-05-10  4:48 Lad Prabhakar
  2013-05-10 10:55 ` Hans Verkuil
  0 siblings, 1 reply; 3+ messages in thread
From: Lad Prabhakar @ 2013-05-10  4:48 UTC (permalink / raw)
  To: LMML, DLOS; +Cc: LKML, Mauro Carvalho Chehab, Lad, Prabhakar

From: Lad, Prabhakar <prabhakar.csengg@gmail.com>

The error path on failure was calling mutex_unlock(), but there was
no actuall call before for mutex_lock(). This patch fixes this issue
by pointing it to proper go label.

Reported-by: Jose Pablo Carballo <jose.carballo@ridgerun.com>
Signed-off-by: Lad, Prabhakar <prabhakar.csengg@gmail.com>
---
 drivers/media/platform/davinci/vpfe_capture.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/drivers/media/platform/davinci/vpfe_capture.c b/drivers/media/platform/davinci/vpfe_capture.c
index 8c50d30..3827fe1 100644
--- a/drivers/media/platform/davinci/vpfe_capture.c
+++ b/drivers/media/platform/davinci/vpfe_capture.c
@@ -1837,7 +1837,7 @@ static int vpfe_probe(struct platform_device *pdev)
 	if (NULL == ccdc_cfg) {
 		v4l2_err(pdev->dev.driver,
 			 "Memory allocation failed for ccdc_cfg\n");
-		goto probe_free_lock;
+		goto probe_free_dev_mem;
 	}
 
 	mutex_lock(&ccdc_lock);
-- 
1.7.4.1


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

* Re: [PATCH] davinci: vpfe: fix error path in probe
  2013-05-10  4:48 [PATCH] davinci: vpfe: fix error path in probe Lad Prabhakar
@ 2013-05-10 10:55 ` Hans Verkuil
  2013-05-10 11:01   ` Prabhakar Lad
  0 siblings, 1 reply; 3+ messages in thread
From: Hans Verkuil @ 2013-05-10 10:55 UTC (permalink / raw)
  To: Lad Prabhakar; +Cc: LMML, DLOS, LKML, Mauro Carvalho Chehab

On Fri May 10 2013 06:48:38 Lad Prabhakar wrote:
> From: Lad, Prabhakar <prabhakar.csengg@gmail.com>
> 
> The error path on failure was calling mutex_unlock(), but there was
> no actuall call before for mutex_lock(). This patch fixes this issue
> by pointing it to proper go label.
> 
> Reported-by: Jose Pablo Carballo <jose.carballo@ridgerun.com>
> Signed-off-by: Lad, Prabhakar <prabhakar.csengg@gmail.com>
> ---
>  drivers/media/platform/davinci/vpfe_capture.c |    2 +-
>  1 files changed, 1 insertions(+), 1 deletions(-)
> 
> diff --git a/drivers/media/platform/davinci/vpfe_capture.c b/drivers/media/platform/davinci/vpfe_capture.c
> index 8c50d30..3827fe1 100644
> --- a/drivers/media/platform/davinci/vpfe_capture.c
> +++ b/drivers/media/platform/davinci/vpfe_capture.c
> @@ -1837,7 +1837,7 @@ static int vpfe_probe(struct platform_device *pdev)
>  	if (NULL == ccdc_cfg) {
>  		v4l2_err(pdev->dev.driver,
>  			 "Memory allocation failed for ccdc_cfg\n");
> -		goto probe_free_lock;
> +		goto probe_free_dev_mem;
>  	}
>  
>  	mutex_lock(&ccdc_lock);
> 

Just FYI:

After applying this patch I get a compiler warning that the probe_free_lock
label is unused. I've added a patch removing that label.

Regards,

	Hans

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

* Re: [PATCH] davinci: vpfe: fix error path in probe
  2013-05-10 10:55 ` Hans Verkuil
@ 2013-05-10 11:01   ` Prabhakar Lad
  0 siblings, 0 replies; 3+ messages in thread
From: Prabhakar Lad @ 2013-05-10 11:01 UTC (permalink / raw)
  To: Hans Verkuil; +Cc: LMML, DLOS, LKML, Mauro Carvalho Chehab

Hi Hans,

On Fri, May 10, 2013 at 4:25 PM, Hans Verkuil <hverkuil@xs4all.nl> wrote:
> On Fri May 10 2013 06:48:38 Lad Prabhakar wrote:
>> From: Lad, Prabhakar <prabhakar.csengg@gmail.com>
[Snip]
>>
>
> Just FYI:
>
> After applying this patch I get a compiler warning that the probe_free_lock
> label is unused. I've added a patch removing that label.
>
Thanks for fixing it :)

Regards,
--Prabhakar

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

end of thread, other threads:[~2013-05-10 11:02 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-05-10  4:48 [PATCH] davinci: vpfe: fix error path in probe Lad Prabhakar
2013-05-10 10:55 ` Hans Verkuil
2013-05-10 11:01   ` Prabhakar Lad

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