PageRenderTime 86ms CodeModel.GetById 28ms RepoModel.GetById 1ms app.codeStats 0ms

/drivers/net/wireless/bcmdhd_4334/include/proto/bcmevent.h

https://bitbucket.org/zarboz/ville-dlx-merger
C Header | 355 lines | 267 code | 58 blank | 30 comment | 0 complexity | 5f19cd65002e3874b608cae510cb372b MD5 | raw file
Possible License(s): GPL-2.0, LGPL-2.0, AGPL-1.0
  1. /*
  2. * Broadcom Event protocol definitions
  3. *
  4. * Copyright (C) 1999-2012, Broadcom Corporation
  5. *
  6. * Unless you and Broadcom execute a separate written software license
  7. * agreement governing use of this software, this software is licensed to you
  8. * under the terms of the GNU General Public License version 2 (the "GPL"),
  9. * available at http://www.broadcom.com/licenses/GPLv2.php, with the
  10. * following added to such license:
  11. *
  12. * As a special exception, the copyright holders of this software give you
  13. * permission to link this software with independent modules, and to copy and
  14. * distribute the resulting executable under terms of your choice, provided that
  15. * you also meet, for each linked independent module, the terms and conditions of
  16. * the license of that module. An independent module is a module which is not
  17. * derived from this software. The special exception does not apply to any
  18. * modifications of the software.
  19. *
  20. * Notwithstanding the above, under no circumstances may you combine this
  21. * software in any way with any other Broadcom software provided under a license
  22. * other than the GPL, without Broadcom's express prior written consent.
  23. *
  24. * Dependencies: proto/bcmeth.h
  25. *
  26. * $Id: bcmevent.h 326276 2012-04-06 23:16:42Z $
  27. *
  28. */
  29. #ifndef _BCMEVENT_H_
  30. #define _BCMEVENT_H_
  31. #ifndef _TYPEDEFS_H_
  32. #include <typedefs.h>
  33. #endif
  34. #include <packed_section_start.h>
  35. #define BCM_EVENT_MSG_VERSION 2
  36. #define BCM_MSG_IFNAME_MAX 16
  37. #define WLC_EVENT_MSG_LINK 0x01
  38. #define WLC_EVENT_MSG_FLUSHTXQ 0x02
  39. #define WLC_EVENT_MSG_GROUP 0x04
  40. #define WLC_EVENT_MSG_UNKBSS 0x08
  41. #define WLC_EVENT_MSG_UNKIF 0x10
  42. typedef BWL_PRE_PACKED_STRUCT struct
  43. {
  44. uint16 version;
  45. uint16 flags;
  46. uint32 event_type;
  47. uint32 status;
  48. uint32 reason;
  49. uint32 auth_type;
  50. uint32 datalen;
  51. struct ether_addr addr;
  52. char ifname[BCM_MSG_IFNAME_MAX];
  53. } BWL_POST_PACKED_STRUCT wl_event_msg_v1_t;
  54. typedef BWL_PRE_PACKED_STRUCT struct
  55. {
  56. uint16 version;
  57. uint16 flags;
  58. uint32 event_type;
  59. uint32 status;
  60. uint32 reason;
  61. uint32 auth_type;
  62. uint32 datalen;
  63. struct ether_addr addr;
  64. char ifname[BCM_MSG_IFNAME_MAX];
  65. uint8 ifidx;
  66. uint8 bsscfgidx;
  67. } BWL_POST_PACKED_STRUCT wl_event_msg_t;
  68. typedef BWL_PRE_PACKED_STRUCT struct bcm_event {
  69. struct ether_header eth;
  70. bcmeth_hdr_t bcm_hdr;
  71. wl_event_msg_t event;
  72. } BWL_POST_PACKED_STRUCT bcm_event_t;
  73. #define BCM_MSG_LEN (sizeof(bcm_event_t) - sizeof(bcmeth_hdr_t) - sizeof(struct ether_header))
  74. #define WLC_E_SET_SSID 0
  75. #define WLC_E_JOIN 1
  76. #define WLC_E_START 2
  77. #define WLC_E_AUTH 3
  78. #define WLC_E_AUTH_IND 4
  79. #define WLC_E_DEAUTH 5
  80. #define WLC_E_DEAUTH_IND 6
  81. #define WLC_E_ASSOC 7
  82. #define WLC_E_ASSOC_IND 8
  83. #define WLC_E_REASSOC 9
  84. #define WLC_E_REASSOC_IND 10
  85. #define WLC_E_DISASSOC 11
  86. #define WLC_E_DISASSOC_IND 12
  87. #define WLC_E_QUIET_START 13
  88. #define WLC_E_QUIET_END 14
  89. #define WLC_E_BEACON_RX 15
  90. #define WLC_E_LINK 16
  91. #define WLC_E_MIC_ERROR 17
  92. #define WLC_E_NDIS_LINK 18
  93. #define WLC_E_ROAM 19
  94. #define WLC_E_TXFAIL 20
  95. #define WLC_E_PMKID_CACHE 21
  96. #define WLC_E_RETROGRADE_TSF 22
  97. #define WLC_E_PRUNE 23
  98. #define WLC_E_AUTOAUTH 24
  99. #define WLC_E_EAPOL_MSG 25
  100. #define WLC_E_SCAN_COMPLETE 26
  101. #define WLC_E_ADDTS_IND 27
  102. #define WLC_E_DELTS_IND 28
  103. #define WLC_E_BCNSENT_IND 29
  104. #define WLC_E_BCNRX_MSG 30
  105. #define WLC_E_BCNLOST_MSG 31
  106. #define WLC_E_ROAM_PREP 32
  107. #define WLC_E_PFN_NET_FOUND 33
  108. #define WLC_E_PFN_NET_LOST 34
  109. #define WLC_E_RESET_COMPLETE 35
  110. #define WLC_E_JOIN_START 36
  111. #define WLC_E_ROAM_START 37
  112. #define WLC_E_ASSOC_START 38
  113. #define WLC_E_IBSS_ASSOC 39
  114. #define WLC_E_RADIO 40
  115. #define WLC_E_PSM_WATCHDOG 41
  116. #define WLC_E_PROBREQ_MSG 44
  117. #define WLC_E_SCAN_CONFIRM_IND 45
  118. #define WLC_E_PSK_SUP 46
  119. #define WLC_E_COUNTRY_CODE_CHANGED 47
  120. #define WLC_E_EXCEEDED_MEDIUM_TIME 48
  121. #define WLC_E_ICV_ERROR 49
  122. #define WLC_E_UNICAST_DECODE_ERROR 50
  123. #define WLC_E_MULTICAST_DECODE_ERROR 51
  124. #define WLC_E_TRACE 52
  125. #ifdef WLBTAMP
  126. #define WLC_E_BTA_HCI_EVENT 53
  127. #endif
  128. #define WLC_E_IF 54
  129. #define WLC_E_P2P_DISC_LISTEN_COMPLETE 55
  130. #define WLC_E_RSSI 56
  131. #define WLC_E_PFN_SCAN_COMPLETE 57
  132. #define WLC_E_EXTLOG_MSG 58
  133. #define WLC_E_ACTION_FRAME 59
  134. #define WLC_E_ACTION_FRAME_COMPLETE 60
  135. #define WLC_E_PRE_ASSOC_IND 61
  136. #define WLC_E_PRE_REASSOC_IND 62
  137. #define WLC_E_CHANNEL_ADOPTED 63
  138. #define WLC_E_AP_STARTED 64
  139. #define WLC_E_DFS_AP_STOP 65
  140. #define WLC_E_DFS_AP_RESUME 66
  141. #define WLC_E_WAI_STA_EVENT 67
  142. #define WLC_E_WAI_MSG 68
  143. #define WLC_E_ESCAN_RESULT 69
  144. #define WLC_E_ACTION_FRAME_OFF_CHAN_COMPLETE 70
  145. #define WLC_E_PROBRESP_MSG 71
  146. #define WLC_E_P2P_PROBREQ_MSG 72
  147. #define WLC_E_DCS_REQUEST 73
  148. #define WLC_E_FIFO_CREDIT_MAP 74
  149. #define WLC_E_ACTION_FRAME_RX 75
  150. #if 0
  151. #define WLC_E_WAKE_EVENT 76
  152. #define WLC_E_RM_COMPLETE 77
  153. #define WLC_E_HTSFSYNC 78
  154. #define WLC_E_OVERLAY_REQ 79
  155. #define WLC_E_CSA_COMPLETE_IND 80
  156. #define WLC_E_EXCESS_PM_WAKE_EVENT 81
  157. #define WLC_E_PFN_SCAN_NONE 82
  158. #define WLC_E_PFN_SCAN_ALLGONE 83
  159. #define WLC_E_GTK_PLUMBED 84
  160. #define WLC_E_ASSOC_IND_NDIS 85
  161. #define WLC_E_REASSOC_IND_NDIS 86
  162. #define WLC_E_ASSOC_REQ_IE 87
  163. #define WLC_E_ASSOC_RESP_IE 88
  164. #define WLC_E_ASSOC_RECREATED 89
  165. #define WLC_E_ACTION_FRAME_RX_NDIS 90
  166. #define WLC_E_AUTH_REQ 91
  167. #define WLC_E_TDLS_PEER_EVENT 92
  168. #define WLC_E_SPEEDY_RECREATE_FAIL 93
  169. #define WLC_E_RELOAD 94
  170. #define WLC_E_RSSI_LOW 95 /* Send up rssi low event */
  171. #define WLC_E_ASSOCREQ_IE 96 /* Send up assoc ie */
  172. #define WLC_E_LOAD_IND 97
  173. #define WLC_E_TX_STAT_ERROR 98
  174. #define WLC_E_LAST 99
  175. #else
  176. #define WLC_E_WAKE_EVENT 76 /* Wake Event timer fired, used for wake WLAN test mode */
  177. #define WLC_E_OVERLAY_REQ 77 /* request an overlay IOCTL/iovar from the host */
  178. #define WLC_E_ASSOC_IND_NDIS 78 /* 802.11 ASSOC indication for NDIS only */
  179. #define WLC_E_REASSOC_IND_NDIS 79 /* 802.11 REASSOC indication for NDIS only */
  180. #define WLC_E_CSA_COMPLETE_IND 80 /* 802.11 CHANNEL SWITCH ACTION completed */
  181. #define WLC_E_EXCESS_PM_WAKE_EVENT 81 /* excess PM Wake Event to inform host */
  182. #define WLC_E_PFN_SCAN_NONE 82 /* no PFN networks around */
  183. #define WLC_E_PFN_SCAN_ALLGONE 83 /* last found PFN network gets lost */
  184. #define WLC_E_GTK_PLUMBED 84
  185. #define WLC_E_ASSOC_REQ_IE 85
  186. #define WLC_E_ASSOC_RESP_IE 86
  187. //Hugh add 2012-05-07 Add new event ++++
  188. #define WLC_E_RSSI_LOW 87 /* Send up rssi low event */
  189. #define WLC_E_LOAD_IND 88 /* loading incicate */
  190. #define WLC_E_TX_STAT_ERROR 89 /* tx error indicate */
  191. //Hugh add 2012-05-07 Add new event ----
  192. #define WLC_E_LAST 90 /* highest val + 1 for range checking */
  193. #endif
  194. typedef struct {
  195. uint event;
  196. const char *name;
  197. } bcmevent_name_t;
  198. extern const bcmevent_name_t bcmevent_names[];
  199. extern const int bcmevent_names_size;
  200. #define WLC_E_STATUS_SUCCESS 0
  201. #define WLC_E_STATUS_FAIL 1
  202. #define WLC_E_STATUS_TIMEOUT 2
  203. #define WLC_E_STATUS_NO_NETWORKS 3
  204. #define WLC_E_STATUS_ABORT 4
  205. #define WLC_E_STATUS_NO_ACK 5
  206. #define WLC_E_STATUS_UNSOLICITED 6
  207. #define WLC_E_STATUS_ATTEMPT 7
  208. #define WLC_E_STATUS_PARTIAL 8
  209. #define WLC_E_STATUS_NEWSCAN 9
  210. #define WLC_E_STATUS_NEWASSOC 10
  211. #define WLC_E_STATUS_11HQUIET 11
  212. #define WLC_E_STATUS_SUPPRESS 12
  213. #define WLC_E_STATUS_NOCHANS 13
  214. #define WLC_E_STATUS_CS_ABORT 15
  215. #define WLC_E_STATUS_ERROR 16
  216. #define WLC_E_REASON_INITIAL_ASSOC 0
  217. #define WLC_E_REASON_LOW_RSSI 1
  218. #define WLC_E_REASON_DEAUTH 2
  219. #define WLC_E_REASON_DISASSOC 3
  220. #define WLC_E_REASON_BCNS_LOST 4
  221. #define WLC_E_REASON_MINTXRATE 9
  222. #define WLC_E_REASON_TXFAIL 10
  223. #define WLC_E_REASON_FAST_ROAM_FAILED 5
  224. #define WLC_E_REASON_DIRECTED_ROAM 6
  225. #define WLC_E_REASON_TSPEC_REJECTED 7
  226. #define WLC_E_REASON_BETTER_AP 8
  227. #define WLC_E_REASON_REQUESTED_ROAM 11
  228. #define WLC_E_PRUNE_ENCR_MISMATCH 1
  229. #define WLC_E_PRUNE_BCAST_BSSID 2
  230. #define WLC_E_PRUNE_MAC_DENY 3
  231. #define WLC_E_PRUNE_MAC_NA 4
  232. #define WLC_E_PRUNE_REG_PASSV 5
  233. #define WLC_E_PRUNE_SPCT_MGMT 6
  234. #define WLC_E_PRUNE_RADAR 7
  235. #define WLC_E_RSN_MISMATCH 8
  236. #define WLC_E_PRUNE_NO_COMMON_RATES 9
  237. #define WLC_E_PRUNE_BASIC_RATES 10
  238. #define WLC_E_PRUNE_CIPHER_NA 12
  239. #define WLC_E_PRUNE_KNOWN_STA 13
  240. #define WLC_E_PRUNE_WDS_PEER 15
  241. #define WLC_E_PRUNE_QBSS_LOAD 16
  242. #define WLC_E_PRUNE_HOME_AP 17
  243. #define WLC_E_SUP_OTHER 0
  244. #define WLC_E_SUP_DECRYPT_KEY_DATA 1
  245. #define WLC_E_SUP_BAD_UCAST_WEP128 2
  246. #define WLC_E_SUP_BAD_UCAST_WEP40 3
  247. #define WLC_E_SUP_UNSUP_KEY_LEN 4
  248. #define WLC_E_SUP_PW_KEY_CIPHER 5
  249. #define WLC_E_SUP_MSG3_TOO_MANY_IE 6
  250. #define WLC_E_SUP_MSG3_IE_MISMATCH 7
  251. #define WLC_E_SUP_NO_INSTALL_FLAG 8
  252. #define WLC_E_SUP_MSG3_NO_GTK 9
  253. #define WLC_E_SUP_GRP_KEY_CIPHER 10
  254. #define WLC_E_SUP_GRP_MSG1_NO_GTK 11
  255. #define WLC_E_SUP_GTK_DECRYPT_FAIL 12
  256. #define WLC_E_SUP_SEND_FAIL 13
  257. #define WLC_E_SUP_DEAUTH 14
  258. #define WLC_E_SUP_WPA_PSK_TMO 15
  259. typedef BWL_PRE_PACKED_STRUCT struct wl_event_rx_frame_data {
  260. uint16 version;
  261. uint16 channel;
  262. int32 rssi;
  263. uint32 mactime;
  264. uint32 rate;
  265. } BWL_POST_PACKED_STRUCT wl_event_rx_frame_data_t;
  266. #define BCM_RX_FRAME_DATA_VERSION 1
  267. typedef struct wl_event_data_if {
  268. uint8 ifidx;
  269. uint8 opcode;
  270. uint8 reserved;
  271. uint8 bssidx;
  272. uint8 role;
  273. } wl_event_data_if_t;
  274. #define WLC_E_IF_ADD 1
  275. #define WLC_E_IF_DEL 2
  276. #define WLC_E_IF_CHANGE 3
  277. #define WLC_E_IF_ROLE_STA 0
  278. #define WLC_E_IF_ROLE_AP 1
  279. #define WLC_E_IF_ROLE_WDS 2
  280. #define WLC_E_IF_ROLE_P2P_GO 3
  281. #define WLC_E_IF_ROLE_P2P_CLIENT 4
  282. #ifdef WLBTAMP
  283. #define WLC_E_IF_ROLE_BTA_CREATOR 5
  284. #define WLC_E_IF_ROLE_BTA_ACCEPTOR 6
  285. #endif
  286. #define WLC_E_LINK_BCN_LOSS 1
  287. #define WLC_E_LINK_DISASSOC 2
  288. #define WLC_E_LINK_ASSOC_REC 3
  289. #define WLC_E_LINK_BSSCFG_DIS 4
  290. #define WLC_E_OVL_DOWNLOAD 0
  291. #define WLC_E_OVL_UPDATE_IND 1
  292. #define WLC_E_TDLS_PEER_DISCOVERED 0
  293. #define WLC_E_TDLS_PEER_CONNECTED 1
  294. #define WLC_E_TDLS_PEER_DISCONNECTED 2
  295. #define WLC_E_RELOAD_STATUS1 1 /* Internal Firmware Error */
  296. #include <packed_section_end.h>
  297. #endif