• Johannes Berg's avatar
    iwlwifi: mvm: fix TX crypto on 22560+ devices · 475c6bde
    Johannes Berg authored
    In the old days, we could transmit with HW crypto with an arbitrary
    key by filling it into TX_CMD. This was broken first with the advent
    of CCMP/GCMP-256 keys which don't fit there.
    
    This was broken *again* with the newer TX_CMD format on 22560+,
    where we simply cannot pass key material anymore. However, we forgot
    to update all the cases when we get a key from mac80211 and don't
    program it into the hardware but still return 0 for HW crypto on TX.
    
    In AP mode with WEP, we tried to fix this by programming the keys
    separately for each station later, but this ultimately turns out to
    be buggy, for example now it leaks memory when we have more than one
    WEP key.
    
    Fix this by simply using only SW crypto for WEP in newer devices by
    returning -EOPNOTSUPP instead of trying to program WEP keys later.
    Signed-off-by: default avatarJohannes Berg <johannes.berg@intel.com>
    Signed-off-by: default avatarLuca Coelho <luciano.coelho@intel.com>
    475c6bde
sta.h 23.9 KB