diff options
author | Adrian Hunter <adrian.hunter@intel.com> | 2014-12-05 12:25:29 -0500 |
---|---|---|
committer | Ulf Hansson <ulf.hansson@linaro.org> | 2015-01-12 04:14:55 -0500 |
commit | d519c863fc198f43c979e9d6a74b53d9c53d55aa (patch) | |
tree | 3f86166666850448441f94d418ee394fcbcff7e0 /drivers/mmc | |
parent | ac00531d9f4be487366573e2bb943e68e9e523ab (diff) |
mmc: sdhci: Add out_unlock to sdhci_execute_tuning
A 'goto' can be used to save duplicating unlocking
and returning.
Signed-off-by: Adrian Hunter <adrian.hunter@intel.com>
Reviewed-by: Aaron Lu <aaron.lu@intel.com>
Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
Diffstat (limited to 'drivers/mmc')
-rw-r--r-- | drivers/mmc/host/sdhci.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/drivers/mmc/host/sdhci.c b/drivers/mmc/host/sdhci.c index 040158d4fc9a..c45beaff1ab5 100644 --- a/drivers/mmc/host/sdhci.c +++ b/drivers/mmc/host/sdhci.c | |||
@@ -1909,9 +1909,7 @@ static int sdhci_execute_tuning(struct mmc_host *mmc, u32 opcode) | |||
1909 | /* FALLTHROUGH */ | 1909 | /* FALLTHROUGH */ |
1910 | 1910 | ||
1911 | default: | 1911 | default: |
1912 | spin_unlock_irqrestore(&host->lock, flags); | 1912 | goto out_unlock; |
1913 | sdhci_runtime_pm_put(host); | ||
1914 | return 0; | ||
1915 | } | 1913 | } |
1916 | 1914 | ||
1917 | if (host->ops->platform_execute_tuning) { | 1915 | if (host->ops->platform_execute_tuning) { |
@@ -2066,6 +2064,7 @@ out: | |||
2066 | 2064 | ||
2067 | sdhci_writel(host, host->ier, SDHCI_INT_ENABLE); | 2065 | sdhci_writel(host, host->ier, SDHCI_INT_ENABLE); |
2068 | sdhci_writel(host, host->ier, SDHCI_SIGNAL_ENABLE); | 2066 | sdhci_writel(host, host->ier, SDHCI_SIGNAL_ENABLE); |
2067 | out_unlock: | ||
2069 | spin_unlock_irqrestore(&host->lock, flags); | 2068 | spin_unlock_irqrestore(&host->lock, flags); |
2070 | sdhci_runtime_pm_put(host); | 2069 | sdhci_runtime_pm_put(host); |
2071 | 2070 | ||