mirror of
https://git.kernel.org/pub/scm/network/wireless/iwd.git
synced 2025-01-20 17:54:05 +01:00
wiphy: Add parser and getter for max ie len attr
This commit is contained in:
parent
506f502900
commit
df43470c32
12
src/wiphy.c
12
src/wiphy.c
@ -67,6 +67,7 @@ struct wiphy {
|
|||||||
uint8_t ext_features[(NUM_NL80211_EXT_FEATURES + 7) / 8];
|
uint8_t ext_features[(NUM_NL80211_EXT_FEATURES + 7) / 8];
|
||||||
uint8_t max_num_ssids_per_scan;
|
uint8_t max_num_ssids_per_scan;
|
||||||
uint32_t max_roc_duration;
|
uint32_t max_roc_duration;
|
||||||
|
uint16_t max_scan_ie_len;
|
||||||
uint16_t supported_iftypes;
|
uint16_t supported_iftypes;
|
||||||
uint16_t supported_ciphers;
|
uint16_t supported_ciphers;
|
||||||
struct scan_freq_set *supported_freqs;
|
struct scan_freq_set *supported_freqs;
|
||||||
@ -363,6 +364,11 @@ uint8_t wiphy_get_max_num_ssids_per_scan(struct wiphy *wiphy)
|
|||||||
return wiphy->max_num_ssids_per_scan;
|
return wiphy->max_num_ssids_per_scan;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
uint16_t wiphy_get_max_scan_ie_len(struct wiphy *wiphy)
|
||||||
|
{
|
||||||
|
return wiphy->max_scan_ie_len;
|
||||||
|
}
|
||||||
|
|
||||||
uint32_t wiphy_get_max_roc_duration(struct wiphy *wiphy)
|
uint32_t wiphy_get_max_roc_duration(struct wiphy *wiphy)
|
||||||
{
|
{
|
||||||
return wiphy->max_roc_duration;
|
return wiphy->max_roc_duration;
|
||||||
@ -834,6 +840,12 @@ static void wiphy_parse_attributes(struct wiphy *wiphy,
|
|||||||
wiphy->max_num_ssids_per_scan =
|
wiphy->max_num_ssids_per_scan =
|
||||||
*((uint8_t *) data);
|
*((uint8_t *) data);
|
||||||
break;
|
break;
|
||||||
|
case NL80211_ATTR_MAX_SCAN_IE_LEN:
|
||||||
|
if (len != sizeof(uint16_t))
|
||||||
|
l_warn("Invalid MAX_SCAN_IE_LEN attribute");
|
||||||
|
else
|
||||||
|
wiphy->max_scan_ie_len = *((uint16_t *) data);
|
||||||
|
break;
|
||||||
case NL80211_ATTR_SUPPORT_IBSS_RSN:
|
case NL80211_ATTR_SUPPORT_IBSS_RSN:
|
||||||
wiphy->support_adhoc_rsn = true;
|
wiphy->support_adhoc_rsn = true;
|
||||||
break;
|
break;
|
||||||
|
@ -64,6 +64,7 @@ bool wiphy_rrm_capable(struct wiphy *wiphy);
|
|||||||
bool wiphy_has_feature(struct wiphy *wiphy, uint32_t feature);
|
bool wiphy_has_feature(struct wiphy *wiphy, uint32_t feature);
|
||||||
bool wiphy_has_ext_feature(struct wiphy *wiphy, uint32_t feature);
|
bool wiphy_has_ext_feature(struct wiphy *wiphy, uint32_t feature);
|
||||||
uint8_t wiphy_get_max_num_ssids_per_scan(struct wiphy *wiphy);
|
uint8_t wiphy_get_max_num_ssids_per_scan(struct wiphy *wiphy);
|
||||||
|
uint16_t wiphy_get_max_scan_ie_len(struct wiphy *wiphy);
|
||||||
uint32_t wiphy_get_max_roc_duration(struct wiphy *wiphy);
|
uint32_t wiphy_get_max_roc_duration(struct wiphy *wiphy);
|
||||||
bool wiphy_supports_iftype(struct wiphy *wiphy, uint32_t iftype);
|
bool wiphy_supports_iftype(struct wiphy *wiphy, uint32_t iftype);
|
||||||
const uint8_t *wiphy_get_supported_rates(struct wiphy *wiphy, unsigned int band,
|
const uint8_t *wiphy_get_supported_rates(struct wiphy *wiphy, unsigned int band,
|
||||||
|
Loading…
Reference in New Issue
Block a user