if_ath_rx_edma.c (286410) | if_ath_rx_edma.c (286437) |
---|---|
1/*- 2 * Copyright (c) 2012 Adrian Chadd <adrian@FreeBSD.org> 3 * All rights reserved. 4 * 5 * Redistribution and use in source and binary forms, with or without 6 * modification, are permitted provided that the following conditions 7 * are met: 8 * 1. Redistributions of source code must retain the above copyright --- 14 unchanged lines hidden (view full) --- 23 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS 24 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER 25 * IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 26 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF 27 * THE POSSIBILITY OF SUCH DAMAGES. 28 */ 29 30#include <sys/cdefs.h> | 1/*- 2 * Copyright (c) 2012 Adrian Chadd <adrian@FreeBSD.org> 3 * All rights reserved. 4 * 5 * Redistribution and use in source and binary forms, with or without 6 * modification, are permitted provided that the following conditions 7 * are met: 8 * 1. Redistributions of source code must retain the above copyright --- 14 unchanged lines hidden (view full) --- 23 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS 24 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER 25 * IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 26 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF 27 * THE POSSIBILITY OF SUCH DAMAGES. 28 */ 29 30#include <sys/cdefs.h> |
31__FBSDID("$FreeBSD: head/sys/dev/ath/if_ath_rx_edma.c 286410 2015-08-07 11:43:14Z glebius $"); | 31__FBSDID("$FreeBSD: head/sys/dev/ath/if_ath_rx_edma.c 286437 2015-08-08 01:10:17Z adrian $"); |
32 33/* 34 * Driver for the Atheros Wireless LAN controller. 35 * 36 * This software is derived from work of Atsushi Onoe; his contribution 37 * is greatly appreciated. 38 */ 39 --- 534 unchanged lines hidden (view full) --- 574 575 return (ngood); 576} 577 578static void 579ath_edma_recv_tasklet(void *arg, int npending) 580{ 581 struct ath_softc *sc = (struct ath_softc *) arg; | 32 33/* 34 * Driver for the Atheros Wireless LAN controller. 35 * 36 * This software is derived from work of Atsushi Onoe; his contribution 37 * is greatly appreciated. 38 */ 39 --- 534 unchanged lines hidden (view full) --- 574 575 return (ngood); 576} 577 578static void 579ath_edma_recv_tasklet(void *arg, int npending) 580{ 581 struct ath_softc *sc = (struct ath_softc *) arg; |
582 struct ifnet *ifp = sc->sc_ifp; |
|
582#ifdef IEEE80211_SUPPORT_SUPERG | 583#ifdef IEEE80211_SUPPORT_SUPERG |
583 struct ieee80211com *ic = &sc->sc_ic; | 584 struct ieee80211com *ic = ifp->if_l2com; |
584#endif 585 586 DPRINTF(sc, ATH_DEBUG_EDMA_RX, "%s: called; npending=%d\n", 587 __func__, 588 npending); 589 590 ATH_PCU_LOCK(sc); 591 if (sc->sc_inreset_cnt > 0) { --- 19 unchanged lines hidden (view full) --- 611 * XXX: If we read the tsf/channoise here and then pass it in, 612 * we could restore the power state before processing 613 * the deferred queue. 614 */ 615 ATH_LOCK(sc); 616 ath_power_restore_power_state(sc); 617 ATH_UNLOCK(sc); 618 | 585#endif 586 587 DPRINTF(sc, ATH_DEBUG_EDMA_RX, "%s: called; npending=%d\n", 588 __func__, 589 npending); 590 591 ATH_PCU_LOCK(sc); 592 if (sc->sc_inreset_cnt > 0) { --- 19 unchanged lines hidden (view full) --- 612 * XXX: If we read the tsf/channoise here and then pass it in, 613 * we could restore the power state before processing 614 * the deferred queue. 615 */ 616 ATH_LOCK(sc); 617 ath_power_restore_power_state(sc); 618 ATH_UNLOCK(sc); 619 |
620 /* XXX inside IF_LOCK ? */ 621 if ((ifp->if_drv_flags & IFF_DRV_OACTIVE) == 0) { |
|
619#ifdef IEEE80211_SUPPORT_SUPERG | 622#ifdef IEEE80211_SUPPORT_SUPERG |
620 ieee80211_ff_age_all(ic, 100); | 623 ieee80211_ff_age_all(ic, 100); |
621#endif | 624#endif |
625 if (! IFQ_IS_EMPTY(&ifp->if_snd)) 626 ath_tx_kick(sc); 627 } |
|
622 if (ath_dfs_tasklet_needed(sc, sc->sc_curchan)) 623 taskqueue_enqueue(sc->sc_tq, &sc->sc_dfstask); 624 625 ATH_PCU_LOCK(sc); 626 sc->sc_rxproc_cnt--; 627 ATH_PCU_UNLOCK(sc); 628} 629 --- 378 unchanged lines hidden --- | 628 if (ath_dfs_tasklet_needed(sc, sc->sc_curchan)) 629 taskqueue_enqueue(sc->sc_tq, &sc->sc_dfstask); 630 631 ATH_PCU_LOCK(sc); 632 sc->sc_rxproc_cnt--; 633 ATH_PCU_UNLOCK(sc); 634} 635 --- 378 unchanged lines hidden --- |