All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] mmc: sdhci: Remove unused ret variables
@ 2014-06-04 13:24 Markus Pargmann
  2014-06-16  8:46 ` Ulf Hansson
  0 siblings, 1 reply; 2+ messages in thread
From: Markus Pargmann @ 2014-06-04 13:24 UTC (permalink / raw)
  To: Chris Ball; +Cc: Ulf Hansson, linux-mmc, kernel, Markus Pargmann

Remove those unused ret variables to make it obvious that these function
will not return any errors in the current implementation.

Signed-off-by: Markus Pargmann <mpa@pengutronix.de>
---
 drivers/mmc/host/sdhci.c | 7 +++----
 1 file changed, 3 insertions(+), 4 deletions(-)

diff --git a/drivers/mmc/host/sdhci.c b/drivers/mmc/host/sdhci.c
index 47055f3..77c1c27 100644
--- a/drivers/mmc/host/sdhci.c
+++ b/drivers/mmc/host/sdhci.c
@@ -2643,7 +2643,6 @@ static void sdhci_runtime_pm_bus_off(struct sdhci_host *host)
 int sdhci_runtime_suspend_host(struct sdhci_host *host)
 {
 	unsigned long flags;
-	int ret = 0;
 
 	/* Disable tuning since we are suspending */
 	if (host->flags & SDHCI_USING_RETUNING_TIMER) {
@@ -2663,14 +2662,14 @@ int sdhci_runtime_suspend_host(struct sdhci_host *host)
 	host->runtime_suspended = true;
 	spin_unlock_irqrestore(&host->lock, flags);
 
-	return ret;
+	return 0;
 }
 EXPORT_SYMBOL_GPL(sdhci_runtime_suspend_host);
 
 int sdhci_runtime_resume_host(struct sdhci_host *host)
 {
 	unsigned long flags;
-	int ret = 0, host_flags = host->flags;
+	int host_flags = host->flags;
 
 	if (host_flags & (SDHCI_USE_SDMA | SDHCI_USE_ADMA)) {
 		if (host->ops->enable_dma)
@@ -2709,7 +2708,7 @@ int sdhci_runtime_resume_host(struct sdhci_host *host)
 
 	spin_unlock_irqrestore(&host->lock, flags);
 
-	return ret;
+	return 0;
 }
 EXPORT_SYMBOL_GPL(sdhci_runtime_resume_host);
 
-- 
2.0.0.rc2


^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH] mmc: sdhci: Remove unused ret variables
  2014-06-04 13:24 [PATCH] mmc: sdhci: Remove unused ret variables Markus Pargmann
@ 2014-06-16  8:46 ` Ulf Hansson
  0 siblings, 0 replies; 2+ messages in thread
From: Ulf Hansson @ 2014-06-16  8:46 UTC (permalink / raw)
  To: Markus Pargmann; +Cc: Chris Ball, linux-mmc, Sascha Hauer

On 4 June 2014 15:24, Markus Pargmann <mpa@pengutronix.de> wrote:
> Remove those unused ret variables to make it obvious that these function
> will not return any errors in the current implementation.
>
> Signed-off-by: Markus Pargmann <mpa@pengutronix.de>

Thanks! Applied for next.

Kind regards
Uffe

> ---
>  drivers/mmc/host/sdhci.c | 7 +++----
>  1 file changed, 3 insertions(+), 4 deletions(-)
>
> diff --git a/drivers/mmc/host/sdhci.c b/drivers/mmc/host/sdhci.c
> index 47055f3..77c1c27 100644
> --- a/drivers/mmc/host/sdhci.c
> +++ b/drivers/mmc/host/sdhci.c
> @@ -2643,7 +2643,6 @@ static void sdhci_runtime_pm_bus_off(struct sdhci_host *host)
>  int sdhci_runtime_suspend_host(struct sdhci_host *host)
>  {
>         unsigned long flags;
> -       int ret = 0;
>
>         /* Disable tuning since we are suspending */
>         if (host->flags & SDHCI_USING_RETUNING_TIMER) {
> @@ -2663,14 +2662,14 @@ int sdhci_runtime_suspend_host(struct sdhci_host *host)
>         host->runtime_suspended = true;
>         spin_unlock_irqrestore(&host->lock, flags);
>
> -       return ret;
> +       return 0;
>  }
>  EXPORT_SYMBOL_GPL(sdhci_runtime_suspend_host);
>
>  int sdhci_runtime_resume_host(struct sdhci_host *host)
>  {
>         unsigned long flags;
> -       int ret = 0, host_flags = host->flags;
> +       int host_flags = host->flags;
>
>         if (host_flags & (SDHCI_USE_SDMA | SDHCI_USE_ADMA)) {
>                 if (host->ops->enable_dma)
> @@ -2709,7 +2708,7 @@ int sdhci_runtime_resume_host(struct sdhci_host *host)
>
>         spin_unlock_irqrestore(&host->lock, flags);
>
> -       return ret;
> +       return 0;
>  }
>  EXPORT_SYMBOL_GPL(sdhci_runtime_resume_host);
>
> --
> 2.0.0.rc2
>
> --
> To unsubscribe from this list: send the line "unsubscribe linux-mmc" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2014-06-16  8:46 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-06-04 13:24 [PATCH] mmc: sdhci: Remove unused ret variables Markus Pargmann
2014-06-16  8:46 ` Ulf Hansson

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.