Received: by 2002:ad5:474a:0:0:0:0:0 with SMTP id i10csp2868448imu; Sun, 13 Jan 2019 12:01:50 -0800 (PST) X-Google-Smtp-Source: ALg8bN5/4GkYmCO0oIx9XDyAv3VQhrDnODNRi76gnwQCVWdqN2FP7y3lF4C+/MT+ej6ogapBuoDr X-Received: by 2002:a17:902:5a86:: with SMTP id r6mr6163401pli.301.1547409710857; Sun, 13 Jan 2019 12:01:50 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1547409710; cv=none; d=google.com; s=arc-20160816; b=oVE+AJeX9U7SkSIMXbNRQ7QmvwToNJlIhxEY9u1E34LApkM4Fhjb7UzeUVTnmBEivC RoJUbJVrdsDR8f8B7vaJUo18ysKo5K+Q8Ws/pC0IjVhRUCEGJuzwkxgBrH0PFenqDRrV PHwBN7xF9ncTGIDynX3UOzxMiG6vWN21d6IBqlrtxHyMoxNKOLgDyMTCEIepdd4yutAH 7o9+4Epe/rKdE9ecpD7vw0pw19bcWJsm84At33BAdOEBeMD5paSMCgoOnSZ8RAzR3oDG b+CkwH17nMdZFpSppCyAJgGVGEsiWuhyZP+2DBHHbOJaMAE1uR1xs6t0gPAOIWMqdDHx 71eA== 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=8unrmlfUkOllm0/NhimN+be3bdXafpQiM0KjBJIodgw=; b=iYj2e8Lr5YTSOpexC8UthbyDh8FRlCRwuC2tEncv981fIrbYHvJgX0T6xhl1rmnfya qhqivPJeKoUq68N39T+0uGHunsO30AsST5K1T1k2chqovM6Hdnfi9hwpBUKSF/fXz0qZ bkkboq/d3xXksWFq3aCPag9uDIxpKElcfQFT1bMPKqlBkpKrTXbAwCbrS3nmeW0bdEp8 SSDIR2+NeYI+UMvnr8jRQW8+80h1+TeoDT3pzB08SxwvNUJhCZRprXVaIlwIt1PG80HP GVklZfPu0A3O+b7uxnv7oENYQCxOC4yI3yhqxdGv7MJUQSZJWGxQjA9m56BIL1jofgbW JLZw== 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 k19si37045265pgn.20.2019.01.13.12.01.35; Sun, 13 Jan 2019 12:01:50 -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 S1726678AbfAMUAS (ORCPT + 99 others); Sun, 13 Jan 2019 15:00:18 -0500 Received: from mail1.windriver.com ([147.11.146.13]:50247 "EHLO mail1.windriver.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726437AbfAMUAH (ORCPT ); Sun, 13 Jan 2019 15:00:07 -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 x0DIei7d026207 (version=TLSv1 cipher=AES128-SHA bits=128 verify=FAIL); Sun, 13 Jan 2019 10:40:44 -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, 13 Jan 2019 10:40:43 -0800 From: Paul Gortmaker To: Lee Jones CC: , Paul Gortmaker , Mark Brown , Charles Keepax , Subject: [PATCH 18/18] mfd: wm8400-core: Make it explicitly non-modular Date: Sun, 13 Jan 2019 13:36:49 -0500 Message-ID: <1547404609-14161-19-git-send-email-paul.gortmaker@windriver.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1547404609-14161-1-git-send-email-paul.gortmaker@windriver.com> References: <1547404609-14161-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: Charles Keepax Cc: patches@opensource.cirrus.com Signed-off-by: Paul Gortmaker Acked-by: Linus Walleij Acked-by: Charles Keepax --- 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