rtc: s3c: Jump to central exit point on getting src clock error

In other error paths in probe, centralized exit point was used so make
this consistent.

Signed-off-by: Krzysztof Kozlowski <krzk@kernel.org>
Signed-off-by: Alexandre Belloni <alexandre.belloni@free-electrons.com>
This commit is contained in:
Krzysztof Kozlowski 2017-06-16 21:28:02 +02:00 коммит произвёл Alexandre Belloni
Родитель fe6d94fe66
Коммит 8768e7b3e3
1 изменённых файлов: 2 добавлений и 2 удалений

Просмотреть файл

@ -510,8 +510,7 @@ static int s3c_rtc_probe(struct platform_device *pdev)
else else
dev_dbg(&pdev->dev, dev_dbg(&pdev->dev,
"probe deferred due to missing rtc src clk\n"); "probe deferred due to missing rtc src clk\n");
clk_disable_unprepare(info->rtc_clk); goto err_src_clk;
return ret;
} }
clk_prepare_enable(info->rtc_src_clk); clk_prepare_enable(info->rtc_src_clk);
} }
@ -575,6 +574,7 @@ static int s3c_rtc_probe(struct platform_device *pdev)
if (info->data->needs_src_clk) if (info->data->needs_src_clk)
clk_disable_unprepare(info->rtc_src_clk); clk_disable_unprepare(info->rtc_src_clk);
err_src_clk:
clk_disable_unprepare(info->rtc_clk); clk_disable_unprepare(info->rtc_clk);
return ret; return ret;