From: Arnd Bergmann <arnd@arndb.de>
To: netdev@vger.kernel.org, Kalle Valo <kvalo@codeaurora.org>
Cc: Michael Buesch <m@bues.ch>,
linux-kernel@vger.kernel.org, zajec5@gmail.com,
Nicolas Ferre <nicolas.ferre@atmel.com>,
Alexandre Belloni <alexandre.belloni@free-electrons.com>,
Jean-Christophe Plagniol-Villard <plagnioj@jcrosoft.com>
Subject: [PATCH] ssb: mark ssb_bus_register as __maybe_unused
Date: Tue, 03 Nov 2015 16:05:51 +0100 [thread overview]
Message-ID: <5928552.0ccybX7Zly@wuerfel> (raw)
The SoC variant of the ssb code is now optional like the other
ones, which means we can build the framwork without any
front-end, but that results in a warning:
drivers/ssb/main.c:616:12: warning: 'ssb_bus_register' defined but not used [-Wunused-function]
This annotates the ssb_bus_register function as __maybe_unused to
shut up the warning. A configuration like this will not work on
any hardware of course, but we still want this to silently build
without warnings if the configuration is allowed in the first
place.
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Fixes: 845da6e58e19 ("ssb: add Kconfig entry for compiling SoC related code")
----
This showed up on ARM at91_defconfig and sama5_defconfig, so we should probably
change those configurations as well. I can't see why they enable CONFIG_SSB
when they do not use any drivers for this framework.
diff --git a/drivers/ssb/main.c b/drivers/ssb/main.c
index 5d1e9a0fc389..e2ff6b5b2094 100644
--- a/drivers/ssb/main.c
+++ b/drivers/ssb/main.c
@@ -613,9 +613,10 @@ out:
return err;
}
-static int ssb_bus_register(struct ssb_bus *bus,
- ssb_invariants_func_t get_invariants,
- unsigned long baseaddr)
+static int __maybe_unused
+ssb_bus_register(struct ssb_bus *bus,
+ ssb_invariants_func_t get_invariants,
+ unsigned long baseaddr)
{
int err;
next reply other threads:[~2015-11-03 15:05 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-11-03 15:05 Arnd Bergmann [this message]
2015-11-03 16:27 ` [PATCH] ssb: mark ssb_bus_register as __maybe_unused Michael Büsch
2015-11-03 16:42 ` Arnd Bergmann
2015-11-03 16:51 ` Michael Büsch
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=5928552.0ccybX7Zly@wuerfel \
--to=arnd@arndb.de \
--cc=alexandre.belloni@free-electrons.com \
--cc=kvalo@codeaurora.org \
--cc=linux-kernel@vger.kernel.org \
--cc=m@bues.ch \
--cc=netdev@vger.kernel.org \
--cc=nicolas.ferre@atmel.com \
--cc=plagnioj@jcrosoft.com \
--cc=zajec5@gmail.com \
/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;
as well as URLs for NNTP newsgroup(s).