Search Linux Wireless

[PATCH] net/wireless/atmel: fix defined but not used warning

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



From: Randy Dunlap <rdunlap@xxxxxxxxxxxxx>

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@xxxxxxxxxxxxx>
Cc: Simon Kelley <simon@xxxxxxxxxxxxxxxxx>
Cc: linux-wireless@xxxxxxxxxxxxxxx
Cc: Kalle Valo <kvalo@xxxxxxxxxxxxxx>
Cc: "David S. Miller" <davem@xxxxxxxxxxxxx>
Cc: netdev@xxxxxxxxxxxxxxx
---
 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;





[Index of Archives]     [Linux Host AP]     [ATH6KL]     [Linux Wireless Personal Area Network]     [Linux Bluetooth]     [Wireless Regulations]     [Linux Netdev]     [Kernel Newbies]     [Linux Kernel]     [IDE]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite Hiking]     [MIPS Linux]     [ARM Linux]     [Linux RAID]

  Powered by Linux