diff options
author | Swarn Singh <swarnkum@codeaurora.org> | 2021-06-28 15:20:42 +0530 |
---|---|---|
committer | Swarn Singh <swarnkum@codeaurora.org> | 2021-06-29 00:04:20 +0530 |
commit | e7965fa3f8d90db031eb0a49278438be9f73df28 (patch) | |
tree | 181a4a151c14ca4ba686a1312b9582ffb7ce3d9f | |
parent | 123e3581b33bf45f3c3c8ad36b492926eeed478c (diff) |
Remove limit on max duration of CSI capture
Remove the limit (900 seconds) on maximum duration of CSI capture.
Also don't stop the CSI capture if the duration configured by user is
zero, in this case the user is expected to stop CSI capture explicitly.
Change-Id: Idf7cc4c58390570c3ce155e3b2139b358acb7cd7
CRs-Fixed: 2979224
-rw-r--r-- | qcwcn/wpa_supplicant_8_lib/driver_cmd_nl80211.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/qcwcn/wpa_supplicant_8_lib/driver_cmd_nl80211.c b/qcwcn/wpa_supplicant_8_lib/driver_cmd_nl80211.c index b06b84d..64cdc17 100644 --- a/qcwcn/wpa_supplicant_8_lib/driver_cmd_nl80211.c +++ b/qcwcn/wpa_supplicant_8_lib/driver_cmd_nl80211.c @@ -42,7 +42,6 @@ #define CSI_STATUS_REJECTED -1 #define ENHANCED_CFR_VER 2 #define CSI_GROUP_BITMAP 1 -#define MAX_CSI_DURATION 900 /* second */ #define CSI_DEFAULT_GROUP_ID 0 #define CSI_FC_STYPE_BEACON 8 #define CSI_MGMT_BEACON (1<<WLAN_FC_STYPE_BEACON) @@ -2235,7 +2234,7 @@ static int wpa_driver_handle_csi_cmd(struct i802_bss *bss, char *cmd, next_arg = get_next_arg(cmd); csi_duration = atoi(next_arg); - if (csi_duration <= 0 || csi_duration > MAX_CSI_DURATION) { + if (csi_duration < 0) { wpa_printf(MSG_ERROR, "Invalid duration"); snprintf(buf, buf_len, "FAIL, Invalid duration"); *status = CSI_STATUS_REJECTED; @@ -2266,7 +2265,7 @@ static int wpa_driver_handle_csi_cmd(struct i802_bss *bss, char *cmd, else if (transport_mode == 0) transport_mode = 0; wpa_driver_start_csi_capture(bss, cmd, buf, buf_len, status, transport_mode); - if (*status == 0) { + if (*status == 0 && csi_duration > 0) { signal(SIGALRM, stop_csi_callback); alarm(csi_duration); wpa_printf(MSG_DEBUG, "set alarm %ds done", csi_duration); |