diff options
author | Wei Yongjun <weiyongjun1@huawei.com> | 2016-09-12 21:48:35 -0500 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2016-09-13 17:20:02 +0200 |
commit | 48fed03b4b37f03f469333269fec50b2b41ed7fb (patch) | |
tree | 12c7a351473fe1e38aab436fbeb0c83c410f2f61 /drivers/usb | |
parent | 947c49afe41fca4c062a8a780b0e003115d7238c (diff) |
usb: musb: am35x: fix error return code in am35x_probe()
Fix to return a negative error code from the usb_phy_generic_register()
error handling case instead of 0, as done elsewhere in this function.
Signed-off-by: Wei Yongjun <weiyongjun1@huawei.com>
Signed-off-by: Bin Liu <b-liu@ti.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/usb')
-rw-r--r-- | drivers/usb/musb/am35x.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/drivers/usb/musb/am35x.c b/drivers/usb/musb/am35x.c index c14577dbedf7..50ca8052bc8e 100644 --- a/drivers/usb/musb/am35x.c +++ b/drivers/usb/musb/am35x.c @@ -510,8 +510,10 @@ static int am35x_probe(struct platform_device *pdev) pdata->platform_ops = &am35x_ops; glue->phy = usb_phy_generic_register(); - if (IS_ERR(glue->phy)) + if (IS_ERR(glue->phy)) { + ret = PTR_ERR(glue->phy); goto err7; + } platform_set_drvdata(pdev, glue); pinfo = am35x_dev_info; |