|
@@ -982,6 +982,7 @@ util_scan_gen_scan_entry(struct wlan_objmgr_pdev *pdev,
|
|
|
uint8_t *frame, qdf_size_t frame_len,
|
|
|
uint32_t frm_subtype,
|
|
|
struct mgmt_rx_event_params *rx_param,
|
|
|
+ struct scan_mbssid_info *mbssid_info,
|
|
|
qdf_list_t *scan_list)
|
|
|
{
|
|
|
struct wlan_frame_hdr *hdr;
|
|
@@ -1105,7 +1106,8 @@ util_scan_gen_scan_entry(struct wlan_objmgr_pdev *pdev,
|
|
|
scan_entry->hidden_ssid_timestamp =
|
|
|
scan_entry->scan_entry_time;
|
|
|
}
|
|
|
-
|
|
|
+ qdf_mem_copy(&scan_entry->mbssid_info, mbssid_info,
|
|
|
+ sizeof(scan_entry->mbssid_info));
|
|
|
if (WLAN_CHAN_IS_5GHZ(scan_entry->channel.chan_idx))
|
|
|
scan_entry->phy_mode = util_scan_get_phymode_5g(scan_entry);
|
|
|
else
|
|
@@ -1285,6 +1287,7 @@ static QDF_STATUS util_scan_parse_mbssid(struct wlan_objmgr_pdev *pdev,
|
|
|
{
|
|
|
struct wlan_bcn_frame *bcn;
|
|
|
struct wlan_frame_hdr *hdr;
|
|
|
+ struct scan_mbssid_info mbssid_info;
|
|
|
QDF_STATUS status;
|
|
|
uint8_t *pos, *subelement, *mbssid_end_pos;
|
|
|
uint8_t *tmp, *mbssid_index_ie;
|
|
@@ -1317,6 +1320,7 @@ static QDF_STATUS util_scan_parse_mbssid(struct wlan_objmgr_pdev *pdev,
|
|
|
if (!tmp)
|
|
|
break;
|
|
|
|
|
|
+ mbssid_info.profile_count = 1 << tmp[2];
|
|
|
mbssid_end_pos = tmp + tmp[1] + 2;
|
|
|
/* Skip Element ID, Len, MaxBSSID Indicator */
|
|
|
if (tmp[1] < 4)
|
|
@@ -1349,7 +1353,9 @@ static QDF_STATUS util_scan_parse_mbssid(struct wlan_objmgr_pdev *pdev,
|
|
|
/* No valid Multiple BSSID-Index element */
|
|
|
continue;
|
|
|
}
|
|
|
-
|
|
|
+ qdf_mem_copy(&mbssid_info.trans_bssid, bssid,
|
|
|
+ QDF_MAC_ADDR_SIZE);
|
|
|
+ mbssid_info.profile_num = mbssid_index_ie[2];
|
|
|
util_gen_new_bssid(bssid, tmp[2], mbssid_index_ie[2],
|
|
|
new_bssid);
|
|
|
new_ie_len = util_gen_new_ie(ie, ielen, subelement + 2,
|
|
@@ -1383,7 +1389,9 @@ static QDF_STATUS util_scan_parse_mbssid(struct wlan_objmgr_pdev *pdev,
|
|
|
status = util_scan_gen_scan_entry(pdev, new_frame,
|
|
|
new_frame_len,
|
|
|
frm_subtype,
|
|
|
- rx_param, scan_list);
|
|
|
+ rx_param,
|
|
|
+ &mbssid_info,
|
|
|
+ scan_list);
|
|
|
if (QDF_IS_STATUS_ERROR(status)) {
|
|
|
qdf_mem_free(new_frame);
|
|
|
scm_err("failed to generate a scan entry");
|
|
@@ -1419,17 +1427,30 @@ util_scan_parse_beacon_frame(struct wlan_objmgr_pdev *pdev,
|
|
|
qdf_list_t *scan_list)
|
|
|
{
|
|
|
struct wlan_bcn_frame *bcn;
|
|
|
+ struct wlan_frame_hdr *hdr;
|
|
|
+ uint8_t *mbssid_ie = NULL;
|
|
|
uint32_t ie_len = 0;
|
|
|
QDF_STATUS status;
|
|
|
+ struct scan_mbssid_info mbssid_info = { 0 };
|
|
|
|
|
|
+ hdr = (struct wlan_frame_hdr *)frame;
|
|
|
bcn = (struct wlan_bcn_frame *)
|
|
|
(frame + sizeof(struct wlan_frame_hdr));
|
|
|
ie_len = (uint16_t)(frame_len -
|
|
|
sizeof(struct wlan_frame_hdr) -
|
|
|
offsetof(struct wlan_bcn_frame, ie));
|
|
|
|
|
|
+ mbssid_ie = util_scan_find_ie(WLAN_ELEMID_MULTIPLE_BSSID,
|
|
|
+ (uint8_t *)&bcn->ie, ie_len);
|
|
|
+ if (mbssid_ie) {
|
|
|
+ qdf_mem_copy(&mbssid_info.trans_bssid,
|
|
|
+ hdr->i_addr3, QDF_MAC_ADDR_SIZE);
|
|
|
+ mbssid_info.profile_count = 1 << mbssid_ie[2];
|
|
|
+ }
|
|
|
+
|
|
|
status = util_scan_gen_scan_entry(pdev, frame, frame_len,
|
|
|
frm_subtype, rx_param,
|
|
|
+ &mbssid_info,
|
|
|
scan_list);
|
|
|
|
|
|
/*
|
|
@@ -1437,8 +1458,7 @@ util_scan_parse_beacon_frame(struct wlan_objmgr_pdev *pdev,
|
|
|
* scan component will create a new entry for
|
|
|
* each BSSID found in the MBSSID
|
|
|
*/
|
|
|
- if (util_scan_find_ie(WLAN_ELEMID_MULTIPLE_BSSID,
|
|
|
- (uint8_t *)&bcn->ie, ie_len))
|
|
|
+ if (mbssid_ie)
|
|
|
status = util_scan_parse_mbssid(pdev, frame, frame_len,
|
|
|
frm_subtype, rx_param,
|
|
|
scan_list);
|