|
@@ -531,7 +531,8 @@ static int __cfg80211_set_encryption(struct cfg80211_registered_device *rdev,
|
|
|
wdev->wext.keys->data[idx];
|
|
|
}
|
|
|
|
|
|
- if (params->cipher != WLAN_CIPHER_SUITE_AES_CMAC &&
|
|
|
+ if ((params->cipher == WLAN_CIPHER_SUITE_WEP40 ||
|
|
|
+ params->cipher == WLAN_CIPHER_SUITE_WEP104) &&
|
|
|
(tx_key || (!addr && wdev->wext.default_key == -1))) {
|
|
|
if (wdev->current_bss)
|
|
|
err = rdev->ops->set_default_key(&rdev->wiphy,
|