From: Arnd Bergmann <arnd@arndb.de>
To: Will Deacon <will.deacon@arm.com>
Cc: Arnd Bergmann <arnd@arndb.de>,
Tyler Baicar <tbaicar@codeaurora.org>,
Xie XiuQi <xiexiuqi@huawei.com>, Borislav Petkov <bp@suse.de>,
linux-kernel@vger.kernel.org
Subject: [PATCH] ras: mark stub functions as 'inline'
Date: Tue, 27 Jun 2017 17:35:41 +0200 [thread overview]
Message-ID: <20170627153603.1358341-1-arnd@arndb.de> (raw)
With CONFIG_RAS disabled, we get two harmless warnings about
unused functions:
include/linux/ras.h:37:13: error: 'log_arm_hw_error' defined but not used [-Werror=unused-function]
static void log_arm_hw_error(struct cper_sec_proc_arm *err) { return; }
include/linux/ras.h:33:13: error: 'log_non_standard_event' defined but not used [-Werror=unused-function]
static void log_non_standard_event(const guid_t *sec_type,
Clearly these are meant to be 'inline', like the other stubs
in the same header.
Fixes: 297b64c74385 ("ras: acpi / apei: generate trace event for unrecognized CPER section")
Fixes: e9279e83ad1f ("trace, ras: add ARM processor error trace event")
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
---
include/linux/ras.h | 12 +++++++-----
1 file changed, 7 insertions(+), 5 deletions(-)
diff --git a/include/linux/ras.h b/include/linux/ras.h
index 7d61863ff265..be5338a35d57 100644
--- a/include/linux/ras.h
+++ b/include/linux/ras.h
@@ -30,11 +30,13 @@ void log_non_standard_event(const guid_t *sec_type,
const u8 sev, const u8 *err, const u32 len);
void log_arm_hw_error(struct cper_sec_proc_arm *err);
#else
-static void log_non_standard_event(const guid_t *sec_type,
- const guid_t *fru_id, const char *fru_text,
- const u8 sev, const u8 *err,
- const u32 len) { return; }
-static void log_arm_hw_error(struct cper_sec_proc_arm *err) { return; }
+static inline void
+log_non_standard_event(const guid_t *sec_type,
+ const guid_t *fru_id, const char *fru_text,
+ const u8 sev, const u8 *err, const u32 len)
+{ return; }
+static inline void
+log_arm_hw_error(struct cper_sec_proc_arm *err) { return; }
#endif
#endif /* __RAS_H__ */
--
2.9.0
next reply other threads:[~2017-06-27 15:37 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-06-27 15:35 Arnd Bergmann [this message]
2017-06-28 10:27 ` Borislav Petkov
2017-06-28 10:28 ` Will Deacon
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=20170627153603.1358341-1-arnd@arndb.de \
--to=arnd@arndb.de \
--cc=bp@suse.de \
--cc=linux-kernel@vger.kernel.org \
--cc=tbaicar@codeaurora.org \
--cc=will.deacon@arm.com \
--cc=xiexiuqi@huawei.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
all inboxes | Powered by JetHome®