浏览代码

qcacmn: Mark spectral cache valid after writing into it

Setting of any spectral parameter after 'wifi load',
before doing a get operation, is not getting affected.
This is because the current implementation marks the
spectral cache valid only during the read operation.
To fix this, mark the cache valid after write as well.

Change-Id: I53df704e60e29cab7ce7afdd49b917e3482479e5
CRs-Fixed: 2238814
Shiva Krishna Pittala 7 年之前
父节点
当前提交
8884aeac63
共有 1 个文件被更改,包括 12 次插入0 次删除
  1. 12 0
      target_if/spectral/target_if_spectral.c

+ 12 - 0
target_if/spectral/target_if_spectral.c

@@ -790,6 +790,10 @@ target_if_spectral_info_write(
 		}
 
 		info->osps_cache.osc_spectral_active = *pval;
+
+		/* The cache is now valid */
+		info->osps_cache.osc_is_valid = 1;
+
 		qdf_spin_unlock(&info->osps_lock);
 		break;
 
@@ -816,6 +820,10 @@ target_if_spectral_info_write(
 		}
 
 		info->osps_cache.osc_spectral_enabled = *pval;
+
+		/* The cache is now valid */
+		info->osps_cache.osc_is_valid = 1;
+
 		qdf_spin_unlock(&info->osps_lock);
 		break;
 
@@ -843,6 +851,10 @@ target_if_spectral_info_write(
 
 		qdf_mem_copy(&info->osps_cache.osc_params,
 			     param, sizeof(info->osps_cache.osc_params));
+
+		/* The cache is now valid */
+		info->osps_cache.osc_is_valid = 1;
+
 		qdf_spin_unlock(&info->osps_lock);
 		break;