xref: /wlan-driver/qca-wifi-host-cmn/wmi/inc/wmi_unified_cfr_api.h (revision 5113495b16420b49004c444715d2daae2066e7dc)
1*5113495bSYour Name /*
2*5113495bSYour Name  * Copyright (c) 2019, 2021 The Linux Foundation. All rights reserved.
3*5113495bSYour Name  * Copyright (c) 2023 Qualcomm Innovation Center, Inc. All rights reserved.
4*5113495bSYour Name  *
5*5113495bSYour Name  * Permission to use, copy, modify, and/or distribute this software for any
6*5113495bSYour Name  * purpose with or without fee is hereby granted, provided that the above
7*5113495bSYour Name  * copyright notice and this permission notice appear in all copies.
8*5113495bSYour Name  *
9*5113495bSYour Name  * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
10*5113495bSYour Name  * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
11*5113495bSYour Name  * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
12*5113495bSYour Name  * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
13*5113495bSYour Name  * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
14*5113495bSYour Name  * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
15*5113495bSYour Name  * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
16*5113495bSYour Name  */
17*5113495bSYour Name 
18*5113495bSYour Name #ifndef _WMI_UNIFIED_CFR_API_H_
19*5113495bSYour Name #define _WMI_UNIFIED_CFR_API_H_
20*5113495bSYour Name 
21*5113495bSYour Name #include "wmi_unified_param.h"
22*5113495bSYour Name #include "wmi_unified_cfr_param.h"
23*5113495bSYour Name 
24*5113495bSYour Name #ifdef WLAN_CFR_ENABLE
25*5113495bSYour Name /**
26*5113495bSYour Name  * wmi_unified_send_peer_cfr_capture_cmd() - WMI function to start CFR capture
27*5113495bSYour Name  * for a peer
28*5113495bSYour Name  * @wmi_handle: WMI handle
29*5113495bSYour Name  * @param: configuration params for capture
30*5113495bSYour Name  *
31*5113495bSYour Name  * Return: QDF_STATUS_SUCCESS if success, else returns proper error code.
32*5113495bSYour Name  */
33*5113495bSYour Name QDF_STATUS
34*5113495bSYour Name wmi_unified_send_peer_cfr_capture_cmd(wmi_unified_t wmi_handle,
35*5113495bSYour Name 				      struct peer_cfr_params *param);
36*5113495bSYour Name /**
37*5113495bSYour Name  * wmi_extract_cfr_peer_tx_event_param() - WMI function to extract cfr tx event
38*5113495bSYour Name  * for a peer
39*5113495bSYour Name  * @wmi_handle: WMI handle
40*5113495bSYour Name  * @evt_buf: Buffer holding event data
41*5113495bSYour Name  * @peer_tx_event: pointer to hold tx event data
42*5113495bSYour Name  *
43*5113495bSYour Name  * Return: QDF_STATUS_SUCCESS if success, else returns proper error code.
44*5113495bSYour Name  */
45*5113495bSYour Name QDF_STATUS
46*5113495bSYour Name wmi_extract_cfr_peer_tx_event_param(wmi_unified_t wmi_handle, void *evt_buf,
47*5113495bSYour Name 				    wmi_cfr_peer_tx_event_param *peer_tx_event);
48*5113495bSYour Name 
49*5113495bSYour Name #ifdef WLAN_ENH_CFR_ENABLE
50*5113495bSYour Name /**
51*5113495bSYour Name  * wmi_unified_send_cfr_rcc_cmd() - WMI function to send CFR RCC param
52*5113495bSYour Name  * @wmi_handle: WMI handle
53*5113495bSYour Name  * @cfg: pointer to RCC param
54*5113495bSYour Name  *
55*5113495bSYour Name  * Return: QDF_STATUS_SUCCESS if success, else returns proper error code.
56*5113495bSYour Name  */
57*5113495bSYour Name QDF_STATUS wmi_unified_send_cfr_rcc_cmd(wmi_unified_t wmi_handle,
58*5113495bSYour Name 					struct cfr_rcc_param *cfg);
59*5113495bSYour Name 
60*5113495bSYour Name /**
61*5113495bSYour Name  * wmi_extract_cfr_pdev_phase_delta_event() - WMI function to extract the
62*5113495bSYour Name  * phase delta information.
63*5113495bSYour Name  * @wmi_handle: WMI handle
64*5113495bSYour Name  * @evt_buf: Buffer holding the event data
65*5113495bSYour Name  * @param: phase delta params to be updated from event
66*5113495bSYour Name  *
67*5113495bSYour Name  * Return: QDF_STATUS_SUCCESS if success, else returns proper error code.
68*5113495bSYour Name  */
69*5113495bSYour Name QDF_STATUS
70*5113495bSYour Name wmi_extract_cfr_pdev_phase_delta_event(wmi_unified_t wmi_handle,
71*5113495bSYour Name 				       void *evt_buf,
72*5113495bSYour Name 				       struct wmi_cfr_phase_delta_param *param);
73*5113495bSYour Name 
74*5113495bSYour Name #ifdef WLAN_RCC_ENHANCED_AOA_SUPPORT
75*5113495bSYour Name QDF_STATUS
76*5113495bSYour Name wmi_extract_cfr_pdev_enhanced_aoa_phasedelta_event_fixed_param
77*5113495bSYour Name 	(wmi_unified_t wmi_handle, void *evt_buf,
78*5113495bSYour Name 	 struct wmi_cfr_enh_phase_delta_param *param);
79*5113495bSYour Name 
80*5113495bSYour Name QDF_STATUS
81*5113495bSYour Name wmi_extract_cfr_pdev_enhanced_aoa_phasedelta_event_data
82*5113495bSYour Name 	(wmi_unified_t wmi_handle, void *evt_buf,
83*5113495bSYour Name 	 struct wmi_cfr_enh_phase_delta_param *param);
84*5113495bSYour Name #endif /* WLAN_RCC_ENHANCED_AOA_SUPPORT */
85*5113495bSYour Name #endif
86*5113495bSYour Name #endif /* WLAN_CFR_ENABLE */
87*5113495bSYour Name #endif /* _WMI_UNIFIED_CFR_API_H_ */
88