From 5bb5ceac1275cbbe757d9eecbd4b8c8a4f403c32 Mon Sep 17 00:00:00 2001 From: Heiner Kallweit Date: Wed, 12 May 2021 22:44:41 +0200 Subject: [PATCH] PNP: Switch over to dev_dbg() Debug output in dmesg log may confuse users, so restrict debug output to cases where DEBUG is defined or dynamic debug output is enabled for the respective code piece. Signed-off-by: Heiner Kallweit [ rjw: Subject and changelog edits ] Signed-off-by: Rafael J. Wysocki --- drivers/pnp/core.c | 5 ++--- drivers/pnp/resource.c | 2 +- 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/drivers/pnp/core.c b/drivers/pnp/core.c index ccdfbf3978c0..4df5aa6a309c 100644 --- a/drivers/pnp/core.c +++ b/drivers/pnp/core.c @@ -215,9 +215,8 @@ int pnp_add_device(struct pnp_dev *dev) for (id = dev->id; id; id = id->next) len += scnprintf(buf + len, sizeof(buf) - len, " %s", id->id); - dev_printk(KERN_DEBUG, &dev->dev, "%s device, IDs%s (%s)\n", - dev->protocol->name, buf, - dev->active ? "active" : "disabled"); + dev_dbg(&dev->dev, "%s device, IDs%s (%s)\n", dev->protocol->name, buf, + dev->active ? "active" : "disabled"); return 0; } diff --git a/drivers/pnp/resource.c b/drivers/pnp/resource.c index 70d4ba95735a..2fa0f7d55259 100644 --- a/drivers/pnp/resource.c +++ b/drivers/pnp/resource.c @@ -540,7 +540,7 @@ struct pnp_resource *pnp_add_irq_resource(struct pnp_dev *dev, int irq, res->start = irq; res->end = irq; - dev_printk(KERN_DEBUG, &dev->dev, "%pR\n", res); + dev_dbg(&dev->dev, "%pR\n", res); return pnp_res; }