Received: by 2002:ad5:474a:0:0:0:0:0 with SMTP id i10csp6514972imu; Sun, 2 Dec 2018 20:29:40 -0800 (PST) X-Google-Smtp-Source: AFSGD/Wokh7H+AQRkUSlMOQPsRPttSe3DK+3IkKDnwpin39SViPSD+KKMYpKO028mgdHom9PF0xY X-Received: by 2002:a17:902:6e16:: with SMTP id u22mr14326148plk.175.1543811380695; Sun, 02 Dec 2018 20:29:40 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1543811380; cv=none; d=google.com; s=arc-20160816; b=VTv42DMnL9PvVXnDdO80N06EvthFTH+b0OxnwH9FgCT9uVQsl7asWx3aEIrcjrXdgQ YmZJn4tXmkaJoioog+0g9XukWOrjXaP0IOsxkrTKdsI5T7gkwzqugdXSEFrtrdZikXxL EE8j42WkMDkAHo4oWbLDiDQKbaiVyMB1dmcgbtS6/+GCNa7FS+FO22NvGkyBPqciGBwz Xnivys31R+WMaCdWO/oZs8v2Tj2emJsifuBpCfy5heMMcbjjRKy+rIQhtuoSS8OyTK6I Pcc386VPR6R4/1BMLOl1msP229WcJYX8RBwkJmeReTFFpSlez7CWL4DQ7GY+AMdza9RF F0ow== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from; bh=PoYcBRr7HeDpKbQHlQmpsvAC/aYSqmEKuevL4vC/B9w=; b=gTzg8rEfnZ5mP9MPwplUIXpiL213+QBs2T4HEn4DRcXeDmT5fpQQ2vBuHHJnlkw+po sXmZrOcXJqozlRKjrHzpTiTUHBK31ZZF3ElXjhl8Y4P/lRRSB9Vrun2sT62peuIEa/gR U9v9uEuvhx5rjm6qmcoyKOPKC7TA/D6yedxdUcyHFzZ5xh2D0VHptf+2tpw7zRk01pJ8 T7337PqxgJf6Hj9rf9dSvK3qCzKeYaX7zjoD47Fu7w/UP4HDRjmiHOnku2awmwJgnkOl vBv+YoKefFDqKHUbYXcB041Ihd3Yf7CztGX2i7DGljmSomLYMjH6b7WMTII+ntrVS5M6 xtpA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id c3si11241665pgw.425.2018.12.02.20.29.25; Sun, 02 Dec 2018 20:29:40 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726014AbeLCE2x (ORCPT + 99 others); Sun, 2 Dec 2018 23:28:53 -0500 Received: from mail1.windriver.com ([147.11.146.13]:60582 "EHLO mail1.windriver.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725807AbeLCE2w (ORCPT ); Sun, 2 Dec 2018 23:28:52 -0500 Received: from ALA-HCA.corp.ad.wrs.com ([147.11.189.40]) by mail1.windriver.com (8.15.2/8.15.1) with ESMTPS id wB34Sm5E015542 (version=TLSv1 cipher=AES128-SHA bits=128 verify=FAIL); Sun, 2 Dec 2018 20:28:48 -0800 (PST) Received: from yow-cube1.wrs.com (128.224.56.98) by ALA-HCA.corp.ad.wrs.com (147.11.189.40) with Microsoft SMTP Server id 14.3.408.0; Sun, 2 Dec 2018 20:28:48 -0800 From: Paul Gortmaker To: Lee Jones CC: , Paul Gortmaker , Mark Brown , Subject: [PATCH 22/22] mfd: wm8400-core: Make it explicitly non-modular Date: Sun, 2 Dec 2018 23:23:29 -0500 Message-ID: <1543811009-15112-23-git-send-email-paul.gortmaker@windriver.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1543811009-15112-1-git-send-email-paul.gortmaker@windriver.com> References: <1543811009-15112-1-git-send-email-paul.gortmaker@windriver.com> MIME-Version: 1.0 Content-Type: text/plain Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org The Kconfig currently controlling compilation of this code is: drivers/mfd/Kconfig:config MFD_WM8400 drivers/mfd/Kconfig: bool "Wolfson Microelectronics WM8400" ...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 was not in use by this code, the init ordering remains unchanged with this commit. A trivial function rename from wm8400_module_init to the name wm8400_driver_init is also done to reduce possible confusion. Also note that MODULE_DEVICE_TABLE is a no-op for non-modular code. We also delete the MODULE_LICENSE tag etc. since all that information is already contained at the top of the file in the comments. Cc: Lee Jones Cc: Mark Brown Cc: patches@opensource.cirrus.com Signed-off-by: Paul Gortmaker --- drivers/mfd/wm8400-core.c | 18 +++--------------- 1 file changed, 3 insertions(+), 15 deletions(-) diff --git a/drivers/mfd/wm8400-core.c b/drivers/mfd/wm8400-core.c index 8a98a2fc74e1..79756c83f5f0 100644 --- a/drivers/mfd/wm8400-core.c +++ b/drivers/mfd/wm8400-core.c @@ -12,7 +12,7 @@ * */ -#include +#include #include #include #include @@ -150,7 +150,6 @@ static const struct i2c_device_id wm8400_i2c_id[] = { { "wm8400", 0 }, { } }; -MODULE_DEVICE_TABLE(i2c, wm8400_i2c_id); static struct i2c_driver wm8400_i2c_driver = { .driver = { @@ -161,7 +160,7 @@ static struct i2c_driver wm8400_i2c_driver = { }; #endif -static int __init wm8400_module_init(void) +static int __init wm8400_driver_init(void) { int ret = -ENODEV; @@ -173,15 +172,4 @@ static int __init wm8400_module_init(void) return ret; } -subsys_initcall(wm8400_module_init); - -static void __exit wm8400_module_exit(void) -{ -#if IS_ENABLED(CONFIG_I2C) - i2c_del_driver(&wm8400_i2c_driver); -#endif -} -module_exit(wm8400_module_exit); - -MODULE_LICENSE("GPL"); -MODULE_AUTHOR("Mark Brown "); +subsys_initcall(wm8400_driver_init); -- 2.7.4