[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Date: Sat, 7 Jul 2018 08:33:09 -0700
From: Randy Dunlap <rdunlap@...radead.org>
To: Simon Kelley <simon@...kelleys.org.uk>,
linux-wireless@...r.kernel.org, Kalle Valo <kvalo@...eaurora.org>,
David Miller <davem@...emloft.net>,
"netdev@...r.kernel.org" <netdev@...r.kernel.org>
Subject: [PATCH] net/wireless/atmel: fix defined but not used warning
From: Randy Dunlap <rdunlap@...radead.org>
Fix a build warning in drivers/net/wireless/atmel/ when CONFIG_PROC_FS
is not enabled by marking the unused function as __maybe_unused.
../drivers/net/wireless/atmel/atmel.c:1402:12: warning: 'atmel_proc_show' defined but not used [-Wunused-function]
Signed-off-by: Randy Dunlap <rdunlap@...radead.org>
Cc: Simon Kelley <simon@...kelleys.org.uk>
Cc: linux-wireless@...r.kernel.org
Cc: Kalle Valo <kvalo@...eaurora.org>
Cc: "David S. Miller" <davem@...emloft.net>
Cc: netdev@...r.kernel.org
---
drivers/net/wireless/atmel/atmel.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
--- linux-next-20180706.orig/drivers/net/wireless/atmel/atmel.c
+++ linux-next-20180706/drivers/net/wireless/atmel/atmel.c
@@ -39,6 +39,7 @@
******************************************************************************/
+#include <linux/compiler.h>
#include <linux/interrupt.h>
#include <linux/kernel.h>
@@ -1399,7 +1400,7 @@ static int atmel_validate_channel(struct
return 0;
}
-static int atmel_proc_show(struct seq_file *m, void *v)
+static int __maybe_unused atmel_proc_show(struct seq_file *m, void *v)
{
struct atmel_private *priv = m->private;
int i;
Powered by blists - more mailing lists