summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPatrice Chotard <patrice.chotard@st.com>2018-03-14 17:48:58 +0100
committerMarek Vasut <marex@denx.de>2018-03-17 03:20:53 +0100
commit6048d42fa7a2b97913db9a033675bf267fb4e030 (patch)
treecd0802848fc0f50cd062e3587156a173b649b90f
parentcab4d48a939537ab10e00429fc774825b743ed10 (diff)
usb: ohci-generic: replace pr_err() by dev_err()
As we get access to struct udevice, use dev_err() instead of pr_err(). Signed-off-by: Patrice Chotard <patrice.chotard@st.com>
-rw-r--r--drivers/usb/host/ohci-generic.c13
1 files changed, 6 insertions, 7 deletions
diff --git a/drivers/usb/host/ohci-generic.c b/drivers/usb/host/ohci-generic.c
index 590fe4ca74..5bdd7995b9 100644
--- a/drivers/usb/host/ohci-generic.c
+++ b/drivers/usb/host/ohci-generic.c
@@ -97,14 +97,14 @@ static int ohci_usb_probe(struct udevice *dev)
err = clk_enable(&priv->clocks[i]);
if (err) {
- pr_err("failed to enable clock %d\n", i);
+ dev_err(dev, "failed to enable clock %d\n", i);
clk_free(&priv->clocks[i]);
goto clk_err;
}
priv->clock_count++;
}
} else if (clock_nb != -ENOENT) {
- pr_err("failed to get clock phandle(%d)\n", clock_nb);
+ dev_err(dev, "failed to get clock phandle(%d)\n", clock_nb);
return clock_nb;
}
@@ -124,20 +124,19 @@ static int ohci_usb_probe(struct udevice *dev)
err = reset_deassert(&priv->resets[i]);
if (err) {
- pr_err("failed to deassert reset %d\n", i);
+ dev_err(dev, "failed to deassert reset %d\n", i);
reset_free(&priv->resets[i]);
goto reset_err;
}
priv->reset_count++;
}
} else if (reset_nb != -ENOENT) {
- pr_err("failed to get reset phandle(%d)\n", reset_nb);
+ dev_err(dev, "failed to get reset phandle(%d)\n", reset_nb);
goto clk_err;
}
err = ohci_setup_phy(dev, 0);
if (err)
-
goto reset_err;
err = ohci_register(dev, regs);
@@ -154,11 +153,11 @@ phy_err:
reset_err:
ret = reset_release_all(priv->resets, priv->reset_count);
if (ret)
- pr_err("failed to assert all resets\n");
+ dev_err(dev, "failed to assert all resets\n");
clk_err:
ret = clk_release_all(priv->clocks, priv->clock_count);
if (ret)
- pr_err("failed to disable all clocks\n");
+ dev_err(dev, "failed to disable all clocks\n");
return err;
}