From: Guillaume Clement <gclement@baobob.org>
To: Forest Bond <forest@alittletooquiet.net>,
Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Cc: devel@driverdev.osuosl.org, linux-kernel@vger.kernel.org,
Guillaume Clement <gclement@baobob.org>
Subject: [PATCH 5/5] staging: vt6655: Fix unused function warning
Date: Tue, 22 Jul 2014 22:08:30 +0200 [thread overview]
Message-ID: <1406059710-30903-6-git-send-email-gclement@baobob.org> (raw)
In-Reply-To: <1406059710-30903-1-git-send-email-gclement@baobob.org>
Sparse reports that MimeThread is not used. Actually, it can be used
if THREAD is defined. By enclosing the MimeThread function into the
same #ifdef as the caller of MimeThread, this fixes the sparse
warnings.
Signed-off-by: Guillaume Clement <gclement@baobob.org>
---
drivers/staging/vt6655/device_main.c | 6 +++++-
1 file changed, 5 insertions(+), 1 deletion(-)
diff --git a/drivers/staging/vt6655/device_main.c b/drivers/staging/vt6655/device_main.c
index 5576c30..fe9e13c 100644
--- a/drivers/staging/vt6655/device_main.c
+++ b/drivers/staging/vt6655/device_main.c
@@ -98,7 +98,9 @@ MODULE_AUTHOR("VIA Networking Technologies, Inc., <lyndonchen@vntek.com.tw>");
MODULE_LICENSE("GPL");
MODULE_DESCRIPTION("VIA Networking Solomon-A/B/G Wireless LAN Adapter Driver");
+#ifdef THREAD
static int mlme_kill;
+#endif
#define DEVICE_PARAM(N, D)
@@ -1596,7 +1598,8 @@ void InitRxManagementQueue(PSDevice pDevice)
//PLICE_DEBUG<-
//PLICE_DEBUG ->
-int MlmeThread(
+#ifdef THREAD
+static int MlmeThread(
void *Context)
{
PSDevice pDevice = (PSDevice) Context;
@@ -1619,6 +1622,7 @@ int MlmeThread(
return 0;
}
+#endif
static int device_open(struct net_device *dev) {
PSDevice pDevice = (PSDevice)netdev_priv(dev);
--
1.8.5.5
prev parent reply other threads:[~2014-07-22 20:09 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-07-22 20:08 [PATCH 0/5] staging: vt6655: fix sparse issues Guillaume Clement
2014-07-22 20:08 ` [PATCH 1/5] staging: vt6655: change type of PortOffset to void __iomem * Guillaume Clement
2014-07-22 22:01 ` Greg Kroah-Hartman
2014-07-22 20:08 ` [PATCH 2/5] staging: vt6655:fix warning for unexported non-static functions Guillaume Clement
2014-07-22 20:08 ` [PATCH 3/5] staging: vt6655: statify some variables Guillaume Clement
2014-07-22 20:08 ` [PATCH 4/5] staging: vt6655: remove unused functions Guillaume Clement
2014-07-22 20:08 ` Guillaume Clement [this message]
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=1406059710-30903-6-git-send-email-gclement@baobob.org \
--to=gclement@baobob.org \
--cc=devel@driverdev.osuosl.org \
--cc=forest@alittletooquiet.net \
--cc=gregkh@linuxfoundation.org \
--cc=linux-kernel@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
all inboxes | Powered by JetHome®