[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-Id: <1385953981-23630-1-git-send-email-festevam@gmail.com>
Date: Mon, 2 Dec 2013 01:13:00 -0200
From: Fabio Estevam <festevam@...il.com>
To: akpm@...ux-foundation.org
Cc: a.zummo@...ertech.it, s.hauer@...gutronix.de,
linux-kernel@...r.kernel.org,
Fabio Estevam <fabio.estevam@...escale.com>
Subject: [PATCH 1/2] rtc: rtc-mxc: Remove unneeded label
From: Fabio Estevam <fabio.estevam@...escale.com>
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@...escale.com>
---
drivers/rtc/rtc-mxc.c | 5 +----
1 file changed, 1 insertion(+), 4 deletions(-)
diff --git a/drivers/rtc/rtc-mxc.c b/drivers/rtc/rtc-mxc.c
index 50c5726..a3ed1cf 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)
pdata->clk = devm_clk_get(&pdev->dev, NULL);
if (IS_ERR(pdata->clk)) {
dev_err(&pdev->dev, "unable to get clock!\n");
- ret = PTR_ERR(pdata->clk);
- goto exit_free_pdata;
+ return PTR_ERR(pdata->clk);
}
clk_prepare_enable(pdata->clk);
@@ -447,8 +446,6 @@ static int mxc_rtc_probe(struct platform_device *pdev)
exit_put_clk:
clk_disable_unprepare(pdata->clk);
-exit_free_pdata:
-
return ret;
}
--
1.8.1.2
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists