From: Simon Horman <horms@verge.net.au>
To: Axel Lin <axel.lin@ingics.com>
Cc: Magnus Damm <damm@opensource.se>,
Guennadi Liakhovetski <g.liakhovetski@gmx.de>,
Thomas Gleixner <tglx@linutronix.de>,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH] irqchip: renesas-irqc: Fix irqc_probe error handling
Date: Wed, 8 May 2013 09:57:02 +0900 [thread overview]
Message-ID: <20130508005702.GB23419@verge.net.au> (raw)
In-Reply-To: <1367831012.3547.2.camel@phoenix>
On Mon, May 06, 2013 at 05:03:32PM +0800, Axel Lin wrote:
> The code in goto err3 path is wrong because it will call fee_irq() with k == 0,
> which means it does free_irq(p->irq[-1].requested_irq, &p->irq[-1]);
>
> Signed-off-by: Axel Lin <axel.lin@ingics.com>
> ---
> drivers/irqchip/irq-renesas-irqc.c | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
Thanks, I have queued this up for v3.11 in the intc-external-irq branch
of my renesas tree on kernel.org.
>
> diff --git a/drivers/irqchip/irq-renesas-irqc.c b/drivers/irqchip/irq-renesas-irqc.c
> index 649cd69..3651f77 100644
> --- a/drivers/irqchip/irq-renesas-irqc.c
> +++ b/drivers/irqchip/irq-renesas-irqc.c
> @@ -252,8 +252,8 @@ static int irqc_probe(struct platform_device *pdev)
>
> return 0;
> err3:
> - for (; k >= 0; k--)
> - free_irq(p->irq[k - 1].requested_irq, &p->irq[k - 1]);
> + while (--k >= 0)
> + free_irq(p->irq[k].requested_irq, &p->irq[k]);
>
> irq_domain_remove(p->irq_domain);
> err2:
> --
> 1.8.1.2
>
>
>
prev parent reply other threads:[~2013-05-08 4:00 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-05-06 9:03 Axel Lin
2013-05-08 0:57 ` Simon Horman [this message]
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=20130508005702.GB23419@verge.net.au \
--to=horms@verge.net.au \
--cc=axel.lin@ingics.com \
--cc=damm@opensource.se \
--cc=g.liakhovetski@gmx.de \
--cc=linux-kernel@vger.kernel.org \
--cc=tglx@linutronix.de \
/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
all inboxes | Powered by JetHome®