public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Hannes Eder <hannes@hanneseder.net>
To: Jiri Kosina <jkosina@suse.cz>
Cc: linux-input@vger.kernel.org
Cc: linux-kernel@vger.kernel.org
Cc: kernel-janitors@vger.kernel.org
Subject: [PATCH] HID: avoid sparse warning in HID_COMPAT_LOAD_DRIVER
Date: Tue, 16 Dec 2008 13:31:31 +0100	[thread overview]
Message-ID: <4947a48f.08b6660a.34ca.ffffa1e8@mx.google.com> (raw)

Impact: include a prototype for the exported function in the macro

Fix about 20 of this warnings:

  drivers/hid/hid-a4tech.c:162:1: warning: symbol 'hid_compat_a4tech' was not declared. Should it be static?

Signed-off-by: Hannes Eder <hannes@hanneseder.net>
---
 include/linux/hid.h |    2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)

diff --git a/include/linux/hid.h b/include/linux/hid.h
index 215035b..81aa84d 100644
--- a/include/linux/hid.h
+++ b/include/linux/hid.h
@@ -793,6 +793,8 @@ dbg_hid(const char *fmt, ...)
 
 #ifdef CONFIG_HID_COMPAT
 #define HID_COMPAT_LOAD_DRIVER(name)	\
+/* prototype to avoid sparse warning */	\
+extern void hid_compat_##name(void);	\
 void hid_compat_##name(void) { }	\
 EXPORT_SYMBOL(hid_compat_##name)
 #else
-- 
1.5.6.3


             reply	other threads:[~2008-12-16 12:57 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-12-16 12:31 Hannes Eder [this message]
2008-12-16 13:35 ` [PATCH] HID: avoid sparse warning in HID_COMPAT_LOAD_DRIVER Jiri Kosina
2008-12-16 15:58 ` Ben Dooks
2008-12-16 16:01   ` Jiri Kosina
2008-12-16 19:41     ` Ben Dooks
2008-12-16 19:44       ` Hannes Eder
2008-12-19  8:31         ` Jiri Slaby
2008-12-19  9:37           ` Jiri Kosina
2008-12-20 16:55             ` Jiri Slaby
2009-02-06 16:07               ` Jiri Kosina

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=4947a48f.08b6660a.34ca.ffffa1e8@mx.google.com \
    --to=hannes@hanneseder.net \
    --cc=jkosina@suse.cz \
    --cc=linux-input@vger.kernel.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