Search Linux Wireless

[PATCH] TI acx100/acx111: Make debug level selectable in configuration

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

 



The debug level for the TI acx100/acx111 driver is only set by editing
one of the header files. This patch adds configuration parameters to
set the debug level, and modifies the header file to use those parameters.

Signed-off-by: Larry Finger <Larry.Finger@xxxxxxxxxxxx>
---

Index: wireless-2.6/drivers/net/wireless/tiacx/Kconfig
===================================================================
--- wireless-2.6.orig/drivers/net/wireless/tiacx/Kconfig
+++ wireless-2.6/drivers/net/wireless/tiacx/Kconfig
@@ -1,6 +1,6 @@
 config ACX_PCI
 	tristate "TI acx100/acx111 802.11b/g PCI"
-	depends on NET_RADIO && EXPERIMENTAL && PCI
+	depends on WLAN_80211 && EXPERIMENTAL && PCI
 	select FW_LOADER
 	select IEEE80211
 	select IEEE80211_SOFTMAC
@@ -36,9 +36,31 @@ config ACX_PCI
 	Texas Instruments did not take part in development of this driver
 	in any way, shape or form.
 
+choice
+	prompt "ACX debug level"
+	depends on ACX_PCI
+	default ACX_PCI_DEBUG_FULL
+
+config ACX_PCI_DEBUG_MIN
+	prompt "No debugging output"
+	bool
+	depends on ACX_PCI
+
+config ACX_PCI_DEBUG_REG
+	prompt "Intermediate debugging output"
+	bool
+	depends on ACX_PCI
+
+config ACX_PCI_DEBUG_MAX
+	prompt "Maximum debugging output"
+	bool
+	depends on ACX_PCI
+
+endchoice
+
 config ACX_USB
 	tristate "TI acx100/acx111 802.11b/g USB"
-	depends on NET_RADIO && EXPERIMENTAL && USB
+	depends on WLAN_80211 && EXPERIMENTAL && USB
 	select FW_LOADER
 	select IEEE80211
 	select IEEE80211_SOFTMAC
@@ -62,3 +84,27 @@ config ACX_USB
 
 	Texas Instruments did not take part in development of this driver
 	in any way, shape or form.
+
+choice
+	prompt "ACX debug level"
+	depends on ACX_USB
+	default ACX_USB_DEBUG_FULL
+
+config ACX_USB_DEBUG_MIN
+	prompt "No debugging output"
+	bool
+	depends on ACX_USB
+
+config ACX_USB_DEBUG_REG
+	prompt "Intermediate debugging output"
+	bool
+	depends on ACX_USB
+
+config ACX_USB_DEBUG_MAX
+	prompt "Maximum debugging output"
+	bool
+	depends on ACX_USB
+
+endchoice
+
+
Index: wireless-2.6/drivers/net/wireless/tiacx/acx_config.h
===================================================================
--- wireless-2.6.orig/drivers/net/wireless/tiacx/acx_config.h
+++ wireless-2.6/drivers/net/wireless/tiacx/acx_config.h
@@ -3,7 +3,20 @@
 /* set to 0 if you don't want any debugging code to be compiled in */
 /* set to 1 if you want some debugging */
 /* set to 2 if you want extensive debug log */
+/* #define ACX_DEBUG 2  This is now set with a configuration variable */
+
+#if (defined CONFIG_ACX_PCI_DEBUG_MIN || defined CONFIG_ACX_USB_DEBUG_MIN)
+#define ACX_DEBUG 0
+#endif
+
+#if (defined CONFIG_ACX_PCI_DEBUG_REG || defined CONFIG_ACX_USB_DEBUG_REG)
+#define ACX_DEBUG 1
+#endif
+
+#if (defined CONFIG_ACX_PCI_DEBUG_MAX || defined CONFIG_ACX_USB_DEBUG_MAX)
 #define ACX_DEBUG 2
+#endif
+
 #define ACX_DEFAULT_MSG (L_ASSOC|L_INIT)
 
 /* assume 32bit I/O width
-
To unsubscribe from this list: send the line "unsubscribe linux-wireless" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Host AP]     [ATH6KL]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [Linux Kernel]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Samba]     [Device Mapper]
  Powered by Linux