From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754100AbcFTXFZ (ORCPT ); Mon, 20 Jun 2016 19:05:25 -0400 Received: from mail.windriver.com ([147.11.1.11]:51891 "EHLO mail.windriver.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753669AbcFTXFT (ORCPT ); Mon, 20 Jun 2016 19:05:19 -0400 From: Paul Gortmaker To: CC: Paul Gortmaker , Greg Kroah-Hartman , Jiri Slaby , Subject: [PATCH 3/3] serial: m32r_sio: make it explicitly non-modular Date: Mon, 20 Jun 2016 18:55:05 -0400 Message-ID: <20160620225505.7320-4-paul.gortmaker@windriver.com> X-Mailer: git-send-email 2.8.4 In-Reply-To: <20160620225505.7320-1-paul.gortmaker@windriver.com> References: <20160620225505.7320-1-paul.gortmaker@windriver.com> MIME-Version: 1.0 Content-Type: text/plain Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org The Kconfig currently controlling compilation of this code is: drivers/tty/serial/Kconfig:config SERIAL_M32R_SIO drivers/tty/serial/Kconfig: bool "M32R SIO I/F" ...meaning that it currently is not being built as a module by anyone. Lets remove the modular code that is essentially orphaned, so that when reading the driver there is no doubt it is builtin-only. Since module_init translates to device_initcall in the non-modular case, the init ordering remains unchanged with this commit. We also delete the MODULE_LICENSE tag etc. since all that information is already contained at the top of the file in the comments. We don't replace module.h with init.h since the file already has that. Cc: Greg Kroah-Hartman Cc: Jiri Slaby Cc: linux-serial@vger.kernel.org Signed-off-by: Paul Gortmaker --- drivers/tty/serial/m32r_sio.c | 18 +----------------- 1 file changed, 1 insertion(+), 17 deletions(-) diff --git a/drivers/tty/serial/m32r_sio.c b/drivers/tty/serial/m32r_sio.c index 68765f7c2645..ea29017d320a 100644 --- a/drivers/tty/serial/m32r_sio.c +++ b/drivers/tty/serial/m32r_sio.c @@ -30,7 +30,6 @@ #define SUPPORT_SYSRQ #endif -#include #include #include #include @@ -1060,19 +1059,4 @@ static int __init m32r_sio_init(void) return ret; } - -static void __exit m32r_sio_exit(void) -{ - int i; - - for (i = 0; i < UART_NR; i++) - uart_remove_one_port(&m32r_sio_reg, &m32r_sio_ports[i].port); - - uart_unregister_driver(&m32r_sio_reg); -} - -module_init(m32r_sio_init); -module_exit(m32r_sio_exit); - -MODULE_LICENSE("GPL"); -MODULE_DESCRIPTION("Generic M32R SIO serial driver"); +device_initcall(m32r_sio_init); -- 2.8.4