u-boot/arch
Pali Rohár 5692e5b244 arm: mvebu: mbus: Fix mbus driver to work also after U-Boot relocation
mbus driver is initialized from arch_cpu_init() callback which is called
before relocation. This driver stores lot of functions and structure
pointers into global variables, so it is data position dependent.

Therefore after relocations all pointers are invalid and driver does not
work anymore as all pointers referes to the old memory, which overlaps with
CONFIG_SYS_LOAD_ADDR and ${loadaddr}.

For example U-Boot fuse command crashes if loadaddr memory is cleared or
rewritten by some image loaded by U-Boot load command.

  mw.w ${loadaddr} 0x0 10000
  fuse read 0 1 2

Fix this issue by removing of all mbus global variables in which are stored
pointers to structures or functions which changes during relocation. And
replace it by direct function calls (not via pointers). With this change
fuse command finally works.

Signed-off-by: Pali Rohár <pali@kernel.org>
Reviewed-by: Chris Packham <chris.packham@alliedtelesis.co.nz>
Reviewed-by: Stefan Roese <sr@denx.de>
2022-08-23 12:35:37 +02:00
..
arc arc: Move SYS_LITTLE_ENDIAN / SYS_BIG_ENDIAN selection to Kconfig 2022-08-12 16:10:49 -04:00
arm arm: mvebu: mbus: Fix mbus driver to work also after U-Boot relocation 2022-08-23 12:35:37 +02:00
m68k Remove CONFIG_SYS_FSL_SCFG_IODSECR1_ADDR et al 2022-08-12 16:10:49 -04:00
microblaze zynqmp: Run board_get_usable_ram_top() only on main U-Boot 2022-07-26 08:23:54 +02:00
mips mips: mtmips: add two reference boards for mt7621 2022-07-13 23:03:37 +02:00
nios2 linker_lists: Rename sections to remove . prefix 2022-06-23 12:58:18 -04:00
powerpc powerpc: remove support for kmtergr1 and MPC8309 2022-08-20 22:45:00 -04:00
riscv riscv: ae350: Fix XIP config boot failure 2022-08-11 18:46:07 +08:00
sandbox bootstd: Add vbe bootmeth into sandbox 2022-08-12 08:17:11 -04:00
sh sh: Remove unused code in arch/sh/lib/bootm.c 2022-08-04 16:18:47 -04:00
x86 video: Rename structs and functions to avoid VBE 2022-08-12 08:14:23 -04:00
xtensa xtensa: Switch to using CONFIG_XTENSA for building device trees 2022-06-28 17:03:31 -04:00
.gitignore
Kconfig arc: Move SYS_LITTLE_ENDIAN / SYS_BIG_ENDIAN selection to Kconfig 2022-08-12 16:10:49 -04:00
Kconfig.nxp Convert CONFIG_SYS_FSL_NUM_CC_PLLS to Kconfig 2022-08-12 16:10:49 -04:00
u-boot-elf.lds