]> git.karo-electronics.de Git - linux-beck.git/commitdiff
serial: samsung: earlycon support depends on CONFIG_SERIAL_SAMSUNG_CONSOLE
authorMarek Szyprowski <m.szyprowski@samsung.com>
Mon, 2 Feb 2015 09:47:35 +0000 (10:47 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Mon, 2 Feb 2015 19:11:00 +0000 (11:11 -0800)
EarlyCon support depends on serial console infrastructure, so the code
implementing it should depend on CONFIG_SERIAL_SAMSUNG_CONSOLE.

This patch fixes the following build break:
CC [M]  drivers/tty/serial/samsung.o
drivers/tty/serial/samsung.c:2468:1: error: expected declaration specifiers or ‘...’ before string constant
drivers/tty/serial/samsung.c:2468:1: error: expected declaration specifiers or ‘...’ before ‘s3c2410_setup_earlycon’
drivers/tty/serial/samsung.c:2487:1: error: expected declaration specifiers or ‘...’ before string constant
drivers/tty/serial/samsung.c:2487:1: error: expected declaration specifiers or ‘...’ before ‘s3c2412_setup_earlycon’
drivers/tty/serial/samsung.c:2488:1: error: expected declaration specifiers or ‘...’ before string constant
drivers/tty/serial/samsung.c:2488:1: error: expected declaration specifiers or ‘...’ before ‘s3c2440_setup_earlycon’
drivers/tty/serial/samsung.c:2489:1: error: expected declaration specifiers or ‘...’ before string constant
drivers/tty/serial/samsung.c:2489:1: error: expected declaration specifiers or ‘...’ before ‘s3c6400_setup_earlycon’
drivers/tty/serial/samsung.c:2506:1: error: expected declaration specifiers or ‘...’ before string constant
drivers/tty/serial/samsung.c:2506:1: error: expected declaration specifiers or ‘...’ before ‘s5pv210_setup_earlycon’
drivers/tty/serial/samsung.c:2507:1: error: expected declaration specifiers or ‘...’ before string constant
drivers/tty/serial/samsung.c:2507:1: error: expected declaration specifiers or ‘...’ before ‘exynos4210_setup_earlycon’
drivers/tty/serial/samsung.c:2468:1: warning: ‘s3c2410_setup_earlycon’ defined but not used [-Wunused-function]
drivers/tty/serial/samsung.c:2487:1: warning: ‘s3c2412_setup_earlycon’ defined but not used [-Wunused-function]
drivers/tty/serial/samsung.c:2488:1: warning: ‘s3c2440_setup_earlycon’ defined but not used [-Wunused-function]
drivers/tty/serial/samsung.c:2489:1: warning: ‘s3c6400_setup_earlycon’ defined but not used [-Wunused-function]
drivers/tty/serial/samsung.c:2506:1: warning: ‘s5pv210_setup_earlycon’ defined but not used [-Wunused-function]
drivers/tty/serial/samsung.c:2507:1: warning: ‘exynos4210_setup_earlycon’ defined but not used [-Wunused-function]
make[3]: *** [drivers/tty/serial/samsung.o] Error 1

Reported-by: kbuild test robot <fengguang.wu@intel.com>
Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/tty/serial/samsung.c

index 236abae97613a383f1cc6030b1d01aa0a58919a8..af821a9087204ec654f637a617513ba06d68a0ef 100644 (file)
@@ -2396,6 +2396,7 @@ static struct platform_driver samsung_serial_driver = {
 
 module_platform_driver(samsung_serial_driver);
 
+#ifdef CONFIG_SERIAL_SAMSUNG_CONSOLE
 /*
  * Early console.
  */
@@ -2498,6 +2499,7 @@ OF_EARLYCON_DECLARE(exynos4210, "samsung,exynos4210-uart",
                        s5pv210_early_console_setup);
 EARLYCON_DECLARE(s5pv210, s5pv210_early_console_setup);
 EARLYCON_DECLARE(exynos4210, s5pv210_early_console_setup);
+#endif
 
 MODULE_ALIAS("platform:samsung-uart");
 MODULE_DESCRIPTION("Samsung SoC Serial port driver");