This diff fixes an athn(4) performance regression on 2GHz. Before I added 11n support athn(4), the driver used to send RTS frames at 2 Mbit/s while operating in the 2GHz band. I changed this to 1 Mbit/s for consistency with other drivers. However, it turns out that the chip does not do what I am asking for.
My athn(4) AP for some reason ends up sending RTS at frames 9 Mbit/s (OFDM). Such frames get lost easily under poor radio conditions, which delays data frames and hurts throughput. This fix restores the previous behaviour. Index: ar5008.c =================================================================== RCS file: /cvs/src/sys/dev/ic/ar5008.c,v retrieving revision 1.44 diff -u -p -r1.44 ar5008.c --- ar5008.c 26 Apr 2017 07:53:17 -0000 1.44 +++ ar5008.c 16 Jul 2017 13:00:37 -0000 @@ -1601,7 +1601,7 @@ ar5008_tx(struct athn_softc *sc, struct } /* Select protection rate (suboptimal but ok). */ protridx = IEEE80211_IS_CHAN_5GHZ(ni->ni_chan) ? - ATHN_RIDX_OFDM6 : ATHN_RIDX_CCK1; + ATHN_RIDX_OFDM6 : ATHN_RIDX_CCK2; if (ds->ds_ctl0 & AR_TXC0_RTS_ENABLE) { /* Account for CTS duration. */ dur += athn_txtime(sc, IEEE80211_ACK_LEN,