diff options
author | Jingoo Han <jg1.han@samsung.com> | 2011-05-13 08:26:23 -0400 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@suse.de> | 2011-05-13 18:51:07 -0400 |
commit | 2328ceaea4fb917f8b861b18151b2245233b083f (patch) | |
tree | 2ec66a92c54d2d16a2a402afeb0f788b4502a46b /drivers/usb/gadget | |
parent | 66e5c643488a26d2a6b737bdbd92fc72f13cdeac (diff) |
USB: s3c-hsotg: return proper error if clk_get fails
Return PTR_ERR(hsotg->clk) instead of -EINVAL if clk_get fails
Signed-off-by: Jingoo Han <jg1.han@samsung.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/usb/gadget')
-rw-r--r-- | drivers/usb/gadget/s3c-hsotg.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/usb/gadget/s3c-hsotg.c b/drivers/usb/gadget/s3c-hsotg.c index 1d332f5da3c8..acb9cc418df9 100644 --- a/drivers/usb/gadget/s3c-hsotg.c +++ b/drivers/usb/gadget/s3c-hsotg.c | |||
@@ -3318,7 +3318,7 @@ static int __devinit s3c_hsotg_probe(struct platform_device *pdev) | |||
3318 | hsotg->clk = clk_get(&pdev->dev, "otg"); | 3318 | hsotg->clk = clk_get(&pdev->dev, "otg"); |
3319 | if (IS_ERR(hsotg->clk)) { | 3319 | if (IS_ERR(hsotg->clk)) { |
3320 | dev_err(dev, "cannot get otg clock\n"); | 3320 | dev_err(dev, "cannot get otg clock\n"); |
3321 | ret = -EINVAL; | 3321 | ret = PTR_ERR(hsotg->clk); |
3322 | goto err_mem; | 3322 | goto err_mem; |
3323 | } | 3323 | } |
3324 | 3324 | ||