Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1467799 > unrolled thread

[PATCH 0/4] gpio: delete MODULE_ tags in non-modular drivers

Started byPaul Gortmaker <paul.gortmaker@windriver.com>
First post2016-08-22 18:50 +0200
Last post2016-08-22 19:00 +0200
Articles 4 — 2 participants

Back to article view | Back to linux.kernel


Contents

  [PATCH 0/4] gpio: delete MODULE_ tags in non-modular drivers Paul Gortmaker <paul.gortmaker@windriver.com> - 2016-08-22 18:50 +0200
    [PATCH 1/4] gpio: msic: drop unused MODULE_ tags from non-modular code Paul Gortmaker <paul.gortmaker@windriver.com> - 2016-08-22 18:50 +0200
      Re: [PATCH 1/4] gpio: msic: drop unused MODULE_ tags from non-modular code Linus Walleij <linus.walleij@linaro.org> - 2016-08-23 11:30 +0200
    [PATCH 2/4] gpio: mxc: drop unused MODULE_ tags from non-modular code Paul Gortmaker <paul.gortmaker@windriver.com> - 2016-08-22 19:00 +0200

#1467799 — [PATCH 0/4] gpio: delete MODULE_ tags in non-modular drivers

FromPaul Gortmaker <paul.gortmaker@windriver.com>
Date2016-08-22 18:50 +0200
Subject[PATCH 0/4] gpio: delete MODULE_ tags in non-modular drivers
Message-ID<s90A9-iZ-15@gated-at.bofh.it>
A nice simple series, with zero runtime changes.  We delete tags like
MODULE_LICENSE, MODULE_AUTHOR (while ensuring the documentation at the
top of file reflects author and license) etc from bool drivers where
the tags are no-ops.

Then we are free to delete the module.h include, which we now know adds
about 750kB of output to an otherwise headerless empty file processed
by cpp.  In addition, it will be clear that the driver is non-modular
now, when inspecting the source code.

---

Cc: Alexandre Courbot <gnurou@gmail.com>
Cc: Daniel Mack <daniel@caiaq.de>
Cc: Juergen Beisert <kernel@pengutronix.de>
Cc: Linus Walleij <linus.walleij@linaro.org>
Cc: Mathias Nyman <mathias.nyman@linux.intel.com>
Cc: Shiraz Hashim <shiraz.linux.kernel@gmail.com>
Cc: Stefan Agner <stefan@agner.ch>
Cc: linux-gpio@vger.kernel.org

Paul Gortmaker (4):
  gpio: msic: drop unused MODULE_ tags from non-modular code
  gpio: mxc: drop unused MODULE_ tags from non-modular code
  gpio: spear-spics: drop unused MODULE_ tags from non-modular code
  gpio: vf610: drop unused MODULE_ tags from non-modular code

 drivers/gpio/gpio-msic.c        |  6 ------
 drivers/gpio/gpio-mxc.c         | 10 ++--------
 drivers/gpio/gpio-spear-spics.c |  7 +------
 drivers/gpio/gpio-vf610.c       |  7 +------
 4 files changed, 4 insertions(+), 26 deletions(-)

-- 
2.8.4

[toc] | [next] | [standalone]


#1467804 — [PATCH 1/4] gpio: msic: drop unused MODULE_ tags from non-modular code

FromPaul Gortmaker <paul.gortmaker@windriver.com>
Date2016-08-22 18:50 +0200
Subject[PATCH 1/4] gpio: msic: drop unused MODULE_ tags from non-modular code
Message-ID<s90Aa-iZ-31@gated-at.bofh.it>
In reply to#1467799
The Kconfig currently controlling compilation of this code is:

drivers/gpio/Kconfig:config GPIO_MSIC
drivers/gpio/Kconfig:   bool "Intel MSIC mixed signal gpio support"

...meaning that it currently is not being built as a module by anyone.

Lets remove the couple traces of modular infrastructure use, so that
when reading the driver there is no doubt it is builtin-only.

We 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: Linus Walleij <linus.walleij@linaro.org>
Cc: Alexandre Courbot <gnurou@gmail.com>
Cc: Mathias Nyman <mathias.nyman@linux.intel.com>
Cc: linux-gpio@vger.kernel.org
Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com>
---
 drivers/gpio/gpio-msic.c | 6 ------
 1 file changed, 6 deletions(-)

diff --git a/drivers/gpio/gpio-msic.c b/drivers/gpio/gpio-msic.c
index d75649787e6c..1b7ce7f85886 100644
--- a/drivers/gpio/gpio-msic.c
+++ b/drivers/gpio/gpio-msic.c
@@ -20,7 +20,6 @@
  *
  */
 
-#include <linux/module.h>
 #include <linux/kernel.h>
 #include <linux/slab.h>
 #include <linux/interrupt.h>
@@ -328,9 +327,4 @@ static int __init platform_msic_gpio_init(void)
 {
 	return platform_driver_register(&platform_msic_gpio_driver);
 }
