summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKiran Kumar Lokere <klokere@codeaurora.org>2017-02-02 18:08:44 -0800
committerqcabuildsw <qcabuildsw@localhost>2017-02-06 23:04:22 -0800
commit79f73eceb9f0f5b4847f6ddf25d5577e1eaffe7b (patch)
tree8ea5b406cd4938499442ebe9bb28f7e33b232ef1
parentdb28ffd6fd984c78432920b93cf3a1083208b7b1 (diff)
qcacld-3.0: Do not disable Qpower in suspend mode
Do not disable the Qpower in suspend mode. Change-Id: I904f1ea4877482eff90599aa2d8f2fb676db0869 CRs-Fixed: 2002833
-rw-r--r--core/wma/inc/wma.h4
-rw-r--r--core/wma/src/wma_power.c48
2 files changed, 5 insertions, 47 deletions
diff --git a/core/wma/inc/wma.h b/core/wma/inc/wma.h
index 107ec7fae285..53a9c2ccbf8a 100644
--- a/core/wma/inc/wma.h
+++ b/core/wma/inc/wma.h
@@ -1001,7 +1001,7 @@ typedef struct {
* @nwType: network type (802.11a/b/g/n/ac)
* @staKeyParams: sta key parameters
* @ps_enabled: is powersave enable/disable
- * @dtim_policy: DTIM policy
+ * @restore_dtim_setting: DTIM settings restore flag
* @peer_count: peer count
* @roam_synch_in_progress: flag is in progress or not
* @plink_status_req: link status request
@@ -1070,7 +1070,7 @@ struct wma_txrx_node {
int8_t max_tx_power;
uint32_t nwType;
void *staKeyParams;
- uint32_t dtim_policy;
+ bool restore_dtim_setting;
uint32_t peer_count;
bool roam_synch_in_progress;
void *plink_status_req;
diff --git a/core/wma/src/wma_power.c b/core/wma/src/wma_power.c
index 8e263dc96af5..b422ee044837 100644
--- a/core/wma/src/wma_power.c
+++ b/core/wma/src/wma_power.c
@@ -1741,7 +1741,6 @@ QDF_STATUS wma_set_smps_params(tp_wma_handle wma, uint8_t vdev_id,
static void wma_set_vdev_suspend_dtim(tp_wma_handle wma, uint8_t vdev_id)
{
struct wma_txrx_node *iface = &wma->interfaces[vdev_id];
- enum powersave_qpower_mode qpower_config = wma_get_qpower_config(wma);
if ((iface->type == WMI_VDEV_TYPE_STA) &&
(iface->dtimPeriod != 0)) {
@@ -1799,16 +1798,6 @@ static void wma_set_vdev_suspend_dtim(tp_wma_handle wma, uint8_t vdev_id)
WMA_LOGD("Set Listen Interval vdevId %d Listen Intv %d",
vdev_id, listen_interval);
- if (qpower_config) {
- WMA_LOGD("disable Qpower in suspend mode!");
- ret = wma_unified_set_sta_ps_param(wma->wmi_handle,
- vdev_id,
- WMI_STA_PS_ENABLE_QPOWER,
- 0);
- if (QDF_IS_STATUS_ERROR(ret))
- WMA_LOGE("Failed to disable Qpower in suspend mode!");
- }
-
/*
* Set inactivity time to 50ms when DUT is in WoW mode.
* It will be recovered to the cfg value when DUT resumes.
@@ -1833,17 +1822,7 @@ static void wma_set_vdev_suspend_dtim(tp_wma_handle wma, uint8_t vdev_id)
if (ret)
WMA_LOGE("%s: Setting TxWake Threshold Failed.",
__func__);
-
- ret = wma_vdev_set_param(wma->wmi_handle, vdev_id,
- WMI_VDEV_PARAM_DTIM_POLICY,
- NORMAL_DTIM);
- if (QDF_IS_STATUS_ERROR(ret))
- WMA_LOGE("Failed to Set to Normal DTIM vdevId %d",
- vdev_id);
-
- /* Set it to Normal DTIM */
- iface->dtim_policy = NORMAL_DTIM;
- WMA_LOGD("Set DTIM Policy to Normal Dtim vdevId %d", vdev_id);
+ iface->restore_dtim_setting = true;
}
}
@@ -1880,11 +1859,10 @@ void wma_set_suspend_dtim(tp_wma_handle wma)
static void wma_set_vdev_resume_dtim(tp_wma_handle wma, uint8_t vdev_id)
{
struct wma_txrx_node *iface = &wma->interfaces[vdev_id];
- enum powersave_qpower_mode qpower_config = wma_get_qpower_config(wma);
u_int32_t inactivity_time;
if ((iface->type == WMI_VDEV_TYPE_STA) &&
- (iface->dtim_policy == NORMAL_DTIM)) {
+ (iface->restore_dtim_setting)) {
QDF_STATUS ret;
uint32_t cfg_data_val = 0;
/* get mac to acess CFG data base */
@@ -1913,27 +1891,6 @@ static void wma_set_vdev_resume_dtim(tp_wma_handle wma, uint8_t vdev_id)
WMA_LOGD("Set Listen Interval vdevId %d Listen Intv %d",
vdev_id, cfg_data_val);
- ret = wma_vdev_set_param(wma->wmi_handle, vdev_id,
- WMI_VDEV_PARAM_DTIM_POLICY,
- STICK_DTIM);
- if (QDF_IS_STATUS_ERROR(ret)) {
- /* Set it back to Stick DTIM */
- WMA_LOGE("Failed to Set to Stick DTIM vdevId %d",
- vdev_id);
- }
- iface->dtim_policy = STICK_DTIM;
- WMA_LOGD("Set DTIM Policy to Stick Dtim vdevId %d", vdev_id);
-
- if (qpower_config) {
- WMA_LOGD("enable Qpower in resume mode!");
- ret = wma_unified_set_sta_ps_param(wma->wmi_handle,
- vdev_id,
- WMI_STA_PS_ENABLE_QPOWER,
- qpower_config);
- if (QDF_IS_STATUS_ERROR(ret))
- WMA_LOGE("Failed to enable Qpower in resume mode!");
- }
-
if (wlan_cfg_get_int(mac, WNI_CFG_PS_DATA_INACTIVITY_TIMEOUT,
&cfg_data_val) != eSIR_SUCCESS) {
QDF_TRACE(QDF_MODULE_ID_WMA, QDF_TRACE_LEVEL_ERROR,
@@ -1941,6 +1898,7 @@ static void wma_set_vdev_resume_dtim(tp_wma_handle wma, uint8_t vdev_id)
cfg_data_val = POWERSAVE_DEFAULT_INACTIVITY_TIME;
}
+ iface->restore_dtim_setting = false;
inactivity_time = (u_int32_t)cfg_data_val;
WMA_LOGD("%s: Setting InActivity time %d.", __func__,
inactivity_time);