]> git.ipfire.org Git - thirdparty/kernel/linux.git/commitdiff
irqchip/apple-aic: Spit out ICH_MISR_EL2 value on spurious vGIC MI
authorMarc Zyngier <maz@kernel.org>
Thu, 20 Nov 2025 17:24:53 +0000 (17:24 +0000)
committerOliver Upton <oupton@kernel.org>
Mon, 24 Nov 2025 22:29:11 +0000 (14:29 -0800)
It is all good and well to scream about spurious vGIC maintenance
interrupts. It would be even better to output the reason why, which
is already checked, but not printed out.

The unsuspecting kernel tinkerer thanks you.

Tested-by: Fuad Tabba <tabba@google.com>
Signed-off-by: Marc Zyngier <maz@kernel.org>
Tested-by: Mark Brown <broonie@kernel.org>
Link: https://msgid.link/20251120172540.2267180-4-maz@kernel.org
Signed-off-by: Oliver Upton <oupton@kernel.org>
drivers/irqchip/irq-apple-aic.c

index 032d66dceb8ec4ecea606bba1649e41ff68684ad..4607f4943b19a528259ba5febfcf194f6576e741 100644 (file)
@@ -411,12 +411,15 @@ static void __exception_irq_entry aic_handle_irq(struct pt_regs *regs)
        if (is_kernel_in_hyp_mode() &&
            (read_sysreg_s(SYS_ICH_HCR_EL2) & ICH_HCR_EL2_En) &&
            read_sysreg_s(SYS_ICH_MISR_EL2) != 0) {
+               u64 val;
+
                generic_handle_domain_irq(aic_irqc->hw_domain,
                                          AIC_FIQ_HWIRQ(AIC_VGIC_MI));
 
                if (unlikely((read_sysreg_s(SYS_ICH_HCR_EL2) & ICH_HCR_EL2_En) &&
-                            read_sysreg_s(SYS_ICH_MISR_EL2))) {
-                       pr_err_ratelimited("vGIC IRQ fired and not handled by KVM, disabling.\n");
+                            (val = read_sysreg_s(SYS_ICH_MISR_EL2)))) {
+                       pr_err_ratelimited("vGIC IRQ fired and not handled by KVM (MISR=%llx), disabling.\n",
+                                          val);
                        sysreg_clear_set_s(SYS_ICH_HCR_EL2, ICH_HCR_EL2_En, 0);
                }
        }