diff options
| -rw-r--r-- | CORE/HDD/src/wlan_hdd_dp_utils.c | 19 |
1 files changed, 11 insertions, 8 deletions
diff --git a/CORE/HDD/src/wlan_hdd_dp_utils.c b/CORE/HDD/src/wlan_hdd_dp_utils.c index 30d53b9213c4..69bc4c7283af 100644 --- a/CORE/HDD/src/wlan_hdd_dp_utils.c +++ b/CORE/HDD/src/wlan_hdd_dp_utils.c @@ -235,9 +235,14 @@ void hdd_dp_util_send_rps_ind(hdd_adapter_t *adapter) { int i = 0; uint8_t cpu_map_list_len = 0; - hdd_context_t *hdd_ctxt = WLAN_HDD_GET_CTX(adapter); + hdd_context_t *hdd_ctxt; struct wlan_rps_data rps_data; + if (NULL == adapter) + return; + + hdd_ctxt = WLAN_HDD_GET_CTX(adapter); + rps_data.num_queues = NUM_TX_QUEUES; hddLog(LOG1, FL("cpu_map_list '%s'"), hdd_ctxt->cfg_ini->cpu_map_list); @@ -265,13 +270,11 @@ void hdd_dp_util_send_rps_ind(hdd_adapter_t *adapter) i, rps_data.cpu_map_list[i]); } - if (NULL != adapter) { - strlcpy(rps_data.ifname, adapter->dev->name, - sizeof(rps_data.ifname)); - wlan_hdd_send_svc_nlink_msg(hdd_ctxt->radio_index, - WLAN_SVC_RPS_ENABLE_IND, - &rps_data, sizeof(rps_data)); - } + strlcpy(rps_data.ifname, adapter->dev->name, + sizeof(rps_data.ifname)); + wlan_hdd_send_svc_nlink_msg(hdd_ctxt->radio_index, + WLAN_SVC_RPS_ENABLE_IND, + &rps_data, sizeof(rps_data)); } #endif /* QCA_FEATURE_RPS */ |
