mail archive of the barebox mailing list
 help / color / mirror / Atom feed
From: Roland Hieber <rhi@pengutronix.de>
To: barebox@lists.infradead.org
Cc: Roland Hieber <rhi@pengutronix.de>
Subject: [PATCH v1 2/3] mci: bcm2835: make locally used functions static
Date: Tue, 15 Jan 2019 11:34:22 +0100	[thread overview]
Message-ID: <20190115103423.5233-2-rhi@pengutronix.de> (raw)
In-Reply-To: <20190115103423.5233-1-rhi@pengutronix.de>

The mci-bcm2835 driver registers itself as an MCI driver on probing, and
is thereby used through the MCI interface, so these functions are not
meant to act as a public interface and only used internally in this
compilation unit.

This fixes the following build warnings:

    .../drivers/mci/mci-bcm2835.c:56:6: warning: no previous prototype for 'bcm2835_mci_write' [-Wmissing-prototypes]
     void bcm2835_mci_write(struct bcm2835_mci_host *host, u32 reg, u32 val)
          ^~~~~~~~~~~~~~~~~
    .../drivers/mci/mci-bcm2835.c:74:5: warning: no previous prototype for 'bcm2835_mci_read' [-Wmissing-prototypes]
     u32 bcm2835_mci_read(struct bcm2835_mci_host *host, u32 reg)
         ^~~~~~~~~~~~~~~~
    .../drivers/mci/mci-bcm2835.c:83:6: warning: no previous prototype for 'bcm2835_mci_write_data' [-Wmissing-prototypes]
     void bcm2835_mci_write_data(struct bcm2835_mci_host *host, u32 *p)
          ^~~~~~~~~~~~~~~~~~~~~~
    .../drivers/mci/mci-bcm2835.c:89:6: warning: no previous prototype for 'bcm2835_mci_read_data' [-Wmissing-prototypes]
     void bcm2835_mci_read_data(struct bcm2835_mci_host *host, u32 *p)
          ^~~~~~~~~~~~~~~~~~~~~
      CC      common/date.o
    .../drivers/mci/mci-bcm2835.c:419:5: warning: no previous prototype for 'bcm2835_mci_reset' [-Wmissing-prototypes]
     int bcm2835_mci_reset(struct mci_host *mci, struct device_d *mci_dev)

Signed-off-by: Roland Hieber <rhi@pengutronix.de>
---
 drivers/mci/mci-bcm2835.c | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)

diff --git a/drivers/mci/mci-bcm2835.c b/drivers/mci/mci-bcm2835.c
index daf771934a..9438e66af0 100644
--- a/drivers/mci/mci-bcm2835.c
+++ b/drivers/mci/mci-bcm2835.c
@@ -53,7 +53,7 @@ struct bcm2835_mci_host {
 	uint64_t last_write;
 };
 
-void bcm2835_mci_write(struct bcm2835_mci_host *host, u32 reg, u32 val)
+static void bcm2835_mci_write(struct bcm2835_mci_host *host, u32 reg, u32 val)
 {
 	/*
 	 * The Arasan has a bugette whereby it may lose the content of
@@ -71,7 +71,7 @@ void bcm2835_mci_write(struct bcm2835_mci_host *host, u32 reg, u32 val)
 	writel(val, host->regs + reg);
 }
 
-u32 bcm2835_mci_read(struct bcm2835_mci_host *host, u32 reg)
+static u32 bcm2835_mci_read(struct bcm2835_mci_host *host, u32 reg)
 {
 	return readl(host->regs + reg);
 }
@@ -80,13 +80,13 @@ u32 bcm2835_mci_read(struct bcm2835_mci_host *host, u32 reg)
  * register is not affected by the twoticks_delay bug
  * and we can thus get better speed here
  */
-void bcm2835_mci_write_data(struct bcm2835_mci_host *host, u32 *p)
+static void bcm2835_mci_write_data(struct bcm2835_mci_host *host, u32 *p)
 {
 	writel(*p, host->regs + SDHCI_BUFFER);
 }
 
 /* Make a read data functions as well just to keep structure */
-void bcm2835_mci_read_data(struct bcm2835_mci_host *host, u32 *p)
+static void bcm2835_mci_read_data(struct bcm2835_mci_host *host, u32 *p)
 {
 	*p = readl(host->regs + SDHCI_BUFFER);
 }
@@ -416,7 +416,7 @@ static void bcm2835_mci_set_ios(struct mci_host *mci, struct mci_ios *ios)
 			host->bus_width, host->clock);
 }
 
-int bcm2835_mci_reset(struct mci_host *mci, struct device_d *mci_dev)
+static int bcm2835_mci_reset(struct mci_host *mci, struct device_d *mci_dev)
 {
 	struct bcm2835_mci_host *host;
 	u32 ret = 0;
-- 
2.20.1


_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox

  reply	other threads:[~2019-01-15 10:34 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-01-15 10:34 [PATCH v1 1/3] ARM: rpi: " Roland Hieber
2019-01-15 10:34 ` Roland Hieber [this message]
2019-01-15 10:34 ` [PATCH v1 3/3] amba: pl011: " Roland Hieber
2019-02-14 13:51   ` Roland Hieber
2019-02-18  8:52     ` Sascha Hauer
2019-02-22  9:23       ` Roland Hieber
2019-01-16  7:52 ` [PATCH v1 1/3] ARM: rpi: " Sascha Hauer

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20190115103423.5233-2-rhi@pengutronix.de \
    --to=rhi@pengutronix.de \
    --cc=barebox@lists.infradead.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox