[PATCH 2/2] ath10k: Support rx-software-crypt mode.
Ben Greear
greearb at candelatech.com
Wed Jan 22 20:40:58 EST 2014
On 01/22/2014 04:41 PM, greearb at candelatech.com wrote:
> From: Ben Greear <greearb at candelatech.com>
>
> With appropriate firmware (probably only CT firmware at this time)
> this allows enabling rx-software-crypt mode. This tells the
> firmware to not decrypt any packets received, but do encrypt
> (as needed) any packets on transmit. This is implemented to get
> around hardware issues that preclude using two stations to
> connect to the same AP while using encryption.
>
I should mention: This depends on a mac80211 patch I sent to
the linux-wireless mailing list. It defines and uses the key flag
used below...
Thanks,
Ben
> /**********/
> /* Crypto */
> /**********/
> @@ -77,6 +85,8 @@ static int ath10k_send_key(struct ath10k_vif *arvif,
> if (cmd == DISABLE_KEY) {
> arg.key_cipher = WMI_CIPHER_NONE;
> arg.key_data = NULL;
> + } else if (ath10k_modparam_nohwcrypt) {
> + key->flags |= IEEE80211_KEY_FLAG_SW_RX_CRYPT;
> }
>
> return ath10k_wmi_vdev_install_key(arvif->ar, &arg);
> @@ -2792,6 +2802,8 @@ static int ath10k_set_key(struct ieee80211_hw *hw, enum set_key_cmd cmd,
>
> mutex_lock(&ar->conf_mutex);
>
> + key->flags &= ~IEEE80211_KEY_FLAG_SW_RX_CRYPT;
> +
> if (sta)
> peer_addr = sta->addr;
> else if (arvif->vdev_type == WMI_VDEV_TYPE_STA)
--
Ben Greear <greearb at candelatech.com>
Candela Technologies Inc http://www.candelatech.com
More information about the ath10k
mailing list