diff options
author | Johannes Berg <johannes.berg@intel.com> | 2011-07-13 13:50:53 -0400 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2011-07-15 13:38:33 -0400 |
commit | f850e00fcd7767d01101e2f0a6d464bee8e48b47 (patch) | |
tree | c90d77261e09a6304e1b507c363e4ff66bc61b8d /net/mac80211 | |
parent | 8bca5d815311f53ada13b62f5e590df40fef317e (diff) |
mac80211: let key iteration get keys in install order
ieee80211_iter_keys() currently returns keys in
the backward order they were installed in, which
is a bit confusing. Add them to the tail of the
key list to make sure iterations go in the same
order that keys were originally installed in.
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'net/mac80211')
-rw-r--r-- | net/mac80211/key.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/net/mac80211/key.c b/net/mac80211/key.c index 739bee13e813..5150c6d11b57 100644 --- a/net/mac80211/key.c +++ b/net/mac80211/key.c | |||
@@ -278,7 +278,7 @@ static void __ieee80211_key_replace(struct ieee80211_sub_if_data *sdata, | |||
278 | bool defunikey, defmultikey, defmgmtkey; | 278 | bool defunikey, defmultikey, defmgmtkey; |
279 | 279 | ||
280 | if (new) | 280 | if (new) |
281 | list_add(&new->list, &sdata->key_list); | 281 | list_add_tail(&new->list, &sdata->key_list); |
282 | 282 | ||
283 | if (sta && pairwise) { | 283 | if (sta && pairwise) { |
284 | rcu_assign_pointer(sta->ptk, new); | 284 | rcu_assign_pointer(sta->ptk, new); |