diff options
author | Jouni Malinen <jouni.malinen@atheros.com> | 2011-05-03 22:45:16 -0700 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@suse.de> | 2011-06-03 10:33:49 +0900 |
commit | 8a2b75b1bc777133e2d70e560e5e49bc1b536b36 (patch) | |
tree | 0c0c032acf8dc0d44b0d7083b91f2ab607ebb159 /net | |
parent | c5c970a5a59305869358cf1e5d2bce710b0e10c7 (diff) | |
download | lwn-8a2b75b1bc777133e2d70e560e5e49bc1b536b36.tar.gz lwn-8a2b75b1bc777133e2d70e560e5e49bc1b536b36.zip |
nl80211: Fix set_key regression with some drivers
commit 0e579d6a8f4aea346da818f13ee71401c125e639 upstream.
Commit dbd2fd656f2060abfd3a16257f8b51ec60f6d2ed added a mechanism for
user space to indicate whether a default key is being configured for
only unicast or only multicast frames instead of all frames. This
commit added a driver capability flag for indicating whether separate
default keys are supported and validation of the set_key command based
on that capability.
However, this single capability flag is not enough to cover possible
difference based on mode (AP/IBSS/STA) and the way this change was
introduced resulted in a regression with drivers that do not indicate
the new capability (i.e.., more or less any non-mac80211 driver using
cfg80211) when using a recent wpa_supplicant snapshot.
Fix the regression by removing the new check which is not strictly
speaking needed. The new separate default key functionality is needed
only for RSN IBSS which has a separate capability indication.
Signed-off-by: Jouni Malinen <jouni.malinen@atheros.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'net')
-rw-r--r-- | net/wireless/nl80211.c | 8 |
1 files changed, 0 insertions, 8 deletions
diff --git a/net/wireless/nl80211.c b/net/wireless/nl80211.c index 9b62710891a2..47d9a875612d 100644 --- a/net/wireless/nl80211.c +++ b/net/wireless/nl80211.c @@ -1679,14 +1679,6 @@ static int nl80211_set_key(struct sk_buff *skb, struct genl_info *info) if (err) goto out; - if (!(rdev->wiphy.flags & - WIPHY_FLAG_SUPPORTS_SEPARATE_DEFAULT_KEYS)) { - if (!key.def_uni || !key.def_multi) { - err = -EOPNOTSUPP; - goto out; - } - } - err = rdev->ops->set_default_key(&rdev->wiphy, dev, key.idx, key.def_uni, key.def_multi); |