Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1739956 > unrolled thread

[PATCH][sdhci-next] mmc: sdhci-omap: make three functions static, fixes warnings

Started byColin King <colin.king@canonical.com>
First post2017-09-26 17:00 +0200
Last post2017-10-02 10:30 +0200
Articles 2 — 2 participants

Back to article view | Back to linux.kernel


Contents

  [PATCH][sdhci-next] mmc: sdhci-omap: make three functions static, fixes warnings Colin King <colin.king@canonical.com> - 2017-09-26 17:00 +0200
    Re: [PATCH][sdhci-next] mmc: sdhci-omap: make three functions static,  fixes warnings Ulf Hansson <ulf.hansson@linaro.org> - 2017-10-02 10:30 +0200

#1739956 — [PATCH][sdhci-next] mmc: sdhci-omap: make three functions static, fixes warnings

FromColin King <colin.king@canonical.com>
Date2017-09-26 17:00 +0200
Subject[PATCH][sdhci-next] mmc: sdhci-omap: make three functions static, fixes warnings
Message-ID<utZv4-66l-15@gated-at.bofh.it>
From: Colin Ian King <colin.king@canonical.com>

The functions sdhci_omap_set_ios, sdhci_omap_set_power and
sdhci_omap_get_min_clock are local to the source and do not need
to be in global scope, so make them static.

Cleans up sparse warnings:
symbol 'sdhci_omap_set_ios' was not declared. Should it be static?
symbol 'sdhci_omap_set_power' was not declared. Should it be static?
symbol 'sdhci_omap_get_min_clock' was not declared. Should it be static?

Signed-off-by: Colin Ian King <colin.king@canonical.com>
---
 drivers/mmc/host/sdhci-omap.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/drivers/mmc/host/sdhci-omap.c b/drivers/mmc/host/sdhci-omap.c
index 5ddae39816b7..628bfe9a3d17 100644
--- a/drivers/mmc/host/sdhci-omap.c
+++ b/drivers/mmc/host/sdhci-omap.c
@@ -262,7 +262,7 @@ static void sdhci_omap_set_bus_mode(struct sdhci_omap_host *omap_host,
 	omap_host->bus_mode = mode;
 }
 
-void sdhci_omap_set_ios(struct mmc_host *mmc, struct mmc_ios *ios)
+static void sdhci_omap_set_ios(struct mmc_host *mmc, struct mmc_ios *ios)
 {
 	struct sdhci_host *host = mmc_priv(mmc);
 	struct sdhci_pltfm_host *pltfm_host;
@@ -323,7 +323,7 @@ static void sdhci_omap_set_clock(struct sdhci_host *host, unsigned int clock)
 	sdhci_omap_start_clock(omap_host);
 }
 
-void sdhci_omap_set_power(struct sdhci_host *host, unsigned char mode,
+static void sdhci_omap_set_power(struct sdhci_host *host, unsigned char mode,
 			  unsigned short vdd)
 {
 	struct mmc_host *mmc = host->mmc;
@@ -344,7 +344,7 @@ static int sdhci_omap_enable_dma(struct sdhci_host *host)
 	return 0;
 }
 
-unsigned int sdhci_omap_get_min_clock(struct sdhci_host *host)
+static unsigned int sdhci_omap_get_min_clock(struct sdhci_host *host)
 {
 	struct sdhci_pltfm_host *pltfm_host = sdhci_priv(host);
 
-- 
2.14.1

[toc] | [next] | [standalone]


#1743014 — Re: [PATCH][sdhci-next] mmc: sdhci-omap: make three functions static, fixes warnings

FromUlf Hansson <ulf.hansson@linaro.org>
Date2017-10-02 10:30 +0200
SubjectRe: [PATCH][sdhci-next] mmc: sdhci-omap: make three functions static, fixes warnings
Message-ID<uw4gW-4Z8-19@gated-at.bofh.it>
In reply to#1739956
On 26 September 2017 at 16:55, Colin King <colin.king@canonical.com> wrote:
> From: Colin Ian King <colin.king@canonical.com>
>
> The functions sdhci_omap_set_ios, sdhci_omap_set_power and
> sdhci_omap_get_min_clock are local to the source and do not need
> to be in global scope, so make them static.
>
> Cleans up sparse warnings:
> symbol 'sdhci_omap_set_ios' was not declared. Should it be static?
> symbol 'sdhci_omap_set_power' was not declared. Should it be static?
> symbol 'sdhci_omap_get_min_clock' was not declared. Should it be static?
>
> Signed-off-by: Colin Ian King <colin.king@canonical.com>

Thanks, applied for next!

Kind regards
Uffe

> ---
>  drivers/mmc/host/sdhci-omap.c | 6 +++---
>  1 file changed, 3 insertions(+), 3 deletions(-)
>
> diff --git a/drivers/mmc/host/sdhci-omap.c b/drivers/mmc/host/sdhci-omap.c
> index 5ddae39816b7..628bfe9a3d17 100644
> --- a/drivers/mmc/host/sdhci-omap.c
> +++ b/drivers/mmc/host/sdhci-omap.c
> @@ -262,7 +262,7 @@ static void sdhci_omap_set_bus_mode(struct sdhci_omap_host *omap_host,
>         omap_host->bus_mode = mode;
>  }
>
> -void sdhci_omap_set_ios(struct mmc_host *mmc, struct mmc_ios *ios)
> +static void sdhci_omap_set_ios(struct mmc_host *mmc, struct mmc_ios *ios)
>  {
>         struct sdhci_host *host = mmc_priv(mmc);
>         struct sdhci_pltfm_host *pltfm_host;
> @@ -323,7 +323,7 @@ static void sdhci_omap_set_clock(struct sdhci_host *host, unsigned int clock)
>         sdhci_omap_start_clock(omap_host);
>  }
>
> -void sdhci_omap_set_power(struct sdhci_host *host, unsigned char mode,
> +static void sdhci_omap_set_power(struct sdhci_host *host, unsigned char mode,
>                           unsigned short vdd)
>  {
>         struct mmc_host *mmc = host->mmc;
> @@ -344,7 +344,7 @@ static int sdhci_omap_enable_dma(struct sdhci_host *host)
>         return 0;
>  }
>
> -unsigned int sdhci_omap_get_min_clock(struct sdhci_host *host)
> +static unsigned int sdhci_omap_get_min_clock(struct sdhci_host *host)
>  {
>         struct sdhci_pltfm_host *pltfm_host = sdhci_priv(host);
>
> --
> 2.14.1
>

[toc] | [prev] | [standalone]


Back to top | Article view | linux.kernel


csiph-web