-
 subsys_initcall(platform_msic_gpio_init);
-
-MODULE_AUTHOR("Mathias Nyman <mathias.nyman@linux.intel.com>");
-MODULE_DESCRIPTION("Intel Medfield MSIC GPIO driver");
-MODULE_LICENSE("GPL v2");
-- 
2.8.4

[toc] | [prev] | [next] | [standalone]


#1468430 — Re: [PATCH 1/4] gpio: msic: drop unused MODULE_ tags from non-modular code

FromLinus Walleij <linus.walleij@linaro.org>
Date2016-08-23 11:30 +0200
SubjectRe: [PATCH 1/4] gpio: msic: drop unused MODULE_ tags from non-modular code
Message-ID<s9gbU-1Ym-9@gated-at.bofh.it>
In reply to#1467804
On Mon, Aug 22, 2016 at 6:48 PM, Paul Gortmaker
<paul.gortmaker@windriver.com> wrote:

> The Kconfig currently controlling compilation of this code is:
>
> drivers/gpio/Kconfig:config GPIO_MSIC
> drivers/gpio/Kconfig:   bool "Intel MSIC mixed signal gpio support"
>
> ...meaning that it currently is not being built as a module by anyone.
>
> Lets remove the couple traces of modular infrastructure use, so that
> when reading the driver there is no doubt it is builtin-only.
>
> We 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: Linus Walleij <linus.walleij@linaro.org>
> Cc: Alexandre Courbot <gnurou@gmail.com>
> Cc: Mathias Nyman <mathias.nyman@linux.intel.com>
> Cc: linux-gpio@vger.kernel.org
> Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com>

Patch applied.

Yours,
Linus Walleij

[toc] | [prev] | [next] | [standalone]


#1467817 — [PATCH 2/4] gpio: mxc: drop unused MODULE_ tags from non-modular code

FromPaul Gortmaker <paul.gortmaker@windriver.com>
Date2016-08-22 19:00 +0200
Subject[PATCH 2/4] gpio: mxc: drop unused MODULE_ tags from non-modular code
Message-ID<s90JQ-my-27@gated-at.bofh.it>
In reply to#1467799
The Kconfig currently controlling compilation of this code is:

drivers/gpio/Kconfig:config GPIO_MXC
drivers/gpio/Kconfig:   def_bool y

...meaning that it currently is not being built as a module by anyone.

Lets remove the couple traces of modular infrastructure use, so that
when reading the driver there is no doubt it is builtin-only.

We delete the MODULE_LICENSE tag etc. since all that information
was (or is now) contained at the top of the file in the comments.
Note the original e-mail had a missing/typo'd @ symbol anyway.

We don't replace module.h with init.h since the file already has that.

Cc: Linus Walleij <linus.walleij@linaro.org>
Cc: Alexandre Courbot <gnurou@gmail.com>
Cc: Daniel Mack <daniel@caiaq.de>
Cc: Juergen Beisert <kernel@pengutronix.de>
Cc: linux-gpio@vger.kernel.org
Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com>
---
 drivers/gpio/gpio-mxc.c | 10 ++--------
 1 file changed, 2 insertions(+), 8 deletions(-)

diff --git a/drivers/gpio/gpio-mxc.c b/drivers/gpio/gpio-mxc.c
index 1b342a3842c8..e35af5249478 100644
--- a/drivers/gpio/gpio-mxc.c
+++ b/drivers/gpio/gpio-mxc.c
@@ -2,7 +2,8 @@
  * MXC GPIO support. (c) 2008 Daniel Mack <daniel@caiaq.de>
  * Copyright 2008 Juergen Beisert, kernel@pengutronix.de
  *
- * Based on code from Freescale,
+ * Based on code from Freescale Semiconductor,
+ * Authors: Daniel Mack, Juergen Beisert.
  * Copyright (C) 2004-2010 Freescale Semiconductor, Inc. All Rights Reserved.
  *
  * This program is free software; you can redistribute it and/or
@@ -33,7 +34,6 @@
 #include <linux/gpio.h>
 #include <linux/of.h>
 #include <linux/of_device.h>
-#include <linux/module.h>
 #include <linux/bug.h>
 
 enum mxc_gpio_hwtype {
@@ -511,9 +511,3 @@ static int __init gpio_mxc_init(void)
 	return platform_driver_register(&mxc_gpio_driver);
 }
 postcore_initcall(gpio_mxc_init);
-
-MODULE_AUTHOR("Freescale Semiconductor, "
-	      "Daniel Mack <danielncaiaq.de>, "
-	      "Juergen Beisert <kernel@pengutronix.de>");
-MODULE_DESCRIPTION("Freescale MXC GPIO");
-MODULE_LICENSE("GPL");
-- 
2.8.4

[toc] | [prev] | [standalone]


Back to top | Article view | linux.kernel


csiph-web