diff options
| author | Mukul Sharma <mukul@qti.qualcomm.com> | 2016-04-11 21:50:44 +0530 |
|---|---|---|
| committer | Anjaneedevi Kapparapu <akappa@codeaurora.org> | 2016-04-18 12:54:47 +0530 |
| commit | c07f8f977191b6ab655aae5f04ee5b3f9c19f790 (patch) | |
| tree | 91cee69850a9658c07ea3d07d9579e450373df35 | |
| parent | 84c4ea5bc10239203e1aef2eeb4741f1bf19715c (diff) | |
qcacld-2.0: Move buckets_scanned mask for extscan get cache result
If host issues extscan get cache results, while gscan is not in
progress then buckets_scanned mask comes as zero. To handle this
issue now firmware sends the buckets_scanned mask as part of
wmi_extscan_rssi_info instead of fixed_param.
Change-Id: I5923a5fc642dd722bf6cc9f5496c7cedcf75e1a5
CRs-Fixed: 1001733
| -rw-r--r-- | CORE/HDD/src/wlan_hdd_cfg80211.c | 15 | ||||
| -rw-r--r-- | CORE/MAC/inc/sirApi.h | 4 | ||||
| -rw-r--r-- | CORE/SERVICES/WMA/wma.c | 5 |
3 files changed, 13 insertions, 11 deletions
diff --git a/CORE/HDD/src/wlan_hdd_cfg80211.c b/CORE/HDD/src/wlan_hdd_cfg80211.c index 6dfc93fdbbd8..89d93093737f 100644 --- a/CORE/HDD/src/wlan_hdd_cfg80211.c +++ b/CORE/HDD/src/wlan_hdd_cfg80211.c @@ -23091,12 +23091,12 @@ wlan_hdd_cfg80211_extscan_cached_results_ind(void *ctx, #define EXTSCAN_CACHED_NL_FIXED_TLV \ (sizeof(data->request_id) + NLA_HDRLEN) + \ (sizeof(data->num_scan_ids) + NLA_HDRLEN) + \ - (sizeof(data->buckets_scanned) + NLA_HDRLEN)+ \ (sizeof(data->more_data) + NLA_HDRLEN) #define EXTSCAN_CACHED_NL_SCAN_ID_TLV \ (sizeof(result->scan_id) + NLA_HDRLEN) + \ (sizeof(result->flags) + NLA_HDRLEN) + \ - (sizeof(result->num_results) + NLA_HDRLEN) + (sizeof(result->num_results) + NLA_HDRLEN)+ \ + (sizeof(result->buckets_scanned) + NLA_HDRLEN) #define EXTSCAN_CACHED_NL_SCAN_RESULTS_TLV \ (sizeof(ap->ts) + NLA_HDRLEN) + \ (sizeof(ap->ssid) + NLA_HDRLEN) + \ @@ -23144,14 +23144,15 @@ wlan_hdd_cfg80211_extscan_cached_results_ind(void *ctx, goto fail; } hddLog(LOG1, - FL("ReqId: %u Num_scan_ids: %u buckets_scanned: %u MoreData: %u"), + FL("ReqId: %u Num_scan_ids: %u MoreData: %u"), data->request_id, data->num_scan_ids, - data->buckets_scanned, data->more_data); + data->more_data); result = &data->result[0]; for (i = 0; i < data->num_scan_ids; i++) { - hddLog(LOG1, "[i=%d] scan_id %u flags %u num_results %u", - i, result->scan_id, result->flags, result->num_results); + hddLog(LOG1, "[i=%d] scan_id %u flags %u num_results %u buckets_scanned: %u", + i, result->scan_id, result->flags, result->num_results, + result->buckets_scanned); ap = &result->ap[0]; for (j = 0; j < result->num_results; j++) { @@ -23231,7 +23232,7 @@ wlan_hdd_cfg80211_extscan_cached_results_ind(void *ctx, result->flags) || nla_put_u32(skb, QCA_WLAN_VENDOR_ATTR_EXTSCAN_RESULTS_BUCKETS_SCANNED, - data->buckets_scanned) || + result->buckets_scanned) || nla_put_u32(skb, QCA_WLAN_VENDOR_ATTR_EXTSCAN_NUM_RESULTS_AVAILABLE, result->num_results)) { diff --git a/CORE/MAC/inc/sirApi.h b/CORE/MAC/inc/sirApi.h index 936b68ad0ef0..7bda8cfa07ce 100644 --- a/CORE/MAC/inc/sirApi.h +++ b/CORE/MAC/inc/sirApi.h @@ -5216,6 +5216,7 @@ struct extscan_hotlist_match * @scan_id: a unique identifier for the scan unit * @flags: a bitmask with additional information about scan * @num_results: number of bssids retrieved by the scan + * @buckets_scanned: bitmask of buckets scanned in current extscan cycle * @ap: wifi scan bssid results info */ struct extscan_cached_scan_result @@ -5223,6 +5224,7 @@ struct extscan_cached_scan_result uint32_t scan_id; uint32_t flags; uint32_t num_results; + uint32_t buckets_scanned; tSirWifiScanResult *ap; }; @@ -5252,7 +5254,6 @@ typedef struct * @more_data: 0 - for last fragment * 1 - still more fragment(s) coming * @num_scan_ids: number of scan ids - * @buckets_scanned: bitmask of buckets scanned in current extscan cycle * @result: wifi scan result */ struct extscan_cached_scan_results @@ -5260,7 +5261,6 @@ struct extscan_cached_scan_results uint32_t request_id; bool more_data; uint32_t num_scan_ids; - uint32_t buckets_scanned; struct extscan_cached_scan_result *result; }; diff --git a/CORE/SERVICES/WMA/wma.c b/CORE/SERVICES/WMA/wma.c index 448700e47d1a..98d21ea9466b 100644 --- a/CORE/SERVICES/WMA/wma.c +++ b/CORE/SERVICES/WMA/wma.c @@ -3924,6 +3924,7 @@ static int wma_fill_num_results_per_scan_id(const u_int8_t *cmd_param_info, t_scan_id_grp->scan_id = src_rssi->scan_cycle_id; t_scan_id_grp->flags = src_rssi->flags; + t_scan_id_grp->buckets_scanned = src_rssi->buckets_scanned; t_scan_id_grp->num_results = 1; for (i = 1; i < event->num_entries_in_page; i++) { src_rssi++; @@ -3934,6 +3935,8 @@ static int wma_fill_num_results_per_scan_id(const u_int8_t *cmd_param_info, prev_scan_id = t_scan_id_grp->scan_id = src_rssi->scan_cycle_id; t_scan_id_grp->flags = src_rssi->flags; + t_scan_id_grp->buckets_scanned = + src_rssi->buckets_scanned; t_scan_id_grp->num_results = 1; } } @@ -4004,7 +4007,6 @@ static int wma_group_num_bss_to_scan_id(const u_int8_t *cmd_param_info, ap->beaconPeriod = src_hotlist->beacon_interval; ap->capability = src_hotlist->capabilities; ap->ieLength = src_hotlist->ie_length; - /* Firmware already applied noise floor adjustment and * due to WMI interface "UINT32 rssi", host driver * receives a positive value, hence convert to @@ -4083,7 +4085,6 @@ static int wma_extscan_cached_results_event_handler(void *handle, vos_mem_zero(dest_cachelist, sizeof(*dest_cachelist)); dest_cachelist->request_id = event->request_id; dest_cachelist->more_data = moredata; - dest_cachelist->buckets_scanned = event->buckets_scanned; scan_ids_cnt = wma_extscan_find_unique_scan_ids(cmd_param_info); WMA_LOGI("scan_ids_cnt %d", scan_ids_cnt); |
