This code in iwm is supposed to match what Linux does.
The Linux code looks like this:

        if (ieee80211_is_data(fc) && len > mvm->rts_threshold &&
            !is_multicast_ether_addr(ieee80211_get_DA(hdr)))
                tx_flags |= TX_CMD_FLG_PROT_REQUIRE;

Our driver had the 'is data' check inverted since the beginning.

Index: if_iwm.c
===================================================================
RCS file: /cvs/src/sys/dev/pci/if_iwm.c,v
retrieving revision 1.92
diff -u -p -r1.92 if_iwm.c
--- if_iwm.c    22 Jun 2016 11:32:12 -0000      1.92
+++ if_iwm.c    3 Jul 2016 09:15:24 -0000
@@ -4516,7 +4516,7 @@ iwm_tx(struct iwm_softc *sc, struct mbuf
                flags |= IWM_TX_CMD_FLG_ACK;
        }
 
-       if (type != IEEE80211_FC0_TYPE_DATA
+       if (type == IEEE80211_FC0_TYPE_DATA
            && (totlen + IEEE80211_CRC_LEN > ic->ic_rtsthreshold)
            && !IEEE80211_IS_MULTICAST(wh->i_addr1)) {
                flags |= IWM_TX_CMD_FLG_PROT_REQUIRE;

Reply via email to