]> pilppa.org Git - linux-2.6-omap-h63xx.git/blobdiff - drivers/staging/wlan-ng/hfa384x.h
Staging: wlan-ng: Remove dead/unused code from p80211req.c
[linux-2.6-omap-h63xx.git] / drivers / staging / wlan-ng / hfa384x.h
index b88bfe4378225dd28098e5e5c1b55505ce0f62aa..e72208674c7e7a6362450d67e0912f13639f0bfa 100644 (file)
 /*=============================================================*/
 #define HFA384x_FIRMWARE_VERSION(a,b,c) (((a) << 16) + ((b) << 8) + (c))
 
-#define HFA384x_LEVEL_TO_dBm(v)   (0x100 + (v) * 100 / 255 - 100)
-
 #include <linux/if_ether.h>
 
 /*------ Constants --------------------------------------------*/
 /*--- Mins & Maxs -----------------------------------*/
-#define                HFA384x_CMD_ALLOC_LEN_MIN       ((u16)4)
-#define                HFA384x_CMD_ALLOC_LEN_MAX       ((u16)2400)
-#define                HFA384x_BAP_DATALEN_MAX         ((u16)4096)
-#define                HFA384x_BAP_OFFSET_MAX          ((u16)4096)
 #define                HFA384x_PORTID_MAX              ((u16)7)
 #define                HFA384x_NUMPORTS_MAX            ((u16)(HFA384x_PORTID_MAX+1))
 #define                HFA384x_PDR_LEN_MAX             ((u16)512)      /* in bytes, from EK */
-#define                HFA384x_PDA_RECS_MAX            ((u16)200)      /* a guess */
 #define                HFA384x_PDA_LEN_MAX             ((u16)1024)     /* in bytes, from EK */
 #define                HFA384x_SCANRESULT_MAX          ((u16)31)
 #define                HFA384x_HSCANRESULT_MAX         ((u16)31)
 #define                HFA384x_CHINFORESULT_MAX        ((u16)16)
-#define                HFA384x_DRVR_FIDSTACKLEN_MAX    (10)
-#define                HFA384x_DRVR_TXBUF_MAX          (sizeof(hfa384x_tx_frame_t) + \
-                                               WLAN_DATA_MAXLEN - \
-                                               WLAN_WEP_IV_LEN - \
-                                               WLAN_WEP_ICV_LEN + 2)
-#define                HFA384x_DRVR_MAGIC              (0x4a2d)
-#define                HFA384x_INFODATA_MAXLEN         (sizeof(hfa384x_infodata_t))
-#define                HFA384x_INFOFRM_MAXLEN          (sizeof(hfa384x_InfFrame_t))
 #define                HFA384x_RID_GUESSING_MAXLEN     2048  /* I'm not really sure */
 #define                HFA384x_RIDDATA_MAXLEN          HFA384x_RID_GUESSING_MAXLEN
 #define                HFA384x_USB_RWMEM_MAXLEN        2048
 
 /*--- Support Constants -----------------------------*/
-#define                HFA384x_BAP_PROC                        ((u16)0)
-#define                HFA384x_BAP_int                         ((u16)1)
 #define                HFA384x_PORTTYPE_IBSS                   ((u16)0)
 #define                HFA384x_PORTTYPE_BSS                    ((u16)1)
-#define                HFA384x_PORTTYPE_WDS                    ((u16)2)
 #define                HFA384x_PORTTYPE_PSUEDOIBSS             ((u16)3)
-#define                HFA384x_PORTTYPE_HOSTAP                 ((u16)6)
-#define                HFA384x_WEPFLAGS_PRIVINVOKED            ((u16)BIT0)
-#define                HFA384x_WEPFLAGS_EXCLUDE                ((u16)BIT1)
-#define                HFA384x_WEPFLAGS_DISABLE_TXCRYPT        ((u16)BIT4)
-#define                HFA384x_WEPFLAGS_DISABLE_RXCRYPT        ((u16)BIT7)
-#define                HFA384x_WEPFLAGS_DISALLOW_MIXED         ((u16)BIT11)
-#define                HFA384x_WEPFLAGS_IV_intERVAL1           ((u16)0)
-#define                HFA384x_WEPFLAGS_IV_intERVAL10          ((u16)BIT5)
-#define                HFA384x_WEPFLAGS_IV_intERVAL50          ((u16)BIT6)
-#define                HFA384x_WEPFLAGS_IV_intERVAL100         ((u16)(BIT5 | BIT6))
-#define                HFA384x_WEPFLAGS_FIRMWARE_WPA           ((u16)BIT8)
-#define                HFA384x_WEPFLAGS_HOST_MIC               ((u16)BIT9)
-#define        HFA384x_ROAMMODE_FWSCAN_FWROAM          ((u16)1)
-#define        HFA384x_ROAMMODE_FWSCAN_HOSTROAM        ((u16)2)
+#define                HFA384x_WEPFLAGS_PRIVINVOKED            ((u16)BIT(0))
+#define                HFA384x_WEPFLAGS_EXCLUDE                ((u16)BIT(1))
+#define                HFA384x_WEPFLAGS_DISABLE_TXCRYPT        ((u16)BIT(4))
+#define                HFA384x_WEPFLAGS_DISABLE_RXCRYPT        ((u16)BIT(7))
 #define        HFA384x_ROAMMODE_HOSTSCAN_HOSTROAM      ((u16)3)
 #define        HFA384x_PORTSTATUS_DISABLED             ((u16)1)
-#define        HFA384x_PORTSTATUS_INITSRCH             ((u16)2)
-#define        HFA384x_PORTSTATUS_CONN_IBSS            ((u16)3)
-#define        HFA384x_PORTSTATUS_CONN_ESS             ((u16)4)
-#define        HFA384x_PORTSTATUS_OOR_ESS              ((u16)5)
-#define        HFA384x_PORTSTATUS_CONN_WDS             ((u16)6)
-#define        HFA384x_PORTSTATUS_HOSTAP               ((u16)8)
 #define                HFA384x_RATEBIT_1                       ((u16)1)
 #define                HFA384x_RATEBIT_2                       ((u16)2)
 #define                HFA384x_RATEBIT_5dot5                   ((u16)4)
 #define                HFA384x_RATEBIT_11                      ((u16)8)
 
-/*--- Just some symbolic names for legibility -------*/
-#define                HFA384x_TXCMD_NORECL            ((u16)0)
-#define                HFA384x_TXCMD_RECL              ((u16)1)
-
 /*--- MAC Internal memory constants and macros ------*/
 /* masks and macros used to manipulate MAC internal memory addresses. */
 /* MAC internal memory addresses are 23 bit quantities.  The MAC uses
  * macros below help handle some of this.
  */
 
-/* Handy constant */
-#define                HFA384x_ADDR_AUX_OFF_MAX        ((u16)0x007f)
-
 /* Mask bits for discarding unwanted pieces in a flat address */
 #define                HFA384x_ADDR_FLAT_AUX_PAGE_MASK (0x007fff80)
 #define                HFA384x_ADDR_FLAT_AUX_OFF_MASK  (0x0000007f)
 #define                HFA384x_ADDR_AUX_PAGE_MASK      (0xffff)
 #define                HFA384x_ADDR_AUX_OFF_MASK       (0x007f)
 
-/* Mask bits for discarding unwanted pieces in CMD format 16-bit address parts */
-#define                HFA384x_ADDR_CMD_PAGE_MASK      (0x007f)
-#define                HFA384x_ADDR_CMD_OFF_MASK       (0xffff)
-
 /* Make a 32-bit flat address from AUX format 16-bit page and offset */
 #define                HFA384x_ADDR_AUX_MKFLAT(p,o)    \
                (((u32)(((u16)(p))&HFA384x_ADDR_AUX_PAGE_MASK)) <<7) | \
                ((u32)(((u16)(o))&HFA384x_ADDR_AUX_OFF_MASK))
 
-/* Make a 32-bit flat address from CMD format 16-bit page and offset */
-#define                HFA384x_ADDR_CMD_MKFLAT(p,o)    \
-               (((u32)(((u16)(p))&HFA384x_ADDR_CMD_PAGE_MASK)) <<16) | \
-               ((u32)(((u16)(o))&HFA384x_ADDR_CMD_OFF_MASK))
-
-/* Make AUX format offset and page from a 32-bit flat address */
-#define                HFA384x_ADDR_AUX_MKPAGE(f) \
-               ((u16)((((u32)(f))&HFA384x_ADDR_FLAT_AUX_PAGE_MASK)>>7))
-#define                HFA384x_ADDR_AUX_MKOFF(f) \
-               ((u16)(((u32)(f))&HFA384x_ADDR_FLAT_AUX_OFF_MASK))
-
 /* Make CMD format offset and page from a 32-bit flat address */
 #define                HFA384x_ADDR_CMD_MKPAGE(f) \
                ((u16)((((u32)(f))&HFA384x_ADDR_FLAT_CMD_PAGE_MASK)>>16))
 #define                HFA384x_ADDR_CMD_MKOFF(f) \
                ((u16)(((u32)(f))&HFA384x_ADDR_FLAT_CMD_OFF_MASK))
 
