xref: /wlan-dirver/qca-wifi-host-cmn/wmi/src/wmi_unified_concurrency_api.c (revision 11f5a63a6cbdda84849a730de22f0a71e635d58c)
1 /*
2  * Copyright (c) 2013-2019 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: Implement API's specific to concurrency component.
20  */
21 
22 #include <wmi_unified_priv.h>
23 #include <wmi_unified_concurrency_api.h>
24 
25 QDF_STATUS wmi_unified_set_enable_disable_mcc_adaptive_scheduler_cmd(
26 		wmi_unified_t wmi_handle, uint32_t mcc_adaptive_scheduler,
27 		uint32_t pdev_id)
28 {
29 	if (wmi_handle->ops->send_set_enable_disable_mcc_adaptive_scheduler_cmd)
30 		return wmi_handle->ops->send_set_enable_disable_mcc_adaptive_scheduler_cmd(wmi_handle,
31 					mcc_adaptive_scheduler, pdev_id);
32 
33 	return QDF_STATUS_E_FAILURE;
34 }
35 
36 QDF_STATUS wmi_unified_set_mcc_channel_time_latency_cmd(
37 	wmi_unified_t wmi_handle,
38 	uint32_t mcc_channel_freq, uint32_t mcc_channel_time_latency)
39 {
40 	if (wmi_handle->ops->send_set_mcc_channel_time_latency_cmd)
41 		return wmi_handle->ops->send_set_mcc_channel_time_latency_cmd(wmi_handle,
42 					mcc_channel_freq,
43 					mcc_channel_time_latency);
44 
45 	return QDF_STATUS_E_FAILURE;
46 }
47 
48 QDF_STATUS wmi_unified_set_mcc_channel_time_quota_cmd(
49 		wmi_unified_t wmi_handle,
50 		uint32_t adapter_1_chan_freq,
51 		uint32_t adapter_1_quota, uint32_t adapter_2_chan_freq)
52 {
53 	if (wmi_handle->ops->send_set_mcc_channel_time_quota_cmd)
54 		return wmi_handle->ops->send_set_mcc_channel_time_quota_cmd(wmi_handle,
55 						adapter_1_chan_freq,
56 						adapter_1_quota,
57 						adapter_2_chan_freq);
58 
59 	return QDF_STATUS_E_FAILURE;
60 }
61 
62