xref: /wlan-driver/qca-wifi-host-cmn/ftm/dispatcher/inc/wlan_ftm_init_deinit_api.h (revision 5113495b16420b49004c444715d2daae2066e7dc)
1 /*
2  * Copyright (c) 2018 The Linux Foundation. All rights reserved.
3  *
4  *
5  * Permission to use, copy, modify, and/or distribute this software for
6  * any purpose with or without fee is hereby granted, provided that the
7  * above copyright notice and this permission notice appear in all
8  * copies.
9  *
10  * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL
11  * WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED
12  * WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE
13  * AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL
14  * DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR
15  * PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER
16  * TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
17  * PERFORMANCE OF THIS SOFTWARE.
18  */
19 
20 /**
21  * DOC: declare the ftm service data structure and apis
22  */
23 #ifndef _WLAN_FTM_UCFG_API_H_
24 #define _WLAN_FTM_UCFG_API_H_
25 
26 #include <qdf_types.h>
27 #include <qdf_status.h>
28 #include <wlan_objmgr_cmn.h>
29 
30 #ifdef QCA_WIFI_FTM
31 /**
32  * dispatcher_ftm_init() - FTM testmode initialization API
33  *
34  * Return: QDF_STATUS_SUCCESS on success, QDF_STATUS_E_** on error
35  */
36 QDF_STATUS dispatcher_ftm_init(void);
37 
38 /**
39  * dispatcher_ftm_deinit() - FTM testmode deinitialization API
40  *
41  * Return: QDF_STATUS_SUCCESS on success, QDF_STATUS_E_** on error
42  */
43 QDF_STATUS dispatcher_ftm_deinit(void);
44 
45 /**
46  * dispatcher_ftm_psoc_open() - FTM module open API
47  * @psoc: psoc object
48  *
49  * Return: QDF_STATUS_SUCCESS on success, QDF_STATUS_E_** on error
50  */
51 QDF_STATUS dispatcher_ftm_psoc_open(struct wlan_objmgr_psoc *psoc);
52 
53 /**
54  * dispatcher_ftm_psoc_close() - FTM module close API
55  * @psoc: psoc object
56  *
57  * Return: QDF_STATUS_SUCCESS on success, QDF_STATUS_E_** on error
58  */
59 QDF_STATUS dispatcher_ftm_psoc_close(struct wlan_objmgr_psoc *psoc);
60 
61 #else
dispatcher_ftm_init(void)62 static inline QDF_STATUS dispatcher_ftm_init(void)
63 {
64 	return QDF_STATUS_SUCCESS;
65 }
66 
dispatcher_ftm_deinit(void)67 static inline QDF_STATUS dispatcher_ftm_deinit(void)
68 {
69 	return QDF_STATUS_SUCCESS;
70 }
71 
72 static inline QDF_STATUS
dispatcher_ftm_psoc_open(struct wlan_objmgr_psoc * psoc)73 dispatcher_ftm_psoc_open(struct wlan_objmgr_psoc *psoc)
74 {
75 	return QDF_STATUS_SUCCESS;
76 }
77 
78 static inline QDF_STATUS
dispatcher_ftm_psoc_close(struct wlan_objmgr_psoc * psoc)79 dispatcher_ftm_psoc_close(struct wlan_objmgr_psoc *psoc)
80 {
81 	return QDF_STATUS_SUCCESS;
82 }
83 #endif
84 #endif /* _WLAN_FTM_UCFG_API_H_ */
85