Commit 471f1b51 authored by Roland Vossen's avatar Roland Vossen Committed by Greg Kroah-Hartman

staging: brcm80211: renamed structures in softmac

Several structures contained a '_c_' in their name that does not add any
information.
Signed-off-by: default avatarArend van Spriel <arend@broadcom.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
parent 27ef0efb
...@@ -20,8 +20,8 @@ ...@@ -20,8 +20,8 @@
#include "main.h" #include "main.h"
#include "alloc.h" #include "alloc.h"
static struct brcms_c_bsscfg *brcms_c_bsscfg_malloc(uint unit); static struct brcms_bss_cfg *brcms_c_bsscfg_malloc(uint unit);
static void brcms_c_bsscfg_mfree(struct brcms_c_bsscfg *cfg); static void brcms_c_bsscfg_mfree(struct brcms_bss_cfg *cfg);
static struct brcms_pub *brcms_c_pub_malloc(uint unit, static struct brcms_pub *brcms_c_pub_malloc(uint unit,
uint *err, uint devid); uint *err, uint devid);
static void brcms_c_pub_mfree(struct brcms_pub *pub); static void brcms_c_pub_mfree(struct brcms_pub *pub);
...@@ -87,11 +87,11 @@ static void brcms_c_pub_mfree(struct brcms_pub *pub) ...@@ -87,11 +87,11 @@ static void brcms_c_pub_mfree(struct brcms_pub *pub)
kfree(pub); kfree(pub);
} }
static struct brcms_c_bsscfg *brcms_c_bsscfg_malloc(uint unit) static struct brcms_bss_cfg *brcms_c_bsscfg_malloc(uint unit)
{ {
struct brcms_c_bsscfg *cfg; struct brcms_bss_cfg *cfg;
cfg = kzalloc(sizeof(struct brcms_c_bsscfg), GFP_ATOMIC); cfg = kzalloc(sizeof(struct brcms_bss_cfg), GFP_ATOMIC);
if (cfg == NULL) if (cfg == NULL)
goto fail; goto fail;
...@@ -106,7 +106,7 @@ static struct brcms_c_bsscfg *brcms_c_bsscfg_malloc(uint unit) ...@@ -106,7 +106,7 @@ static struct brcms_c_bsscfg *brcms_c_bsscfg_malloc(uint unit)
return NULL; return NULL;
} }
static void brcms_c_bsscfg_mfree(struct brcms_c_bsscfg *cfg) static void brcms_c_bsscfg_mfree(struct brcms_bss_cfg *cfg)
{ {
if (cfg == NULL) if (cfg == NULL)
return; return;
...@@ -117,7 +117,7 @@ static void brcms_c_bsscfg_mfree(struct brcms_c_bsscfg *cfg) ...@@ -117,7 +117,7 @@ static void brcms_c_bsscfg_mfree(struct brcms_c_bsscfg *cfg)
} }
static void brcms_c_bsscfg_ID_assign(struct brcms_c_info *wlc, static void brcms_c_bsscfg_ID_assign(struct brcms_c_info *wlc,
struct brcms_c_bsscfg *bsscfg) struct brcms_bss_cfg *bsscfg)
{ {
bsscfg->ID = wlc->next_bsscfg_ID; bsscfg->ID = wlc->next_bsscfg_ID;
wlc->next_bsscfg_ID++; wlc->next_bsscfg_ID++;
...@@ -144,9 +144,9 @@ struct brcms_c_info *brcms_c_attach_malloc(uint unit, uint *err, uint devid) ...@@ -144,9 +144,9 @@ struct brcms_c_info *brcms_c_attach_malloc(uint unit, uint *err, uint devid)
} }
wlc->pub->wlc = wlc; wlc->pub->wlc = wlc;
/* allocate struct brcms_c_hw_info state structure */ /* allocate struct brcms_hardware state structure */
wlc->hw = kzalloc(sizeof(struct brcms_c_hw_info), GFP_ATOMIC); wlc->hw = kzalloc(sizeof(struct brcms_hardware), GFP_ATOMIC);
if (wlc->hw == NULL) { if (wlc->hw == NULL) {
*err = 1005; *err = 1005;
goto fail; goto fail;
...@@ -154,7 +154,7 @@ struct brcms_c_info *brcms_c_attach_malloc(uint unit, uint *err, uint devid) ...@@ -154,7 +154,7 @@ struct brcms_c_info *brcms_c_attach_malloc(uint unit, uint *err, uint devid)
wlc->hw->wlc = wlc; wlc->hw->wlc = wlc;
wlc->hw->bandstate[0] = wlc->hw->bandstate[0] =
kzalloc(sizeof(struct brcms_c_hwband) * MAXBANDS, GFP_ATOMIC); kzalloc(sizeof(struct brcms_hw_band) * MAXBANDS, GFP_ATOMIC);
if (wlc->hw->bandstate[0] == NULL) { if (wlc->hw->bandstate[0] == NULL) {
*err = 1006; *err = 1006;
goto fail; goto fail;
...@@ -162,9 +162,9 @@ struct brcms_c_info *brcms_c_attach_malloc(uint unit, uint *err, uint devid) ...@@ -162,9 +162,9 @@ struct brcms_c_info *brcms_c_attach_malloc(uint unit, uint *err, uint devid)
int i; int i;
for (i = 1; i < MAXBANDS; i++) { for (i = 1; i < MAXBANDS; i++) {
wlc->hw->bandstate[i] = (struct brcms_c_hwband *) wlc->hw->bandstate[i] = (struct brcms_hw_band *)
((unsigned long)wlc->hw->bandstate[0] + ((unsigned long)wlc->hw->bandstate[0] +
(sizeof(struct brcms_c_hwband) * i)); (sizeof(struct brcms_hw_band) * i));
} }
} }
...@@ -202,21 +202,21 @@ struct brcms_c_info *brcms_c_attach_malloc(uint unit, uint *err, uint devid) ...@@ -202,21 +202,21 @@ struct brcms_c_info *brcms_c_attach_malloc(uint unit, uint *err, uint devid)
} }
} }
wlc->protection = kzalloc(sizeof(struct brcms_c_protection), wlc->protection = kzalloc(sizeof(struct brcms_protection),
GFP_ATOMIC); GFP_ATOMIC);
if (wlc->protection == NULL) { if (wlc->protection == NULL) {
*err = 1016; *err = 1016;
goto fail; goto fail;
} }
wlc->stf = kzalloc(sizeof(struct brcms_c_stf), GFP_ATOMIC); wlc->stf = kzalloc(sizeof(struct brcms_stf), GFP_ATOMIC);
if (wlc->stf == NULL) { if (wlc->stf == NULL) {
*err = 1017; *err = 1017;
goto fail; goto fail;
} }
wlc->bandstate[0] = wlc->bandstate[0] =
kzalloc(sizeof(struct brcms_c_band)*MAXBANDS, GFP_ATOMIC); kzalloc(sizeof(struct brcms_band)*MAXBANDS, GFP_ATOMIC);
if (wlc->bandstate[0] == NULL) { if (wlc->bandstate[0] == NULL) {
*err = 1025; *err = 1025;
goto fail; goto fail;
...@@ -224,13 +224,13 @@ struct brcms_c_info *brcms_c_attach_malloc(uint unit, uint *err, uint devid) ...@@ -224,13 +224,13 @@ struct brcms_c_info *brcms_c_attach_malloc(uint unit, uint *err, uint devid)
int i; int i;
for (i = 1; i < MAXBANDS; i++) { for (i = 1; i < MAXBANDS; i++) {
wlc->bandstate[i] = (struct brcms_c_band *) wlc->bandstate[i] = (struct brcms_band *)
((unsigned long)wlc->bandstate[0] ((unsigned long)wlc->bandstate[0]
+ (sizeof(struct brcms_c_band)*i)); + (sizeof(struct brcms_band)*i));
} }
} }
wlc->corestate = kzalloc(sizeof(struct brcms_c_core), GFP_ATOMIC); wlc->corestate = kzalloc(sizeof(struct brcms_core), GFP_ATOMIC);
if (wlc->corestate == NULL) { if (wlc->corestate == NULL) {
*err = 1026; *err = 1026;
goto fail; goto fail;
......
...@@ -436,7 +436,7 @@ brcms_c_ampdu_tx_operational(struct brcms_c_info *wlc, u8 tid, ...@@ -436,7 +436,7 @@ brcms_c_ampdu_tx_operational(struct brcms_c_info *wlc, u8 tid,
} }
int int
brcms_c_sendampdu(struct ampdu_info *ampdu, struct brcms_c_txq_info *qi, brcms_c_sendampdu(struct ampdu_info *ampdu, struct brcms_txq_info *qi,
struct sk_buff **pdu, int prec) struct sk_buff **pdu, int prec)
{ {
struct brcms_c_info *wlc; struct brcms_c_info *wlc;
...@@ -1204,7 +1204,7 @@ static void dma_cb_fn_ampdu(void *txi, void *arg_a) ...@@ -1204,7 +1204,7 @@ static void dma_cb_fn_ampdu(void *txi, void *arg_a)
void brcms_c_ampdu_flush(struct brcms_c_info *wlc, void brcms_c_ampdu_flush(struct brcms_c_info *wlc,
struct ieee80211_sta *sta, u16 tid) struct ieee80211_sta *sta, u16 tid)
{ {
struct brcms_c_txq_info *qi = wlc->pkt_queue; struct brcms_txq_info *qi = wlc->pkt_queue;
struct pktq *pq = &qi->q; struct pktq *pq = &qi->q;
int prec; int prec;
struct cb_del_ampdu_pars ampdu_pars; struct cb_del_ampdu_pars ampdu_pars;
......
...@@ -20,7 +20,7 @@ ...@@ -20,7 +20,7 @@
extern struct ampdu_info *brcms_c_ampdu_attach(struct brcms_c_info *wlc); extern struct ampdu_info *brcms_c_ampdu_attach(struct brcms_c_info *wlc);
extern void brcms_c_ampdu_detach(struct ampdu_info *ampdu); extern void brcms_c_ampdu_detach(struct ampdu_info *ampdu);
extern int brcms_c_sendampdu(struct ampdu_info *ampdu, extern int brcms_c_sendampdu(struct ampdu_info *ampdu,
struct brcms_c_txq_info *qi, struct brcms_txq_info *qi,
struct sk_buff **aggp, int prec); struct sk_buff **aggp, int prec);
extern void brcms_c_ampdu_dotxstatus(struct ampdu_info *ampdu, struct scb *scb, extern void brcms_c_ampdu_dotxstatus(struct ampdu_info *ampdu, struct scb *scb,
struct sk_buff *p, struct tx_status *txs); struct sk_buff *p, struct tx_status *txs);
......
This diff is collapsed.
...@@ -19,7 +19,7 @@ ...@@ -19,7 +19,7 @@
#include <brcmu_wifi.h> #include <brcmu_wifi.h>
#include "types.h" #include "types.h"
/* dup state between BMAC(struct brcms_c_hw_info) 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 {
u32 machwcap; /* mac hw capibility */ u32 machwcap; /* mac hw capibility */
...@@ -78,97 +78,97 @@ extern int brcms_b_detach(struct brcms_c_info *wlc); ...@@ -78,97 +78,97 @@ extern int brcms_b_detach(struct brcms_c_info *wlc);
extern void brcms_b_watchdog(void *arg); extern void brcms_b_watchdog(void *arg);
/* up/down, reset, clk */ /* up/down, reset, clk */
extern void brcms_b_copyto_objmem(struct brcms_c_hw_info *wlc_hw, extern void brcms_b_copyto_objmem(struct brcms_hardware *wlc_hw,
uint offset, const void *buf, int len, uint offset, const void *buf, int len,
u32 sel); u32 sel);
extern void brcms_b_copyfrom_objmem(struct brcms_c_hw_info *wlc_hw, uint offset, extern void brcms_b_copyfrom_objmem(struct brcms_hardware *wlc_hw, uint offset,
void *buf, int len, u32 sel); void *buf, int len, u32 sel);
#define brcms_b_copyfrom_shm(wlc_hw, offset, buf, len) \ #define brcms_b_copyfrom_shm(wlc_hw, offset, buf, len) \
brcms_b_copyfrom_objmem(wlc_hw, offset, buf, len, OBJADDR_SHM_SEL) brcms_b_copyfrom_objmem(wlc_hw, offset, buf, len, OBJADDR_SHM_SEL)
#define brcms_b_copyto_shm(wlc_hw, offset, buf, len) \ #define brcms_b_copyto_shm(wlc_hw, offset, buf, len) \
brcms_b_copyto_objmem(wlc_hw, offset, buf, len, OBJADDR_SHM_SEL) brcms_b_copyto_objmem(wlc_hw, offset, buf, len, OBJADDR_SHM_SEL)
extern void brcms_b_core_phypll_reset(struct brcms_c_hw_info *wlc_hw); extern void brcms_b_core_phypll_reset(struct brcms_hardware *wlc_hw);
extern void brcms_b_core_phypll_ctl(struct brcms_c_hw_info *wlc_hw, bool on); extern void brcms_b_core_phypll_ctl(struct brcms_hardware *wlc_hw, bool on);
extern void brcms_b_phyclk_fgc(struct brcms_c_hw_info *wlc_hw, bool clk); extern void brcms_b_phyclk_fgc(struct brcms_hardware *wlc_hw, bool clk);
extern void brcms_b_macphyclk_set(struct brcms_c_hw_info *wlc_hw, bool clk); extern void brcms_b_macphyclk_set(struct brcms_hardware *wlc_hw, bool clk);
extern void brcms_b_phy_reset(struct brcms_c_hw_info *wlc_hw); extern void brcms_b_phy_reset(struct brcms_hardware *wlc_hw);
extern void brcms_b_corereset(struct brcms_c_hw_info *wlc_hw, u32 flags); extern void brcms_b_corereset(struct brcms_hardware *wlc_hw, u32 flags);
extern void brcms_b_reset(struct brcms_c_hw_info *wlc_hw); extern void brcms_b_reset(struct brcms_hardware *wlc_hw);
extern void brcms_b_init(struct brcms_c_hw_info *wlc_hw, chanspec_t chanspec, extern void brcms_b_init(struct brcms_hardware *wlc_hw, chanspec_t chanspec,
bool mute); bool mute);
extern int brcms_b_up_prep(struct brcms_c_hw_info *wlc_hw); extern int brcms_b_up_prep(struct brcms_hardware *wlc_hw);
extern int brcms_b_up_finish(struct brcms_c_hw_info *wlc_hw); extern int brcms_b_up_finish(struct brcms_hardware *wlc_hw);
extern int brcms_b_bmac_down_prep(struct brcms_c_hw_info *wlc_hw); extern int brcms_b_bmac_down_prep(struct brcms_hardware *wlc_hw);
extern int brcms_b_down_finish(struct brcms_c_hw_info *wlc_hw); extern int brcms_b_down_finish(struct brcms_hardware *wlc_hw);
extern void brcms_b_switch_macfreq(struct brcms_c_hw_info *wlc_hw, u8 spurmode); extern void brcms_b_switch_macfreq(struct brcms_hardware *wlc_hw, u8 spurmode);
/* chanspec, ucode interface */ /* chanspec, ucode interface */
extern void brcms_b_set_chanspec(struct brcms_c_hw_info *wlc_hw, extern void brcms_b_set_chanspec(struct brcms_hardware *wlc_hw,
chanspec_t chanspec, chanspec_t chanspec,
bool mute, struct txpwr_limits *txpwr); bool mute, struct txpwr_limits *txpwr);
extern int brcms_b_xmtfifo_sz_get(struct brcms_c_hw_info *wlc_hw, uint fifo, extern int brcms_b_xmtfifo_sz_get(struct brcms_hardware *wlc_hw, uint fifo,
uint *blocks); uint *blocks);
extern void brcms_b_mhf(struct brcms_c_hw_info *wlc_hw, u8 idx, u16 mask, extern void brcms_b_mhf(struct brcms_hardware *wlc_hw, u8 idx, u16 mask,
u16 val, int bands); u16 val, int bands);
extern void brcms_b_mctrl(struct brcms_c_hw_info *wlc_hw, u32 mask, u32 val); extern void brcms_b_mctrl(struct brcms_hardware *wlc_hw, u32 mask, u32 val);
extern u16 brcms_b_mhf_get(struct brcms_c_hw_info *wlc_hw, u8 idx, int bands); extern u16 brcms_b_mhf_get(struct brcms_hardware *wlc_hw, u8 idx, int bands);
extern void brcms_b_txant_set(struct brcms_c_hw_info *wlc_hw, u16 phytxant); extern void brcms_b_txant_set(struct brcms_hardware *wlc_hw, u16 phytxant);
extern u16 brcms_b_get_txant(struct brcms_c_hw_info *wlc_hw); extern u16 brcms_b_get_txant(struct brcms_hardware *wlc_hw);
extern void brcms_b_antsel_type_set(struct brcms_c_hw_info *wlc_hw, extern void brcms_b_antsel_type_set(struct brcms_hardware *wlc_hw,
u8 antsel_type); u8 antsel_type);
extern int brcms_b_state_get(struct brcms_c_hw_info *wlc_hw, extern int brcms_b_state_get(struct brcms_hardware *wlc_hw,
struct brcms_b_state *state); struct brcms_b_state *state);
extern void brcms_b_write_shm(struct brcms_c_hw_info *wlc_hw, uint offset, extern void brcms_b_write_shm(struct brcms_hardware *wlc_hw, uint offset,
u16 v); u16 v);
extern u16 brcms_b_read_shm(struct brcms_c_hw_info *wlc_hw, uint offset); extern u16 brcms_b_read_shm(struct brcms_hardware *wlc_hw, uint offset);
extern void brcms_b_write_template_ram(struct brcms_c_hw_info *wlc_hw, extern void brcms_b_write_template_ram(struct brcms_hardware *wlc_hw,
int offset, int len, void *buf); int offset, int len, void *buf);
extern void brcms_b_copyfrom_vars(struct brcms_c_hw_info *wlc_hw, char **buf, extern void brcms_b_copyfrom_vars(struct brcms_hardware *wlc_hw, char **buf,
uint *len); uint *len);
extern void brcms_b_hw_etheraddr(struct brcms_c_hw_info *wlc_hw, extern void brcms_b_hw_etheraddr(struct brcms_hardware *wlc_hw,
u8 *ea); u8 *ea);
extern bool brcms_b_radio_read_hwdisabled(struct brcms_c_hw_info *wlc_hw); extern bool brcms_b_radio_read_hwdisabled(struct brcms_hardware *wlc_hw);
extern void brcms_b_set_shortslot(struct brcms_c_hw_info *wlc_hw, extern void brcms_b_set_shortslot(struct brcms_hardware *wlc_hw,
bool shortslot); bool shortslot);
extern void brcms_b_band_stf_ss_set(struct brcms_c_hw_info *wlc_hw, extern void brcms_b_band_stf_ss_set(struct brcms_hardware *wlc_hw,
u8 stf_mode); u8 stf_mode);
extern void brcms_b_wait_for_wake(struct brcms_c_hw_info *wlc_hw); extern void brcms_b_wait_for_wake(struct brcms_hardware *wlc_hw);
extern void brcms_c_ucode_wake_override_set(struct brcms_c_hw_info *wlc_hw, extern void brcms_c_ucode_wake_override_set(struct brcms_hardware *wlc_hw,
u32 override_bit); u32 override_bit);
extern void brcms_c_ucode_wake_override_clear(struct brcms_c_hw_info *wlc_hw, extern void brcms_c_ucode_wake_override_clear(struct brcms_hardware *wlc_hw,
u32 override_bit); u32 override_bit);
extern void brcms_b_set_addrmatch(struct brcms_c_hw_info *wlc_hw, extern void brcms_b_set_addrmatch(struct brcms_hardware *wlc_hw,
int match_reg_offset, int match_reg_offset,
const u8 *addr); const u8 *addr);
extern void brcms_b_write_hw_bcntemplates(struct brcms_c_hw_info *wlc_hw, extern void brcms_b_write_hw_bcntemplates(struct brcms_hardware *wlc_hw,
void *bcn, int len, bool both); void *bcn, int len, bool both);
extern void brcms_b_read_tsf(struct brcms_c_hw_info *wlc_hw, u32 *tsf_l_ptr, extern void brcms_b_read_tsf(struct brcms_hardware *wlc_hw, u32 *tsf_l_ptr,
u32 *tsf_h_ptr); u32 *tsf_h_ptr);
extern void brcms_b_set_cwmin(struct brcms_c_hw_info *wlc_hw, u16 newmin); extern void brcms_b_set_cwmin(struct brcms_hardware *wlc_hw, u16 newmin);
extern void brcms_b_set_cwmax(struct brcms_c_hw_info *wlc_hw, u16 newmax); extern void brcms_b_set_cwmax(struct brcms_hardware *wlc_hw, u16 newmax);
extern void brcms_b_retrylimit_upd(struct brcms_c_hw_info *wlc_hw, u16 SRL, extern void brcms_b_retrylimit_upd(struct brcms_hardware *wlc_hw, u16 SRL,
u16 LRL); u16 LRL);
extern void brcms_b_fifoerrors(struct brcms_c_hw_info *wlc_hw); extern void brcms_b_fifoerrors(struct brcms_hardware *wlc_hw);
/* API for BMAC driver (e.g. wlc_phy.c etc) */ /* API for BMAC driver (e.g. wlc_phy.c etc) */
extern void brcms_b_bw_set(struct brcms_c_hw_info *wlc_hw, u16 bw); extern void brcms_b_bw_set(struct brcms_hardware *wlc_hw, u16 bw);
extern void brcms_b_pllreq(struct brcms_c_hw_info *wlc_hw, bool set, extern void brcms_b_pllreq(struct brcms_hardware *wlc_hw, bool set,
mbool req_bit); mbool req_bit);
extern void brcms_b_hw_up(struct brcms_c_hw_info *wlc_hw); extern void brcms_b_hw_up(struct brcms_hardware *wlc_hw);
extern u16 brcms_b_rate_shm_offset(struct brcms_c_hw_info *wlc_hw, u8 rate); extern u16 brcms_b_rate_shm_offset(struct brcms_hardware *wlc_hw, u8 rate);
extern void brcms_b_antsel_set(struct brcms_c_hw_info *wlc_hw, extern void brcms_b_antsel_set(struct brcms_hardware *wlc_hw,
u32 antsel_avail); u32 antsel_avail);
#endif /* _BRCM_BOTTOM_MAC_H_ */ #endif /* _BRCM_BOTTOM_MAC_H_ */
...@@ -869,7 +869,7 @@ brcms_c_channels_init(struct brcms_cm_info *wlc_cm, ...@@ -869,7 +869,7 @@ brcms_c_channels_init(struct brcms_cm_info *wlc_cm,
{ {
struct brcms_c_info *wlc = wlc_cm->wlc; struct brcms_c_info *wlc = wlc_cm->wlc;
uint i, j; uint i, j;
struct brcms_c_band *band; struct brcms_band *band;
const struct locale_info *li; const struct locale_info *li;
chanvec_t sup_chan; chanvec_t sup_chan;
const struct locale_mimo_info *li_mimo; const struct locale_mimo_info *li_mimo;
...@@ -970,7 +970,7 @@ static void brcms_c_quiet_channels_reset(struct brcms_cm_info *wlc_cm) ...@@ -970,7 +970,7 @@ static void brcms_c_quiet_channels_reset(struct brcms_cm_info *wlc_cm)
{ {
struct brcms_c_info *wlc = wlc_cm->wlc; struct brcms_c_info *wlc = wlc_cm->wlc;
uint i, j; uint i, j;
struct brcms_c_band *band; struct brcms_band *band;
const chanvec_t *chanvec; const chanvec_t *chanvec;
memset(&wlc_cm->quiet_channels, 0, sizeof(chanvec_t)); memset(&wlc_cm->quiet_channels, 0, sizeof(chanvec_t));
...@@ -1262,7 +1262,7 @@ brcms_c_channel_reg_limits(struct brcms_cm_info *wlc_cm, chanspec_t chanspec, ...@@ -1262,7 +1262,7 @@ brcms_c_channel_reg_limits(struct brcms_cm_info *wlc_cm, chanspec_t chanspec,
int maxpwr; int maxpwr;
int delta; int delta;
const struct country_info *country; const struct country_info *country;
struct brcms_c_band *band; struct brcms_band *band;
const struct locale_info *li; const struct locale_info *li;
int conducted_max; int conducted_max;
int conducted_ofdm_max; int conducted_ofdm_max;
......
This diff is collapsed.
...@@ -73,13 +73,6 @@ ...@@ -73,13 +73,6 @@
(((val) & (~(field ## _M << field ## _S))) | \ (((val) & (~(field ## _M << field ## _S))) | \
((unsigned)(bits) << field ## _S)) ((unsigned)(bits) << field ## _S))
/* For managing scan result lists */
struct brcms_c_bss_list {
uint count;
bool beacon; /* set for beacon, cleared for probe response */
struct brcms_bss_info *ptrs[MAXBSS];
};
#define SW_TIMER_MAC_STAT_UPD 30 /* periodic MAC stats update */ #define SW_TIMER_MAC_STAT_UPD 30 /* periodic MAC stats update */
/* Double check that unsupported cores are not enabled */ /* Double check that unsupported cores are not enabled */
...@@ -236,7 +229,7 @@ extern const u8 prio2fifo[]; ...@@ -236,7 +229,7 @@ extern const u8 prio2fifo[];
#define WLCWLUNIT(wlc) ((wlc)->pub->unit) #define WLCWLUNIT(wlc) ((wlc)->pub->unit)
struct brcms_c_protection { struct brcms_protection {
bool _g; /* use g spec protection, driver internal */ bool _g; /* use g spec protection, driver internal */
s8 g_override; /* override for use of g spec protection */ s8 g_override; /* override for use of g spec protection */
u8 gmode_user; /* user config gmode, operating band->gmode is different */ u8 gmode_user; /* user config gmode, operating band->gmode is different */
...@@ -251,7 +244,7 @@ struct brcms_c_protection { ...@@ -251,7 +244,7 @@ struct brcms_c_protection {
}; };
/* anything affects the single/dual streams/antenna operation */ /* anything affects the single/dual streams/antenna operation */
struct brcms_c_stf { struct brcms_stf {
u8 hw_txchain; /* HW txchain bitmap cfg */ u8 hw_txchain; /* HW txchain bitmap cfg */
u8 txchain; /* txchain bitmap being used */ u8 txchain; /* txchain bitmap being used */
u8 txstreams; /* number of txchains being used */ u8 txstreams; /* number of txchains being used */
...@@ -348,7 +341,7 @@ struct wsec_key { ...@@ -348,7 +341,7 @@ struct wsec_key {
/* /*
* core state (mac) * core state (mac)
*/ */
struct brcms_c_core { struct brcms_core {
uint coreidx; /* # sb enumerated core */ uint coreidx; /* # sb enumerated core */
/* fifo */ /* fifo */
...@@ -361,7 +354,7 @@ struct brcms_c_core { ...@@ -361,7 +354,7 @@ struct brcms_c_core {
/* /*
* band state (phy+ana+radio) * band state (phy+ana+radio)
*/ */
struct brcms_c_band { struct brcms_band {
int bandtype; /* WLC_BAND_2G, WLC_BAND_5G */ int bandtype; /* WLC_BAND_2G, WLC_BAND_5G */
uint bandunit; /* bandstate[] index */ uint bandunit; /* bandstate[] index */
...@@ -450,19 +443,19 @@ struct brcms_c_if { ...@@ -450,19 +443,19 @@ struct brcms_c_if {
*/ */
u8 flags; /* flags for the interface */ u8 flags; /* flags for the interface */
struct brcms_if *wlif; /* pointer to wlif */ struct brcms_if *wlif; /* pointer to wlif */
struct brcms_c_txq_info *qi; /* pointer to associated tx queue */ struct brcms_txq_info *qi; /* pointer to associated tx queue */
union { union {
/* pointer to scb if WLC_IFTYPE_WDS */ /* pointer to scb if WLC_IFTYPE_WDS */
struct scb *scb; struct scb *scb;
/* pointer to bsscfg if WLC_IFTYPE_BSS */ /* pointer to bsscfg if WLC_IFTYPE_BSS */
struct brcms_c_bsscfg *bsscfg; struct brcms_bss_cfg *bsscfg;
} u; } u;
}; };
/* flags for the interface, this interface is linked to a brcms_if */ /* flags for the interface, this interface is linked to a brcms_if */
#define WLC_IF_LINKED 0x02 #define WLC_IF_LINKED 0x02
struct brcms_c_hwband { struct brcms_hw_band {
int bandtype; /* WLC_BAND_2G, WLC_BAND_5G */ int bandtype; /* WLC_BAND_2G, WLC_BAND_5G */
uint bandunit; /* bandstate[] index */ uint bandunit; /* bandstate[] index */
u16 mhfs[MHFMAX]; /* MHF array shadow */ u16 mhfs[MHFMAX]; /* MHF array shadow */
...@@ -479,7 +472,7 @@ struct brcms_c_hwband { ...@@ -479,7 +472,7 @@ struct brcms_c_hwband {
bool abgphy_encore; bool abgphy_encore;
}; };
struct brcms_c_hw_info { struct brcms_hardware {
bool _piomode; /* true if pio mode */ bool _piomode; /* true if pio mode */
struct brcms_c_info *wlc; struct brcms_c_info *wlc;
...@@ -506,9 +499,9 @@ struct brcms_c_hw_info { ...@@ -506,9 +499,9 @@ struct brcms_c_hw_info {
d11regs_t *regs; /* pointer to device registers */ d11regs_t *regs; /* pointer to device registers */
void *physhim; /* phy shim layer handler */ void *physhim; /* phy shim layer handler */
void *phy_sh; /* pointer to shared phy state */ void *phy_sh; /* pointer to shared phy state */
struct brcms_c_hwband *band;/* pointer to active per-band state */ struct brcms_hw_band *band;/* pointer to active per-band state */
/* band state per phy/radio */ /* band state per phy/radio */
struct brcms_c_hwband *bandstate[MAXBANDS]; struct brcms_hw_band *bandstate[MAXBANDS];
u16 bmac_phytxant; /* cache of high phytxant state */ u16 bmac_phytxant; /* cache of high phytxant state */
bool shortslot; /* currently using 11g ShortSlot timing */ bool shortslot; /* currently using 11g ShortSlot timing */
u16 SRL; /* 802.11 dot11ShortRetryLimit */ u16 SRL; /* 802.11 dot11ShortRetryLimit */
...@@ -561,8 +554,8 @@ struct brcms_c_hw_info { ...@@ -561,8 +554,8 @@ struct brcms_c_hw_info {
* if they belong to the same flow of traffic from the device. For multi-channel * if they belong to the same flow of traffic from the device. For multi-channel
* operation there are independent TX Queues for each channel. * operation there are independent TX Queues for each channel.
*/ */
struct brcms_c_txq_info { struct brcms_txq_info {
struct brcms_c_txq_info *next; struct brcms_txq_info *next;
struct pktq q; struct pktq q;
uint stopped; /* tx flow control bits */ uint stopped; /* tx flow control bits */
}; };
...@@ -576,7 +569,7 @@ struct brcms_c_info { ...@@ -576,7 +569,7 @@ struct brcms_c_info {
d11regs_t *regs; /* pointer to device registers */ d11regs_t *regs; /* pointer to device registers */
/* HW related state used primarily by BMAC */ /* HW related state used primarily by BMAC */
struct brcms_c_hw_info *hw; struct brcms_hardware *hw;
/* clock */ /* clock */
int clkreq_override; /* setting for clkreq for PCIE : Auto, 0, 1 */ int clkreq_override; /* setting for clkreq for PCIE : Auto, 0, 1 */
...@@ -593,11 +586,11 @@ struct brcms_c_info { ...@@ -593,11 +586,11 @@ struct brcms_c_info {
bool clk; /* core is out of reset and has clock */ bool clk; /* core is out of reset and has clock */
/* multiband */ /* multiband */
struct brcms_c_core *core; /* pointer to active io core */ struct brcms_core *core; /* pointer to active io core */
struct brcms_c_band *band; /* pointer to active per-band state */ struct brcms_band *band; /* pointer to active per-band state */
struct brcms_c_core *corestate; /* per-core state (one per hw core) */ struct brcms_core *corestate; /* per-core state (one per hw core) */
/* per-band state (one per phy/radio): */ /* per-band state (one per phy/radio): */
struct brcms_c_band *bandstate[MAXBANDS]; struct brcms_band *bandstate[MAXBANDS];
bool war16165; /* PCI slow clock 16165 war flag */ bool war16165; /* PCI slow clock 16165 war flag */
...@@ -680,11 +673,11 @@ struct brcms_c_info { ...@@ -680,11 +673,11 @@ struct brcms_c_info {
* BSS Configurations set of BSS configurations, idx 0 is default and * BSS Configurations set of BSS configurations, idx 0 is default and
* always valid * always valid
*/ */
struct brcms_c_bsscfg *bsscfg[WLC_MAXBSSCFG]; struct brcms_bss_cfg *bsscfg[WLC_MAXBSSCFG];
struct brcms_c_bsscfg *cfg; /* the primary bsscfg (can be AP or STA) */ struct brcms_bss_cfg *cfg; /* the primary bsscfg (can be AP or STA) */
/* tx queue */ /* tx queue */
struct brcms_c_txq_info *tx_queues; /* common TX Queue list */ struct brcms_txq_info *tx_queues; /* common TX Queue list */
/* security */ /* security */
struct wsec_key *wsec_keys[WSEC_MAX_KEYS]; /* dynamic key storage */ struct wsec_key *wsec_keys[WSEC_MAX_KEYS]; /* dynamic key storage */
...@@ -737,10 +730,10 @@ struct brcms_c_info { ...@@ -737,10 +730,10 @@ struct brcms_c_info {
s8 shortslot_override; /* 11g ShortSlot override */ s8 shortslot_override; /* 11g ShortSlot override */
bool include_legacy_erp; /* include Legacy ERP info elt ID 47 as well as g ID 42 */ bool include_legacy_erp; /* include Legacy ERP info elt ID 47 as well as g ID 42 */
struct brcms_c_protection *protection; struct brcms_protection *protection;
s8 PLCPHdr_override; /* 802.11b Preamble Type override */ s8 PLCPHdr_override; /* 802.11b Preamble Type override */
struct brcms_c_stf *stf; struct brcms_stf *stf;
ratespec_t bcn_rspec; /* save bcn ratespec purpose */ ratespec_t bcn_rspec; /* save bcn ratespec purpose */
...@@ -751,7 +744,7 @@ struct brcms_c_info { ...@@ -751,7 +744,7 @@ struct brcms_c_info {
u16 next_bsscfg_ID; u16 next_bsscfg_ID;
struct brcms_c_txq_info *pkt_queue; /* txq for transmit packets */ struct brcms_txq_info *pkt_queue; /* txq for transmit packets */
u32 mpc_dur; /* total time (ms) in mpc mode except for the u32 mpc_dur; /* total time (ms) in mpc mode except for the
* portion since radio is turned off last time * portion since radio is turned off last time
*/ */
...@@ -775,7 +768,7 @@ struct antsel_info { ...@@ -775,7 +768,7 @@ struct antsel_info {
}; };
/* BSS configuration state */ /* BSS configuration state */
struct brcms_c_bsscfg { struct brcms_bss_cfg {
struct brcms_c_info *wlc; /* wlc to which this bsscfg belongs to. */ struct brcms_c_info *wlc; /* wlc to which this bsscfg belongs to. */
bool up; /* is this configuration up operational */ bool up; /* is this configuration up operational */
bool enable; /* is this configuration enabled */ bool enable; /* is this configuration enabled */
...@@ -906,8 +899,8 @@ extern void brcms_c_print_txdesc(struct d11txh *txh); ...@@ -906,8 +899,8 @@ extern void brcms_c_print_txdesc(struct d11txh *txh);
#define brcms_c_print_txdesc(a) #define brcms_c_print_txdesc(a)
#endif #endif
extern void brcms_c_setxband(struct brcms_c_hw_info *wlc_hw, uint bandunit); extern void brcms_c_setxband(struct brcms_hardware *wlc_hw, uint bandunit);
extern void brcms_c_coredisable(struct brcms_c_hw_info *wlc_hw); extern void brcms_c_coredisable(struct brcms_hardware *wlc_hw);
extern bool brcms_c_valid_rate(struct brcms_c_info *wlc, ratespec_t rate, extern bool brcms_c_valid_rate(struct brcms_c_info *wlc, ratespec_t rate,
int band, bool verbose); int band, bool verbose);
...@@ -915,7 +908,7 @@ extern void brcms_c_ap_upd(struct brcms_c_info *wlc); ...@@ -915,7 +908,7 @@ extern void brcms_c_ap_upd(struct brcms_c_info *wlc);
/* helper functions */ /* helper functions */
extern void brcms_c_shm_ssid_upd(struct brcms_c_info *wlc, extern void brcms_c_shm_ssid_upd(struct brcms_c_info *wlc,
struct brcms_c_bsscfg *cfg); struct brcms_bss_cfg *cfg);
extern int brcms_c_set_gmode(struct brcms_c_info *wlc, u8 gmode, bool config); extern int brcms_c_set_gmode(struct brcms_c_info *wlc, u8 gmode, bool config);
extern void brcms_c_mac_bcn_promisc_change(struct brcms_c_info *wlc, extern void brcms_c_mac_bcn_promisc_change(struct brcms_c_info *wlc,
...@@ -923,13 +916,13 @@ extern void brcms_c_mac_bcn_promisc_change(struct brcms_c_info *wlc, ...@@ -923,13 +916,13 @@ extern void brcms_c_mac_bcn_promisc_change(struct brcms_c_info *wlc,
extern void brcms_c_mac_bcn_promisc(struct brcms_c_info *wlc); extern void brcms_c_mac_bcn_promisc(struct brcms_c_info *wlc);
extern void brcms_c_mac_promisc(struct brcms_c_info *wlc); extern void brcms_c_mac_promisc(struct brcms_c_info *wlc);
extern void brcms_c_txflowcontrol(struct brcms_c_info *wlc, extern void brcms_c_txflowcontrol(struct brcms_c_info *wlc,
struct brcms_c_txq_info *qi, struct brcms_txq_info *qi,
bool on, int prio); bool on, int prio);
extern void brcms_c_txflowcontrol_override(struct brcms_c_info *wlc, extern void brcms_c_txflowcontrol_override(struct brcms_c_info *wlc,
struct brcms_c_txq_info *qi, struct brcms_txq_info *qi,
bool on, uint override); bool on, uint override);
extern bool brcms_c_txflowcontrol_prio_isset(struct brcms_c_info *wlc, extern bool brcms_c_txflowcontrol_prio_isset(struct brcms_c_info *wlc,
struct brcms_c_txq_info *qi, struct brcms_txq_info *qi,
int prio); int prio);
extern void brcms_c_send_q(struct brcms_c_info *wlc); extern void brcms_c_send_q(struct brcms_c_info *wlc);
extern int brcms_c_prep_pdu(struct brcms_c_info *wlc, struct sk_buff *pdu, extern int brcms_c_prep_pdu(struct brcms_c_info *wlc, struct sk_buff *pdu,
...@@ -948,12 +941,12 @@ extern u16 brcms_c_compute_rtscts_dur(struct brcms_c_info *wlc, bool cts_only, ...@@ -948,12 +941,12 @@ extern u16 brcms_c_compute_rtscts_dur(struct brcms_c_info *wlc, bool cts_only,
bool ba); bool ba);
extern void brcms_c_tbtt(struct brcms_c_info *wlc); extern void brcms_c_tbtt(struct brcms_c_info *wlc);
extern void brcms_c_inval_dma_pkts(struct brcms_c_hw_info *hw, extern void brcms_c_inval_dma_pkts(struct brcms_hardware *hw,
struct ieee80211_sta *sta, struct ieee80211_sta *sta,
void (*dma_callback_fn)); void (*dma_callback_fn));
extern void brcms_c_reprate_init(struct brcms_c_info *wlc); extern void brcms_c_reprate_init(struct brcms_c_info *wlc);
extern void brcms_c_bsscfg_reprate_init(struct brcms_c_bsscfg *bsscfg); extern void brcms_c_bsscfg_reprate_init(struct brcms_bss_cfg *bsscfg);
/* Shared memory access */ /* Shared memory access */
extern void brcms_c_write_shm(struct brcms_c_info *wlc, uint offset, u16 v); extern void brcms_c_write_shm(struct brcms_c_info *wlc, uint offset, u16 v);
...@@ -963,11 +956,11 @@ extern void brcms_c_copyto_shm(struct brcms_c_info *wlc, uint offset, ...@@ -963,11 +956,11 @@ extern void brcms_c_copyto_shm(struct brcms_c_info *wlc, uint offset,
extern void brcms_c_update_beacon(struct brcms_c_info *wlc); extern void brcms_c_update_beacon(struct brcms_c_info *wlc);
extern void brcms_c_bss_update_beacon(struct brcms_c_info *wlc, extern void brcms_c_bss_update_beacon(struct brcms_c_info *wlc,
struct brcms_c_bsscfg *bsscfg); struct brcms_bss_cfg *bsscfg);
extern void brcms_c_update_probe_resp(struct brcms_c_info *wlc, bool suspend); extern void brcms_c_update_probe_resp(struct brcms_c_info *wlc, bool suspend);
extern void brcms_c_bss_update_probe_resp(struct brcms_c_info *wlc, extern void brcms_c_bss_update_probe_resp(struct brcms_c_info *wlc,
struct brcms_c_bsscfg *cfg, struct brcms_bss_cfg *cfg,
bool suspend); bool suspend);
extern bool brcms_c_ismpc(struct brcms_c_info *wlc); extern bool brcms_c_ismpc(struct brcms_c_info *wlc);
extern bool brcms_c_is_non_delay_mpc(struct brcms_c_info *wlc); extern bool brcms_c_is_non_delay_mpc(struct brcms_c_info *wlc);
...@@ -990,15 +983,15 @@ extern bool brcms_c_timers_init(struct brcms_c_info *wlc, int unit); ...@@ -990,15 +983,15 @@ extern bool brcms_c_timers_init(struct brcms_c_info *wlc, int unit);
extern int brcms_c_set_nmode(struct brcms_c_info *wlc, s32 nmode); extern int brcms_c_set_nmode(struct brcms_c_info *wlc, s32 nmode);
extern void brcms_c_mimops_action_ht_send(struct brcms_c_info *wlc, extern void brcms_c_mimops_action_ht_send(struct brcms_c_info *wlc,
struct brcms_c_bsscfg *bsscfg, struct brcms_bss_cfg *bsscfg,
u8 mimops_mode); u8 mimops_mode);
extern void brcms_c_switch_shortslot(struct brcms_c_info *wlc, bool shortslot); extern void brcms_c_switch_shortslot(struct brcms_c_info *wlc, bool shortslot);
extern void brcms_c_set_bssid(struct brcms_c_bsscfg *cfg); extern void brcms_c_set_bssid(struct brcms_bss_cfg *cfg);
extern void brcms_c_edcf_setparams(struct brcms_c_info *wlc, bool suspend); extern void brcms_c_edcf_setparams(struct brcms_c_info *wlc, bool suspend);
extern void brcms_c_set_ratetable(struct brcms_c_info *wlc); extern void brcms_c_set_ratetable(struct brcms_c_info *wlc);
extern int brcms_c_set_mac(struct brcms_c_bsscfg *cfg); extern int brcms_c_set_mac(struct brcms_bss_cfg *cfg);
extern void brcms_c_beacon_phytxctl_txant_upd(struct brcms_c_info *wlc, extern void brcms_c_beacon_phytxctl_txant_upd(struct brcms_c_info *wlc,
ratespec_t bcn_rate); ratespec_t bcn_rate);
extern void brcms_c_mod_prb_rsp_rate_table(struct brcms_c_info *wlc, extern void brcms_c_mod_prb_rsp_rate_table(struct brcms_c_info *wlc,
......
...@@ -30,12 +30,12 @@ ...@@ -30,12 +30,12 @@
/* PHY SHIM module specific state */ /* PHY SHIM module specific state */
struct phy_shim_info { struct phy_shim_info {
struct brcms_c_hw_info *wlc_hw; /* pointer to main wlc_hw structure */ struct brcms_hardware *wlc_hw; /* pointer to main wlc_hw structure */
void *wlc; /* pointer to main wlc structure */ void *wlc; /* pointer to main wlc structure */
void *wl; /* pointer to os-specific private state */ void *wl; /* pointer to os-specific private state */
}; };
struct phy_shim_info *wlc_phy_shim_attach(struct brcms_c_hw_info *wlc_hw, struct phy_shim_info *wlc_phy_shim_attach(struct brcms_hardware *wlc_hw,
void *wl, void *wlc) { void *wl, void *wlc) {
struct phy_shim_info *physhim = NULL; struct phy_shim_info *physhim = NULL;
......
...@@ -108,7 +108,7 @@ ...@@ -108,7 +108,7 @@
#define WLC_N_TXRX_CHAIN0 0 #define WLC_N_TXRX_CHAIN0 0
#define WLC_N_TXRX_CHAIN1 1 #define WLC_N_TXRX_CHAIN1 1
extern struct phy_shim_info *wlc_phy_shim_attach(struct brcms_c_hw_info *wlc_hw, extern struct phy_shim_info *wlc_phy_shim_attach(struct brcms_hardware *wlc_hw,
void *wl, void *wlc); void *wl, void *wlc);
extern void wlc_phy_shim_detach(struct phy_shim_info *physhim); extern void wlc_phy_shim_detach(struct phy_shim_info *physhim);
......
...@@ -290,7 +290,7 @@ int brcms_c_stf_txchain_set(struct brcms_c_info *wlc, s32 int_val, bool force) ...@@ -290,7 +290,7 @@ int brcms_c_stf_txchain_set(struct brcms_c_info *wlc, s32 int_val, bool force)
} }
/* update wlc->stf->ss_opmode which represents the operational stf_ss mode we're using */ /* update wlc->stf->ss_opmode which represents the operational stf_ss mode we're using */
int brcms_c_stf_ss_update(struct brcms_c_info *wlc, struct brcms_c_band *band) int brcms_c_stf_ss_update(struct brcms_c_info *wlc, struct brcms_band *band)
{ {
int ret_code = 0; int ret_code = 0;
u8 prev_stf_ss; u8 prev_stf_ss;
......
...@@ -27,7 +27,7 @@ extern void brcms_c_stf_ss_algo_channel_get(struct brcms_c_info *wlc, ...@@ -27,7 +27,7 @@ extern void brcms_c_stf_ss_algo_channel_get(struct brcms_c_info *wlc,
u16 *ss_algo_channel, u16 *ss_algo_channel,
chanspec_t chanspec); chanspec_t chanspec);
extern int brcms_c_stf_ss_update(struct brcms_c_info *wlc, extern int brcms_c_stf_ss_update(struct brcms_c_info *wlc,
struct brcms_c_band *band); struct brcms_band *band);
extern void brcms_c_stf_phy_txant_upd(struct brcms_c_info *wlc); extern void brcms_c_stf_phy_txant_upd(struct brcms_c_info *wlc);
extern int brcms_c_stf_txchain_set(struct brcms_c_info *wlc, s32 int_val, extern int brcms_c_stf_txchain_set(struct brcms_c_info *wlc, s32 int_val,
bool force); bool force);
......
...@@ -358,12 +358,12 @@ struct ieee80211_sta; ...@@ -358,12 +358,12 @@ struct ieee80211_sta;
struct ieee80211_tx_queue_params; struct ieee80211_tx_queue_params;
struct brcms_info; struct brcms_info;
struct brcms_c_info; struct brcms_c_info;
struct brcms_c_hw_info; struct brcms_hardware;
struct brcms_c_if; struct brcms_c_if;
struct brcmu_iovar; struct brcmu_iovar;
struct brcmu_strbuf; struct brcmu_strbuf;
struct brcms_c_txq_info; struct brcms_txq_info;
struct brcms_c_band; struct brcms_band;
struct dma_pub; struct dma_pub;
struct si_pub; struct si_pub;
struct tx_status; struct tx_status;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment