[PATCH 10/13] irqchip/armada-370-xp: Fix reenabling last per-CPU interrupt

Thomas Gleixner tglx at linutronix.de
Sun Jul 28 14:47:30 PDT 2024


On Mon, Jul 15 2024 at 12:51, Marek Behún wrote:
> The number of per-CPU interrupts is 29 (0 to 28). This is described by
> the constant MPIC_MAX_PER_CPU_IRQS, set to 28 (the maximum per-CPU
> interrupt).
>
> Commit 0fa4ce746d1d ("irqchip/armada-370-xp: Re-enable per-CPU
> interrupts at resume time") used the constant incorrectly in the
> for-loop, it used the operator < instead of <=, causing it to iterate
> only the first 28 interrupts (0 to 27), ignoring the last, 28th,
> per-CPU interrupt.
>
> To avoid this kind of confusions, fix this issue by renaming the constant
> to MPIC_PER_CPU_IRQS_NR and set it to 29, the number of per-CPU IRQs.
> Update its use in mpic_is_percpu_irq() accordingly.
>
> Fixes: 0fa4ce746d1d ("irqchip/armada-370-xp: Re-enable per-CPU interrupts at resume time")
> Signed-off-by: Marek Behún <kabel at kernel.org>

Please don't hide fixes in the middle of a refactoring series. Split
them out and make sure that they can be applied w/o prerequisites so
they can be easily backported.

Thanks,

        tglx



More information about the linux-arm-kernel mailing list