Linux-ARM-Kernel Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Lorenzo Pieralisi <lpieralisi@kernel.org>
To: Sascha Bischoff <Sascha.Bischoff@arm.com>
Cc: "linux-arm-kernel@lists.infradead.org"
	<linux-arm-kernel@lists.infradead.org>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	nd <nd@arm.com>, "maz@kernel.org" <maz@kernel.org>
Subject: Re: [PATCH v2 2/2] irqchip/gic-v5: Synchronize CPU interface disable
Date: Tue, 11 Aug 2026 18:31:52 +0200	[thread overview]
Message-ID: <antOeLXBm2yqVjZx@red-moon> (raw)
In-Reply-To: <20260811152630.942023-3-sascha.bischoff@arm.com>

On Tue, Aug 11, 2026 at 03:27:31PM +0000, Sascha Bischoff wrote:
> The write disabling the GICv5 CPU interface is only guaranteed to take
> effect after a context synchronization event. Without one, execution can
> return from gicv5_cpu_disable_interrupts() while an interrupt is still
> able to be taken.
> 
> Add an ISB after the ICC_CR0_EL1 write to ensure interrupts are
> disabled before the function returns. No corresponding ISB is added
> when enabling the interface, as interrupt delivery is asynchronous and
> there is no obvious benefit to waiting for it.
> 
> Fixes: 7ec80fb3f025 ("irqchip/gic-v5: Add GICv5 PPI support")
> Link: https://sashiko.dev/#/patchset/20260724104819.1296803-1-sascha.bischoff@arm.com?part=6
> Signed-off-by: Sascha Bischoff <sascha.bischoff@arm.com>
> ---
>  drivers/irqchip/irq-gic-v5.c | 1 +
>  1 file changed, 1 insertion(+)

Reviewed-by: Lorenzo Pieralisi <lpieralisi@kernel.org>

> diff --git a/drivers/irqchip/irq-gic-v5.c b/drivers/irqchip/irq-gic-v5.c
> index e9d1795235a66..6a99c541b559b 100644
> --- a/drivers/irqchip/irq-gic-v5.c
> +++ b/drivers/irqchip/irq-gic-v5.c
> @@ -983,6 +983,7 @@ static void gicv5_cpu_disable_interrupts(void)
>  
>  	cr0 = FIELD_PREP(ICC_CR0_EL1_EN, 0);
>  	write_sysreg_s(cr0, SYS_ICC_CR0_EL1);
> +	isb();
>  }
>  
>  static void gicv5_cpu_enable_interrupts(void)
> -- 
> 2.34.1


      reply	other threads:[~2026-08-11 16:32 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-08-11 15:26 [PATCH v2 0/2] irqchip/gic-v5: GICv5 KVM IRS review fixes Sascha Bischoff
2026-08-11 15:27 ` [PATCH v2 1/2] irqchip/gic-v5: Clear per-CPU IRS data on teardown Sascha Bischoff
2026-08-11 15:27 ` [PATCH v2 2/2] irqchip/gic-v5: Synchronize CPU interface disable Sascha Bischoff
2026-08-11 16:31   ` Lorenzo Pieralisi [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=antOeLXBm2yqVjZx@red-moon \
    --to=lpieralisi@kernel.org \
    --cc=Sascha.Bischoff@arm.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=maz@kernel.org \
    --cc=nd@arm.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox