Thread (6 messages) 6 messages, 3 authors, 2016-01-26

[PATCH] 8250: uniphier: allow modular build with 8250 console

From: Masahiro Yamada <hidden>
Date: 2016-01-21 11:39:20
Also in: linux-serial, lkml

Hi Arnd,


2016-01-14 7:33 GMT+09:00 Arnd Bergmann [off-list ref]:
quoted hunk ↗ jump to hunk
The recently added uniphier 8250 port driver supports early console
probing, and it supports being built as a module, but the combination
of the two fails to link:

ERROR: "early_serial8250_setup" [drivers/tty/serial/8250/8250_uniphier.ko] undefined!

Given that earlycon support in a loadable module makes no sense,
making that code conditional on 'MODULE' is a correct solution.

Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Fixes: b8d20e06eaad ("serial: 8250_uniphier: add earlycon support")
diff --git a/drivers/tty/serial/8250/8250_uniphier.c b/drivers/tty/serial/8250/8250_uniphier.c
index bab6b3ae2540..1b7bd26555b7 100644
--- a/drivers/tty/serial/8250/8250_uniphier.c
+++ b/drivers/tty/serial/8250/8250_uniphier.c
@@ -35,7 +35,7 @@ struct uniphier8250_priv {
        spinlock_t atomic_write_lock;
 };

-#ifdef CONFIG_SERIAL_8250_CONSOLE
+#if defined(CONFIG_SERIAL_8250_CONSOLE) && !defined(MODULE)
 static int __init uniphier_early_console_setup(struct earlycon_device *device,
                                               const char *options)
 {

If my patch (https://patchwork.kernel.org/patch/8029331/) is accepted,
this build error will be fixed as well.  But I doubt it is accepted soon...

So, I am OK with this workaround to fix "make allmodconfig".

Acked-by: Masahiro Yamada <redacted>



-- 
Best Regards
Masahiro Yamada
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help