From: Jouni Malinen Date: Sun, 1 Jan 2017 22:27:58 +0000 (+0200) Subject: Enable Beacon Report using beacon table for all drivers X-Git-Tag: hostap_2_7~1845 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=de6ec8b55841d6385be5b2d1c8ac4698fe1a5b60;p=thirdparty%2Fhostap.git Enable Beacon Report using beacon table for all drivers The special parameters for beacon report scan are not needed for the beacon report when using the beacon table measurement mode. Advertise support for this case regardless of whether the driver supports the scan parameters. Signed-off-by: Jouni Malinen --- diff --git a/wpa_supplicant/rrm.c b/wpa_supplicant/rrm.c index dfa042230..12a3a925c 100644 --- a/wpa_supplicant/rrm.c +++ b/wpa_supplicant/rrm.c @@ -1030,11 +1030,13 @@ wpas_rm_handle_beacon_req(struct wpa_supplicant *wpa_s, u32 _rand; int ret = 0, res; - if (!(wpa_s->drv_rrm_flags & WPA_DRIVER_FLAGS_SUPPORT_BEACON_REPORT)) - return 0; - if (len < sizeof(*req)) return -1; + + if (req->mode != BEACON_REPORT_MODE_TABLE && + !(wpa_s->drv_rrm_flags & WPA_DRIVER_FLAGS_SUPPORT_BEACON_REPORT)) + return 0; + subelems = req->variable; elems_len = len - sizeof(*req); rand_interval = le_to_host16(req->rand_interval); diff --git a/wpa_supplicant/sme.c b/wpa_supplicant/sme.c index ce116f640..18b1165d5 100644 --- a/wpa_supplicant/sme.c +++ b/wpa_supplicant/sme.c @@ -189,8 +189,8 @@ static void sme_auth_handle_rrm(struct wpa_supplicant *wpa_s, if (wpa_s->drv_rrm_flags & WPA_DRIVER_FLAGS_SUPPORT_BEACON_REPORT) *pos |= WLAN_RRM_CAPS_BEACON_REPORT_PASSIVE | - WLAN_RRM_CAPS_BEACON_REPORT_ACTIVE | - WLAN_RRM_CAPS_BEACON_REPORT_TABLE; + WLAN_RRM_CAPS_BEACON_REPORT_ACTIVE; + *pos |= WLAN_RRM_CAPS_BEACON_REPORT_TABLE; if (wpa_s->lci) pos[1] |= WLAN_RRM_CAPS_LCI_MEASUREMENT;