forked from luck/tmp_suning_uos_patched
ed423d80bb
[ Upstream commit 382e6e177bc1c02473e56591fe5083ae1e4904f6 ] The arm64 entry code suffers from an annoying issue on taking a NMI, as it sets PMR to a value that actually allows IRQs to be acknowledged. This is done for consistency with other parts of the code, and is in the process of being fixed. This shouldn't be a problem, as we are not enabling interrupts whilst in NMI context. However, in the infortunate scenario that we took a spurious NMI (retired before the read of IAR) *and* that there is an IRQ pending at the same time, we'll ack the IRQ in NMI context. Too bad. In order to avoid deadlocks while running something like perf, teach the GICv3 driver about this situation: if we were in a context where no interrupt should have fired, transiently set PMR to a value that only allows NMIs before acking the pending interrupt, and restore the original value after that. This papers over the core issue for the time being, and makes NMIs great again. Sort of. Fixes: 4d6a38da8e79e94c ("arm64: entry: always set GIC_PRIO_PSR_I_SET during entry") Co-developed-by: Mark Rutland <mark.rutland@arm.com> Signed-off-by: Mark Rutland <mark.rutland@arm.com> Signed-off-by: Marc Zyngier <maz@kernel.org> Reviewed-by: Mark Rutland <mark.rutland@arm.com> Link: https://lore.kernel.org/lkml/20210610145731.1350460-1-maz@kernel.org Signed-off-by: Sasha Levin <sashal@kernel.org> |
||
---|---|---|
.. | ||
alphascale_asm9260-icoll.h | ||
exynos-combiner.c | ||
irq-al-fic.c | ||
irq-alpine-msi.c | ||
irq-armada-370-xp.c | ||
irq-aspeed-i2c-ic.c | ||
irq-aspeed-scu-ic.c | ||
irq-aspeed-vic.c | ||
irq-ath79-cpu.c | ||
irq-ath79-misc.c | ||
irq-ativic32.c | ||
irq-atmel-aic-common.c | ||
irq-atmel-aic-common.h | ||
irq-atmel-aic.c | ||
irq-atmel-aic5.c | ||
irq-bcm2835.c | ||
irq-bcm2836.c | ||
irq-bcm6345-l1.c | ||
irq-bcm7038-l1.c | ||
irq-bcm7120-l2.c | ||
irq-brcmstb-l2.c | ||
irq-clps711x.c | ||
irq-crossbar.c | ||
irq-csky-apb-intc.c | ||
irq-csky-mpintc.c | ||
irq-davinci-aintc.c | ||
irq-davinci-cp-intc.c | ||
irq-digicolor.c | ||
irq-dw-apb-ictl.c | ||
irq-eznps.c | ||
irq-ftintc010.c | ||
irq-gic-common.c | ||
irq-gic-common.h | ||
irq-gic-pm.c | ||
irq-gic-realview.c | ||
irq-gic-v2m.c | ||
irq-gic-v3-its-fsl-mc-msi.c | ||
irq-gic-v3-its-pci-msi.c | ||
irq-gic-v3-its-platform-msi.c | ||
irq-gic-v3-its.c | ||
irq-gic-v3-mbi.c | ||
irq-gic-v3.c | ||
irq-gic-v4.c | ||
irq-gic.c | ||
irq-goldfish-pic.c | ||
irq-hip04.c | ||
irq-i8259.c | ||
irq-imgpdc.c | ||
irq-imx-gpcv2.c | ||
irq-imx-intmux.c | ||
irq-imx-irqsteer.c | ||
irq-ingenic-tcu.c | ||
irq-ingenic.c | ||
irq-ixp4xx.c | ||
irq-jcore-aic.c | ||
irq-keystone.c | ||
irq-loongson-htpic.c | ||
irq-loongson-htvec.c | ||
irq-loongson-liointc.c | ||
irq-loongson-pch-msi.c | ||
irq-loongson-pch-pic.c | ||
irq-lpc32xx.c | ||
irq-ls-extirq.c | ||
irq-ls-scfg-msi.c | ||
irq-ls1x.c | ||
irq-madera.c | ||
irq-mbigen.c | ||
irq-meson-gpio.c | ||
irq-mips-cpu.c | ||
irq-mips-gic.c | ||
irq-mmp.c | ||
irq-mscc-ocelot.c | ||
irq-mst-intc.c | ||
irq-mtk-cirq.c | ||
irq-mtk-sysirq.c | ||
irq-mvebu-gicp.c | ||
irq-mvebu-icu.c | ||
irq-mvebu-odmi.c | ||
irq-mvebu-pic.c | ||
irq-mvebu-sei.c | ||
irq-mxs.c | ||
irq-nvic.c | ||
irq-omap-intc.c | ||
irq-ompic.c | ||
irq-or1k-pic.c | ||
irq-orion.c | ||
irq-owl-sirq.c | ||
irq-partition-percpu.c | ||
irq-pic32-evic.c | ||
irq-pruss-intc.c | ||
irq-rda-intc.c | ||
irq-renesas-h8s.c | ||
irq-renesas-h8300h.c | ||
irq-renesas-intc-irqpin.c | ||
irq-renesas-irqc.c | ||
irq-renesas-rza1.c | ||
irq-riscv-intc.c | ||
irq-sa11x0.c | ||
irq-sifive-plic.c | ||
irq-sirfsoc.c | ||
irq-sl28cpld.c | ||
irq-sni-exiu.c | ||
irq-st.c | ||
irq-stm32-exti.c | ||
irq-sun4i.c | ||
irq-sunxi-nmi.c | ||
irq-tango.c | ||
irq-tb10x.c | ||
irq-tegra.c | ||
irq-ti-sci-inta.c | ||
irq-ti-sci-intr.c | ||
irq-ts4800.c | ||
irq-uniphier-aidet.c | ||
irq-versatile-fpga.c | ||
irq-vf610-mscm-ir.c | ||
irq-vic.c | ||
irq-vt8500.c | ||
irq-xilinx-intc.c | ||
irq-xtensa-mx.c | ||
irq-xtensa-pic.c | ||
irq-zevio.c | ||
irqchip.c | ||
Kconfig | ||
Makefile | ||
qcom-irq-combiner.c | ||
qcom-pdc.c | ||
spear-shirq.c |