aboutsummaryrefslogtreecommitdiffstats
path: root/hostapd
diff options
context:
space:
mode:
authorKyeyoon Park <kyeyoonp@qca.qualcomm.com>2014-10-15 23:36:04 (GMT)
committerJouni Malinen <j@w1.fi>2014-10-21 20:25:48 (GMT)
commitec8f36afca731aa6a30a314c54bb83441180719d (patch)
tree024bbf8bdd135f7049d29515b36ed6122e97ab66 /hostapd
parent8a5cc2fe385bc8afa4260f8953664db9861430eb (diff)
downloadhostap-ec8f36afca731aa6a30a314c54bb83441180719d.zip
hostap-ec8f36afca731aa6a30a314c54bb83441180719d.tar.gz
hostap-ec8f36afca731aa6a30a314c54bb83441180719d.tar.bz2
AP: Add support for BSS load element (STA Count, Channel Utilization)
The new "bss_load_update_period" parameter can be used to configure hostapd to advertise its BSS Load element in Beacon and Probe Response frames. This parameter is in the units of BUs (Beacon Units). When enabled, the STA Count and the Channel Utilization value will be updated periodically in the BSS Load element. The AAC is set to 0 sinze explicit admission control is not supported. Channel Utilization is calculated based on the channel survey information from the driver and as such, requires a driver that supports providing that information for the current operating channel. Signed-off-by: Kyeyoon Park <kyeyoonp@qca.qualcomm.com>
Diffstat (limited to 'hostapd')
-rw-r--r--hostapd/Android.mk1
-rw-r--r--hostapd/Makefile1
-rw-r--r--hostapd/config_file.c9
-rw-r--r--hostapd/hostapd.conf5
4 files changed, 16 insertions, 0 deletions
diff --git a/hostapd/Android.mk b/hostapd/Android.mk
index edaf6fc..84a8778 100644
--- a/hostapd/Android.mk
+++ b/hostapd/Android.mk
@@ -95,6 +95,7 @@ OBJS += src/ap/preauth_auth.c
OBJS += src/ap/pmksa_cache_auth.c
OBJS += src/ap/ieee802_11_shared.c
OBJS += src/ap/beacon.c
+OBJS += src/ap/bss_load.c
OBJS_d =
OBJS_p =
LIBS =
diff --git a/hostapd/Makefile b/hostapd/Makefile
index ac6373e..dc5eacd 100644
--- a/hostapd/Makefile
+++ b/hostapd/Makefile
@@ -59,6 +59,7 @@ OBJS += ../src/ap/preauth_auth.o
OBJS += ../src/ap/pmksa_cache_auth.o
OBJS += ../src/ap/ieee802_11_shared.o
OBJS += ../src/ap/beacon.o
+OBJS += ../src/ap/bss_load.o
OBJS_c = hostapd_cli.o ../src/common/wpa_ctrl.o ../src/utils/os_$(CONFIG_OS).o
diff --git a/hostapd/config_file.c b/hostapd/config_file.c
index d4ba7cc..ddebf1f 100644
--- a/hostapd/config_file.c
+++ b/hostapd/config_file.c
@@ -2489,6 +2489,15 @@ static int hostapd_config_fill(struct hostapd_config *conf,
line, bss->dtim_period);
return 1;
}
+ } else if (os_strcmp(buf, "bss_load_update_period") == 0) {
+ bss->bss_load_update_period = atoi(pos);
+ if (bss->bss_load_update_period < 0 ||
+ bss->bss_load_update_period > 100) {
+ wpa_printf(MSG_ERROR,
+ "Line %d: invalid bss_load_update_period %d",
+ line, bss->bss_load_update_period);
+ return 1;
+ }
} else if (os_strcmp(buf, "rts_threshold") == 0) {
conf->rts_threshold = atoi(pos);
if (conf->rts_threshold < 0 || conf->rts_threshold > 2347) {
diff --git a/hostapd/hostapd.conf b/hostapd/hostapd.conf
index d4e5bf0..2e6f841 100644
--- a/hostapd/hostapd.conf
+++ b/hostapd/hostapd.conf
@@ -435,6 +435,11 @@ wmm_ac_vo_acm=0
# associated stations in the BSS. By default, this bridging is allowed.
#ap_isolate=1
+# BSS Load update period (in BUs)
+# This field is used to enable and configure adding a BSS Load element into
+# Beacon and Probe Response frames.
+#bss_load_update_period=50
+
# Fixed BSS Load value for testing purposes
# This field can be used to configure hostapd to add a fixed BSS Load element
# into Beacon and Probe Response frames for testing purposes. The format is