All of lore.kernel.org
 help / color / mirror / Atom feed
From: Marc Zyngier <marc.zyngier@arm.com>
To: Shaokun Zhang <zhangshaokun@hisilicon.com>
Cc: <linux-kernel@vger.kernel.org>,
	Nianyao Tang <tangnianyao@huawei.com>,
	Thomas Gleixner <tglx@linutronix.de>,
	Jason Cooper <jason@lakedaemon.net>
Subject: Re: [PATCH] irqchip/gic-v3-its: Free unused vpt_page when alloc vpe table fail
Date: Fri, 26 Jul 2019 10:18:44 +0100	[thread overview]
Message-ID: <20190726101844.79cb10b5@why> (raw)
In-Reply-To: <1564105905-15410-1-git-send-email-zhangshaokun@hisilicon.com>

On Fri, 26 Jul 2019 09:51:45 +0800
Shaokun Zhang <zhangshaokun@hisilicon.com> wrote:

> From: Nianyao Tang <tangnianyao@huawei.com>
> 
> In its_vpe_init, when its_alloc_vpe_table fails, we should free
> vpt_page allocated just before, instead of vpe->vpt_page.
> Let's fix it.
> 
> Cc: Thomas Gleixner <tglx@linutronix.de> 
> Cc: Jason Cooper <jason@lakedaemon.net>
> Cc: Marc Zyngier <marc.zyngier@arm.com>
> Signed-off-by: Nianyao Tang <tangnianyao@huawei.com>
> ---
>  drivers/irqchip/irq-gic-v3-its.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/irqchip/irq-gic-v3-its.c b/drivers/irqchip/irq-gic-v3-its.c
> index 730fbe0..1b5c367 100644
> --- a/drivers/irqchip/irq-gic-v3-its.c
> +++ b/drivers/irqchip/irq-gic-v3-its.c
> @@ -3010,7 +3010,7 @@ static int its_vpe_init(struct its_vpe *vpe)
>  
>  	if (!its_alloc_vpe_table(vpe_id)) {
>  		its_vpe_id_free(vpe_id);
> -		its_free_pending_table(vpe->vpt_page);
> +		its_free_pending_table(vpt_page);
>  		return -ENOMEM;
>  	}
>  

Oops, well caught. Please repost this patch with your own SoB added
though, as you're posting the patch on behalf of someone else.

Thanks,

	M.
-- 
Without deviation from the norm, progress is not possible.

  reply	other threads:[~2019-07-26  9:18 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-07-26  1:51 [PATCH] irqchip/gic-v3-its: Free unused vpt_page when alloc vpe table fail Shaokun Zhang
2019-07-26  9:18 ` Marc Zyngier [this message]
2019-07-26  9:24   ` Zhangshaokun
2019-07-26  9:32 ` [PATCH v2] " Shaokun Zhang
2019-07-26 13:17   ` Marc Zyngier

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=20190726101844.79cb10b5@why \
    --to=marc.zyngier@arm.com \
    --cc=jason@lakedaemon.net \
    --cc=linux-kernel@vger.kernel.org \
    --cc=tangnianyao@huawei.com \
    --cc=tglx@linutronix.de \
    --cc=zhangshaokun@hisilicon.com \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.