* [U-Boot] [PATCH 1/2] ARM: exynos: Fix build error if SERIAL is disabled in SPL
@ 2016-04-30 22:36 Marek Vasut
2016-04-30 22:36 ` [U-Boot] [PATCH 2/2] ARM: exynos: Disable serial support " Marek Vasut
2016-05-01 18:55 ` [U-Boot] [PATCH 1/2] ARM: exynos: Fix build error if SERIAL is disabled " Simon Glass
0 siblings, 2 replies; 8+ messages in thread
From: Marek Vasut @ 2016-04-30 22:36 UTC (permalink / raw)
To: u-boot
If CONFIG_SPL_SERIAL_SUPPORT is not defined in include/configs/exynos5-common.h
the following error is produced during the build of the SPL:
arch/arm/mach-exynos/built-in.o: In function `do_lowlevel_init':
...u-boot/arch/arm/mach-exynos/lowlevel_init.c:221: undefined reference to `debug_uart_init'
Add additional condition to check if SPL build is in progress and
in that case check if CONFIG_SPL_SERIAL_SUPPORT is also set before
enabling the debug UART.
Signed-off-by: Marek Vasut <marex@denx.de>
Cc: Simon Glass <sjg@chromium.org>
Cc: Tom Rini <trini@konsulko.com>
---
arch/arm/mach-exynos/lowlevel_init.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/arch/arm/mach-exynos/lowlevel_init.c b/arch/arm/mach-exynos/lowlevel_init.c
index 6c39cb2..1e090fd 100644
--- a/arch/arm/mach-exynos/lowlevel_init.c
+++ b/arch/arm/mach-exynos/lowlevel_init.c
@@ -216,9 +216,12 @@ int do_lowlevel_init(void)
if (actions & DO_CLOCKS) {
system_clock_init();
#ifdef CONFIG_DEBUG_UART
+#if (defined(CONFIG_SPL_BUILD) && defined(CONFIG_SPL_SERIAL_SUPPORT)) || \
+ !defined(CONFIG_SPL_BUILD)
exynos_pinmux_config(PERIPH_ID_UART3, PINMUX_FLAG_NONE);
debug_uart_init();
#endif
+#endif
mem_ctrl_init(actions & DO_MEM_RESET);
tzpc_init();
}
--
2.7.0
^ permalink raw reply related [flat|nested] 8+ messages in thread
* [U-Boot] [PATCH 2/2] ARM: exynos: Disable serial support in SPL
2016-04-30 22:36 [U-Boot] [PATCH 1/2] ARM: exynos: Fix build error if SERIAL is disabled in SPL Marek Vasut
@ 2016-04-30 22:36 ` Marek Vasut
2016-05-01 18:55 ` Simon Glass
2016-05-01 18:57 ` Tom Rini
2016-05-01 18:55 ` [U-Boot] [PATCH 1/2] ARM: exynos: Fix build error if SERIAL is disabled " Simon Glass
1 sibling, 2 replies; 8+ messages in thread
From: Marek Vasut @ 2016-04-30 22:36 UTC (permalink / raw)
To: u-boot
The exynos5 platforms use DM in U-Boot and do not use DM in SPL. The serial
driver, serial_s5p.c, is DM-only. This is OK for U-Boot, but in SPL, this
will fail with the following compile error:
drivers/built-in.o: In function `get_current':
...u-boot/drivers/serial/serial.c:387: undefined reference to `default_serial_console'
This warning happens because common/console.c is compiled into U-Boot SPL
if CONFIG_SPL_SERIAL_SUPPORT . The common/console.c invokes serial_*()
functions and since exynos5 does not use DM in SPL, these functions come
from drivers/serial/serial.c . The serial_*() locate default serial port
by calling default_serial_console(), but because the serial_s5p.c is DM-only,
it does no longer define default_serial_console(). Thus the error.
Signed-off-by: Marek Vasut <marex@denx.de>
Cc: Simon Glass <sjg@chromium.org>
Cc: Tom Rini <trini@konsulko.com>
---
include/configs/exynos5-common.h | 1 -
1 file changed, 1 deletion(-)
diff --git a/include/configs/exynos5-common.h b/include/configs/exynos5-common.h
index b2ff4dd..6846ad6 100644
--- a/include/configs/exynos5-common.h
+++ b/include/configs/exynos5-common.h
@@ -60,7 +60,6 @@
#define CONFIG_SPL_LIBCOMMON_SUPPORT
#define CONFIG_SPL_GPIO_SUPPORT
-#define CONFIG_SPL_SERIAL_SUPPORT
#define CONFIG_SPL_LIBGENERIC_SUPPORT
/* specific .lds file */
--
2.7.0
^ permalink raw reply related [flat|nested] 8+ messages in thread
* [U-Boot] [PATCH 1/2] ARM: exynos: Fix build error if SERIAL is disabled in SPL
2016-04-30 22:36 [U-Boot] [PATCH 1/2] ARM: exynos: Fix build error if SERIAL is disabled in SPL Marek Vasut
2016-04-30 22:36 ` [U-Boot] [PATCH 2/2] ARM: exynos: Disable serial support " Marek Vasut
@ 2016-05-01 18:55 ` Simon Glass
2016-05-26 5:01 ` Minkyu Kang
1 sibling, 1 reply; 8+ messages in thread
From: Simon Glass @ 2016-05-01 18:55 UTC (permalink / raw)
To: u-boot
+Minkyu
On 30 April 2016 at 16:36, Marek Vasut <marex@denx.de> wrote:
> If CONFIG_SPL_SERIAL_SUPPORT is not defined in include/configs/exynos5-common.h
> the following error is produced during the build of the SPL:
>
> arch/arm/mach-exynos/built-in.o: In function `do_lowlevel_init':
> ...u-boot/arch/arm/mach-exynos/lowlevel_init.c:221: undefined reference to `debug_uart_init'
>
> Add additional condition to check if SPL build is in progress and
> in that case check if CONFIG_SPL_SERIAL_SUPPORT is also set before
> enabling the debug UART.
>
> Signed-off-by: Marek Vasut <marex@denx.de>
> Cc: Simon Glass <sjg@chromium.org>
> Cc: Tom Rini <trini@konsulko.com>
> ---
> arch/arm/mach-exynos/lowlevel_init.c | 3 +++
> 1 file changed, 3 insertions(+)
Reviewed-by: Simon Glass <sjg@chromium.org>
^ permalink raw reply [flat|nested] 8+ messages in thread
* [U-Boot] [PATCH 2/2] ARM: exynos: Disable serial support in SPL
2016-04-30 22:36 ` [U-Boot] [PATCH 2/2] ARM: exynos: Disable serial support " Marek Vasut
@ 2016-05-01 18:55 ` Simon Glass
2016-05-01 18:57 ` Tom Rini
1 sibling, 0 replies; 8+ messages in thread
From: Simon Glass @ 2016-05-01 18:55 UTC (permalink / raw)
To: u-boot
On 30 April 2016 at 16:36, Marek Vasut <marex@denx.de> wrote:
> The exynos5 platforms use DM in U-Boot and do not use DM in SPL. The serial
> driver, serial_s5p.c, is DM-only. This is OK for U-Boot, but in SPL, this
> will fail with the following compile error:
>
> drivers/built-in.o: In function `get_current':
> ...u-boot/drivers/serial/serial.c:387: undefined reference to `default_serial_console'
>
> This warning happens because common/console.c is compiled into U-Boot SPL
> if CONFIG_SPL_SERIAL_SUPPORT . The common/console.c invokes serial_*()
> functions and since exynos5 does not use DM in SPL, these functions come
> from drivers/serial/serial.c . The serial_*() locate default serial port
> by calling default_serial_console(), but because the serial_s5p.c is DM-only,
> it does no longer define default_serial_console(). Thus the error.
>
> Signed-off-by: Marek Vasut <marex@denx.de>
> Cc: Simon Glass <sjg@chromium.org>
> Cc: Tom Rini <trini@konsulko.com>
> ---
> include/configs/exynos5-common.h | 1 -
> 1 file changed, 1 deletion(-)
Reviewed-by: Simon Glass <sjg@chromium.org>
^ permalink raw reply [flat|nested] 8+ messages in thread
* [U-Boot] [PATCH 2/2] ARM: exynos: Disable serial support in SPL
2016-04-30 22:36 ` [U-Boot] [PATCH 2/2] ARM: exynos: Disable serial support " Marek Vasut
2016-05-01 18:55 ` Simon Glass
@ 2016-05-01 18:57 ` Tom Rini
2016-05-01 19:46 ` Marek Vasut
1 sibling, 1 reply; 8+ messages in thread
From: Tom Rini @ 2016-05-01 18:57 UTC (permalink / raw)
To: u-boot
On Sun, May 01, 2016 at 12:36:12AM +0200, Marek Vasut wrote:
> The exynos5 platforms use DM in U-Boot and do not use DM in SPL. The serial
> driver, serial_s5p.c, is DM-only. This is OK for U-Boot, but in SPL, this
> will fail with the following compile error:
>
> drivers/built-in.o: In function `get_current':
> ...u-boot/drivers/serial/serial.c:387: undefined reference to `default_serial_console'
>
> This warning happens because common/console.c is compiled into U-Boot SPL
> if CONFIG_SPL_SERIAL_SUPPORT . The common/console.c invokes serial_*()
> functions and since exynos5 does not use DM in SPL, these functions come
> from drivers/serial/serial.c . The serial_*() locate default serial port
> by calling default_serial_console(), but because the serial_s5p.c is DM-only,
> it does no longer define default_serial_console(). Thus the error.
This is OK short term, can you see if turning on DM in SPL is easy for
these platforms instead? Thanks!
--
Tom
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: Digital signature
URL: <http://lists.denx.de/pipermail/u-boot/attachments/20160501/bf740ac0/attachment.sig>
^ permalink raw reply [flat|nested] 8+ messages in thread
* [U-Boot] [PATCH 2/2] ARM: exynos: Disable serial support in SPL
2016-05-01 18:57 ` Tom Rini
@ 2016-05-01 19:46 ` Marek Vasut
2016-05-26 5:01 ` Minkyu Kang
0 siblings, 1 reply; 8+ messages in thread
From: Marek Vasut @ 2016-05-01 19:46 UTC (permalink / raw)
To: u-boot
On 05/01/2016 08:57 PM, Tom Rini wrote:
> On Sun, May 01, 2016 at 12:36:12AM +0200, Marek Vasut wrote:
>
>> The exynos5 platforms use DM in U-Boot and do not use DM in SPL. The serial
>> driver, serial_s5p.c, is DM-only. This is OK for U-Boot, but in SPL, this
>> will fail with the following compile error:
>>
>> drivers/built-in.o: In function `get_current':
>> ...u-boot/drivers/serial/serial.c:387: undefined reference to `default_serial_console'
>>
>> This warning happens because common/console.c is compiled into U-Boot SPL
>> if CONFIG_SPL_SERIAL_SUPPORT . The common/console.c invokes serial_*()
>> functions and since exynos5 does not use DM in SPL, these functions come
>> from drivers/serial/serial.c . The serial_*() locate default serial port
>> by calling default_serial_console(), but because the serial_s5p.c is DM-only,
>> it does no longer define default_serial_console(). Thus the error.
>
> This is OK short term
Yes, indeed.
> can you see if turning on DM in SPL is easy for
> these platforms instead? Thanks!
>
I hope Simon can take a look into that ;-)
--
Best regards,
Marek Vasut
^ permalink raw reply [flat|nested] 8+ messages in thread
* [U-Boot] [PATCH 2/2] ARM: exynos: Disable serial support in SPL
2016-05-01 19:46 ` Marek Vasut
@ 2016-05-26 5:01 ` Minkyu Kang
0 siblings, 0 replies; 8+ messages in thread
From: Minkyu Kang @ 2016-05-26 5:01 UTC (permalink / raw)
To: u-boot
On 02/05/16 04:46, Marek Vasut wrote:
> On 05/01/2016 08:57 PM, Tom Rini wrote:
>> On Sun, May 01, 2016 at 12:36:12AM +0200, Marek Vasut wrote:
>>
>>> The exynos5 platforms use DM in U-Boot and do not use DM in SPL. The serial
>>> driver, serial_s5p.c, is DM-only. This is OK for U-Boot, but in SPL, this
>>> will fail with the following compile error:
>>>
>>> drivers/built-in.o: In function `get_current':
>>> ...u-boot/drivers/serial/serial.c:387: undefined reference to `default_serial_console'
>>>
>>> This warning happens because common/console.c is compiled into U-Boot SPL
>>> if CONFIG_SPL_SERIAL_SUPPORT . The common/console.c invokes serial_*()
>>> functions and since exynos5 does not use DM in SPL, these functions come
>>> from drivers/serial/serial.c . The serial_*() locate default serial port
>>> by calling default_serial_console(), but because the serial_s5p.c is DM-only,
>>> it does no longer define default_serial_console(). Thus the error.
>>
>> This is OK short term
>
> Yes, indeed.
>
>> can you see if turning on DM in SPL is easy for
>> these platforms instead? Thanks!
>>
> I hope Simon can take a look into that ;-)
>
applied to u-boot-samsung.
Thanks,
Minkyu Kang.
^ permalink raw reply [flat|nested] 8+ messages in thread
* [U-Boot] [PATCH 1/2] ARM: exynos: Fix build error if SERIAL is disabled in SPL
2016-05-01 18:55 ` [U-Boot] [PATCH 1/2] ARM: exynos: Fix build error if SERIAL is disabled " Simon Glass
@ 2016-05-26 5:01 ` Minkyu Kang
0 siblings, 0 replies; 8+ messages in thread
From: Minkyu Kang @ 2016-05-26 5:01 UTC (permalink / raw)
To: u-boot
On 02/05/16 03:55, Simon Glass wrote:
> +Minkyu
>
> On 30 April 2016 at 16:36, Marek Vasut <marex@denx.de> wrote:
>> If CONFIG_SPL_SERIAL_SUPPORT is not defined in include/configs/exynos5-common.h
>> the following error is produced during the build of the SPL:
>>
>> arch/arm/mach-exynos/built-in.o: In function `do_lowlevel_init':
>> ...u-boot/arch/arm/mach-exynos/lowlevel_init.c:221: undefined reference to `debug_uart_init'
>>
>> Add additional condition to check if SPL build is in progress and
>> in that case check if CONFIG_SPL_SERIAL_SUPPORT is also set before
>> enabling the debug UART.
>>
>> Signed-off-by: Marek Vasut <marex@denx.de>
>> Cc: Simon Glass <sjg@chromium.org>
>> Cc: Tom Rini <trini@konsulko.com>
>> ---
>> arch/arm/mach-exynos/lowlevel_init.c | 3 +++
>> 1 file changed, 3 insertions(+)
>
> Reviewed-by: Simon Glass <sjg@chromium.org>
>
>
applied to u-boot-samsung.
Thanks,
Minkyu Kang.
^ permalink raw reply [flat|nested] 8+ messages in thread
end of thread, other threads:[~2016-05-26 5:01 UTC | newest]
Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-04-30 22:36 [U-Boot] [PATCH 1/2] ARM: exynos: Fix build error if SERIAL is disabled in SPL Marek Vasut
2016-04-30 22:36 ` [U-Boot] [PATCH 2/2] ARM: exynos: Disable serial support " Marek Vasut
2016-05-01 18:55 ` Simon Glass
2016-05-01 18:57 ` Tom Rini
2016-05-01 19:46 ` Marek Vasut
2016-05-26 5:01 ` Minkyu Kang
2016-05-01 18:55 ` [U-Boot] [PATCH 1/2] ARM: exynos: Fix build error if SERIAL is disabled " Simon Glass
2016-05-26 5:01 ` Minkyu Kang
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox