ath9k: fix too early enabling of rx during ath_startrecv()
authorFelix Fietkau <nbd@openwrt.org>
Thu, 7 Apr 2011 17:30:32 +0000 (19:30 +0200)
committerJohn W. Linville <linville@tuxdriver.com>
Tue, 12 Apr 2011 20:57:36 +0000 (16:57 -0400)
rx should only be enabled after enough rx buffers have been given to the
hardware, however ath_rx_buf_link was calling ath9k_hw_rxena after every
single added buffer.
Fix this by calling ath9k_hw_rxena directly from the rx tasklet after
completion instead.

Signed-off-by: Felix Fietkau <nbd@openwrt.org>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
drivers/net/wireless/ath/ath9k/recv.c

index ef198ae71eb73ffe0a2a6a8d941737e3967ea124..b81bfc4d66ef9b50b68b7c3868a03253a6ae146d 100644 (file)
@@ -75,7 +75,6 @@ static void ath_rx_buf_link(struct ath_softc *sc, struct ath_buf *bf)
                *sc->rx.rxlink = bf->bf_daddr;
 
        sc->rx.rxlink = &ds->ds_link;
-       ath9k_hw_rxena(ah);
 }
 
 static void ath_setdefantenna(struct ath_softc *sc, u32 antenna)
@@ -1765,6 +1764,7 @@ requeue:
                } else {
                        list_move_tail(&bf->list, &sc->rx.rxbuf);
                        ath_rx_buf_link(sc, bf);
+                       ath9k_hw_rxena(ah);
                }
        } while (1);