board: sl28: add config to enable console output on SER0
Sometimes it is desireable to have the console output on the first serial line. Introduce a configuration option for it (in the board scope). Signed-off-by: Michael Walle <michael@walle.cc> Reviewed-by: Priyanka Jain <priyanka.jain@nxp.com>
This commit is contained in:
parent
6d1ab4a10e
commit
9b3843f8f7
|
@ -133,6 +133,14 @@
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
|
#ifdef CONFIG_SL28_ENABLE_SER0_CONSOLE
|
||||||
|
/ {
|
||||||
|
chosen {
|
||||||
|
stdout-path = "serial2:115200n8";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
#endif
|
||||||
|
|
||||||
#ifdef CONFIG_SL28_SPL_LOADS_ATF_BL31
|
#ifdef CONFIG_SL28_SPL_LOADS_ATF_BL31
|
||||||
&binman {
|
&binman {
|
||||||
fit {
|
fit {
|
||||||
|
@ -250,6 +258,10 @@
|
||||||
u-boot,dm-pre-reloc;
|
u-boot,dm-pre-reloc;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
&lpuart1 {
|
||||||
|
u-boot,dm-pre-reloc;
|
||||||
|
};
|
||||||
|
|
||||||
&serial0 {
|
&serial0 {
|
||||||
u-boot,dm-pre-reloc;
|
u-boot,dm-pre-reloc;
|
||||||
};
|
};
|
||||||
|
|
|
@ -48,4 +48,14 @@ config SL28_BL32_ENTRY_ADDR
|
||||||
|
|
||||||
endif
|
endif
|
||||||
|
|
||||||
|
config SL28_ENABLE_SER0_CONSOLE
|
||||||
|
bool "Enable console output on SER0"
|
||||||
|
select DM_SERIAL
|
||||||
|
select SPL_DM_SERIAL
|
||||||
|
select FSL_LPUART
|
||||||
|
help
|
||||||
|
By default the console output of this board is on the second serial
|
||||||
|
line (SER1). Sometimes it is desirable to enable output on the first
|
||||||
|
serial line (SER0). For example, if you have a carrier which only
|
||||||
|
supports the first serial port.
|
||||||
endif
|
endif
|
||||||
|
|
|
@ -4,7 +4,7 @@ ifndef CONFIG_SPL_BUILD
|
||||||
obj-y += sl28.o cmds.o
|
obj-y += sl28.o cmds.o
|
||||||
endif
|
endif
|
||||||
|
|
||||||
obj-y += ddr.o
|
obj-y += common.o ddr.o
|
||||||
|
|
||||||
ifdef CONFIG_SPL_BUILD
|
ifdef CONFIG_SPL_BUILD
|
||||||
obj-y += spl.o
|
obj-y += spl.o
|
||||||
|
|
|
@ -0,0 +1,11 @@
|
||||||
|
// SPDX-License-Identifier: GPL-2.0+
|
||||||
|
|
||||||
|
#include <common.h>
|
||||||
|
#include <asm/global_data.h>
|
||||||
|
|
||||||
|
DECLARE_GLOBAL_DATA_PTR;
|
||||||
|
|
||||||
|
u32 get_lpuart_clk(void)
|
||||||
|
{
|
||||||
|
return gd->bus_clk / CONFIG_SYS_FSL_LPUART_CLK_DIV;
|
||||||
|
}
|
Loading…
Reference in New Issue