OSDN Git Service
(root)
/
uclinux-h8
/
linux.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
8a99b6a
)
usb: mtu3: fix error code for getting extcon device
author
Chunfeng Yun
<chunfeng.yun@mediatek.com>
Wed, 3 Jan 2018 08:53:17 +0000
(16:53 +0800)
committer
Greg Kroah-Hartman
<gregkh@linuxfoundation.org>
Tue, 9 Jan 2018 15:21:27 +0000
(16:21 +0100)
When failing to get extcon device, extcon_get_edev_by_phandle()
may return different error codes, but not only -EPROBE_DEFER,
so can't always return -EPROBE_DEFER, and fix it.
Signed-off-by: Chunfeng Yun <chunfeng.yun@mediatek.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/usb/mtu3/mtu3_plat.c
patch
|
blob
|
history
diff --git
a/drivers/usb/mtu3/mtu3_plat.c
b/drivers/usb/mtu3/mtu3_plat.c
index
3650fd1
..
5b2110b
100644
(file)
--- a/
drivers/usb/mtu3/mtu3_plat.c
+++ b/
drivers/usb/mtu3/mtu3_plat.c
@@
-308,7
+308,7
@@
static int get_ssusb_rscs(struct platform_device *pdev, struct ssusb_mtk *ssusb)
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
-EPROBE_DEFER
;
+ return
PTR_ERR(otg_sx->edev)
;
}
}