MLK-22866 imx8: Remove the optee shared memory from DDR banks rel_imx_4.19.35_1.1.0
authorYe Li <ye.li@nxp.com>
Tue, 29 Oct 2019 07:11:33 +0000 (00:11 -0700)
committerYe Li <ye.li@nxp.com>
Tue, 29 Oct 2019 08:02:56 +0000 (01:02 -0700)
commit4d377539a1190e838eae5d8b8a794dde0696d572
tree12aafd62b1dc0785f6b6a5f0be0bba654acba60e
parent64f857aefa3050bbfc1c096b873f5b37644722e0
MLK-22866 imx8: Remove the optee shared memory from DDR banks

Optee has 4MB shared memory at its top space which was assigned to
non-secure OS partition in ATF. By default this memory is added to
u-boot DDR banks and will pass to kernel. This means kernel has possibility
to allocate from this memory for system usage. At same time this memory is
used by optee and mem-remapped by optee kernel driver. So it is possible to
have conflict and cause kernel crash.

Fix the issue by removing the shared memory from u-boot DDR banks. Then it
is not visible for both u-boot and kernel and can avoid such issue.

Signed-off-by: Ye Li <ye.li@nxp.com>
Reviewed-by: Anson Huang <Anson.Huang@nxp.com>
(cherry picked from commit 164279c42de0d058b7abe198cc154ee683087e6a)
arch/arm/mach-imx/imx8/cpu.c