-
Notifications
You must be signed in to change notification settings - Fork 152
RDKBWIFI-386: Channel Scan Report - BSS Load element is wrong #989
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: develop
Are you sure you want to change the base?
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -33,6 +33,8 @@ | |
| #define EM_NEIGBOUR_SCAN_PROVIDER_DELAY_SEC 5 // 5 Seconds | ||
| #define EM_NEIGBOUR_SCAN_INTERVAL_MSEC 60000 // 60 Seconds | ||
| #define EM_DEF_LINK_METRICS_COLLECT_INTERVAL_MSEC 10000 // 10 Seconds | ||
| #define EM_BSS_COLOR_DEFAULT 0x3F | ||
| #define EM_SCAN_TYPE_ACTIVE 1 | ||
|
|
||
| static bool is_monitor_done = false; | ||
|
|
||
|
|
@@ -645,6 +647,7 @@ static int em_prepare_scan_response_data(wifi_provider_response_t *provider_resp | |
| wifi_neighbor_ap2_t *wifi_scan_data = NULL; | ||
| radio_interface_mapping_t *radio_iface_map = NULL; | ||
| char time_str[32] = { 0 }; | ||
| int dwell_time = provider_response->args.dwell_time; | ||
|
|
||
| wifi_mgr_t *wifi_mgr = get_wifimgr_obj(); | ||
| wifi_platform_property_t *wifi_prop = &wifi_mgr->hal_cap.wifi_prop; | ||
|
|
@@ -744,17 +747,32 @@ static int em_prepare_scan_response_data(wifi_provider_response_t *provider_resp | |
| neighbor->signal_strength = src->ap_SignalStrength; | ||
| strncpy(neighbor->channel_bandwidth, src->ap_OperatingChannelBandwidth, | ||
| EM_MAX_CHANNEL_BW_LEN); | ||
| neighbor->channel_utilization = src->ap_ChannelUtilization; | ||
| neighbor->bss_load_element_present = 0; | ||
| neighbor->bss_color = 0; | ||
| neighbor->bss_color = EM_BSS_COLOR_DEFAULT; | ||
| neighbor->bss_load_element_present = 0; | ||
|
|
||
| /* Initialize to defaults to avoid stale/uninitialized data */ | ||
| neighbor->channel_utilization = 0; | ||
| neighbor->station_count = 0; | ||
|
Comment on lines
+750
to
755
|
||
|
|
||
| /* | ||
| * Populate channel utilization, Station count | ||
| * only if the bss load element is present. | ||
| */ | ||
Sangeetha-selvaraj18 marked this conversation as resolved.
Show resolved
Hide resolved
|
||
| if (src->bss_load_element_present) { | ||
| neighbor->bss_load_element_present = src->bss_load_element_present; | ||
| neighbor->channel_utilization = src->ap_ChannelUtilization; | ||
| neighbor->station_count = src->ap_StaCount; | ||
Sangeetha-selvaraj18 marked this conversation as resolved.
Show resolved
Hide resolved
|
||
| } | ||
Sangeetha-selvaraj18 marked this conversation as resolved.
Show resolved
Hide resolved
|
||
| res->num_neighbors++; | ||
| wifi_util_dbg_print(WIFI_EM, "%s:%d BSSID: %s SSID: %s\n", __func__, __LINE__, | ||
| src->ap_BSSID, src->ap_SSID); | ||
| wifi_util_dbg_print(WIFI_EM, "bss_color 0x%x ch_util %d bss_element_presnt %d sta_cnt %d for BSSID: %s SSID: %s\n", | ||
Sangeetha-selvaraj18 marked this conversation as resolved.
Show resolved
Hide resolved
|
||
| neighbor->bss_color, neighbor->channel_utilization, neighbor->bss_load_element_present, | ||
| neighbor->station_count, src->ap_BSSID, src->ap_SSID); | ||
| } else { | ||
| wifi_util_error_print(WIFI_EM, "%s:%d : Maximum number of neighbors reached.\n", | ||
| __func__, __LINE__); | ||
| } | ||
| res->aggregate_scan_duration = dwell_time; | ||
| res->scan_type = EM_SCAN_TYPE_ACTIVE; | ||
| } | ||
| wifi_util_dbg_print(WIFI_EM, "%s:%d Scan results updated for radio mac : %s\n", __func__, | ||
| __LINE__, to_mac_str(radio_mac, mac_str)); | ||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -1060,6 +1060,8 @@ int execute_radio_channel_api(wifi_mon_collector_element_t *c_elem, wifi_monitor | |
| } | ||
| } | ||
|
|
||
| args->dwell_time = dwell_time; | ||
|
|
||
|
Comment on lines
+1063
to
+1064
|
||
| int buffer_size = sizeof(char) * num_channels * 5; | ||
| channel_buff = (char *)malloc(buffer_size); | ||
| if (channel_buff != NULL) { | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Address indentation