diff options
author | Lukasz Majewski <lukma@denx.de> | 2019-06-04 15:42:04 +0200 |
---|---|---|
committer | Stefano Babic <sbabic@denx.de> | 2019-07-19 20:14:50 +0200 |
commit | 1b8c986b684c481d2a3a87200e80421129abe32e (patch) | |
tree | 88e5f3f4b5f38f62e17bf4356cdac136978f19cc /drivers/serial | |
parent | 4b969deac059a6957cdce47195f1bdd763ee5f85 (diff) | |
download | u-boot-1b8c986b684c481d2a3a87200e80421129abe32e.tar.gz |
IMX: serial: dm: Set DM_FLAG_PRE_RELOC in the IMX uart driver
The DM_FLAG_PRE_RELOC shall be set unconditionally as this driver is going
to be re-used in both early SPL and U-Boot proper's pre-reloc.
For i.MX based devices it is crucial to have available the serial console
before relocation (otherwise the board may hand).
The device definition may be provided either via device tree description or
with U_BOOT_DEVICE(mxc_serial) definition. In the latter case the device
will not bind in U-Boot proper when DM_FLAG_PRE_RELOC is not set.
The !CONFIG_IS_ENABLED(OF_CONTROL) #if check was set as a "workaround" for
DM problem described in following commit 4687919684e0
("serial: Remove DM_FLAG_PRE_RELOC flag in various drivers").
Let's look on this check more thoroughly - we add this flag if the board
doesn't support OF_CONTROL. This is a bit strange as the serial_mxc.c can
be used with CONFIG_DM_SERIAL but without corresponding device tree
description (OF_CONTROL). In such case the aforementioned
U_BOOT_DEVICE(mxc_serial) definition is used.
Other boards/SoCs have this flag set unconditionally for serial driver.
Signed-off-by: Lukasz Majewski <lukma@denx.de>
Diffstat (limited to 'drivers/serial')
-rw-r--r-- | drivers/serial/serial_mxc.c | 2 |
1 files changed, 0 insertions, 2 deletions
diff --git a/drivers/serial/serial_mxc.c b/drivers/serial/serial_mxc.c index a435e68005..c5da8e45f5 100644 --- a/drivers/serial/serial_mxc.c +++ b/drivers/serial/serial_mxc.c @@ -360,9 +360,7 @@ U_BOOT_DRIVER(serial_mxc) = { #endif .probe = mxc_serial_probe, .ops = &mxc_serial_ops, -#if !CONFIG_IS_ENABLED(OF_CONTROL) .flags = DM_FLAG_PRE_RELOC, -#endif }; #endif |