-/*--- Aux register masks/tests ----------------------*/
-/* Some of the upper bits of the AUX offset register are used to */
-/*  select address space. */
-#define                HFA384x_AUX_CTL_EXTDS   (0x00)
-#define                HFA384x_AUX_CTL_NV      (0x01)
-#define                HFA384x_AUX_CTL_PHY     (0x02)
-#define                HFA384x_AUX_CTL_ICSRAM  (0x03)
-
-/* Make AUX register offset and page values from a flat address */
-#define                HFA384x_AUX_MKOFF(f, c) \
-       (HFA384x_ADDR_AUX_MKOFF(f) | (((u16)(c))<<12))
-#define                HFA384x_AUX_MKPAGE(f)   HFA384x_ADDR_AUX_MKPAGE(f)
-
 
 /*--- Controller Memory addresses -------------------*/
 #define                HFA3842_PDA_BASE        (0x007f0000UL)
 #define                HFA384x_DLSTATE_DISABLED                0
 #define                HFA384x_DLSTATE_RAMENABLED              1
 #define                HFA384x_DLSTATE_FLASHENABLED            2
-#define                HFA384x_DLSTATE_FLASHWRITTEN            3
-#define                HFA384x_DLSTATE_FLASHWRITEPENDING       4
-#define                HFA384x_DLSTATE_GENESIS                 5
 
 #define                HFA384x_CMD_OFF                 (0x00)
 #define                HFA384x_PARAM0_OFF              (0x04)
 #define                HFA384x_PCI_M1_CTL_OFF          (0xac)
 
 /*--- Register Field Masks --------------------------*/
