u-boot/arch/arm/cpu/armv8/fsl-layerscape
Andre Przywara 6c7691edd5 armv8: Always unmask SErrors
The ARMv8 architecture describes the "SError interrupt" as the fourth
kind of exception, next to synchronous exceptions, IRQs, and FIQs.
Those SErrors signal exceptional conditions from which the system might
not easily recover, and are normally generated by the interconnect as a
response to some bus error. A typical situation is access to a
non-existing memory address or device, but it might be deliberately
triggered by a device as well.
The SError interrupt replaces the Armv7 asynchronous abort.

Trusted Firmware enters U-Boot (BL33) typically with SErrors masked,
and we never enable them. However any SError condition still triggers
the SError interrupt, and this condition stays pending, it just won't be
handled. If now later on the Linux kernel unmasks the "A" bit in PState,
it will immediately take the exception, leading to a kernel crash.
This leaves many people scratching their head about the reason for
this, and leads to long debug sessions, possibly looking at the wrong
places (the kernel, but not U-Boot).

To avoid the situation, just unmask SErrors early in the ARMv8 boot
process, so that the U-Boot exception handlers reports them in a timely
manner. As SErrors are typically asynchronous, the register dump does
not need to point at the actual culprit, but it should happen very
shortly after the condition.

For those exceptions to be taken, we also need to route them to EL2,
if U-Boot is running in this exception level.

This removes the respective code snippet from the Freescale lowlevel
routine, as this is now handled in generic ARMv8 code.

Reported-by: Nishanth Menon <nm@ti.com>
Signed-off-by: Andre Przywara <andre.przywara@arm.com>
2022-03-02 13:59:29 -05:00
..
doc WS cleanup: remove SPACE(s) followed by TAB 2021-09-30 09:08:16 -04:00
cpu.c Finish conversion of CONFIG_SYS_CLK_FREQ to Kconfig 2021-12-27 16:20:18 -05:00
cpu.h armv8: layerscape: add PSCI support for cpu release 2021-06-17 11:46:11 +05:30
fdt.c fdt_support: Add fdt_for_each_node_by_compatible() helper macro 2022-01-20 11:35:29 +01:00
fsl_lsch2_serdes.c arch/arm/cpu/armv8/fsl-layerscape/fsl_lsch2_serdes.c: Fix spelling of "resetting". 2022-01-13 07:57:49 -05:00
fsl_lsch2_speed.c Finish conversion of CONFIG_SYS_CLK_FREQ to Kconfig 2021-12-27 16:20:18 -05:00
fsl_lsch3_serdes.c armv8: lx2162a: Add Soc changes to support LX2162A 2020-12-10 13:56:39 +05:30
fsl_lsch3_speed.c Finish conversion of CONFIG_SYS_CLK_FREQ to Kconfig 2021-12-27 16:20:18 -05:00
icid.c fdt_support: Add fdt_for_each_node_by_compatible() helper macro 2022-01-20 11:35:29 +01:00
Kconfig Convert CONFIG_TIMESTAMP to Kconfig 2022-01-21 14:01:34 -05:00
lowlevel.S armv8: Always unmask SErrors 2022-03-02 13:59:29 -05:00
ls1012a_serdes.c SPDX: Convert all of our single license tags to Linux Kernel style 2018-05-07 09:34:12 -04:00
ls1028_ids.c armv8: ls1028a: use the official compatible string for the GPU 2021-11-09 17:18:23 +05:30
ls1028a_serdes.c armv8: ls1028a_serdes: Add few missing serdes protocols 2020-01-24 14:28:26 +05:30
ls1043_ids.c armv8: fsl-layerscape: fix SEC QI ICID setup 2019-03-03 22:01:09 +05:30
ls1043a_psci.S SPDX: Convert all of our single license tags to Linux Kernel style 2018-05-07 09:34:12 -04:00
ls1043a_serdes.c SPDX: Convert all of our single license tags to Linux Kernel style 2018-05-07 09:34:12 -04:00
ls1046_ids.c armv8: fsl-layerscape: fix SEC QI ICID setup 2019-03-03 22:01:09 +05:30
ls1046a_serdes.c armv8: ls1046afrwy: Add support for LS1046AFRWY platform 2019-06-19 12:54:57 +05:30
ls1088_ids.c armv8: fsl-layerscape: guard caam specific defines 2019-11-08 11:13:38 +05:30
ls1088a_serdes.c net: replace the "xfi" phy-mode with "10gbase-r" 2021-09-28 18:50:56 +03:00
ls2080a_serdes.c SPDX: Convert all of our single license tags to Linux Kernel style 2018-05-07 09:34:12 -04:00
ls2088_ids.c armv8: ls2088a: add icid setup for platform devices 2019-11-08 11:13:38 +05:30
lx2160_ids.c armv8: lx2160a: add icid setup for platform devices 2019-11-08 11:13:38 +05:30
lx2160a_serdes.c armv8: lx2162a: Add Soc changes to support LX2162A 2020-12-10 13:56:39 +05:30
Makefile armv8: lx2162a: Add Soc changes to support LX2162A 2020-12-10 13:56:39 +05:30
mp.c Finish conversion of CONFIG_SYS_CLK_FREQ to Kconfig 2021-12-27 16:20:18 -05:00
ppa.c common: Drop asm/global_data.h from common header 2021-02-02 15:33:42 -05:00
soc.c armv8: fsl-layerscape: rework the dwc3 snooping enable code 2021-11-09 17:18:23 +05:30
spintable.S armv8: Disable pointer authentication traps for EL1 2021-09-02 10:17:45 -04:00
spl.c Finish CONFIG_VID et al conversion to Kconfig 2021-12-27 08:41:38 -05:00