xref: /wlan-dirver/qca-wifi-host-cmn/wmi/inc/wmi_unified_dfs_api.h (revision 3149adf58a329e17232a4c0e58d460d025edd55a)
1 /*
2  * Copyright (c) 2017-2018 The Linux Foundation. All rights reserved.
3  *
4  * Permission to use, copy, modify, and/or distribute this software for
5  * any purpose with or without fee is hereby granted, provided that the
6  * above copyright notice and this permission notice appear in all
7  * copies.
8  *
9  * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL
10  * WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED
11  * WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE
12  * AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL
13  * DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR
14  * PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER
15  * TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
16  * PERFORMANCE OF THIS SOFTWARE.
17  */
18 /**
19  * DOC: This file contains the API definitions for the Unified Wireless Module
20  * Interface (WMI) which are specific to DFS module.
21  */
22 
23 #ifndef _WMI_UNIFIED_DFS_API_H_
24 #define _WMI_UNIFIED_DFS_API_H_
25 
26 #include <wlan_dfs_utils_api.h>
27 
28 /**
29  * wmi_extract_dfs_cac_complete_event() - function to handle cac complete event
30  * @handle: wma handle
31  * @event_buf: event buffer
32  * @vdev_id: vdev id
33  * @len: length of buffer
34  *
35  * Return: 0 for success or error code
36  */
37 QDF_STATUS wmi_extract_dfs_cac_complete_event(void *wmi_hdl,
38 		uint8_t *evt_buf,
39 		uint32_t *vdev_id,
40 		uint32_t len);
41 
42 /**
43  * wmi_extract_dfs_radar_detection_event() - function to handle radar event
44  * @handle: wma handle
45  * @event_buf: event buffer
46  * @radar_found: radar found event info
47  * @vdev_id: vdev id
48  * @len: length of buffer
49  *
50  * Return: 0 for success or error code
51  */
52 QDF_STATUS wmi_extract_dfs_radar_detection_event(void *wmi_hdl,
53 		uint8_t *evt_buf,
54 		struct radar_found_info *radar_found,
55 		uint32_t len);
56 
57 #ifdef QCA_MCL_DFS_SUPPORT
58 /**
59  * wmi_extract_wlan_radar_event_info() - function to handle radar pulse event.
60  * @wmi_hdl: wmi handle
61  * @evt_buf: event buffer
62  * @wlan_radar_event: pointer to radar event info structure
63  * @len: length of buffer
64  *
65  * Return: QDF_STATUS
66  */
67 QDF_STATUS wmi_extract_wlan_radar_event_info(void *wmi_hdl,
68 		uint8_t *evt_buf,
69 		struct radar_event_info *wlan_radar_event,
70 		uint32_t len);
71 #endif
72 #endif /* _WMI_UNIFIED_DFS_API_H_ */
73