-#define                HFA384x_CMD_BUSY                ((u16)BIT15)
-#define                HFA384x_CMD_AINFO               ((u16)(BIT14 | BIT13 | BIT12 | BIT11 | BIT10 | BIT9 | BIT8))
-#define                HFA384x_CMD_MACPORT             ((u16)(BIT10 | BIT9 | BIT8))
-#define                HFA384x_CMD_RECL                ((u16)BIT8)
-#define                HFA384x_CMD_WRITE               ((u16)BIT8)
-#define                HFA384x_CMD_PROGMODE            ((u16)(BIT9 | BIT8))
-#define                HFA384x_CMD_CMDCODE             ((u16)(BIT5 | BIT4 | BIT3 | BIT2 | BIT1 | BIT0))
-
-#define                HFA384x_STATUS_RESULT           ((u16)(BIT14 | BIT13 | BIT12 | BIT11 | BIT10 | BIT9 | BIT8))
-#define                HFA384x_STATUS_CMDCODE          ((u16)(BIT5 | BIT4 | BIT3 | BIT2 | BIT1 | BIT0))
-
-#define                HFA384x_OFFSET_BUSY             ((u16)BIT15)
-#define                HFA384x_OFFSET_ERR              ((u16)BIT14)
-#define                HFA384x_OFFSET_DATAOFF          ((u16)(BIT11 | BIT10 | BIT9 | BIT8 | BIT7 | BIT6 | BIT5 | BIT4 | BIT3 | BIT2 | BIT1))
-
-#define                HFA384x_EVSTAT_TICK             ((u16)BIT15)
-#define                HFA384x_EVSTAT_WTERR            ((u16)BIT14)
-#define                HFA384x_EVSTAT_INFDROP          ((u16)BIT13)
-#define                HFA384x_EVSTAT_INFO             ((u16)BIT7)
-#define                HFA384x_EVSTAT_DTIM             ((u16)BIT5)
-#define                HFA384x_EVSTAT_CMD              ((u16)BIT4)
-#define                HFA384x_EVSTAT_ALLOC            ((u16)BIT3)
-#define                HFA384x_EVSTAT_TXEXC            ((u16)BIT2)
-#define                HFA384x_EVSTAT_TX               ((u16)BIT1)
-#define                HFA384x_EVSTAT_RX               ((u16)BIT0)
+#define                HFA384x_CMD_BUSY                ((u16)BIT(15))
+#define                HFA384x_CMD_AINFO               ((u16)(BIT(14) | BIT(13) | BIT(12) | BIT(11) | BIT(10) | BIT(9) | BIT(8)))
+#define                HFA384x_CMD_MACPORT             ((u16)(BIT(10) | BIT(9) | BIT(8)))
+#define                HFA384x_CMD_RECL                ((u16)BIT(8))
+#define                HFA384x_CMD_WRITE               ((u16)BIT(8))
+#define                HFA384x_CMD_PROGMODE            ((u16)(BIT(9) | BIT(8)))
+#define                HFA384x_CMD_CMDCODE             ((u16)(BIT(5) | BIT(4) | BIT(3) | BIT(2) | BIT(1) | BIT(0)))
+
+#define                HFA384x_STATUS_RESULT           ((u16)(BIT(14) | BIT(13) | BIT(12) | BIT(11) | BIT(10) | BIT(9) | BIT(8)))
+#define                HFA384x_STATUS_CMDCODE          ((u16)(BIT(5) | BIT(4) | BIT(3) | BIT(2) | BIT(1) | BIT(0)))
+
+#define                HFA384x_OFFSET_BUSY             ((u16)BIT(15))
+#define                HFA384x_OFFSET_ERR              ((u16)BIT(14))
+#define                HFA384x_OFFSET_DATAOFF          ((u16)(BIT(11) | BIT(10) | BIT(9) | BIT(8) | BIT(7) | BIT(6) | BIT(5) | BIT(4) | BIT(3) | BIT(2) | BIT(1)))
+
+#define                HFA384x_EVSTAT_TICK             ((u16)BIT(15))
+#define                HFA384x_EVSTAT_WTERR            ((u16)BIT(14))
+#define                HFA384x_EVSTAT_INFDROP          ((u16)BIT(13))
+#define                HFA384x_EVSTAT_INFO             ((u16)BIT(7))
+#define                HFA384x_EVSTAT_DTIM             ((u16)BIT(5))
+#define                HFA384x_EVSTAT_CMD              ((u16)BIT(4))
+#define                HFA384x_EVSTAT_ALLOC            ((u16)BIT(3))
+#define                HFA384x_EVSTAT_TXEXC            ((u16)BIT(2))
+#define                HFA384x_EVSTAT_TX               ((u16)BIT(1))
+#define                HFA384x_EVSTAT_RX               ((u16)BIT(0)
 
 #define         HFA384x_int_BAP_OP           (HFA384x_EVSTAT_INFO|HFA384x_EVSTAT_RX|HFA384x_EVSTAT_TX|HFA384x_EVSTAT_TXEXC)
 
 #define         HFA384x_int_NORMAL           (HFA384x_EVSTAT_INFO|HFA384x_EVSTAT_RX|HFA384x_EVSTAT_TX|HFA384x_EVSTAT_TXEXC|HFA384x_EVSTAT_INFDROP|HFA384x_EVSTAT_ALLOC|HFA384x_EVSTAT_DTIM)
 
