mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Thomas Renninger <trenn@suse.de>
To: trenn@suse.de
Cc: bjorn.helgaas@hp.com, gregkh@suse.de, jbaron@redhat.com,
	linux-kernel@vger.kernel.org
Subject: [PATCH 2/4] PNP: Compile all pnp built-in stuff in one module namespace
Date: Thu, 16 Sep 2010 00:11:46 +0200	[thread overview]
Message-ID: <1284588708-54170-3-git-send-email-trenn@suse.de> (raw)
In-Reply-To: <1284588708-54170-1-git-send-email-trenn@suse.de>

before, dynamic debug info (/sys/kernel/debug/dynamic_debug/control) showed
the file name as module name of each dynamic debug message (in square brackets):
drivers/pnp/core.c:198 [core]pnp_add_device p "%s device, IDs%s (%s)\012"
drivers/pnp/resource.c:619 [resource]pnp_add_bus_resource p "  add %pr\012"
..
drivers/pnp/pnpacpi/core.c:89 [core]pnpacpi_set_resources p "set resources\012"
..

With this patch the module name will be pnp for all "drivers/pnp/* -r" code:
drivers/pnp/core.c:198 [pnp]pnp_add_device p "%s device, IDs%s (%s)\012"
drivers/pnp/resource.c:619 [pnp]pnp_add_bus_resource p "  add %pr\012"
..
drivers/pnp/pnpacpi/core.c:112 [pnp]pnpacpi_disable_resources p "disable resources\012"

This has advantages:
  - Any pnp code can make use of the moduleparam.h interface, the modules
    will show up as pnp.param.
  - Passing pnp.ddebug as kernel boot param will enable all pnp debug messages
    with my previous patch and CONFIG_DYNAMIC_DEBUG enabled.


Signed-off-by: Thomas Renninger <trenn@suse.de>
CC: Bjorn Helgaas <bjorn.helgaas@hp.com>
CC: Jason Baron <jbaron@redhat.com>
CC: Greg KH <gregkh@suse.de>
CC: lkml <linux-kernel@vger.kernel.org>
---
 drivers/pnp/Makefile         |    6 ++++--
 drivers/pnp/isapnp/Makefile  |    6 +++---
 drivers/pnp/pnpacpi/Makefile |    3 ++-
 drivers/pnp/pnpbios/Makefile |    5 +++--
 4 files changed, 12 insertions(+), 8 deletions(-)

diff --git a/drivers/pnp/Makefile b/drivers/pnp/Makefile
index 8de3775..bfba893 100644
--- a/drivers/pnp/Makefile
+++ b/drivers/pnp/Makefile
@@ -2,11 +2,13 @@
 # Makefile for the Linux Plug-and-Play Support.
 #
 
-obj-y		:= core.o card.o driver.o resource.o manager.o support.o interface.o quirks.o
+obj-y		:= pnp.o
+
+pnp-y		:= core.o card.o driver.o resource.o manager.o support.o interface.o quirks.o
 
 obj-$(CONFIG_PNPACPI)		+= pnpacpi/
 obj-$(CONFIG_PNPBIOS)		+= pnpbios/
 obj-$(CONFIG_ISAPNP)		+= isapnp/
 
 # pnp_system_init goes after pnpacpi/pnpbios init
-obj-y				+= system.o
+pnp-y				+= system.o
diff --git a/drivers/pnp/isapnp/Makefile b/drivers/pnp/isapnp/Makefile
index cac18bb..6e607aa 100644
--- a/drivers/pnp/isapnp/Makefile
+++ b/drivers/pnp/isapnp/Makefile
@@ -1,7 +1,7 @@
 #
 # Makefile for the kernel ISAPNP driver.
 #
+obj-y			+= pnp.o
+pnp-y			:= core.o compat.o
 
