aboutsummaryrefslogtreecommitdiff
path: root/drivers/net/wireless/ath9k/main.c
diff options
context:
space:
mode:
authorSujith <Sujith.Manoharan@atheros.com>2008-11-28 22:19:02 +0530
committerJohn W. Linville <linville@tuxdriver.com>2008-12-05 09:35:08 -0500
commit88b126af946e7ea789f2a52d9d25aca681f93067 (patch)
tree0991493a6fc53675ca73d971bb92ae77fb628a48 /drivers/net/wireless/ath9k/main.c
parent04bd4638097c767278fdf12d50fecc8b60194d39 (diff)
ath9k: Add ATH9K_DEBUG configuration option
Make debugging configurable, and add a module parameter to give the debug mask. Add debug.c to hold all debug specific code. Signed-off-by: Sujith <Sujith.Manoharan@atheros.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless/ath9k/main.c')
-rw-r--r--drivers/net/wireless/ath9k/main.c18
1 files changed, 2 insertions, 16 deletions
diff --git a/drivers/net/wireless/ath9k/main.c b/drivers/net/wireless/ath9k/main.c
index de059c38467..9e7045dd733 100644
--- a/drivers/net/wireless/ath9k/main.c
+++ b/drivers/net/wireless/ath9k/main.c
@@ -38,21 +38,6 @@ static struct pci_device_id ath_pci_id_table[] __devinitdata = {
static void ath_detach(struct ath_softc *sc);
-void DPRINTF(struct ath_softc *sc, int dbg_mask, const char *fmt, ...)
-{
- if (!sc)
- return;
-
- if (sc->sc_debug & dbg_mask) {
- va_list args;
-
- va_start(args, fmt);
- printk(KERN_DEBUG "ath9k: ");
- vprintk(fmt, args);
- va_end(args);
- }
-}
-
/* return bus cachesize in 4B word units */
static void bus_read_cachesize(struct ath_softc *sc, int *csz)
@@ -1325,7 +1310,8 @@ static int ath_init(u16 devid, struct ath_softc *sc)
/* XXX: hardware will not be ready until ath_open() being called */
sc->sc_flags |= SC_OP_INVALID;
- sc->sc_debug = DBG_DEFAULT;
+
+ ath9k_init_debug(sc);
spin_lock_init(&sc->sc_resetlock);
tasklet_init(&sc->intr_tq, ath9k_tasklet, (unsigned long)sc);