-#define                HFA384x_intEN_TICK              ((u16)BIT15)
-#define                HFA384x_intEN_WTERR             ((u16)BIT14)
-#define                HFA384x_intEN_INFDROP           ((u16)BIT13)
-#define                HFA384x_intEN_INFO              ((u16)BIT7)
-#define                HFA384x_intEN_DTIM              ((u16)BIT5)
-#define                HFA384x_intEN_CMD               ((u16)BIT4)
-#define                HFA384x_intEN_ALLOC             ((u16)BIT3)
-#define                HFA384x_intEN_TXEXC             ((u16)BIT2)
-#define                HFA384x_intEN_TX                ((u16)BIT1)
-#define                HFA384x_intEN_RX                ((u16)BIT0)
-
-#define                HFA384x_EVACK_TICK              ((u16)BIT15)
-#define                HFA384x_EVACK_WTERR             ((u16)BIT14)
-#define                HFA384x_EVACK_INFDROP           ((u16)BIT13)
-#define                HFA384x_EVACK_INFO              ((u16)BIT7)
-#define                HFA384x_EVACK_DTIM              ((u16)BIT5)
-#define                HFA384x_EVACK_CMD               ((u16)BIT4)
-#define                HFA384x_EVACK_ALLOC             ((u16)BIT3)
-#define                HFA384x_EVACK_TXEXC             ((u16)BIT2)
-#define                HFA384x_EVACK_TX                ((u16)BIT1)
-#define                HFA384x_EVACK_RX                ((u16)BIT0)
-
-#define                HFA384x_CONTROL_AUXEN           ((u16)(BIT15 | BIT14))
+#define                HFA384x_intEN_TICK              ((u16)BIT(15))
+#define                HFA384x_intEN_WTERR             ((u16)BIT(14))
+#define                HFA384x_intEN_INFDROP           ((u16)BIT(13))
+#define                HFA384x_intEN_INFO              ((u16)BIT(7))
+#define                HFA384x_intEN_DTIM              ((u16)BIT(5))
+#define                HFA384x_intEN_CMD               ((u16)BIT(4))
+#define                HFA384x_intEN_ALLOC             ((u16)BIT(3))
+#define                HFA384x_intEN_TXEXC             ((u16)BIT(2))
+#define                HFA384x_intEN_TX                ((u16)BIT(1))
+#define                HFA384x_intEN_RX                ((u16)BIT(0)
+
+#define                HFA384x_EVACK_TICK              ((u16)BIT(15))
+#define                HFA384x_EVACK_WTERR             ((u16)BIT(14))
+#define                HFA384x_EVACK_INFDROP           ((u16)BIT(13))
+#define                HFA384x_EVACK_INFO              ((u16)BIT(7))
+#define                HFA384x_EVACK_DTIM              ((u16)BIT(5))
+#define                HFA384x_EVACK_CMD               ((u16)BIT(4))
+#define                HFA384x_EVACK_ALLOC             ((u16)BIT(3))
+#define                HFA384x_EVACK_TXEXC             ((u16)BIT(2))
+#define                HFA384x_EVACK_TX                ((u16)BIT(1))
+#define                HFA384x_EVACK_RX                ((u16)BIT(0)
+
+#define                HFA384x_CONTROL_AUXEN           ((u16)(BIT(15) | BIT(14)))
 
 
 /*--- Command Code Constants --------------------------*/
@@ -883,11 +811,11 @@ PD Record codes
 /*=============================================================*/
 /*------ Types and their related constants --------------------*/
 
-#define HFA384x_HOSTAUTHASSOC_HOSTAUTH   BIT0
-#define HFA384x_HOSTAUTHASSOC_HOSTASSOC  BIT1
+#define HFA384x_HOSTAUTHASSOC_HOSTAUTH   BIT(0)
+#define HFA384x_HOSTAUTHASSOC_HOSTASSOC  BIT(1)
 
 #define HFA384x_WHAHANDLING_DISABLED     0
-#define HFA384x_WHAHANDLING_PASSTHROUGH  BIT1
+#define HFA384x_WHAHANDLING_PASSTHROUGH  BIT(1)
 
 /*-------------------------------------------------------------*/
 /* Commonly used basic types */
@@ -1518,11 +1446,11 @@ typedef struct hfa384x_LFOStatus
        u16  VRHFOResult;
 } __attribute__((packed)) hfa384x_LFOStatus_t;
 
-#define HFA384x_TESTRESULT_ALLPASSED    BIT0
-#define HFA384x_TESTRESULT_LFO_FAIL     BIT1
-#define HFA384x_TESTRESULT_VR_HF0_FAIL  BIT2
-#define HFA384x_HOST_FIRM_COORDINATE    BIT7
-#define HFA384x_TESTRESULT_COORDINATE   BIT15
+#define HFA384x_TESTRESULT_ALLPASSED    BIT(0)
+#define HFA384x_TESTRESULT_LFO_FAIL     BIT(1)
+#define HFA384x_TESTRESULT_VR_HF0_FAIL  BIT(2)
+#define HFA384x_HOST_FIRM_COORDINATE    BIT(7)
+#define HFA384x_TESTRESULT_COORDINATE   BIT(15)
 
 /*-- Information Record: LEDControl --*/
 typedef struct hfa384x_LEDControl
@@ -1606,20 +1534,20 @@ typedef struct hfa384x_tx_frame
 Communication Frames: Field Masks for Transmit Frames
 --------------------------------------------------------------------*/
 /*-- Status Field --*/
-#define                HFA384x_TXSTATUS_ACKERR                 ((u16)BIT5)
-#define                HFA384x_TXSTATUS_FORMERR                ((u16)BIT3)
-#define                HFA384x_TXSTATUS_DISCON                 ((u16)BIT2)
-#define                HFA384x_TXSTATUS_AGEDERR                ((u16)BIT1)
-#define                HFA384x_TXSTATUS_RETRYERR               ((u16)BIT0)
+#define                HFA384x_TXSTATUS_ACKERR                 ((u16)BIT(5))
+#define                HFA384x_TXSTATUS_FORMERR                ((u16)BIT(3))
+#define                HFA384x_TXSTATUS_DISCON                 ((u16)BIT(2))
+#define                HFA384x_TXSTATUS_AGEDERR                ((u16)BIT(1))
+#define                HFA384x_TXSTATUS_RETRYERR               ((u16)BIT(0))
 /*-- Transmit Control Field --*/
