xref: /OK3568_Linux_fs/kernel/drivers/net/wireless/nxp/mlinux/moal_wext.h (revision 4882a59341e53eb6f0b4789bf948001014eff981)
1 /** @file moal_wext.h
2  *
3  * @brief This file contains definition for wireless extension IOCTL call.
4  *
5  *
6  * Copyright 2008-2021 NXP
7  *
8  * This software file (the File) is distributed by NXP
9  * under the terms of the GNU General Public License Version 2, June 1991
10  * (the License).  You may use, redistribute and/or modify the File in
11  * accordance with the terms and conditions of the License, a copy of which
12  * is available by writing to the Free Software Foundation, Inc.,
13  * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA or on the
14  * worldwide web at http://www.gnu.org/licenses/old-licenses/gpl-2.0.txt.
15  *
16  * THE FILE IS DISTRIBUTED AS-IS, WITHOUT WARRANTY OF ANY KIND, AND THE
17  * IMPLIED WARRANTIES OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE
18  * ARE EXPRESSLY DISCLAIMED.  The License provides additional details about
19  * this warranty disclaimer.
20  *
21  */
22 
23 /********************************************************
24 Change log:
25     10/21/2008: initial version
26 ********************************************************/
27 
28 #ifndef _WOAL_WEXT_H_
29 #define _WOAL_WEXT_H_
30 
31 /** NF value for default scan */
32 #define MRVDRV_NF_DEFAULT_SCAN_VALUE (-96)
33 
34 #if LINUX_VERSION_CODE >= KERNEL_VERSION(2, 6, 27)
35 /** Add event */
36 #define IWE_STREAM_ADD_EVENT(i, c, e, w, l)                                    \
37 	iwe_stream_add_event((i), (c), (e), (w), (l))
38 /** Add point */
39 #define IWE_STREAM_ADD_POINT(i, c, e, w, p)                                    \
40 	iwe_stream_add_point((i), (c), (e), (w), (p))
41 /** Add value */
42 #define IWE_STREAM_ADD_VALUE(i, c, v, e, w, l)                                 \
43 	iwe_stream_add_value((i), (c), (v), (e), (w), (l))
44 #else
45 /** Add event */
46 #define IWE_STREAM_ADD_EVENT(i, c, e, w, l)                                    \
47 	iwe_stream_add_event((c), (e), (w), (l))
48 /** Add point */
49 #define IWE_STREAM_ADD_POINT(i, c, e, w, p)                                    \
50 	iwe_stream_add_point((c), (e), (w), (p))
51 /** Add value */
52 #define IWE_STREAM_ADD_VALUE(i, c, v, e, w, l)                                 \
53 	iwe_stream_add_value((c), (v), (e), (w), (l))
54 #endif
55 
56 extern struct iw_handler_def woal_handler_def;
57 struct iw_statistics *woal_get_wireless_stats(struct net_device *dev);
58 #endif /* _WOAL_WEXT_H_ */
59