u-boot-brain/arch
Bin Meng 4854ebc57e arm: stm32mp: Remove DM_FLAG_PRE_RELOC flag
When a driver declares DM_FLAG_PRE_RELOC flag, it wishes to be
bound before relocation. However due to a bug in the DM core,
the flag only takes effect when devices are statically declared
via U_BOOT_DEVICE(). This bug has been fixed recently by commit
"dm: core: Respect drivers with the DM_FLAG_PRE_RELOC flag in
lists_bind_fdt()", but with the fix, it has a side effect that
all existing drivers that declared DM_FLAG_PRE_RELOC flag will
be bound before relocation now. This may expose potential boot
failure on some boards due to insufficient memory during the
pre-relocation stage.

To mitigate this potential impact, the following changes are
implemented:

- Remove DM_FLAG_PRE_RELOC flag in the driver, if the driver
  only supports configuration from device tree (OF_CONTROL)
- Keep DM_FLAG_PRE_RELOC flag in the driver only if the device
  is statically declared via U_BOOT_DEVICE()
- Surround DM_FLAG_PRE_RELOC flag with OF_CONTROL check, for
  drivers that support both statically declared devices and
  configuration from device tree

Signed-off-by: Bin Meng <bmeng.cn@gmail.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
Reviewed-by: Patrick Delaunay <patrick.delaunay@st.com>
2018-11-14 09:16:28 -08:00
..
arc emdk->emsdp: Rename board 2018-11-01 23:04:05 +03:00
arm arm: stm32mp: Remove DM_FLAG_PRE_RELOC flag 2018-11-14 09:16:28 -08:00
m68k m68k: ColdFire mcf5441x, add eSDHC support 2018-09-16 00:01:13 +02:00
microblaze arch: types.h: factor out fixed width typedefs to int-ll64.h 2018-09-10 20:48:16 -04:00
mips mips: Implement {in, out}_{le, be}_{16, 32, 64} and {in, out}_8 2018-11-14 09:16:27 -08:00
nds32 config.mk: Remove duplicated -fno-strict-aliasing 2018-09-25 21:50:34 -04:00
nios2 .gitignore: move *.dtb and *.dtb.S patterns to the top-level .gitignore 2018-06-18 14:43:12 -04:00
powerpc powerpc: t1040: Correct RCW EC2 settings 2018-10-29 13:19:43 -07:00
riscv riscv: bootm: Add dm_remove_devices_flags() call to do_bootm_linux() 2018-11-14 09:16:27 -08:00
sandbox test: dm: virtio: Add test cases for virtio uclass 2018-11-14 09:16:28 -08:00
sh sh: tmu: Zap get_tbclk and timer_read_counter 2018-09-15 03:19:07 +02:00
x86 x86: Implement arch-specific io accessor routines 2018-11-14 09:16:27 -08:00
xtensa xtensa: use asm-generic/atomic.h 2018-09-25 21:49:18 -04:00
.gitignore
Kconfig test: dm: virtio: Add test cases for virtio uclass 2018-11-14 09:16:28 -08:00