-#define                HFA384x_TX_CFPOLL                       ((u16)BIT12)
-#define                HFA384x_TX_PRST                         ((u16)BIT11)
-#define                HFA384x_TX_MACPORT                      ((u16)(BIT10 | BIT9 | BIT8))
-#define                HFA384x_TX_NOENCRYPT                    ((u16)BIT7)
-#define                HFA384x_TX_RETRYSTRAT                   ((u16)(BIT6 | BIT5))
-#define                HFA384x_TX_STRUCTYPE                    ((u16)(BIT4 | BIT3))
-#define                HFA384x_TX_TXEX                         ((u16)BIT2)
-#define                HFA384x_TX_TXOK                         ((u16)BIT1)
+#define                HFA384x_TX_CFPOLL                       ((u16)BIT(12))
+#define                HFA384x_TX_PRST                         ((u16)BIT(11))
+#define                HFA384x_TX_MACPORT                      ((u16)(BIT(10) | BIT(9) | BIT(8)))
+#define                HFA384x_TX_NOENCRYPT                    ((u16)BIT(7))
+#define                HFA384x_TX_RETRYSTRAT                   ((u16)(BIT(6) | BIT(5)))
+#define                HFA384x_TX_STRUCTYPE                    ((u16)(BIT(4) | BIT(3)))
+#define                HFA384x_TX_TXEX                         ((u16)BIT(2))
+#define                HFA384x_TX_TXOK                         ((u16)BIT(1))
 /*--------------------------------------------------------------------
 Communication Frames: Test/Get/Set Field Values for Transmit Frames
 --------------------------------------------------------------------*/
@@ -1695,10 +1623,10 @@ Communication Frames: Field Masks for Receive Frames
 #define                HFA384x_RX_DATA_OFF                     ((u16)60)
 
 /*-- Status Fields --*/
-#define                HFA384x_RXSTATUS_MSGTYPE                ((u16)(BIT15 | BIT14 | BIT13))
-#define                HFA384x_RXSTATUS_MACPORT                ((u16)(BIT10 | BIT9 | BIT8))
-#define                HFA384x_RXSTATUS_UNDECR                 ((u16)BIT1)
-#define                HFA384x_RXSTATUS_FCSERR                 ((u16)BIT0)
+#define                HFA384x_RXSTATUS_MSGTYPE                ((u16)(BIT(15) | BIT(14) | BIT(13)))
+#define                HFA384x_RXSTATUS_MACPORT                ((u16)(BIT(10) | BIT(9) | BIT(8)))
+#define                HFA384x_RXSTATUS_UNDECR                 ((u16)BIT(1))
+#define                HFA384x_RXSTATUS_FCSERR                 ((u16)BIT(0))
 /*--------------------------------------------------------------------
 Communication Frames: Test/Get/Set Field Values for Receive Frames
 --------------------------------------------------------------------*/
@@ -1822,8 +1750,8 @@ typedef struct hfa384x_ChInfoResultSub
        u16     active;
 } __attribute__((packed)) hfa384x_ChInfoResultSub_t;
 
-#define HFA384x_CHINFORESULT_BSSACTIVE BIT0
-#define HFA384x_CHINFORESULT_PCFACTIVE BIT1
+#define HFA384x_CHINFORESULT_BSSACTIVE BIT(0)
+#define HFA384x_CHINFORESULT_PCFACTIVE BIT(1)
 
 typedef struct hfa384x_ChInfoResult
 {
@@ -2444,9 +2372,9 @@ typedef struct hfa484x_metacmd
 #define        MAX_GRP_ADDR            32
 #define WLAN_COMMENT_MAX       80  /* Max. length of user comment string. */
 
-#define MM_SAT_PCF             (BIT14)
-#define MM_GCSD_PCF            (BIT15)
-#define MM_GCSD_PCF_EB         (BIT14 | BIT15)
+#define MM_SAT_PCF             (BIT(14))
+#define MM_GCSD_PCF            (BIT(15))
+#define MM_GCSD_PCF_EB         (BIT(14) | BIT(15))
 
 #define WLAN_STATE_STOPPED     0   /* Network is not active. */
 #define WLAN_STATE_STARTED     1   /* Network has been started. */