Re: [PATCH 2/3] watchdog: iTCO_wdt: use dev_*() instead of pr_*() for logging
From: Guenter Roeck
Date: Wed Jun 09 2021 - 19:56:06 EST
On Wed, Jun 09, 2021 at 03:32:29PM -0500, Bjorn Helgaas wrote:
> On Tue, Nov 17, 2020 at 04:22:13PM +0100, Enrico Weigelt, metux IT consult wrote:
> > For device log outputs, it's better to have device name / ID
> > prefixed in all messages, so use the proper dev_*() functions here.
> >
> > Explicit message on module load/unload don't seem to be really helpful
> > (we have other means to check which modules have been loaded), instead
> > just add noise to the kernel log. So, removing them.
> >
> > Signed-off-by: Enrico Weigelt, metux IT consult <info@xxxxxxxxx>
>
> I like this patch a lot; thanks for doing it! It's merged upstream as
> c21172b3a73e ("watchdog: iTCO_wdt: use dev_*() instead of pr_*() for
> logging").
>
> It looks like there are a couple more pr_err() uses, so I wondered if
> they were missed or skipped intentionally:
>
> if (p->smi_res) {
> /* The TCO logic uses the TCO_EN bit in the SMI_EN register */
> if (!devm_request_region(dev, p->smi_res->start,
> resource_size(p->smi_res),
> pdev->name)) {
> pr_err("I/O address 0x%04llx already in use, device disabled\n",
> (u64)SMI_EN(p));
> return -EBUSY;
> }
> } else if (iTCO_vendorsupport ||
> turn_SMI_watchdog_clear_off >= p->iTCO_version) {
> pr_err("SMI I/O resource is missing\n");
> return -ENODEV;
> }
>
The above came in with a recent commit. I suspect they simply got lost,
and they should be converted as well.
Guenter