diff options
author | Fabio Estevam <fabio.estevam@freescale.com> | 2014-01-23 18:55:04 -0500 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2014-01-23 19:36:59 -0500 |
commit | fbd5e754cb03c134ed45ff3417606daf61f576ca (patch) | |
tree | af940a0d948e99f49994809ce7962052cf434ac9 /drivers/rtc | |
parent | a3e6ad6740c6e77beda83d4238f2123bf3aef45f (diff) |
drivers/rtc/rtc-mxc.c: remove unneeded label
There is no need to jump to the 'exit_free_pdata' label when
devm_clk_get() fails, as we can directly return the error and simplify the
code a bit.
Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'drivers/rtc')
-rw-r--r-- | drivers/rtc/rtc-mxc.c | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/drivers/rtc/rtc-mxc.c b/drivers/rtc/rtc-mxc.c index 50c572645546..a3ed1cf935ba 100644 --- a/drivers/rtc/rtc-mxc.c +++ b/drivers/rtc/rtc-mxc.c | |||
@@ -391,8 +391,7 @@ static int mxc_rtc_probe(struct platform_device *pdev) | |||
391 | pdata->clk = devm_clk_get(&pdev->dev, NULL); | 391 | pdata->clk = devm_clk_get(&pdev->dev, NULL); |
392 | if (IS_ERR(pdata->clk)) { | 392 | if (IS_ERR(pdata->clk)) { |
393 | dev_err(&pdev->dev, "unable to get clock!\n"); | 393 | dev_err(&pdev->dev, "unable to get clock!\n"); |
394 | ret = PTR_ERR(pdata->clk); | 394 | return PTR_ERR(pdata->clk); |
395 | goto exit_free_pdata; | ||
396 | } | 395 | } |
397 | 396 | ||
398 | clk_prepare_enable(pdata->clk); | 397 | clk_prepare_enable(pdata->clk); |
@@ -447,8 +446,6 @@ static int mxc_rtc_probe(struct platform_device *pdev) | |||
447 | exit_put_clk: | 446 | exit_put_clk: |
448 | clk_disable_unprepare(pdata->clk); | 447 | clk_disable_unprepare(pdata->clk); |
449 | 448 | ||
450 | exit_free_pdata: | ||
451 | |||
452 | return ret; | 449 | return ret; |
453 | } | 450 | } |
454 | 451 | ||