提交 d519c863 编写于 作者: A Adrian Hunter 提交者: Ulf Hansson

mmc: sdhci: Add out_unlock to sdhci_execute_tuning

A 'goto' can be used to save duplicating unlocking
and returning.
Signed-off-by: NAdrian Hunter <adrian.hunter@intel.com>
Reviewed-by: NAaron Lu <aaron.lu@intel.com>
Signed-off-by: NUlf Hansson <ulf.hansson@linaro.org>
上级 ac00531d
......@@ -1909,9 +1909,7 @@ static int sdhci_execute_tuning(struct mmc_host *mmc, u32 opcode)
/* FALLTHROUGH */
default:
spin_unlock_irqrestore(&host->lock, flags);
sdhci_runtime_pm_put(host);
return 0;
goto out_unlock;
}
if (host->ops->platform_execute_tuning) {
......@@ -2066,6 +2064,7 @@ static int sdhci_execute_tuning(struct mmc_host *mmc, u32 opcode)
sdhci_writel(host, host->ier, SDHCI_INT_ENABLE);
sdhci_writel(host, host->ier, SDHCI_SIGNAL_ENABLE);
out_unlock:
spin_unlock_irqrestore(&host->lock, flags);
sdhci_runtime_pm_put(host);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册