summaryrefslogtreecommitdiffstats
path: root/drivers/usb/mtu3
diff options
context:
space:
mode:
authorChunfeng Yun <chunfeng.yun@mediatek.com>2021-05-28 08:10:59 +0200
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2021-06-03 13:53:04 +0200
commitf3ec606efc2015060156729b8533216ae0bacf70 (patch)
tree17cde1bbb7c4e1c3dad523bdb5ba5dd7f52c2437 /drivers/usb/mtu3
parentusb: mtu3: dump a status register of IPPC (diff)
downloadlinux-f3ec606efc2015060156729b8533216ae0bacf70.tar.xz
linux-f3ec606efc2015060156729b8533216ae0bacf70.zip
usb: mtu3: use dev_err_probe to print error log about extcon
Print an error log when the error number is not -EPROBE_DEFER Signed-off-by: Chunfeng Yun <chunfeng.yun@mediatek.com> Link: https://lore.kernel.org/r/1622182260-23767-4-git-send-email-chunfeng.yun@mediatek.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/usb/mtu3')
-rw-r--r--drivers/usb/mtu3/mtu3_plat.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/usb/mtu3/mtu3_plat.c b/drivers/usb/mtu3/mtu3_plat.c
index 7786a95a874e..eaeda391693a 100644
--- a/drivers/usb/mtu3/mtu3_plat.c
+++ b/drivers/usb/mtu3/mtu3_plat.c
@@ -302,8 +302,8 @@ static int get_ssusb_rscs(struct platform_device *pdev, struct ssusb_mtk *ssusb)
if (!otg_sx->role_sw_used && of_property_read_bool(node, "extcon")) {
otg_sx->edev = extcon_get_edev_by_phandle(ssusb->dev, 0);
if (IS_ERR(otg_sx->edev)) {
- dev_err(ssusb->dev, "couldn't get extcon device\n");
- return PTR_ERR(otg_sx->edev);
+ return dev_err_probe(dev, PTR_ERR(otg_sx->edev),
+ "couldn't get extcon device\n");
}
}