nl80211: Determine maximum number of supported AKMs
Use the recently added attribute to determine whether the kernel supports a larger number of AKM suites in various commands. Signed-off-by: Veerendranath Jakkam <quic_vjakkam@quicinc.com>
This commit is contained in:
parent
48c620829c
commit
0ce1545dcb
4 changed files with 12 additions and 0 deletions
|
@ -2182,6 +2182,9 @@ struct wpa_driver_capa {
|
|||
|
||||
/* Maximum number of supported CSA counters */
|
||||
u16 max_csa_counters;
|
||||
|
||||
/* Maximum number of supported AKM suites in commands */
|
||||
unsigned int max_num_akms;
|
||||
};
|
||||
|
||||
|
||||
|
|
|
@ -1087,6 +1087,10 @@ static int wiphy_info_handler(struct nl_msg *msg, void *arg)
|
|||
if (tb[NL80211_ATTR_WIPHY_SELF_MANAGED_REG])
|
||||
capa->flags |= WPA_DRIVER_FLAGS_SELF_MANAGED_REGULATORY;
|
||||
|
||||
if (tb[NL80211_ATTR_MAX_NUM_AKM_SUITES])
|
||||
capa->max_num_akms =
|
||||
nla_get_u16(tb[NL80211_ATTR_MAX_NUM_AKM_SUITES]);
|
||||
|
||||
return NL_SKIP;
|
||||
}
|
||||
|
||||
|
@ -1165,6 +1169,9 @@ static int wpa_driver_nl80211_get_info(struct wpa_driver_nl80211_data *drv,
|
|||
if (info->update_ft_ies_supported)
|
||||
drv->capa.flags |= WPA_DRIVER_FLAGS_UPDATE_FT_IES;
|
||||
|
||||
if (!drv->capa.max_num_akms)
|
||||
drv->capa.max_num_akms = NL80211_MAX_NR_AKM_SUITES;
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
|
|
@ -6771,6 +6771,7 @@ static int wpa_supplicant_init_iface(struct wpa_supplicant *wpa_s,
|
|||
wpa_s->num_multichan_concurrent =
|
||||
capa.num_multichan_concurrent;
|
||||
wpa_s->wmm_ac_supported = capa.wmm_ac_supported;
|
||||
wpa_s->max_num_akms = capa.max_num_akms;
|
||||
|
||||
if (capa.mac_addr_rand_scan_supported)
|
||||
wpa_s->mac_addr_rand_supported |= MAC_ADDR_RAND_SCAN;
|
||||
|
|
|
@ -932,6 +932,7 @@ struct wpa_supplicant {
|
|||
unsigned int max_match_sets;
|
||||
unsigned int max_remain_on_chan;
|
||||
unsigned int max_stations;
|
||||
unsigned int max_num_akms;
|
||||
|
||||
int pending_mic_error_report;
|
||||
int pending_mic_error_pairwise;
|
||||
|
|
Loading…
Reference in a new issue