From e3b05ae8aeb8f30a3746d31415f173d7478ec706 Mon Sep 17 00:00:00 2001 From: Edayilliam Jayadev Date: Mon, 15 Jun 2020 17:09:18 +0530 Subject: [PATCH] qcacmn: Initialize start scan related parameters before sending WMI command Host maintains a flag variable for ensuring that the start scan response WMI event is received from FW before the spectral reports. Following are the expected sequence of operations. 1) is_resp_event_received = false 2) start scan WMI command 3) start scan response WMI event (is_resp_event_received is set to true here) Current sequence of operations are the following. a) start scan WMI command b) is_event_received = false If the start scan response WMI event is received in between a) and b) there is a possibility that the flag is_resp_event_received is overwritten to false by b). This can lead to an assert during the spectral report processing. CRs-Fixed: 2708320 Change-Id: I18020bf866b9cb3a3cc64df56398d751c91dd2f2 --- target_if/spectral/target_if_spectral.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/target_if/spectral/target_if_spectral.c b/target_if/spectral/target_if_spectral.c index ce1cd622ca2d..367aeef7ad4e 100644 --- a/target_if/spectral/target_if_spectral.c +++ b/target_if/spectral/target_if_spectral.c @@ -3869,10 +3869,10 @@ target_if_spectral_scan_enable_params(struct target_if_spectral *spectral, if (!p_sops->is_spectral_active(spectral, smode)) { p_sops->configure_spectral(spectral, spectral_params, smode); + spectral->rparams.marker[smode].is_valid = false; p_sops->start_spectral_scan(spectral, smode, err); spectral->timestamp_war.timestamp_war_offset[smode] = 0; spectral->timestamp_war.last_fft_timestamp[smode] = 0; - spectral->rparams.marker[smode].is_valid = false; } /* get current spectral configuration */