提交 9b5795a7 编写于 作者: R Roland Vossen 提交者: Greg Kroah-Hartman

staging: brcm80211: cleaned up more softmac macro's

Substituted/removed macro's.
Reported-by: NJohannes Berg <johannes@sipsolutions.net>
Reviewed-by: NPieter-Paul Giesberts <pieterpg@broadcom.com>
Reviewed-by: NArend van Spriel <arend@broadcom.com>
Signed-off-by: NRoland Vossen <rvossen@broadcom.com>
Signed-off-by: NGreg Kroah-Hartman <gregkh@suse.de>
上级 d7084380
...@@ -267,6 +267,20 @@ ...@@ -267,6 +267,20 @@
#define APHY_SLOT_TIME 9 #define APHY_SLOT_TIME 9
#define BPHY_SLOT_TIME 20 #define BPHY_SLOT_TIME 20
#define WL_SPURAVOID_OFF 0
#define WL_SPURAVOID_ON1 1
#define WL_SPURAVOID_ON2 2
/*
* 32 SSID chars, max of 4 chars for each SSID char "\xFF", plus NULL.
*/
#define SSID_FMT_BUF_LEN ((4 * IEEE80211_MAX_SSID_LEN) + 1)
/* defaults for the HT (MIMO) bss */
#define HT_CAP (IEEE80211_HT_CAP_SM_PS |\
IEEE80211_HT_CAP_SUP_WIDTH_20_40 | IEEE80211_HT_CAP_GRN_FLD |\
IEEE80211_HT_CAP_MAX_AMSDU | IEEE80211_HT_CAP_DSSSCCK40)
/* /*
* The following table lists the buffer memory allocated to xmt fifos in HW. * The following table lists the buffer memory allocated to xmt fifos in HW.
* the size is in units of 256bytes(one block), total size is HW dependent * the size is in units of 256bytes(one block), total size is HW dependent
...@@ -361,6 +375,10 @@ ...@@ -361,6 +375,10 @@
#define IS_MBAND_UNLOCKED(wlc) \ #define IS_MBAND_UNLOCKED(wlc) \
((wlc->pub->_nbands > 1) && !(wlc)->bandlocked) ((wlc->pub->_nbands > 1) && !(wlc)->bandlocked)
#define CHSPEC_WLC_BW(chanspec) (CHSPEC_IS40(chanspec) ? BRCMS_40_MHZ : \
CHSPEC_IS20(chanspec) ? BRCMS_20_MHZ : \
BRCMS_10_MHZ)
/* dup state between BMAC(struct brcms_hardware) and HIGH(struct brcms_c_info) /* dup state between BMAC(struct brcms_hardware) and HIGH(struct brcms_c_info)
driver */ driver */
struct brcms_b_state { struct brcms_b_state {
......
...@@ -23,7 +23,6 @@ ...@@ -23,7 +23,6 @@
#include "types.h" #include "types.h"
#include "d11.h" #include "d11.h"
#define MA_WINDOW_SZ 8 /* moving average window size */
#define INVCHANNEL 255 /* invalid channel */ #define INVCHANNEL 255 /* invalid channel */
/* max # brcms_c_module_register() calls */ /* max # brcms_c_module_register() calls */
......
...@@ -64,6 +64,9 @@ ...@@ -64,6 +64,9 @@
#define MAXNUMRDES 9 /* Maximum OTP redundancy entries */ #define MAXNUMRDES 9 /* Maximum OTP redundancy entries */
/* Fixed size subregions sizes in words */
#define OTPGU_CI_SZ 2
/* OTP function struct */ /* OTP function struct */
struct otp_fn_s { struct otp_fn_s {
int (*size)(struct otpinfo *oi); int (*size)(struct otpinfo *oi);
...@@ -111,8 +114,6 @@ static struct otpinfo otpinfo; ...@@ -111,8 +114,6 @@ static struct otpinfo otpinfo;
* *
*/ */
#define HWSW_RGN(rgn) (((rgn) == OTP_HW_RGN) ? "h/w" : "s/w")
/* OTP layout */ /* OTP layout */
/* CC revs 21, 24 and 27 OTP General Use Region word offset */ /* CC revs 21, 24 and 27 OTP General Use Region word offset */
#define REVA4_OTPGU_BASE 12 #define REVA4_OTPGU_BASE 12
......
...@@ -30,12 +30,6 @@ ...@@ -30,12 +30,6 @@
/* OTP Size */ /* OTP Size */
#define OTP_SZ_MAX (6144/8) /* maximum bytes in one CIS */ #define OTP_SZ_MAX (6144/8) /* maximum bytes in one CIS */
/* Fixed size subregions sizes in words */
#define OTPGU_CI_SZ 2
/* OTP usage */
#define OTP4325_FM_DISABLED_OFFSET 188
struct otpinfo; struct otpinfo;
/* Exported functions */ /* Exported functions */
......
...@@ -19,19 +19,6 @@ ...@@ -19,19 +19,6 @@
#define _BRCM_PMU_H_ #define _BRCM_PMU_H_
#include "types.h" #include "types.h"
/*
* LDO selections used in si_pmu_set_ldo_voltage
*/
#define SET_LDO_VOLTAGE_LDO1 1
#define SET_LDO_VOLTAGE_LDO2 2
#define SET_LDO_VOLTAGE_LDO3 3
#define SET_LDO_VOLTAGE_PAREF 4
#define SET_LDO_VOLTAGE_CLDO_PWM 5
#define SET_LDO_VOLTAGE_CLDO_BURST 6
#define SET_LDO_VOLTAGE_CBUCK_PWM 7
#define SET_LDO_VOLTAGE_CBUCK_BURST 8
#define SET_LDO_VOLTAGE_LNLDO1 9
#define SET_LDO_VOLTAGE_LNLDO2_SEL 10
extern u16 si_pmu_fast_pwrup_delay(struct si_pub *sih); extern u16 si_pmu_fast_pwrup_delay(struct si_pub *sih);
extern void si_pmu_sprom_enable(struct si_pub *sih, bool enable); extern void si_pmu_sprom_enable(struct si_pub *sih, bool enable);
......
...@@ -40,10 +40,6 @@ ...@@ -40,10 +40,6 @@
#define BRCMS_20_MHZ 20 /* 20Mhz nphy channel bandwidth */ #define BRCMS_20_MHZ 20 /* 20Mhz nphy channel bandwidth */
#define BRCMS_40_MHZ 40 /* 40Mhz nphy channel bandwidth */ #define BRCMS_40_MHZ 40 /* 40Mhz nphy channel bandwidth */
#define CHSPEC_WLC_BW(chanspec) (CHSPEC_IS40(chanspec) ? BRCMS_40_MHZ : \
CHSPEC_IS20(chanspec) ? BRCMS_20_MHZ : \
BRCMS_10_MHZ)
#define BRCMS_RSSI_MINVAL -200 /* Low value, e.g. for forcing roam */ #define BRCMS_RSSI_MINVAL -200 /* Low value, e.g. for forcing roam */
#define BRCMS_RSSI_NO_SIGNAL -91 /* NDIS RSSI link quality cutoffs */ #define BRCMS_RSSI_NO_SIGNAL -91 /* NDIS RSSI link quality cutoffs */
#define BRCMS_RSSI_VERY_LOW -80 /* Very low quality cutoffs */ #define BRCMS_RSSI_VERY_LOW -80 /* Very low quality cutoffs */
...@@ -52,13 +48,6 @@ ...@@ -52,13 +48,6 @@
#define BRCMS_RSSI_VERY_GOOD -58 /* Very good quality cutoffs */ #define BRCMS_RSSI_VERY_GOOD -58 /* Very good quality cutoffs */
#define BRCMS_RSSI_EXCELLENT -57 /* Excellent quality cutoffs */ #define BRCMS_RSSI_EXCELLENT -57 /* Excellent quality cutoffs */
/* macro to perform PHY -> D11 PHY TYPE, currently 1:1 */
#define BRCMS_PHYTYPE(_x) (_x)
#define MA_WINDOW_SZ 8 /* moving average window size */
#define BRCMS_SNR_INVALID 0 /* invalid SNR value */
/* a large TX Power as an init value to factor out of min() calculations, /* a large TX Power as an init value to factor out of min() calculations,
* keep low enough to fit in an s8, units are .25 dBm * keep low enough to fit in an s8, units are .25 dBm
*/ */
...@@ -87,9 +76,6 @@ ...@@ -87,9 +76,6 @@
/* driver's default tx antenna setting */ /* driver's default tx antenna setting */
#define ANT_TX_DEF 3 #define ANT_TX_DEF 3
/* use all available core for transmit */
#define TXCORE_POLICY_ALL 0x1
/* Tx Chain values */ /* Tx Chain values */
/* def bitmap of txchain */ /* def bitmap of txchain */
#define TXCHAIN_DEF 0x1 #define TXCHAIN_DEF 0x1
...@@ -113,15 +99,9 @@ ...@@ -113,15 +99,9 @@
#define ANTSWITCH_TYPE_3 3 #define ANTSWITCH_TYPE_3 3
#define RXBUFSZ PKTBUFSZ #define RXBUFSZ PKTBUFSZ
/* aid bitmap size in bytes */
#define AIDMAPSZ (roundup(MAXSCB, NBBY)/NBBY)
#define MAX_STREAMS_SUPPORTED 4 /* max number of streams supported */ #define MAX_STREAMS_SUPPORTED 4 /* max number of streams supported */
#define WL_SPURAVOID_OFF 0
#define WL_SPURAVOID_ON1 1
#define WL_SPURAVOID_ON2 2
struct brcms_tunables { struct brcms_tunables {
int ntxd; /* size of tx descriptor table */ int ntxd; /* size of tx descriptor table */
int nrxd; /* size of rx descriptor table */ int nrxd; /* size of rx descriptor table */
...@@ -158,24 +138,11 @@ struct rsn_parms { ...@@ -158,24 +138,11 @@ struct rsn_parms {
u8 PAD[4]; /* padding for future growth */ u8 PAD[4]; /* padding for future growth */
}; };
/*
* 32 SSID chars, max of 4 chars for each SSID char "\xFF", plus NULL.
*/
#define SSID_FMT_BUF_LEN ((4 * IEEE80211_MAX_SSID_LEN) + 1)
#define RSN_FLAGS_SUPPORTED 0x1 /* Flag for rsn_params */
#define RSN_FLAGS_PREAUTH 0x2 /* Flag for WPA2 rsn_params */
/* All the HT-specific default advertised capabilities (including AMPDU) /* All the HT-specific default advertised capabilities (including AMPDU)
* should be grouped here at one place * should be grouped here at one place
*/ */
#define AMPDU_DEF_MPDU_DENSITY 6 /* default mpdu density (110 ==> 4us) */ #define AMPDU_DEF_MPDU_DENSITY 6 /* default mpdu density (110 ==> 4us) */
/* defaults for the HT (MIMO) bss */
#define HT_CAP (IEEE80211_HT_CAP_SM_PS |\
IEEE80211_HT_CAP_SUP_WIDTH_20_40 | IEEE80211_HT_CAP_GRN_FLD |\
IEEE80211_HT_CAP_MAX_AMSDU | IEEE80211_HT_CAP_DSSSCCK40)
/* wlc internal bss_info */ /* wlc internal bss_info */
struct brcms_bss_info { struct brcms_bss_info {
u8 BSSID[ETH_ALEN]; /* network BSSID */ u8 BSSID[ETH_ALEN]; /* network BSSID */
...@@ -202,22 +169,6 @@ struct brcms_bss_info { ...@@ -202,22 +169,6 @@ struct brcms_bss_info {
u8 wpacfg; /* wpa config index */ u8 wpacfg; /* wpa config index */
}; };
/* IOVar flags for common error checks */
#define IOVF_MFG (1<<3) /* flag for mfgtest iovars */
#define IOVF_WHL (1<<4) /* value must be whole (0-max) */
#define IOVF_NTRL (1<<5) /* value must be natural (1-max) */
#define IOVF_SET_UP (1<<6) /* set requires driver be up */
#define IOVF_SET_DOWN (1<<7) /* set requires driver be down */
#define IOVF_SET_CLK (1<<8) /* set requires core clock */
#define IOVF_SET_BAND (1<<9) /* set requires fixed band */
#define IOVF_GET_UP (1<<10) /* get requires driver be up */
#define IOVF_GET_DOWN (1<<11) /* get requires driver be down */
#define IOVF_GET_CLK (1<<12) /* get requires core clock */
#define IOVF_GET_BAND (1<<13) /* get requires fixed band */
#define IOVF_OPEN_ALLOW (1<<14) /* set allowed iovar for opensrc */
#define MAC80211_PROMISC_BCNS (1 << 0) #define MAC80211_PROMISC_BCNS (1 << 0)
#define MAC80211_SCAN (1 << 1) #define MAC80211_SCAN (1 << 1)
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册