Re: [PATCH v3 8/8] s390/pci: Unregister the adapter interrupt first in zpci_irq_exit()
From: Niklas Schnelle
Date: Mon Oct 12 2026 - 05:10:54 EST
On Fri, 2026-10-09 at 08:15 +0200, Tobias Schumacher wrote:
> zpci_irq_exit() frees the interrupt bit vectors before unregistering the
> adapter interrupt whose handler uses them. This is only called from the
> pci_base_init() error path, where no handler is expected to run, but
> unregister first anyway so the vectors are never freed under a live
> handler.
>
> Signed-off-by: Tobias Schumacher <ts@xxxxxxxxxxxxx>
> ---
> arch/s390/pci/pci_irq.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/arch/s390/pci/pci_irq.c b/arch/s390/pci/pci_irq.c
> index 4b8ebb987580..16ae80ed2d13 100644
> --- a/arch/s390/pci/pci_irq.c
> +++ b/arch/s390/pci/pci_irq.c
> @@ -674,6 +674,7 @@ void __init zpci_irq_exit(void)
> {
> unsigned int cpu;
>
> + unregister_adapter_interrupt(&zpci_airq);
> if (irq_delivery == DIRECTED) {
> for_each_possible_cpu(cpu) {
> airq_iv_release(zpci_dibv[cpu]);
> @@ -684,5 +685,4 @@ void __init zpci_irq_exit(void)
> }
> if (zpci_sbv)
> airq_iv_release(zpci_sbv);
> - unregister_adapter_interrupt(&zpci_airq);
> }
As said in my reply to the Sashiko mail I think its concern is out of
scope for this patch and this is a worthwhile, free standing cleanup.
I agree that this is theoretical enough that we don't really need a
Fixes tag or Cc stable though I'd leave it to you.
Feel free to add my:
Reviewed-by: Niklas Schnelle <schnelle@xxxxxxxxxxxxx>