From patchwork Mon Jun 6 09:41:03 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Masahiro Yamada X-Patchwork-Id: 69400 Delivered-To: patch@linaro.org Received: by 10.140.106.246 with SMTP id e109csp1392472qgf; Mon, 6 Jun 2016 02:42:38 -0700 (PDT) X-Received: by 10.66.63.98 with SMTP id f2mr23975524pas.123.1465206158550; Mon, 06 Jun 2016 02:42:38 -0700 (PDT) Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id l5si25693795paa.207.2016.06.06.02.42.38; Mon, 06 Jun 2016 02:42:38 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-serial-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@nifty.com; spf=pass (google.com: best guess record for domain of linux-serial-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-serial-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751228AbcFFJmh (ORCPT + 2 others); Mon, 6 Jun 2016 05:42:37 -0400 Received: from conuserg-07.nifty.com ([210.131.2.74]:37518 "EHLO conuserg-07.nifty.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751193AbcFFJmg (ORCPT ); Mon, 6 Jun 2016 05:42:36 -0400 Received: from beagle.diag.org (p14092-ipngnfx01kyoto.kyoto.ocn.ne.jp [153.142.97.92]) (authenticated) by conuserg-07.nifty.com with ESMTP id u569e1aJ006920; Mon, 6 Jun 2016 18:40:09 +0900 DKIM-Filter: OpenDKIM Filter v2.10.3 conuserg-07.nifty.com u569e1aJ006920 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nifty.com; s=dec2015msa; t=1465206011; bh=BCpxlnPFd6VZz4qy9vc3FO1dn7GStl2cOKhnMm4sQfE=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=NZ0wbKa/juu7PZxiORi6KvfrveG+5RXct9PpgfXO03vZISZX4YmdluwcWrsOt900X VXPiF1uFpXwe+UEFGZWqU361VBSBs1XrVBh/BQWuKjMwI2CKmdoq1jc8xsNske7roh Oi8w4/Qrrbw1DSKzeL3c9x29oEkjcn0CA9k5pm1IlG7025xNd0FQE1giy5TmD8S4lo jykBfoWLhUgstHFRTNXoNfzeBjf07KAsKy+8FTnimcPPYL08mexNrY2eJMxPJzFhKA g7G7tParTZBshVzczjQWi3f3z3wGKTJVlTKDfpWMKBX64IBAA6zFeXmRjb5MuxFxe0 ugbv2Zkit404Q== X-Nifty-SrcIP: [153.142.97.92] From: Masahiro Yamada To: linux-serial@vger.kernel.org Cc: Arnd Bergmann , Peter Hurley , Rob Herring , Paul Burton , Greg Kroah-Hartman , Matthias Brugger , Masahiro Yamada , Matt Redfearn , Jiri Slaby , linux-kernel@vger.kernel.org, Paul Gortmaker , Anton Wuerfel , Scott Wood , Andy Shevchenko , Martin Sperl , Heikki Krogerus , Mathieu OTHACEHE , Ricardo Ribalda Delgado , Mans Rullgard Subject: [PATCH 4/4] serial: 8250_ingenic: drop #if conditional surrounding earlycon code Date: Mon, 6 Jun 2016 18:41:03 +0900 Message-Id: <1465206063-1018-5-git-send-email-yamada.masahiro@socionext.com> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1465206063-1018-1-git-send-email-yamada.masahiro@socionext.com> References: <1465206063-1018-1-git-send-email-yamada.masahiro@socionext.com> Sender: linux-serial-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-serial@vger.kernel.org The #if defined(CONFIG_SERIAL_EARLYCON) && !defined(MODULE) conditional has been added to the OF_EARLYCON_DECLARE() define. The same conditional can be dropped from 8250_ingenic.c because the unused symbols will be marked as __maybe_unsed. Also, the Kconfig dependency can become much simpler. Signed-off-by: Masahiro Yamada --- drivers/tty/serial/8250/8250_ingenic.c | 2 -- drivers/tty/serial/8250/Kconfig | 2 +- 2 files changed, 1 insertion(+), 3 deletions(-) -- 1.9.1 -- To unsubscribe from this list: send the line "unsubscribe linux-serial" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html diff --git a/drivers/tty/serial/8250/8250_ingenic.c b/drivers/tty/serial/8250/8250_ingenic.c index b0677f6..4d9dc10 100644 --- a/drivers/tty/serial/8250/8250_ingenic.c +++ b/drivers/tty/serial/8250/8250_ingenic.c @@ -48,7 +48,6 @@ static const struct of_device_id of_match[]; #define UART_MCR_MDCE BIT(7) #define UART_MCR_FCM BIT(6) -#if defined(CONFIG_SERIAL_EARLYCON) && !defined(MODULE) static struct earlycon_device *early_device; static uint8_t __init early_in(struct uart_port *port, int offset) @@ -141,7 +140,6 @@ OF_EARLYCON_DECLARE(jz4775_uart, "ingenic,jz4775-uart", EARLYCON_DECLARE(jz4780_uart, ingenic_early_console_setup); OF_EARLYCON_DECLARE(jz4780_uart, "ingenic,jz4780-uart", ingenic_early_console_setup); -#endif /* CONFIG_SERIAL_EARLYCON */ static void ingenic_uart_serial_out(struct uart_port *p, int offset, int value) { diff --git a/drivers/tty/serial/8250/Kconfig b/drivers/tty/serial/8250/Kconfig index b5a0f2e..7c6f7af 100644 --- a/drivers/tty/serial/8250/Kconfig +++ b/drivers/tty/serial/8250/Kconfig @@ -396,7 +396,7 @@ config SERIAL_8250_UNIPHIER config SERIAL_8250_INGENIC tristate "Support for Ingenic SoC serial ports" depends on SERIAL_8250 - depends on (OF_FLATTREE && SERIAL_8250_CONSOLE) || !SERIAL_EARLYCON + depends on OF_FLATTREE depends on MIPS || COMPILE_TEST help If you have a system using an Ingenic SoC and wish to make use of