From 847f76760a9eb95c81a2e09aa001d824a2948370 Mon Sep 17 00:00:00 2001 From: John Crispin Date: Tue, 27 Jul 2021 16:42:19 -0700 Subject: [PATCH] RNR: Add configuration option Adds configuration option 'rnr' to enable the reduced neighbor report elements in Beacon and Probe Response frames. Signed-off-by: John Crispin Signed-off-by: Aloka Dixit --- hostapd/config_file.c | 2 ++ hostapd/hostapd.conf | 3 +++ src/ap/ap_config.h | 2 ++ 3 files changed, 7 insertions(+) diff --git a/hostapd/config_file.c b/hostapd/config_file.c index a57797262..daf3f37ad 100644 --- a/hostapd/config_file.c +++ b/hostapd/config_file.c @@ -4712,6 +4712,8 @@ static int hostapd_config_fill(struct hostapd_config *conf, if (get_hex_config(bss->ext_capa, EXT_CAPA_MAX_LEN, line, "ext_capa", pos)) return 1; + } else if (os_strcmp(buf, "rnr") == 0) { + bss->rnr = atoi(pos); } else { wpa_printf(MSG_ERROR, "Line %d: unknown configuration item '%s'", diff --git a/hostapd/hostapd.conf b/hostapd/hostapd.conf index 6b807f489..67d4cefb9 100644 --- a/hostapd/hostapd.conf +++ b/hostapd/hostapd.conf @@ -2921,6 +2921,9 @@ own_ip_addr=127.0.0.1 # that allows sending of such data. Default: 0. #stationary_ap=0 +# Enable reduced neighbor reporting (RNR) +#rnr=0 + ##### Airtime policy configuration ########################################### # Set the airtime policy operating mode: diff --git a/src/ap/ap_config.h b/src/ap/ap_config.h index 3ba368987..b8f791e56 100644 --- a/src/ap/ap_config.h +++ b/src/ap/ap_config.h @@ -894,6 +894,8 @@ struct hostapd_bss_config { u8 ext_capa_mask[EXT_CAPA_MAX_LEN]; u8 ext_capa[EXT_CAPA_MAX_LEN]; + + u8 rnr; }; /**