MLK-22622 imx8m: Add Workaround for ROM SError issue
authorYe Li <ye.li@nxp.com>
Fri, 6 Sep 2019 08:21:00 +0000 (01:21 -0700)
committerYe Li <ye.li@nxp.com>
Sun, 29 Sep 2019 08:33:25 +0000 (01:33 -0700)
commitddc6076928ad160e9638c200ee78caa2601e6e6d
tree68603b9fed0783c91ba83927e26a4fe2cb38ce08
parentdea8b7b9dac2e471fc8313fd289beb71d03e65c2
MLK-22622 imx8m: Add Workaround for ROM SError issue

ROM SError happens on two cases:

1. ERR050342, on iMX8MQ HDCP enabled parts ROM writes to GPV1 register, but
when ROM patch lock is fused, this write will cause SError.

2. ERR050350, on iMX8MQ/MM/MN, when the field return fuse is burned, HAB
is field return mode, but the last 4K of ROM is still protected and cause SError.

Since ROM mask SError until ATF unmask it, so then ATF always meets the exception.
This patch works around the issue in SPL by enabling SPL Exception vectors table
and the SError exception, take the exception to eret immediately to clear the SError.

Signed-off-by: Ye Li <ye.li@nxp.com>
Reviewed-by: Peng Fan <peng.fan@nxp.com>
(cherry picked from commit f05dd45251ca82cc54e13a616f00744c26faab53)
(cherry picked from commit 25d059411e702a4002f1aa157839001f796dd9f6)
arch/arm/mach-imx/imx8m/Kconfig
arch/arm/mach-imx/imx8m/soc.c
arch/arm/mach-imx/lowlevel.S