]> git.baikalelectronics.ru Git - uboot.git/commit
socfpga: arria10: Allow dcache_enable before relocation
authorPaweł Anikiel <pan@semihalf.com>
Fri, 17 Jun 2022 10:47:26 +0000 (12:47 +0200)
committerTien Fong Chee <tien.fong.chee@intel.com>
Fri, 1 Jul 2022 06:57:15 +0000 (14:57 +0800)
commit45599a51a7332426c0a94a822a9a18dbfca11cee
tree27a3b69531fc9a55d833ff44a42d14b669feda29
parentc3ae6fab0ee69aa2507a4bca83ab2e6417337bdf
socfpga: arria10: Allow dcache_enable before relocation

Before relocating to SDRAM, the ECC is initialized by clearing the
whole SDRAM. In order to speed this up, dcache_enable is used (see
sdram_init_ecc_bits).

Since commit 2e4fa5bed8a5 ("arm: cp15: update DACR value to activate
access control"), this no longer works, because running code in OCRAM
with the XN bit set causes a page fault. Override dram_bank_mmu_setup
to disable XN in the OCRAM and setup DRAM dcache before relocation.

Signed-off-by: Paweł Anikiel <pan@semihalf.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
arch/arm/mach-socfpga/misc_arria10.c