summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorEnrico Weigelt, metux IT consult <info@metux.net>2020-12-03 19:24:22 +0100
committerLinus Walleij <linus.walleij@linaro.org>2020-12-08 09:41:32 +0100
commita922a24454088c62688472c16c42ea944496cf24 (patch)
tree2c338f9fb3324980da833f6cb560611f1c3b5627
parent3bf1d26c8a165db5bbb65c21327ac2055d70e76f (diff)
downloadlinux-a922a24454088c62688472c16c42ea944496cf24.tar.bz2
drivers: gpio: amd8111: prefer dev_err()/dev_info() over raw printk
For logging in device contexts, dev_*() functions are preferred over raw printk(), which also print out device name. Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net> Link: https://lore.kernel.org/r/20201203182423.5499-2-info@metux.net Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
-rw-r--r--drivers/gpio/gpio-amd8111.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/drivers/gpio/gpio-amd8111.c b/drivers/gpio/gpio-amd8111.c
index fdcebe59510d..0e260950992d 100644
--- a/drivers/gpio/gpio-amd8111.c
+++ b/drivers/gpio/gpio-amd8111.c
@@ -179,7 +179,6 @@ static int __init amd_gpio_init(void)
struct pci_dev *pdev = NULL;
const struct pci_device_id *ent;
-
/* We look for our device - AMD South Bridge
* I don't know about a system with two such bridges,
* so we can assume that there is max. one device.
@@ -223,11 +222,10 @@ found:
spin_lock_init(&gp.lock);
- printk(KERN_INFO "AMD-8111 GPIO detected\n");
+ dev_info(&pdev->dev, "AMD-8111 GPIO detected\n");
err = gpiochip_add_data(&gp.chip, &gp);
if (err) {
- printk(KERN_ERR "GPIO registering failed (%d)\n",
- err);
+ dev_err(&pdev->dev, "GPIO registering failed (%d)\n", err);
ioport_unmap(gp.pm);
goto out;
}