wifi: mac80211: use IEEE80211_MLD_MAX_NUM_LINKS
authorJohannes Berg <johannes.berg@intel.com>
Mon, 30 May 2022 20:36:30 +0000 (22:36 +0200)
committerJohannes Berg <johannes.berg@intel.com>
Mon, 20 Jun 2022 10:55:20 +0000 (12:55 +0200)
Remove MAX_STA_LINKS and use IEEE80211_MLD_MAX_NUM_LINKS
instead to unify between the station and other data structures.

Signed-off-by: Johannes Berg <johannes.berg@intel.com>
include/net/mac80211.h
net/mac80211/sta_info.h

index 4dc51c52dd28cef373061a64be4782f524cf3ad3..902a10ee50f25e83010a4388b07a6d40de1af7ce 100644 (file)
@@ -2061,8 +2061,6 @@ struct ieee80211_sta_txpwr {
        enum nl80211_tx_power_setting type;
 };
 
-#define MAX_STA_LINKS                  15
-
 /**
  * struct ieee80211_link_sta - station Link specific info
  * All link specific info for a STA link for a non MLD STA(single)
@@ -2190,7 +2188,7 @@ struct ieee80211_sta {
 
        bool multi_link_sta;
        struct ieee80211_link_sta deflink;
-       struct ieee80211_link_sta *link[MAX_STA_LINKS];
+       struct ieee80211_link_sta *link[IEEE80211_MLD_MAX_NUM_LINKS];
 
        /* must be last */
        u8 drv_priv[] __aligned(sizeof(void *));
index 134a7dad0ac488178ddc0778a92803635d67f306..2ff3d5fd0cbf7fdd77ce71e259408dfc8b5d172a 100644 (file)
@@ -710,7 +710,7 @@ struct sta_info {
 
        bool multi_link_sta;
        struct link_sta_info deflink;
-       struct link_sta_info *link[MAX_STA_LINKS];
+       struct link_sta_info *link[IEEE80211_MLD_MAX_NUM_LINKS];
 
        /* keep last! */
        struct ieee80211_sta sta;