lkml.org 
[lkml]   [2014]   [Jul]   [22]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
From
Subject[PATCH 5/5] staging: vt6655: Fix unused function warning
Date
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


\
 
 \ /
  Last update: 2014-07-22 22:41    [W:1.526 / U:0.008 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site