summaryrefslogtreecommitdiffstats
path: root/net/mac80211/iface.c
diff options
context:
space:
mode:
authorJohannes Berg <johannes.berg@intel.com>2022-08-17 11:17:01 +0200
committerJohannes Berg <johannes.berg@intel.com>2022-08-25 10:41:07 +0200
commitccdde7c74ffd7e8bdd3cf685bbfa41231c8e3131 (patch)
tree0b8a0007b5827c7d7fb2cdce62c190b5d1d36c98 /net/mac80211/iface.c
parentwifi: cfg80211: Add link_id parameter to various key operations for MLO (diff)
downloadlinux-ccdde7c74ffd7e8bdd3cf685bbfa41231c8e3131.tar.xz
linux-ccdde7c74ffd7e8bdd3cf685bbfa41231c8e3131.zip
wifi: mac80211: properly implement MLO key handling
Implement key installation and lookup (on TX and RX) for MLO, so we can use multiple GTKs/IGTKs/BIGTKs. Co-authored-by: Ilan Peer <ilan.peer@intel.com> Signed-off-by: Ilan Peer <ilan.peer@intel.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Diffstat (limited to 'net/mac80211/iface.c')
-rw-r--r--net/mac80211/iface.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/net/mac80211/iface.c b/net/mac80211/iface.c
index 3c30e1219861..b6e581fc9a40 100644
--- a/net/mac80211/iface.c
+++ b/net/mac80211/iface.c
@@ -434,10 +434,19 @@ struct link_container {
static void ieee80211_free_links(struct ieee80211_sub_if_data *sdata,
struct link_container **links)
{
+ LIST_HEAD(keys);
unsigned int link_id;
+ for (link_id = 0; link_id < IEEE80211_MLD_MAX_NUM_LINKS; link_id++) {
+ if (!links[link_id])
+ continue;
+ ieee80211_remove_link_keys(&links[link_id]->data, &keys);
+ }
+
synchronize_rcu();
+ ieee80211_free_key_list(sdata->local, &keys);
+
for (link_id = 0; link_id < IEEE80211_MLD_MAX_NUM_LINKS; link_id++) {
if (!links[link_id])
continue;