diff options
author | Jouni Malinen <j@w1.fi> | 2014-01-15 00:01:08 +0200 |
---|---|---|
committer | Johannes Berg <johannes.berg@intel.com> | 2014-02-04 21:48:08 +0100 |
commit | b43504cf75b8b8773ee70c90bcd691282e151b9a (patch) | |
tree | 20d2758a4e6602f0a2e43a80585923d70ffbd17d /net/wireless/nl80211.c | |
parent | 1df4a51082df6e5b0b8eb70df81885b9b4c9e6ec (diff) | |
download | lwn-b43504cf75b8b8773ee70c90bcd691282e151b9a.tar.gz lwn-b43504cf75b8b8773ee70c90bcd691282e151b9a.zip |
cfg80211: Advertise maximum associated STAs in AP mode
This allows drivers to advertise the maximum number of associated
stations they support in AP mode (including P2P GO). User space
applications can use this for cleaner way of handling the limit (e.g.,
hostapd rejecting IEEE 802.11 authentication without manual
configuration of the limit) or to figure out what type of use cases can
be executed with multiple devices before trying and failing.
Signed-off-by: Jouni Malinen <j@w1.fi>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Diffstat (limited to 'net/wireless/nl80211.c')
-rw-r--r-- | net/wireless/nl80211.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/net/wireless/nl80211.c b/net/wireless/nl80211.c index 6e7d580ec645..b2ac1410b113 100644 --- a/net/wireless/nl80211.c +++ b/net/wireless/nl80211.c @@ -1588,6 +1588,12 @@ static int nl80211_send_wiphy(struct cfg80211_registered_device *dev, (nla_put_flag(msg, NL80211_ATTR_SUPPORT_5_MHZ) || nla_put_flag(msg, NL80211_ATTR_SUPPORT_10_MHZ))) goto nla_put_failure; + + if (dev->wiphy.max_ap_assoc_sta && + nla_put_u32(msg, NL80211_ATTR_MAX_AP_ASSOC_STA, + dev->wiphy.max_ap_assoc_sta)) + goto nla_put_failure; + state->split_start++; break; case 11: |