Ticket #705: ani_sensitity_fix.diff

File ani_sensitity_fix.diff, 1.9 kB (added by tjalling.hattink@ti-wmc.nl, 5 years ago)

ANI sensitivity patch.

  • ath/if_ath.c

    old new  
    19051905 
    19061906        if (sc->sc_softled) 
    19071907                ath_hal_gpioCfgOutput(ah, sc->sc_ledpin); 
     1908 
     1909        if (sc->sc_opmode != HAL_M_STA) 
     1910        { 
     1911                /* Turn off ANI (ambient noise immunity) in other modes than station 
     1912                 * because it causes receive sensitivity problems in OFDM modulations. 
     1913                 */ 
     1914                if (ath_hal_getcapability(sc->sc_ah, HAL_CAP_INTMIT, 0, NULL) == HAL_OK)  
     1915                        ath_hal_setcapability(sc->sc_ah, HAL_CAP_INTMIT, 1, 0, NULL); 
     1916        } 
     1917 
    19081918        /* 
    19091919         * This is needed only to setup initial state 
    19101920         * but it's best done after a reset. 
     
    21552165        if (!ath_hal_reset(ah, sc->sc_opmode, &sc->sc_curchan, AH_TRUE, &status)) 
    21562166                printk("%s: %s: unable to reset hardware: '%s' (HAL status %u)\n", 
    21572167                        dev->name, __func__, ath_get_hal_status_desc(status), status); 
     2168 
     2169        if (sc->sc_opmode != HAL_M_STA) 
     2170        { 
     2171                /* Turn off ANI (ambient noise immunity) in other modes than station 
     2172                 * because it causes receive sensitivity problems in OFDM modulations. 
     2173                 */ 
     2174                if (ath_hal_getcapability(sc->sc_ah, HAL_CAP_INTMIT, 0, NULL) == HAL_OK)  
     2175                        ath_hal_setcapability(sc->sc_ah, HAL_CAP_INTMIT, 1, 0, NULL); 
     2176        } 
     2177 
    21582178        ath_update_txpow(sc);           /* update tx power state */ 
    21592179        if (ath_startrecv(sc) != 0)     /* restart recv */ 
    21602180                printk("%s: %s: unable to start recv logic\n", 
     
    77927812                if (sc->sc_softled) 
    77937813                        ath_hal_gpioCfgOutput(ah, sc->sc_ledpin); 
    77947814                 
     7815                if (sc->sc_opmode != HAL_M_STA) 
     7816                { 
     7817                        /* Turn off ANI (ambient noise immunity) in other modes than station 
     7818                         * because it causes receive sensitivity problems in OFDM modulations. 
     7819                         */ 
     7820                        if (ath_hal_getcapability(sc->sc_ah, HAL_CAP_INTMIT, 0, NULL) == HAL_OK)  
     7821                                ath_hal_setcapability(sc->sc_ah, HAL_CAP_INTMIT, 1, 0, NULL); 
     7822                } 
     7823 
    77957824                sc->sc_curchan = hchan; 
    77967825                ath_update_txpow(sc);           /* update tx power state */ 
    77977826