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 <hkallweit1@gmail.com>
[ rjw: Subject and changelog edits ]
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
This commit is contained in:
Heiner Kallweit 2021-05-12 22:44:41 +02:00 committed by Rafael J. Wysocki
parent b15fc7c2c8
commit 5bb5ceac12
2 changed files with 3 additions and 4 deletions

View File

@ -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;
}

View File

@ -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;
}