1 /* 2 * Copyright (c) 2020-2021, The Linux Foundation. All rights reserved. 3 * 4 * Permission to use, copy, modify, and/or distribute this software for any 5 * purpose with or without fee is hereby granted, provided that the above 6 * copyright notice and this permission notice appear in all copies. 7 * 8 * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES 9 * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF 10 * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR 11 * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES 12 * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN 13 * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF 14 * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. 15 */ 16 17 /** 18 * DOC: This file contains the API definitions for the Unified Wireless Module 19 * Interface (WMI) which are specific to DFS module. 20 */ 21 22 #ifndef _WMI_UNIFIED_DCS_API_H_ 23 #define _WMI_UNIFIED_DCS_API_H_ 24 25 #include <qdf_status.h> 26 #include <wmi_unified_api.h> 27 #include <wmi_unified_priv.h> 28 #include <wlan_objmgr_vdev_obj.h> 29 30 /** 31 * wmi_extract_dcs_interference_type() - extract dcs interference type 32 * @wmi_handle: wmi handle 33 * @evt_buf: pointer to event buffer 34 * @param: Pointer to hold dcs interference param 35 * 36 * This function gets called to extract dcs interference type from dcs FW event 37 * 38 * Return: QDF_STATUS_SUCCESS on success and QDF_STATUS_E_FAILURE for failure 39 */ 40 QDF_STATUS wmi_extract_dcs_interference_type( 41 void *wmi_hdl, 42 void *evt_buf, 43 struct wlan_host_dcs_interference_param *param); 44 45 /** 46 * wmi_extract_dcs_im_tgt_stats() - extract dcs im target stats 47 * @wmi_handle: wmi handle 48 * @evt_buf: pointer to event buffer 49 * @wlan_stat: Pointer to hold wlan stats 50 * 51 * This function gets called to extract dcs im target stats from event 52 * 53 * Return: QDF_STATUS_SUCCESS on success and QDF_STATUS_E_FAILURE for failure 54 */ 55 QDF_STATUS wmi_extract_dcs_im_tgt_stats( 56 void *wmi_hdl, 57 void *evt_buf, 58 struct wlan_host_dcs_im_tgt_stats *wlan_stat); 59 60 /* 61 * wmi_extract_dcs_awgn_info() - extract DCS AWGN interference info from event 62 * @wmi_handle: WMI handle 63 * @evt_buf: Pointer to event buffer 64 * @awgn_info: Pointer to hold AWGN interference info 65 * 66 * Return: QDF_STATUS_SUCCESS on success and QDF_STATUS_E_FAILURE for failure 67 */ 68 QDF_STATUS 69 wmi_extract_dcs_awgn_info(wmi_unified_t wmi_hdl, void *evt_buf, 70 struct wlan_host_dcs_awgn_info *awgn_info); 71 72 /** 73 * wmi_send_dcs_pdev_param() - send dcs pdev param 74 * @wmi_handle: wmi handle 75 * @pdev_idx: pdev id 76 * @is_host_pdev_id: host pdev_id or not 77 * @dcs_enable: value of dcs enable 78 * 79 * This functions gets called to send dcs pdev param 80 * 81 * Return: QDF_STATUS 82 */ 83 QDF_STATUS wmi_send_dcs_pdev_param(wmi_unified_t wmi_handle, 84 uint32_t pdev_idx, 85 bool is_host_pdev_id, 86 uint32_t dcs_enable); 87 #endif /* _WMI_UNIFIED_DCS_API_H_ */ 88