]> git.karo-electronics.de Git - mv-sheeva.git/commitdiff
ath5k: more debug prints for resets
authorBruno Randolf <br1@einfach.org>
Wed, 16 Jun 2010 10:11:12 +0000 (19:11 +0900)
committerJohn W. Linville <linville@tuxdriver.com>
Wed, 16 Jun 2010 18:58:58 +0000 (14:58 -0400)
Add a debug print for every case of reset.

Signed-off-by: Bruno Randolf <br1@einfach.org>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
drivers/net/wireless/ath/ath5k/base.c
drivers/net/wireless/ath/ath5k/debug.c

index 9d37c1a43a9d2adc84d981d5043359bcb69cddf3..936afd7bae7e811f45323fb9e03456dedb8c2de1 100644 (file)
@@ -1111,8 +1111,9 @@ ath5k_setup_bands(struct ieee80211_hw *hw)
 static int
 ath5k_chan_set(struct ath5k_softc *sc, struct ieee80211_channel *chan)
 {
-       ATH5K_DBG(sc, ATH5K_DEBUG_RESET, "(%u MHz) -> (%u MHz)\n",
-               sc->curchan->center_freq, chan->center_freq);
+       ATH5K_DBG(sc, ATH5K_DEBUG_RESET,
+                 "channel set, resetting (%u -> %u MHz)\n",
+                 sc->curchan->center_freq, chan->center_freq);
 
        /*
         * To switch channels clear any pending DMA operations;
@@ -2298,6 +2299,8 @@ ath5k_beacon_send(struct ath5k_softc *sc)
                        ATH5K_DBG(sc, ATH5K_DEBUG_BEACON,
                                "stuck beacon time (%u missed)\n",
                                sc->bmisscount);
+                       ATH5K_DBG(sc, ATH5K_DEBUG_RESET,
+                                 "stuck beacon, resetting\n");
                        tasklet_schedule(&sc->restq);
                }
                return;
@@ -2705,6 +2708,8 @@ ath5k_intr(int irq, void *dev_id)
                         * Fatal errors are unrecoverable.
                         * Typically these are caused by DMA errors.
                         */
+                       ATH5K_DBG(sc, ATH5K_DEBUG_RESET,
+                                 "fatal int, resetting\n");
                        tasklet_schedule(&sc->restq);
                } else if (unlikely(status & AR5K_INT_RXORN)) {
                        /*
@@ -2717,8 +2722,11 @@ ath5k_intr(int irq, void *dev_id)
                         * this guess is copied from the HAL.
                         */
                        sc->stats.rxorn_intr++;
-                       if (ah->ah_mac_srev < AR5K_SREV_AR5212)
+                       if (ah->ah_mac_srev < AR5K_SREV_AR5212) {
+                               ATH5K_DBG(sc, ATH5K_DEBUG_RESET,
+                                         "rx overrun, resetting\n");
                                tasklet_schedule(&sc->restq);
+                       }
                        else
                                tasklet_schedule(&sc->rxtq);
                } else {
index 0f2e37d85cbd6704a886df9c2eb97f0718d4d963..5984edc955157f98eaed666a178a781d6aec3e12 100644 (file)
@@ -278,6 +278,7 @@ static ssize_t write_file_reset(struct file *file,
                                 size_t count, loff_t *ppos)
 {
        struct ath5k_softc *sc = file->private_data;
+       ATH5K_DBG(sc, ATH5K_DEBUG_RESET, "debug file triggered reset\n");
        tasklet_schedule(&sc->restq);
        return count;
 }