diff mbox

[-next] backlight: lm3630: add missing destroy_workqueue() on error in lm3630a_intr_config()

Message ID CAPgLHd_Sqru87pYM3aB1_57hD0eWX4Rb3huPqjQxX93HRrCQzw@mail.gmail.com (mailing list archive)
State New, archived
Headers show

Commit Message

Wei Yongjun Sept. 27, 2013, 9:50 a.m. UTC
From: Wei Yongjun <yongjun_wei@trendmicro.com.cn>

Add the missing destroy_workqueue() before return from
lm3630a_intr_config() in the error handling case.

Signed-off-by: Wei Yongjun <yongjun_wei@trendmicro.com.cn>
---
 drivers/video/backlight/lm3630a_bl.c | 1 +
 1 file changed, 1 insertion(+)


--
To unsubscribe from this list: send the line "unsubscribe linux-fbdev" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Comments

Jingoo Han Oct. 1, 2013, 1:08 a.m. UTC | #1
On Friday, September 27, 2013 6:51 PM, Wei Yongjun wrote:
> 
> From: Wei Yongjun <yongjun_wei@trendmicro.com.cn>
> 
> Add the missing destroy_workqueue() before return from
> lm3630a_intr_config() in the error handling case.
> 
> Signed-off-by: Wei Yongjun <yongjun_wei@trendmicro.com.cn>

+cc Andrew Morton, Daniel Jeong

Acked-by: Jingoo Han <jg1.han@samsung.com>


Best regards,
Jingoo Han

> ---
>  drivers/video/backlight/lm3630a_bl.c | 1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/drivers/video/backlight/lm3630a_bl.c b/drivers/video/backlight/lm3630a_bl.c
> index c63f918..0e5d8d3 100644
> --- a/drivers/video/backlight/lm3630a_bl.c
> +++ b/drivers/video/backlight/lm3630a_bl.c
> @@ -154,6 +154,7 @@ static int lm3630a_intr_config(struct lm3630a_chip *pchip)
>  	    (pchip->irq, NULL, lm3630a_isr_func,
>  	     IRQF_TRIGGER_FALLING | IRQF_ONESHOT, "lm3630a_irq", pchip)) {
>  		dev_err(pchip->dev, "request threaded irq fail\n");
> +		destroy_workqueue(pchip->irqthread);
>  		return -ENOMEM;
>  	}
>  	return rval;
> 
> --

--
To unsubscribe from this list: send the line "unsubscribe linux-fbdev" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
diff mbox

Patch

diff --git a/drivers/video/backlight/lm3630a_bl.c b/drivers/video/backlight/lm3630a_bl.c
index c63f918..0e5d8d3 100644
--- a/drivers/video/backlight/lm3630a_bl.c
+++ b/drivers/video/backlight/lm3630a_bl.c
@@ -154,6 +154,7 @@  static int lm3630a_intr_config(struct lm3630a_chip *pchip)
 	    (pchip->irq, NULL, lm3630a_isr_func,
 	     IRQF_TRIGGER_FALLING | IRQF_ONESHOT, "lm3630a_irq", pchip)) {
 		dev_err(pchip->dev, "request threaded irq fail\n");
+		destroy_workqueue(pchip->irqthread);
 		return -ENOMEM;
 	}
 	return rval;