Linux Kernel  3.7.1
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
wm_ioctl.h
Go to the documentation of this file.
1 /*
2  * Copyright (c) 2012 GCT Semiconductor, Inc. All rights reserved.
3  *
4  * This software is licensed under the terms of the GNU General Public
5  * License version 2, as published by the Free Software Foundation, and
6  * may be copied, distributed, and modified under those terms.
7  *
8  * This program is distributed in the hope that it will be useful,
9  * but WITHOUT ANY WARRANTY; without even the implied warranty of
10  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11  * GNU General Public License for more details.
12  */
13 
14 #if !defined(WM_IOCTL_H_20080714)
15 #define WM_IOCTL_H_20080714
16 #if !defined(__KERNEL__)
17 #include <net/if.h>
18 #endif
19 
20 #define NETLINK_WIMAX 31
21 
22 #define SIOCWMIOCTL SIOCDEVPRIVATE
23 
24 #define SIOCG_DATA 0x8D10
25 #define SIOCS_DATA 0x8D11
26 
27 enum {
33 
35 };
36 
37 #define SIOC_DATA_MAX 16
38 
39 /* FSM */
40 enum {
41  M_INIT = 0,
48 
49  C_INIT = 0,
60 
61  D_INIT = 0,
65 
67 };
68 
69 struct fsm_s {
70  int m_status; /*main status*/
71  int c_status; /*connection status*/
72  int d_status; /*oma-dm status*/
73 };
74 
75 struct data_s {
76  int size;
77  void *buf;
78 };
79 
80 struct wm_req_s {
81  union {
83  } ifr_ifrn;
84 
85  unsigned short cmd;
86 
87  unsigned short data_id;
88  struct data_s data;
89 
90 /* NOTE: sizeof(struct wm_req_s) must be less than sizeof(struct ifreq). */
91 };
92 
93 #ifndef ifr_name
94 #define ifr_name ifr_ifrn.ifrn_name
95 #endif
96 
97 #endif