brcmfmac: move firmware event related defines to fweh.h
authorArend van Spriel <arend@broadcom.com>
Fri, 29 Nov 2013 11:25:23 +0000 (12:25 +0100)
committerJohn W. Linville <linville@tuxdriver.com>
Mon, 2 Dec 2013 19:25:25 +0000 (14:25 -0500)
The dhd.h file contained a number of definitions that are
related to events received from the firmware. Those are
processed and dispatched in the driver by fweh. Hence the
definitions are moved to its include file.

Reviewed-by: Hante Meuleman <meuleman@broadcom.com>
Reviewed-by: Pieter-Paul Giesberts <pieterpg@broadcom.com>
Signed-off-by: Arend van Spriel <arend@broadcom.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
drivers/net/wireless/brcm80211/brcmfmac/dhd.h
drivers/net/wireless/brcm80211/brcmfmac/fweh.h

index da5cf00ac09c8eef13151aa0a60f1b10582d89bb..252024bcbc3ba736c65d18975f2b5106e026737a 100644 (file)
 
 #define DOT11_MAX_DEFAULT_KEYS 4
 
-#define BRCMF_E_STATUS_SUCCESS                 0
-#define BRCMF_E_STATUS_FAIL                    1
-#define BRCMF_E_STATUS_TIMEOUT                 2
-#define BRCMF_E_STATUS_NO_NETWORKS             3
-#define BRCMF_E_STATUS_ABORT                   4
-#define BRCMF_E_STATUS_NO_ACK                  5
-#define BRCMF_E_STATUS_UNSOLICITED             6
-#define BRCMF_E_STATUS_ATTEMPT                 7
-#define BRCMF_E_STATUS_PARTIAL                 8
-#define BRCMF_E_STATUS_NEWSCAN                 9
-#define BRCMF_E_STATUS_NEWASSOC                        10
-#define BRCMF_E_STATUS_11HQUIET                        11
-#define BRCMF_E_STATUS_SUPPRESS                        12
-#define BRCMF_E_STATUS_NOCHANS                 13
-#define BRCMF_E_STATUS_CS_ABORT                        15
-#define BRCMF_E_STATUS_ERROR                   16
-
-#define BRCMF_E_REASON_INITIAL_ASSOC           0
-#define BRCMF_E_REASON_LOW_RSSI                        1
-#define BRCMF_E_REASON_DEAUTH                  2
-#define BRCMF_E_REASON_DISASSOC                        3
-#define BRCMF_E_REASON_BCNS_LOST               4
-#define BRCMF_E_REASON_MINTXRATE               9
-#define BRCMF_E_REASON_TXFAIL                  10
-
-#define BRCMF_E_REASON_LINK_BSSCFG_DIS         4
-#define BRCMF_E_REASON_FAST_ROAM_FAILED                5
-#define BRCMF_E_REASON_DIRECTED_ROAM           6
-#define BRCMF_E_REASON_TSPEC_REJECTED          7
-#define BRCMF_E_REASON_BETTER_AP               8
-
-#define BRCMF_E_IF_ADD                         1
-#define BRCMF_E_IF_DEL                         2
-#define BRCMF_E_IF_CHANGE                      3
-
-#define BRCMF_E_IF_FLAG_NOIF                   1
-
-#define BRCMF_E_IF_ROLE_STA                    0
-#define BRCMF_E_IF_ROLE_AP                     1
-#define BRCMF_E_IF_ROLE_WDS                    2
-
 /* Small, medium and maximum buffer size for dcmd
  */
 #define BRCMF_DCMD_SMLEN       256
@@ -156,14 +115,6 @@ struct brcmf_pub {
 #endif
 };
 
-struct brcmf_if_event {
-       u8 ifidx;
-       u8 action;
-       u8 flags;
-       u8 bssidx;
-       u8 role;
-};
-
 /* forward declarations */
 struct brcmf_cfg80211_vif;
 struct brcmf_fws_mac_descriptor;
index 14bc24dc5baeb1f8272b4da0660d893c4bfc9b48..51b53a73d07464c0bb9b8b5a6f551e20314c37ce 100644 (file)
@@ -122,6 +122,52 @@ enum brcmf_fweh_event_code {
 #define BRCMF_EVENT_MSG_FLUSHTXQ       0x02
 #define BRCMF_EVENT_MSG_GROUP          0x04
 
+/* status field values in struct brcmf_event_msg */
+#define BRCMF_E_STATUS_SUCCESS                 0
+#define BRCMF_E_STATUS_FAIL                    1
+#define BRCMF_E_STATUS_TIMEOUT                 2
+#define BRCMF_E_STATUS_NO_NETWORKS             3
+#define BRCMF_E_STATUS_ABORT                   4
+#define BRCMF_E_STATUS_NO_ACK                  5
+#define BRCMF_E_STATUS_UNSOLICITED             6
+#define BRCMF_E_STATUS_ATTEMPT                 7
+#define BRCMF_E_STATUS_PARTIAL                 8
+#define BRCMF_E_STATUS_NEWSCAN                 9
+#define BRCMF_E_STATUS_NEWASSOC                        10
+#define BRCMF_E_STATUS_11HQUIET                        11
+#define BRCMF_E_STATUS_SUPPRESS                        12
+#define BRCMF_E_STATUS_NOCHANS                 13
+#define BRCMF_E_STATUS_CS_ABORT                        15
+#define BRCMF_E_STATUS_ERROR                   16
+
+/* reason field values in struct brcmf_event_msg */
+#define BRCMF_E_REASON_INITIAL_ASSOC           0
+#define BRCMF_E_REASON_LOW_RSSI                        1
+#define BRCMF_E_REASON_DEAUTH                  2
+#define BRCMF_E_REASON_DISASSOC                        3
+#define BRCMF_E_REASON_BCNS_LOST               4
+#define BRCMF_E_REASON_MINTXRATE               9
+#define BRCMF_E_REASON_TXFAIL                  10
+
+#define BRCMF_E_REASON_LINK_BSSCFG_DIS         4
+#define BRCMF_E_REASON_FAST_ROAM_FAILED                5
+#define BRCMF_E_REASON_DIRECTED_ROAM           6
+#define BRCMF_E_REASON_TSPEC_REJECTED          7
+#define BRCMF_E_REASON_BETTER_AP               8
+
+/* action field values for brcmf_ifevent */
+#define BRCMF_E_IF_ADD                         1
+#define BRCMF_E_IF_DEL                         2
+#define BRCMF_E_IF_CHANGE                      3
+
+/* flag field values for brcmf_ifevent */
+#define BRCMF_E_IF_FLAG_NOIF                   1
+
+/* role field values for brcmf_ifevent */
+#define BRCMF_E_IF_ROLE_STA                    0
+#define BRCMF_E_IF_ROLE_AP                     1
+#define BRCMF_E_IF_ROLE_WDS                    2
+
 /**
  * definitions for event packet validation.
  */
@@ -160,6 +206,14 @@ struct brcmf_event_msg {
        u8 bsscfgidx;
 };
 
+struct brcmf_if_event {
+       u8 ifidx;
+       u8 action;
+       u8 flags;
+       u8 bssidx;
+       u8 role;
+};
+
 typedef int (*brcmf_fweh_handler_t)(struct brcmf_if *ifp,
                                    const struct brcmf_event_msg *evtmsg,
                                    void *data);