-isapnp-proc-$(CONFIG_PROC_FS) = proc.o
-
-obj-y := core.o compat.o $(isapnp-proc-y)
+pnp-$(CONFIG_PROC_FS)	+= proc.o
diff --git a/drivers/pnp/pnpacpi/Makefile b/drivers/pnp/pnpacpi/Makefile
index 905326f..40c93da 100644
--- a/drivers/pnp/pnpacpi/Makefile
+++ b/drivers/pnp/pnpacpi/Makefile
@@ -1,5 +1,6 @@
 #
 # Makefile for the kernel PNPACPI driver.
 #
+obj-y += pnp.o
 
-obj-y := core.o rsparser.o
+pnp-y := core.o rsparser.o
diff --git a/drivers/pnp/pnpbios/Makefile b/drivers/pnp/pnpbios/Makefile
index 3cd3ed7..240b0ff 100644
--- a/drivers/pnp/pnpbios/Makefile
+++ b/drivers/pnp/pnpbios/Makefile
@@ -1,7 +1,8 @@
 #
 # Makefile for the kernel PNPBIOS driver.
 #
+obj-y := pnp.o
 
-pnpbios-proc-$(CONFIG_PNPBIOS_PROC_FS) = proc.o
+pnp-y := core.o bioscalls.o rsparser.o
 
-obj-y := core.o bioscalls.o rsparser.o $(pnpbios-proc-y)
+pnp-$(CONFIG_PNPBIOS_PROC_FS) += proc.o
-- 
1.6.0.2


  parent reply	other threads:[~2010-09-15 22:12 UTC|newest]

Thread overview: 23+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-09-15 22:11 Dynamic Debug module.ddebug fake param enhancements Thomas Renninger
2010-09-15 22:11 ` [PATCH 1/4] Dynamic Debug: Introduce global fake module param module.ddebug - V3 Thomas Renninger
2010-09-17 19:54   ` Jason Baron
2010-09-17 21:52     ` Thomas Renninger
2010-09-20 18:44       ` Jason Baron
2010-09-24 12:18         ` Thomas Renninger
2010-09-24 12:28         ` Dynamic Debug module.ddebug fake param enhancements V4 Thomas Renninger
2010-09-24 14:56           ` Bjorn Helgaas
2010-09-27  8:25             ` Thomas Renninger
2010-09-27 15:09               ` Bjorn Helgaas
2010-09-28 12:25                 ` Thomas Renninger
2010-09-28 14:22                   ` Bjorn Helgaas
2010-10-06 20:59                     ` Greg KH
2010-09-24 12:28         ` [PATCH 1/4] Dynamic Debug: Introduce global fake module param module.ddebug - V4 Thomas Renninger
2010-10-06 21:16           ` Greg KH
2010-10-06 21:40             ` Thomas Renninger
2010-10-06 21:51               ` Greg KH
2010-09-24 12:28         ` [PATCH 2/4] PNP: Compile all pnp built-in stuff in one module namespace Thomas Renninger
2010-09-24 12:28         ` [PATCH 3/4] PNP: Use dev_dbg instead of dev_printk(KERN_DEBUG.. if DYNAMIC_DEBUG is compiled in Thomas Renninger
2010-09-24 12:28         ` [PATCH 4/4] kernel/module.c: Fix compiler warnings if debug " Thomas Renninger
2010-09-15 22:11 ` Thomas Renninger [this message]
2010-09-15 22:11 ` [PATCH 3/4] PNP: Use dev_dbg instead of dev_printk(KERN_DEBUG.. if DYNAMIC_DEBUG " Thomas Renninger
2010-09-15 22:11 ` [PATCH 4/4] kernel/module.c: Fix compiler warnings if debug " Thomas Renninger

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1284588708-54170-3-git-send-email-trenn@suse.de \
    --to=trenn@suse.de \
    --cc=bjorn.helgaas@hp.com \
    --cc=gregkh@suse.de \
    --cc=jbaron@redhat.com \
    --cc=linux-kernel@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®