From 97ef062bbe08f46903f29ecdf432be302c977f3b Mon Sep 17 00:00:00 2001 From: Bjorn Helgaas Date: Tue, 19 Aug 2008 16:53:41 -0600 Subject: PNP: add CONFIG_PNP_DEBUG_MESSAGES and pnp_dbg() This adds the core function pnp_dbg() and a new config option to enable it. The PNP core debugging messages can be enabled at boot-time with the "pnp.debug" kernel parameter. Signed-off-by: Bjorn Helgaas Signed-off-by: Andi Kleen Signed-off-by: Len Brown --- drivers/pnp/core.c | 11 +++++++++++ 1 file changed, 11 insertions(+) (limited to 'drivers/pnp/core.c') diff --git a/drivers/pnp/core.c b/drivers/pnp/core.c index 7cb1ffc14d4e..61291b5bfe12 100644 --- a/drivers/pnp/core.c +++ b/drivers/pnp/core.c @@ -221,3 +221,14 @@ static int __init pnp_init(void) } subsys_initcall(pnp_init); + +int pnp_debug; + +#if defined(CONFIG_PNP_DEBUG_MESSAGES) +static int __init pnp_debug_setup(char *__unused) +{ + pnp_debug = 1; + return 1; +} +__setup("pnp.debug", pnp_debug_setup); +#endif -- cgit v1.2.1