From: 함명주 <myungjoo.ham@samsung.com>
To: Axel Lin <axel.lin@gmail.com>,
"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>
Cc: 김동근 <dg77.kim@samsung.com>, 박경민 <kyungmin.park@samsung.com>,
"Arnd Bergmann" <arnd@arndb.de>,
"Greg Kroah-Hartman" <greg@kroah.com>
Subject: Re: [PATCH] misc: Fix irq leak in max8997_muic_probe error path
Date: Mon, 19 Dec 2011 02:29:43 +0000 (GMT) [thread overview]
Message-ID: <24320092.1406411324261782944.JavaMail.weblogic@epml05> (raw)
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain; charset=euc-kr, Size: 1284 bytes --]
> Current code does not properly free allocated irqs if request_threaded_irq
> returns error, fix it.
>
> Signed-off-by: Axel Lin <axel.lin@gmail.com>
Thanks for pointing that out.
Acked-by: MyungJoo Ham <myungjoo.ham@samsung.com>
> ---
> drivers/misc/max8997-muic.c | 6 ++----
> 1 files changed, 2 insertions(+), 4 deletions(-)
>
> diff --git a/drivers/misc/max8997-muic.c b/drivers/misc/max8997-muic.c
> index 74a9448..409b7fc 100644
> --- a/drivers/misc/max8997-muic.c
> +++ b/drivers/misc/max8997-muic.c
> @@ -566,10 +566,6 @@ static int __devinit max8997_muic_probe(struct platform_device *pdev)
> "failed: irq request (IRQ: %d,"
> " error :%d)\n",
> muic_irq->irq, ret);
> -
> - for (i = i - 1; i >= 0; i--)
> - free_irq(muic_irq->irq, info);
> -
> goto err_irq;
> }
> }
> @@ -583,6 +579,8 @@ static int __devinit max8997_muic_probe(struct platform_device *pdev)
> return ret;
>
> err_irq:
> + while (--i >= 0)
> + free_irq(pdata->irq_base + muic_irqs[i].irq, info);
> sysfs_remove_group(&pdev->dev.kobj, &max8997_muic_group);
> err_sysfs:
> err_pdata:
> --
> 1.7.5.4
ÿôèº{.nÇ+·®+%Ëÿ±éݶ\x17¥wÿº{.nÇ+·¥{±þG«éÿ{ayº\x1dÊÚë,j\a¢f£¢·hïêÿêçz_è®\x03(éÝ¢j"ú\x1a¶^[m§ÿÿ¾\a«þG«éÿ¢¸?¨èÚ&£ø§~á¶iOæ¬z·vØ^\x14\x04\x1a¶^[m§ÿÿÃ\fÿ¶ìÿ¢¸?I¥
next reply other threads:[~2011-12-19 2:29 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-12-19 2:29 함명주 [this message]
-- strict thread matches above, loose matches on Subject: below --
2011-12-18 2:03 [PATCH] misc: Fix irq leak in max8997_muic_probe error path Axel Lin
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=24320092.1406411324261782944.JavaMail.weblogic@epml05 \
--to=myungjoo.ham@samsung.com \
--cc=arnd@arndb.de \
--cc=axel.lin@gmail.com \
--cc=dg77.kim@samsung.com \
--cc=greg@kroah.com \
--cc=kyungmin.park@samsung.com \
--cc=linux-kernel@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox