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


Groups > linux.kernel > #1463241 > unrolled thread

[PATCH] pnp: isapnp: make core more explicitly non-modular

Started byPaul Gortmaker <paul.gortmaker@windriver.com>
First post2016-08-16 00:50 +0200
Last post2016-08-16 08:30 +0200
Articles 3 — 3 participants

Back to article view | Back to linux.kernel


Contents

  [PATCH] pnp: isapnp: make core more explicitly non-modular Paul Gortmaker <paul.gortmaker@windriver.com> - 2016-08-16 00:50 +0200
    Re: [PATCH] pnp: isapnp: make core more explicitly non-modular "Rafael J. Wysocki" <rjw@rjwysocki.net> - 2016-08-16 01:30 +0200
    Re: [PATCH] pnp: isapnp: make core more explicitly non-modular Jaroslav Kysela <perex@perex.cz> - 2016-08-16 08:30 +0200

#1463241 — [PATCH] pnp: isapnp: make core more explicitly non-modular

FromPaul Gortmaker <paul.gortmaker@windriver.com>
Date2016-08-16 00:50 +0200
Subject[PATCH] pnp: isapnp: make core more explicitly non-modular
Message-ID<s6yRI-3f5-23@gated-at.bofh.it>
The Makefile currently controlling compilation of this code is:

obj-y                   += pnp.o
pnp-y                   := core.o compat.o

...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.

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.

We don't replace module.h with init.h since the file already has that.
But we do add moduleparam.h since the file does use module_param().

Cc: Jaroslav Kysela <perex@perex.cz>
Cc: "Rafael J. Wysocki" <rafael.j.wysocki@intel.com>
Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com>
---
 drivers/pnp/isapnp/core.c | 5 +----
 1 file changed, 1 insertion(+), 4 deletions(-)

diff --git a/drivers/pnp/isapnp/core.c b/drivers/pnp/isapnp/core.c
index cf88f9b62445..d8bf5a13aa07 100644
--- a/drivers/pnp/isapnp/core.c
+++ b/drivers/pnp/isapnp/core.c
@@ -34,7 +34,7 @@
  *  2003-08-11	Resource Management Updates - Adam Belay <ambx1@neo.rr.com>
  */
 
-#include <linux/module.h>
+#include <linux/moduleparam.h>
 #include <linux/kernel.h>
 #include <linux/errno.h>
 #include <linux/delay.h>
@@ -54,8 +54,6 @@ static int isapnp_rdp;		/* Read Data Port */
 static int isapnp_reset = 1;	/* reset all PnP cards (deactivate) */
 static int isapnp_verbose = 1;	/* verbose mode */
 
-MODULE_AUTHOR("Jaroslav Kysela <perex@perex.cz>");
-MODULE_DESCRIPTION("Generic ISA Plug & Play support");
 module_param(isapnp_disable, int, 0);
 MODULE_PARM_DESC(isapnp_disable, "ISA Plug & Play disable");
 module_param(isapnp_rdp, int, 0);
@@ -64,7 +62,6 @@ module_param(isapnp_reset, int, 0);
 MODULE_PARM_DESC(isapnp_reset, "ISA Plug & Play reset all cards");
 module_param(isapnp_verbose, int, 0);
 MODULE_PARM_DESC(isapnp_verbose, "ISA Plug & Play verbose mode");
-MODULE_LICENSE("GPL");
 
 #define _PIDXR		0x279
 #define _PNPWRP		0xa79
-- 
2.8.4

[toc] | [next] | [standalone]


#1463275

From"Rafael J. Wysocki" <rjw@rjwysocki.net>
Date2016-08-16 01:30 +0200
Message-ID<s6zup-3Hz-11@gated-at.bofh.it>
In reply to#1463241
On Monday, August 15, 2016 06:42:33 PM Paul Gortmaker wrote:
> The Makefile currently controlling compilation of this code is:
> 
> obj-y                   += pnp.o
> pnp-y                   := core.o compat.o
> 
> ...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.
> 
> 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.
> 
> We don't replace module.h with init.h since the file already has that.
> But we do add moduleparam.h since the file does use module_param().
> 
> Cc: Jaroslav Kysela <perex@perex.cz>
> Cc: "Rafael J. Wysocki" <rafael.j.wysocki@intel.com>
> Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com>

I'll queue up this one for v4.9, thanks!

Best,
Rafael

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


#1463445

FromJaroslav Kysela <perex@perex.cz>
Date2016-08-16 08:30 +0200
Message-ID<s6G2R-7Xd-15@gated-at.bofh.it>
In reply to#1463241
Dne 16.8.2016 v 00:42 Paul Gortmaker napsal(a):
> The Makefile currently controlling compilation of this code is:
> 
> obj-y                   += pnp.o
> pnp-y                   := core.o compat.o
> 
> ...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.
> 
> 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.
> 
> We don't replace module.h with init.h since the file already has that.
> But we do add moduleparam.h since the file does use module_param().
> 
> Cc: Jaroslav Kysela <perex@perex.cz>
> Cc: "Rafael J. Wysocki" <rafael.j.wysocki@intel.com>
> Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com>

Acked-by: Jaroslav Kysela <perex@perex.cz>

-- 
Jaroslav Kysela <perex@perex.cz>
Linux Sound Maintainer; ALSA Project; Red Hat, Inc.

[toc] | [prev] | [standalone]


Back to top | Article view | linux.kernel


csiph-web