diff options
author | Roland Vossen | 2011-07-06 00:02:38 +0200 |
---|---|---|
committer | Greg Kroah-Hartman | 2011-07-06 04:47:48 +0200 |
commit | cc87568a0f94e907d357e041fcbff4f8aaccbd8c (patch) | |
tree | f6990319a039b7bc2eb15bdc5abbc7f26fb0b0b1 /drivers/staging/brcm80211/brcmsmac/phy | |
parent | staging: brcm80211: removed remains of assert mechanism in fullmac (diff) | |
download | kernel-qcow2-linux-cc87568a0f94e907d357e041fcbff4f8aaccbd8c.tar.gz kernel-qcow2-linux-cc87568a0f94e907d357e041fcbff4f8aaccbd8c.tar.xz kernel-qcow2-linux-cc87568a0f94e907d357e041fcbff4f8aaccbd8c.zip |
staging: brcm80211: replaced various typedefs in softmac
typedefs are undesirable according to documentation/CodingStyle.
Signed-off-by: Arend van Spriel <arend@broadcom.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/staging/brcm80211/brcmsmac/phy')
-rw-r--r-- | drivers/staging/brcm80211/brcmsmac/phy/phy_cmn.c | 32 | ||||
-rw-r--r-- | drivers/staging/brcm80211/brcmsmac/phy/phy_hal.h | 6 | ||||
-rw-r--r-- | drivers/staging/brcm80211/brcmsmac/phy/phy_int.h | 85 | ||||
-rw-r--r-- | drivers/staging/brcm80211/brcmsmac/phy/phy_lcn.c | 239 | ||||
-rw-r--r-- | drivers/staging/brcm80211/brcmsmac/phy/phy_lcn.h | 2 | ||||
-rw-r--r-- | drivers/staging/brcm80211/brcmsmac/phy/phy_n.c | 293 | ||||
-rw-r--r-- | drivers/staging/brcm80211/brcmsmac/phy/phytbl_lcn.c | 29 | ||||
-rw-r--r-- | drivers/staging/brcm80211/brcmsmac/phy/phytbl_lcn.h | 28 | ||||
-rw-r--r-- | drivers/staging/brcm80211/brcmsmac/phy/phytbl_n.c | 18 | ||||
-rw-r--r-- | drivers/staging/brcm80211/brcmsmac/phy/phytbl_n.h | 8 |
10 files changed, 374 insertions, 366 deletions
diff --git a/drivers/staging/brcm80211/brcmsmac/phy/phy_cmn.c b/drivers/staging/brcm80211/brcmsmac/phy/phy_cmn.c index b527e5f0fac0..57195a5f160d 100644 --- a/drivers/staging/brcm80211/brcmsmac/phy/phy_cmn.c +++ b/drivers/staging/brcm80211/brcmsmac/phy/phy_cmn.c @@ -29,13 +29,12 @@ u32 phyhal_msg_level = PHYHAL_ERROR; -typedef struct _chan_info_basic { +struct chan_info_basic { u16 chan; u16 freq; -} chan_info_basic_t; - -static chan_info_basic_t chan_info_all[] = { +}; +static struct chan_info_basic chan_info_all[] = { {1, 2412}, {2, 2417}, {3, 2422}, @@ -469,11 +468,11 @@ static void WLBANDINITFN(wlc_set_phy_uninitted) (phy_info_t *pi) } } -shared_phy_t *wlc_phy_shared_attach(shared_phy_params_t *shp) +struct shared_phy *wlc_phy_shared_attach(struct shared_phy_params *shp) { - shared_phy_t *sh; + struct shared_phy *sh; - sh = kzalloc(sizeof(shared_phy_t), GFP_ATOMIC); + sh = kzalloc(sizeof(struct shared_phy), GFP_ATOMIC); if (sh == NULL) { return NULL; } @@ -506,7 +505,7 @@ shared_phy_t *wlc_phy_shared_attach(shared_phy_params_t *shp) return sh; } -wlc_phy_t *wlc_phy_attach(shared_phy_t *sh, void *regs, int bandtype, +wlc_phy_t *wlc_phy_attach(struct shared_phy *sh, void *regs, int bandtype, char *vars, struct wiphy *wiphy) { phy_info_t *pi; @@ -998,7 +997,7 @@ void wlc_phy_table_data_write(phy_info_t *pi, uint width, u32 val) } void -wlc_phy_write_table(phy_info_t *pi, const phytbl_info_t *ptbl_info, +wlc_phy_write_table(phy_info_t *pi, const struct phytbl_info *ptbl_info, u16 tblAddr, u16 tblDataHi, u16 tblDataLo) { uint idx; @@ -1038,7 +1037,7 @@ wlc_phy_write_table(phy_info_t *pi, const phytbl_info_t *ptbl_info, } void -wlc_phy_read_table(phy_info_t *pi, const phytbl_info_t *ptbl_info, +wlc_phy_read_table(phy_info_t *pi, const struct phytbl_info *ptbl_info, u16 tblAddr, u16 tblDataHi, u16 tblDataLo) { uint idx; @@ -1076,7 +1075,8 @@ wlc_phy_read_table(phy_info_t *pi, const phytbl_info_t *ptbl_info, } uint -wlc_phy_init_radio_regs_allbands(phy_info_t *pi, radio_20xx_regs_t *radioregs) +wlc_phy_init_radio_regs_allbands(phy_info_t *pi, + struct radio_20xx_regs *radioregs) { uint i = 0; @@ -1093,7 +1093,7 @@ wlc_phy_init_radio_regs_allbands(phy_info_t *pi, radio_20xx_regs_t *radioregs) } uint -wlc_phy_init_radio_regs(phy_info_t *pi, radio_regs_t *radioregs, +wlc_phy_init_radio_regs(phy_info_t *pi, struct radio_regs *radioregs, u16 core_offset) { uint i = 0; @@ -2440,7 +2440,7 @@ wlc_phy_noise_sample_request(wlc_phy_t *pih, u8 reason, u8 ch) OR_REG(&pi->regs->maccommand, MCMD_BG_NOISE); } else { - phy_iq_est_t est[PHY_CORE_MAX]; + struct phy_iq_est est[PHY_CORE_MAX]; u32 cmplx_pwr[PHY_CORE_MAX]; s8 noise_dbm_ant[PHY_CORE_MAX]; u16 log_num_samps, num_samps, classif_state = 0; @@ -2675,8 +2675,8 @@ void wlc_phy_compute_dB(u32 *cmplx_pwr, s8 *p_cmplx_pwr_dB, u8 core) void wlc_phy_rssi_compute(wlc_phy_t *pih, void *ctx) { - wlc_d11rxhdr_t *wlc_rxhdr = (wlc_d11rxhdr_t *) ctx; - d11rxhdr_t *rxh = &wlc_rxhdr->rxhdr; + struct brcms_d11rxhdr *wlc_rxhdr = (struct brcms_d11rxhdr *) ctx; + struct d11rxhdr *rxh = &wlc_rxhdr->rxhdr; int rssi = le16_to_cpu(rxh->PhyRxStatus_1) & PRXS1_JSSI_MASK; uint radioid = pih->radioid; phy_info_t *pi = (phy_info_t *) pih; @@ -2694,7 +2694,7 @@ void wlc_phy_rssi_compute(wlc_phy_t *pih, void *ctx) if (ISLCNPHY(pi)) { u8 gidx = (le16_to_cpu(rxh->PhyRxStatus_2) & 0xFC00) >> 10; - phy_info_lcnphy_t *pi_lcn = pi->u.pi_lcnphy; + struct phy_info_lcnphy *pi_lcn = pi->u.pi_lcnphy; if (rssi > 127) rssi -= 256; diff --git a/drivers/staging/brcm80211/brcmsmac/phy/phy_hal.h b/drivers/staging/brcm80211/brcmsmac/phy/phy_hal.h index 0ea337be846b..d1d03a624ef0 100644 --- a/drivers/staging/brcm80211/brcmsmac/phy/phy_hal.h +++ b/drivers/staging/brcm80211/brcmsmac/phy/phy_hal.h @@ -176,9 +176,9 @@ struct shared_phy_params { }; -extern shared_phy_t *wlc_phy_shared_attach(shared_phy_params_t *shp); -extern wlc_phy_t *wlc_phy_attach(shared_phy_t *sh, void *regs, int bandtype, - char *vars, struct wiphy *wiphy); +extern struct shared_phy *wlc_phy_shared_attach(struct shared_phy_params *shp); +extern wlc_phy_t *wlc_phy_attach(struct shared_phy *sh, void *regs, + int bandtype, char *vars, struct wiphy *wiphy); extern void wlc_phy_detach(wlc_phy_t *ppi); extern bool wlc_phy_get_phyversion(wlc_phy_t *pih, u16 *phytype, diff --git a/drivers/staging/brcm80211/brcmsmac/phy/phy_int.h b/drivers/staging/brcm80211/brcmsmac/phy/phy_int.h index 0019c044148d..d8c86d97ef39 100644 --- a/drivers/staging/brcm80211/brcmsmac/phy/phy_int.h +++ b/drivers/staging/brcm80211/brcmsmac/phy/phy_int.h @@ -41,7 +41,7 @@ extern u32 phyhal_msg_level; #define LCNXN_BASEREV 16 -struct wlc_phy_srom_fem { +struct brcms_phy_srom_fem { u8 tssipos; /* TSSI positive slope, 1: positive, 0: negative */ u8 extpagain; /* Ext PA gain-type: full-gain: 0, pa-lite: 1, no_pa: 2 */ u8 pdetrange; /* support 32 combinations of different Pdet dynamic ranges */ @@ -441,11 +441,11 @@ struct txiqcal_cache { u16 txcal_coeffs_2G[8]; u16 txcal_radio_regs_2G[8]; - nphy_iq_comp_t rxcal_coeffs_2G; + struct nphy_iq_comp rxcal_coeffs_2G; u16 txcal_coeffs_5G[8]; u16 txcal_radio_regs_5G[8]; - nphy_iq_comp_t rxcal_coeffs_5G; + struct nphy_iq_comp rxcal_coeffs_5G; }; struct nphy_pwrctrl { @@ -595,12 +595,12 @@ struct phy_func_ptr { struct phy_info { wlc_phy_t pubpi_ro; - shared_phy_t *sh; - phy_func_ptr_t pi_fptr; + struct shared_phy *sh; + struct phy_func_ptr pi_fptr; void *pi_ptr; union { - phy_info_lcnphy_t *pi_lcnphy; + struct phy_info_lcnphy *pi_lcnphy; } u; bool user_txpwr_at_rfport; @@ -650,8 +650,8 @@ struct phy_info { s8 tx_power_offset[TXP_NUM_RATES]; u8 tx_power_target[TXP_NUM_RATES]; - wlc_phy_srom_fem_t srom_fem2g; - wlc_phy_srom_fem_t srom_fem5g; + struct brcms_phy_srom_fem srom_fem2g; + struct brcms_phy_srom_fem srom_fem5g; u8 tx_power_max; u8 tx_power_max_rate_ind; @@ -722,7 +722,8 @@ struct phy_info { u16 mintxbias; u16 mintxmag; - lo_complex_abgphy_info_t gphy_locomp_iq[STATIC_NUM_RF][STATIC_NUM_BB]; + struct lo_complex_abgphy_info gphy_locomp_iq + [STATIC_NUM_RF][STATIC_NUM_BB]; s8 stats_11b_txpower[STATIC_NUM_RF][STATIC_NUM_BB]; u16 gain_table[TX_GAIN_TABLE_LENGTH]; bool loopback_gain; @@ -780,8 +781,8 @@ struct phy_info { u32 nphy_bb_mult_save; u16 nphy_txiqlocal_bestc[11]; bool nphy_txiqlocal_coeffsvalid; - phy_txpwrindex_t nphy_txpwrindex[PHY_CORE_NUM_2]; - phy_pwrctrl_t nphy_pwrctrl_info[PHY_CORE_NUM_2]; + struct nphy_txpwrindex nphy_txpwrindex[PHY_CORE_NUM_2]; + struct nphy_pwrctrl nphy_pwrctrl_info[PHY_CORE_NUM_2]; u16 cck2gpo; u32 ofdm2gpo; u32 ofdm5gpo; @@ -849,8 +850,8 @@ struct phy_info { bool internal_tx_iqlo_cal_tapoff_intpa_nphy; s16 nphy_lastcal_temp; - txiqcal_cache_t calibration_cache; - rssical_cache_t rssical_cache; + struct txiqcal_cache calibration_cache; + struct rssical_cache rssical_cache; u8 nphy_txpwr_idx[2]; u8 nphy_papd_cal_type; @@ -881,7 +882,7 @@ struct phy_info { u8 nphy_txcal_pwr_idx[2]; u8 nphy_rxcal_pwr_idx[2]; u16 nphy_cal_orig_tx_gain[2]; - nphy_txgains_t nphy_cal_target_gain; + struct nphy_txgains nphy_cal_target_gain; u16 nphy_txcal_bbmult; u16 nphy_gmval; @@ -892,7 +893,7 @@ struct phy_info { bool nphy_aband_spurwar_en; u16 nphy_rccal_value; u16 nphy_crsminpwr[3]; - phy_noisevar_buf_t nphy_saved_noisevars; + struct nphy_noisevar_buf nphy_saved_noisevars; bool nphy_anarxlpf_adjusted; bool nphy_crsminpwr_adjusted; bool nphy_noisevars_adjusted; @@ -963,21 +964,23 @@ struct lcnphy_radio_regs { u8 do_init_g; }; -extern lcnphy_radio_regs_t lcnphy_radio_regs_2064[]; -extern lcnphy_radio_regs_t lcnphy_radio_regs_2066[]; -extern radio_regs_t regs_2055[], regs_SYN_2056[], regs_TX_2056[], +extern struct lcnphy_radio_regs lcnphy_radio_regs_2064[]; +extern struct lcnphy_radio_regs lcnphy_radio_regs_2066[]; +extern struct radio_regs regs_2055[], regs_SYN_2056[], regs_TX_2056[], regs_RX_2056[]; -extern radio_regs_t regs_SYN_2056_A1[], regs_TX_2056_A1[], regs_RX_2056_A1[]; -extern radio_regs_t regs_SYN_2056_rev5[], regs_TX_2056_rev5[], +extern struct radio_regs regs_SYN_2056_A1[], regs_TX_2056_A1[], + regs_RX_2056_A1[]; +extern struct radio_regs regs_SYN_2056_rev5[], regs_TX_2056_rev5[], regs_RX_2056_rev5[]; -extern radio_regs_t regs_SYN_2056_rev6[], regs_TX_2056_rev6[], +extern struct radio_regs regs_SYN_2056_rev6[], regs_TX_2056_rev6[], regs_RX_2056_rev6[]; -extern radio_regs_t regs_SYN_2056_rev7[], regs_TX_2056_rev7[], +extern struct radio_regs regs_SYN_2056_rev7[], regs_TX_2056_rev7[], regs_RX_2056_rev7[]; -extern radio_regs_t regs_SYN_2056_rev8[], regs_TX_2056_rev8[], +extern struct radio_regs regs_SYN_2056_rev8[], regs_TX_2056_rev8[], regs_RX_2056_rev8[]; -extern radio_20xx_regs_t regs_2057_rev4[], regs_2057_rev5[], regs_2057_rev5v1[]; -extern radio_20xx_regs_t regs_2057_rev7[], regs_2057_rev8[]; +extern struct radio_20xx_regs regs_2057_rev4[], regs_2057_rev5[], + regs_2057_rev5v1[]; +extern struct radio_20xx_regs regs_2057_rev7[], regs_2057_rev8[]; extern char *phy_getvar(phy_info_t *pi, const char *name); extern int phy_getintvar(phy_info_t *pi, const char *name); @@ -1004,12 +1007,13 @@ extern void wlc_phyreg_exit(wlc_phy_t *pih); extern void wlc_radioreg_enter(wlc_phy_t *pih); extern void wlc_radioreg_exit(wlc_phy_t *pih); -extern void wlc_phy_read_table(phy_info_t *pi, const phytbl_info_t *ptbl_info, +extern void wlc_phy_read_table(phy_info_t *pi, + const struct phytbl_info *ptbl_info, u16 tblAddr, u16 tblDataHi, u16 tblDatalo); extern void wlc_phy_write_table(phy_info_t *pi, - const phytbl_info_t *ptbl_info, u16 tblAddr, - u16 tblDataHi, u16 tblDatalo); + const struct phytbl_info *ptbl_info, + u16 tblAddr, u16 tblDataHi, u16 tblDatalo); extern void wlc_phy_table_addr(phy_info_t *pi, uint tbl_id, uint tbl_offset, u16 tblAddr, u16 tblDataHi, u16 tblDataLo); @@ -1023,8 +1027,9 @@ extern u8 wlc_phy_nbits(s32 value); extern void wlc_phy_compute_dB(u32 *cmplx_pwr, s8 *p_dB, u8 core); extern uint wlc_phy_init_radio_regs_allbands(phy_info_t *pi, - radio_20xx_regs_t *radioregs); -extern uint wlc_phy_init_radio_regs(phy_info_t *pi, radio_regs_t *radioregs, + struct radio_20xx_regs *radioregs); +extern uint wlc_phy_init_radio_regs(phy_info_t *pi, + struct radio_regs *radioregs, u16 core_offset); extern void wlc_phy_txpower_ipa_upd(phy_info_t *pi); @@ -1101,8 +1106,9 @@ extern void wlc_phy_txpower_recalc_target(phy_info_t *pi); #define LCNPHY_TX_PWR_CTRL_TEMPBASED 0xE001 -extern void wlc_lcnphy_write_table(phy_info_t *pi, const phytbl_info_t *pti); -extern void wlc_lcnphy_read_table(phy_info_t *pi, phytbl_info_t *pti); +extern void wlc_lcnphy_write_table(phy_info_t *pi, + const struct phytbl_info *pti); +extern void wlc_lcnphy_read_table(phy_info_t *pi, struct phytbl_info *pti); extern void wlc_lcnphy_set_tx_iqcc(phy_info_t *pi, u16 a, u16 b); extern void wlc_lcnphy_set_tx_locc(phy_info_t *pi, u16 didq); extern void wlc_lcnphy_get_tx_iqcc(phy_info_t *pi, u16 *a, u16 *b); @@ -1167,12 +1173,12 @@ extern s16 wlc_phy_tempsense_nphy(phy_info_t *pi); extern u16 wlc_phy_classifier_nphy(phy_info_t *pi, u16 mask, u16 val); -extern void wlc_phy_rx_iq_est_nphy(phy_info_t *pi, phy_iq_est_t *est, +extern void wlc_phy_rx_iq_est_nphy(phy_info_t *pi, struct phy_iq_est *est, u16 num_samps, u8 wait_time, u8 wait_for_crs); extern void wlc_phy_rx_iq_coeffs_nphy(phy_info_t *pi, u8 write, - nphy_iq_comp_t *comp); + struct nphy_iq_comp *comp); extern void wlc_phy_aci_and_noise_reduction_nphy(phy_info_t *pi); extern void wlc_phy_rxcore_setstate_nphy(wlc_phy_t *pih, u8 rxcore_bitmask); @@ -1184,10 +1190,12 @@ extern void wlc_phy_txpwr_apply_nphy(phy_info_t *pi); extern void wlc_phy_txpwr_papd_cal_nphy(phy_info_t *pi); extern u16 wlc_phy_txpwr_idx_get_nphy(phy_info_t *pi); -extern nphy_txgains_t wlc_phy_get_tx_gain_nphy(phy_info_t *pi); -extern int wlc_phy_cal_txiqlo_nphy(phy_info_t *pi, nphy_txgains_t target_gain, +extern struct nphy_txgains wlc_phy_get_tx_gain_nphy(phy_info_t *pi); +extern int wlc_phy_cal_txiqlo_nphy(phy_info_t *pi, + struct nphy_txgains target_gain, bool full, bool m); -extern int wlc_phy_cal_rxiq_nphy(phy_info_t *pi, nphy_txgains_t target_gain, +extern int wlc_phy_cal_rxiq_nphy(phy_info_t *pi, + struct nphy_txgains target_gain, u8 type, bool d); extern void wlc_phy_txpwr_index_nphy(phy_info_t *pi, u8 core_mask, s8 txpwrindex, bool res); @@ -1205,7 +1213,8 @@ extern void wlc_phy_est_tonepwr_nphy(phy_info_t *pi, s32 *qdBm_pwrbuf, u8 num_samps); extern void wlc_phy_radio205x_vcocal_nphy(phy_info_t *pi); -extern int wlc_phy_rssi_compute_nphy(phy_info_t *pi, wlc_d11rxhdr_t *wlc_rxh); +extern int wlc_phy_rssi_compute_nphy(phy_info_t *pi, + struct brcms_d11rxhdr *wlc_rxh); #define NPHY_TESTPATTERN_BPHY_EVM 0 #define NPHY_TESTPATTERN_BPHY_RFCS 1 diff --git a/drivers/staging/brcm80211/brcmsmac/phy/phy_lcn.c b/drivers/staging/brcm80211/brcmsmac/phy/phy_lcn.c index 3b61bebbe2b6..47a0a1a62f27 100644 --- a/drivers/staging/brcm80211/brcmsmac/phy/phy_lcn.c +++ b/drivers/staging/brcm80211/brcmsmac/phy/phy_lcn.c @@ -136,60 +136,55 @@ (0 != (read_phy_reg((pi), 0x43b) & (0x1 << 6))) #define wlc_lcnphy_total_tx_frames(pi) \ - wlapi_bmac_read_shm((pi)->sh->physhim, M_UCODE_MACSTAT + offsetof(macstat_t, txallfrm)) + wlapi_bmac_read_shm((pi)->sh->physhim, \ + M_UCODE_MACSTAT + offsetof(struct macstat, txallfrm)) -typedef struct { +struct lcnphy_txgains { u16 gm_gain; u16 pga_gain; u16 pad_gain; u16 dac_gain; -} lcnphy_txgains_t; +}; -typedef enum { +enum lcnphy_cal_mode { LCNPHY_CAL_FULL, LCNPHY_CAL_RECAL, LCNPHY_CAL_CURRECAL, LCNPHY_CAL_DIGCAL, LCNPHY_CAL_GCTRL -} lcnphy_cal_mode_t; - -typedef struct { - lcnphy_txgains_t gains; - bool useindex; - u8 index; -} lcnphy_txcalgains_t; +}; -typedef struct { +struct lcnphy_rx_iqcomp { u8 chan; s16 a; s16 b; -} lcnphy_rx_iqcomp_t; +}; -typedef struct { +struct lcnphy_spb_tone { s16 re; s16 im; -} lcnphy_spb_tone_t; +}; -typedef struct { +struct lcnphy_unsign16_struct { u16 re; u16 im; -} lcnphy_unsign16_struct; +}; -typedef struct { +struct lcnphy_iq_est { u32 iq_prod; u32 i_pwr; u32 q_pwr; -} lcnphy_iq_est_t; +}; -typedef struct { +struct lcnphy_sfo_cfg { u16 ptcentreTs20; u16 ptcentreFactor; -} lcnphy_sfo_cfg_t; +}; -typedef enum { +enum lcnphy_papd_cal_type { LCNPHY_PAPD_CAL_CW, LCNPHY_PAPD_CAL_OFDM -} lcnphy_papd_cal_type_t; +}; typedef u16 iqcal_gain_params_lcnphy[9]; @@ -206,7 +201,7 @@ static const u16 iqcal_gainparams_numgains_lcnphy[1] = { sizeof(*tbl_iqcal_gainparams_lcnphy_2G), }; -static const lcnphy_sfo_cfg_t lcnphy_sfo_cfg[] = { +static const struct lcnphy_sfo_cfg lcnphy_sfo_cfg[] = { {965, 1087}, {967, 1085}, {969, 1082}, @@ -272,7 +267,7 @@ u16 lcnphy_iqcal_ir_gainladder[] = { }; static const -lcnphy_spb_tone_t lcnphy_spb_tone_3750[] = { +struct lcnphy_spb_tone lcnphy_spb_tone_3750[] = { {88, 0}, {73, 49}, {34, 81}, @@ -365,7 +360,7 @@ u16 rxiq_cal_rf_reg[11] = { }; static const -lcnphy_rx_iqcomp_t lcnphy_rx_iqcomp_table_rev0[] = { +struct lcnphy_rx_iqcomp lcnphy_rx_iqcomp_table_rev0[] = { {1, 0, 0}, {2, 0, 0}, {3, 0, 0}, @@ -542,11 +537,11 @@ static const s8 lcnphy_gain_index_offset_for_rssi[] = { extern const u8 spur_tbl_rev0[]; extern const u32 dot11lcnphytbl_rx_gain_info_sz_rev1; -extern const dot11lcnphytbl_info_t dot11lcnphytbl_rx_gain_info_rev1[]; -extern const dot11lcnphytbl_info_t dot11lcn_sw_ctrl_tbl_info_4313_bt_epa; -extern const dot11lcnphytbl_info_t dot11lcn_sw_ctrl_tbl_info_4313_bt_epa_p250; +extern const struct phytbl_info dot11lcnphytbl_rx_gain_info_rev1[]; +extern const struct phytbl_info dot11lcn_sw_ctrl_tbl_info_4313_bt_epa; +extern const struct phytbl_info dot11lcn_sw_ctrl_tbl_info_4313_bt_epa_p250; -typedef struct _chan_info_2064_lcnphy { +struct chan_info_2064_lcnphy { uint chan; uint freq; u8 logen_buftune; @@ -557,9 +552,9 @@ typedef struct _chan_info_2064_lcnphy { u8 pa_rxrf_lna1_freq_tune; u8 pa_rxrf_lna2_freq_tune; u8 rxrf_rxrf_spare1; -} chan_info_2064_lcnphy_t; +}; -static chan_info_2064_lcnphy_t chan_info_2064_lcnphy[] = { +static struct chan_info_2064_lcnphy chan_info_2064_lcnphy[] = { {1, 2412, 0x0B, 0x0A, 0x00, 0x07, 0x0A, 0x88, 0x88, 0x80}, {2, 2417, 0x0B, 0x0A, 0x00, 0x07, 0x0A, 0x88, 0x88, 0x80}, {3, 2422, 0x0B, 0x0A, 0x00, 0x07, 0x0A, 0x88, 0x88, 0x80}, @@ -576,7 +571,7 @@ static chan_info_2064_lcnphy_t chan_info_2064_lcnphy[] = { {14, 2484, 0x0B, 0x0A, 0x00, 0x07, 0x0A, 0x88, 0x88, 0x80}, }; -lcnphy_radio_regs_t lcnphy_radio_regs_2064[] = { +struct lcnphy_radio_regs lcnphy_radio_regs_2064[] = { {0x00, 0, 0, 0, 0}, {0x01, 0x64, 0x64, 0, 0}, {0x02, 0x20, 0x20, 0, 0}, @@ -982,14 +977,15 @@ static void wlc_lcnphy_set_pa_gain(phy_info_t *pi, u16 gain); static void wlc_lcnphy_set_trsw_override(phy_info_t *pi, bool tx, bool rx); static void wlc_lcnphy_set_bbmult(phy_info_t *pi, u8 m0); static u8 wlc_lcnphy_get_bbmult(phy_info_t *pi); -static void wlc_lcnphy_get_tx_gain(phy_info_t *pi, lcnphy_txgains_t *gains); +static void wlc_lcnphy_get_tx_gain(phy_info_t *pi, + struct lcnphy_txgains *gains); static void wlc_lcnphy_set_tx_gain_override(phy_info_t *pi, bool bEnable); static void wlc_lcnphy_toggle_afe_pwdn(phy_info_t *pi); static void wlc_lcnphy_rx_gain_override_enable(phy_info_t *pi, bool enable); static void wlc_lcnphy_set_tx_gain(phy_info_t *pi, - lcnphy_txgains_t *target_gains); + struct lcnphy_txgains *target_gains); static bool wlc_lcnphy_rx_iq_est(phy_info_t *pi, u16 num_samps, - u8 wait_time, lcnphy_iq_est_t *iq_est); + u8 wait_time, struct lcnphy_iq_est *iq_est); static bool wlc_lcnphy_calc_rx_iq_comp(phy_info_t *pi, u16 num_samps); static u16 wlc_lcnphy_get_pa_gain(phy_info_t *pi); static void wlc_lcnphy_afe_clk_init(phy_info_t *pi, u8 mode); @@ -998,7 +994,7 @@ static void wlc_lcnphy_radio_2064_channel_tune_4313(phy_info_t *pi, u8 channel); static void wlc_lcnphy_load_tx_gain_table(phy_info_t *pi, - const lcnphy_tx_gain_tbl_entry *g); + const struct lcnphy_tx_gain_tbl_entry *g); static void wlc_lcnphy_samp_cap(phy_info_t *pi, int clip_detect_algo, u16 thresh, s16 *ptr, int mode); @@ -1009,7 +1005,8 @@ static void wlc_lcnphy_tx_iqlo_loopback_cleanup(phy_info_t *pi, u16 *values_to_save); static void wlc_lcnphy_set_cc(phy_info_t *pi, int cal_type, s16 coeff_x, s16 coeff_y); -static lcnphy_unsign16_struct wlc_lcnphy_get_cc(phy_info_t *pi, int cal_type); +static struct lcnphy_unsign16_struct wlc_lcnphy_get_cc(phy_info_t *pi, + int cal_type); static void wlc_lcnphy_a1(phy_info_t *pi, int cal_type, int num_levels, int step_size_lg2); static void wlc_lcnphy_tx_iqlo_soft_cal_full(phy_info_t *pi); @@ -1028,12 +1025,12 @@ static int wlc_lcnphy_load_tx_iir_filter(phy_info_t *pi, bool is_ofdm, s16 filt_type); static void wlc_lcnphy_set_rx_iq_comp(phy_info_t *pi, u16 a, u16 b); -void wlc_lcnphy_write_table(phy_info_t *pi, const phytbl_info_t *pti) +void wlc_lcnphy_write_table(phy_info_t *pi, const struct phytbl_info *pti) { wlc_phy_write_table(pi, pti, 0x455, 0x457, 0x456); } -void wlc_lcnphy_read_table(phy_info_t *pi, phytbl_info_t *pti) +void wlc_lcnphy_read_table(phy_info_t *pi, struct phytbl_info *pti) { wlc_phy_read_table(pi, pti, 0x455, 0x457, 0x456); } @@ -1043,7 +1040,7 @@ wlc_lcnphy_common_read_table(phy_info_t *pi, u32 tbl_id, const void *tbl_ptr, u32 tbl_len, u32 tbl_width, u32 tbl_offset) { - phytbl_info_t tab; + struct phytbl_info tab; tab.tbl_id = tbl_id; tab.tbl_ptr = tbl_ptr; tab.tbl_len = tbl_len; @@ -1058,7 +1055,7 @@ wlc_lcnphy_common_write_table(phy_info_t *pi, u32 tbl_id, u32 tbl_width, u32 tbl_offset) { - phytbl_info_t tab; + struct phytbl_info tab; tab.tbl_id = tbl_id; tab.tbl_ptr = tbl_ptr; tab.tbl_len = tbl_len; @@ -1116,7 +1113,7 @@ static int wlc_lcnphy_calc_floor(s16 coeff_x, int type) s8 wlc_lcnphy_get_current_tx_pwr_idx(phy_info_t *pi) { s8 index; - phy_info_lcnphy_t *pi_lcn = pi->u.pi_lcnphy; + struct phy_info_lcnphy *pi_lcn = pi->u.pi_lcnphy; if (txpwrctrl_off(pi)) index = pi_lcn->lcnphy_current_index; @@ -1131,7 +1128,7 @@ s8 wlc_lcnphy_get_current_tx_pwr_idx(phy_info_t *pi) static u32 wlc_lcnphy_measure_digital_power(phy_info_t *pi, u16 nsamples) { - lcnphy_iq_est_t iq_est = { 0, 0, 0 }; + struct lcnphy_iq_est iq_est = { 0, 0, 0 }; if (!wlc_lcnphy_rx_iq_est(pi, nsamples, 32, &iq_est)) return 0; @@ -1276,7 +1273,7 @@ static u16 wlc_lcnphy_get_pa_gain(phy_info_t *pi) } static void -wlc_lcnphy_set_tx_gain(phy_info_t *pi, lcnphy_txgains_t *target_gains) +wlc_lcnphy_set_tx_gain(phy_info_t *pi, struct lcnphy_txgains *target_gains) { u16 pa_gain = wlc_lcnphy_get_pa_gain(pi); @@ -1304,7 +1301,7 @@ wlc_lcnphy_set_tx_gain(phy_info_t *pi, lcnphy_txgains_t *target_gains) static void wlc_lcnphy_set_bbmult(phy_info_t *pi, u8 m0) { u16 m0m1 = (u16) m0 << 8; - phytbl_info_t tab; + struct phytbl_info tab; tab.tbl_ptr = &m0m1; tab.tbl_len = 1; @@ -1317,7 +1314,7 @@ static void wlc_lcnphy_set_bbmult(phy_info_t *pi, u8 m0) static void wlc_lcnphy_clear_tx_power_offsets(phy_info_t *pi) { u32 data_buf[64]; - phytbl_info_t tab; + struct phytbl_info tab; memset(data_buf, 0, sizeof(data_buf)); @@ -1337,13 +1334,13 @@ static void wlc_lcnphy_clear_tx_power_offsets(phy_info_t *pi) wlc_lcnphy_write_table(pi, &tab); } -typedef enum { +enum lcnphy_tssi_mode { LCNPHY_TSSI_PRE_PA, LCNPHY_TSSI_POST_PA, LCNPHY_TSSI_EXT -} lcnphy_tssi_mode_t; +}; -static void wlc_lcnphy_set_tssi_mux(phy_info_t *pi, lcnphy_tssi_mode_t pos) +static void wlc_lcnphy_set_tssi_mux(phy_info_t *pi, enum lcnphy_tssi_mode pos) { mod_phy_reg(pi, 0x4d7, (0x1 << 0), (0x1) << 0); @@ -1406,7 +1403,7 @@ static u16 wlc_lcnphy_rfseq_tbl_adc_pwrup(phy_info_t *pi) static void wlc_lcnphy_pwrctrl_rssiparams(phy_info_t *pi) { u16 auxpga_vmid, auxpga_vmid_temp, auxpga_gain_temp; - phy_info_lcnphy_t *pi_lcn = pi->u.pi_lcnphy; + struct phy_info_lcnphy *pi_lcn = pi->u.pi_lcnphy; auxpga_vmid = (2 << 8) | (pi_lcn->lcnphy_rssi_vc << 4) | pi_lcn->lcnphy_rssi_vf; @@ -1449,7 +1446,7 @@ static void wlc_lcnphy_pwrctrl_rssiparams(phy_info_t *pi) static void wlc_lcnphy_tssi_setup(phy_info_t *pi) { - phytbl_info_t tab; + struct phytbl_info tab; u32 rfseq, ind; tab.tbl_id = LCNPHY_TBL_ID_TXPWRCTL; @@ -1564,7 +1561,7 @@ static void wlc_lcnphy_tssi_setup(phy_info_t *pi) void wlc_lcnphy_tx_pwr_update_npt(phy_info_t *pi) { u16 tx_cnt, tx_total, npt; - phy_info_lcnphy_t *pi_lcn = pi->u.pi_lcnphy; + struct phy_info_lcnphy *pi_lcn = pi->u.pi_lcnphy; tx_total = wlc_lcnphy_total_tx_frames(pi); tx_cnt = tx_total - pi_lcn->lcnphy_tssi_tx_cnt; @@ -1593,7 +1590,7 @@ s32 wlc_lcnphy_tssi2dbm(s32 tssi, s32 a1, s32 b0, s32 b1) static void wlc_lcnphy_txpower_reset_npt(phy_info_t *pi) { - phy_info_lcnphy_t *pi_lcn = pi->u.pi_lcnphy; + struct phy_info_lcnphy *pi_lcn = pi->u.pi_lcnphy; if (wlc_lcnphy_tempsense_based_pwr_ctrl_enabled(pi)) return; @@ -1603,7 +1600,7 @@ static void wlc_lcnphy_txpower_reset_npt(phy_info_t *pi) void wlc_lcnphy_txpower_recalc_target(phy_info_t *pi) { - phytbl_info_t tab; + struct phytbl_info tab; u32 rate_table[WLC_NUM_RATES_CCK + WLC_NUM_RATES_OFDM + WLC_NUM_RATES_MCS_1_STREAM]; uint i, j; @@ -1638,7 +1635,7 @@ static void wlc_lcnphy_set_tx_pwr_soft_ctrl(phy_info_t *pi, s8 index) u32 ofdm_offset, reg_offset_cck; int i; u16 index2; - phytbl_info_t tab; + struct phytbl_info tab; if (wlc_lcnphy_tssi_based_pwr_ctrl_enabled(pi)) return; @@ -1691,7 +1688,7 @@ static s8 wlc_lcnphy_tempcompensated_txpwrctrl(phy_info_t *pi) s16 manp, meas_temp, temp_diff; bool neg = 0; u16 temp; - phy_info_lcnphy_t *pi_lcn = pi->u.pi_lcnphy; + struct phy_info_lcnphy *pi_lcn = pi->u.pi_lcnphy; if (wlc_lcnphy_tssi_based_pwr_ctrl_enabled(pi)) return pi_lcn->lcnphy_current_index; @@ -1767,7 +1764,7 @@ void wlc_lcnphy_set_tx_pwr_ctrl(phy_info_t *pi, u16 mode) { u16 old_mode = wlc_lcnphy_get_tx_pwr_ctrl(pi); s8 index; - phy_info_lcnphy_t *pi_lcn = pi->u.pi_lcnphy; + struct phy_info_lcnphy *pi_lcn = pi->u.pi_lcnphy; mode = wlc_lcnphy_set_tx_pwr_ctrl_mode(pi, mode); old_mode = wlc_lcnphy_set_tx_pwr_ctrl_mode(pi, old_mode); @@ -1831,11 +1828,11 @@ static bool wlc_lcnphy_iqcal_wait(phy_info_t *pi) static void wlc_lcnphy_tx_iqlo_cal(phy_info_t *pi, - lcnphy_txgains_t *target_gains, - lcnphy_cal_mode_t cal_mode, bool keep_tone) + struct lcnphy_txgains *target_gains, + enum lcnphy_cal_mode cal_mode, bool keep_tone) { - lcnphy_txgains_t cal_gains, temp_gains; + struct lcnphy_txgains cal_gains, temp_gains; u16 hash; u8 band_idx; int j; @@ -1861,10 +1858,10 @@ wlc_lcnphy_tx_iqlo_cal(phy_info_t *pi, u16 tx_pwr_ctrl_old, save_txpwrctrlrfctrl2; u16 save_sslpnCalibClkEnCtrl, save_sslpnRxFeClkEnCtrl; bool tx_gain_override_old; - lcnphy_txgains_t old_gains; + struct lcnphy_txgains old_gains; uint i, n_cal_cmds = 0, n_cal_start = 0; u16 *values_to_save; - phy_info_lcnphy_t *pi_lcn = pi->u.pi_lcnphy; + struct phy_info_lcnphy *pi_lcn = pi->u.pi_lcnphy; if (NORADIO_ENAB(pi->pubpi)) return; @@ -2068,7 +2065,7 @@ wlc_lcnphy_tx_iqlo_cal(phy_info_t *pi, static void wlc_lcnphy_idle_tssi_est(wlc_phy_t *ppi) { bool suspend, tx_gain_override_old; - lcnphy_txgains_t old_gains; + struct lcnphy_txgains old_gains; phy_info_t *pi = (phy_info_t *) ppi; u16 idleTssi, idleTssi0_2C, idleTssi0_OB, idleTssi0_regvalue_OB, idleTssi0_regvalue_2C; @@ -2137,14 +2134,14 @@ static void wlc_lcnphy_vbat_temp_sense_setup(phy_info_t *pi, u8 mode) u16 save_txpwrCtrlEn; u8 auxpga_vmidcourse, auxpga_vmidfine, auxpga_gain; u16 auxpga_vmid; - phytbl_info_t tab; + struct phytbl_info tab; u32 val; u8 save_reg007, save_reg0FF, save_reg11F, save_reg005, save_reg025, save_reg112; u16 values_to_save[14]; s8 index; int i; - phy_info_lcnphy_t *pi_lcn = pi->u.pi_lcnphy; + struct phy_info_lcnphy *pi_lcn = pi->u.pi_lcnphy; udelay(999); save_reg007 = (u8) read_radio_reg(pi, RADIO_2064_REG007); @@ -2275,9 +2272,9 @@ static void wlc_lcnphy_vbat_temp_sense_setup(phy_info_t *pi, u8 mode) void WLBANDINITFN(wlc_lcnphy_tx_pwr_ctrl_init) (wlc_phy_t *ppi) { - lcnphy_txgains_t tx_gains; + struct lcnphy_txgains tx_gains; u8 bbmult; - phytbl_info_t tab; + struct phytbl_info tab; s32 a1, b0, b1; s32 tssi, pwr, maxtargetpwr, mintargetpwr; bool suspend; @@ -2354,7 +2351,7 @@ void WLBANDINITFN(wlc_lcnphy_tx_pwr_ctrl_init) (wlc_phy_t *ppi) static u8 wlc_lcnphy_get_bbmult(phy_info_t *pi) { u16 m0m1; - phytbl_info_t tab; + struct phytbl_info tab; tab.tbl_ptr = &m0m1; tab.tbl_len = 1; @@ -2386,7 +2383,7 @@ wlc_lcnphy_get_radio_loft(phy_info_t *pi, *fq0 = LCNPHY_IQLOCC_READ(read_radio_reg(pi, RADIO_2064_REG08C)); } -static void wlc_lcnphy_get_tx_gain(phy_info_t *pi, lcnphy_txgains_t *gains) +static void wlc_lcnphy_get_tx_gain(phy_info_t *pi, struct lcnphy_txgains *gains) { u16 dac_gain; @@ -2407,7 +2404,7 @@ static void wlc_lcnphy_get_tx_gain(phy_info_t *pi, lcnphy_txgains_t *gains) void wlc_lcnphy_set_tx_iqcc(phy_info_t *pi, u16 a, u16 b) { - phytbl_info_t tab; + struct phytbl_info tab; u16 iqcc[2]; iqcc[0] = a; @@ -2423,7 +2420,7 @@ void wlc_lcnphy_set_tx_iqcc(phy_info_t *pi, u16 a, u16 b) void wlc_lcnphy_set_tx_locc(phy_info_t *pi, u16 didq) { - phytbl_info_t tab; + struct phytbl_info tab; tab.tbl_id = LCNPHY_TBL_ID_IQLOCAL; tab.tbl_width = 16; @@ -2435,12 +2432,12 @@ void wlc_lcnphy_set_tx_locc(phy_info_t *pi, u16 didq) void wlc_lcnphy_set_tx_pwr_by_index(phy_info_t *pi, int index) { - phytbl_info_t tab; + struct phytbl_info tab; u16 a, b; u8 bb_mult; u32 bbmultiqcomp, txgain, locoeffs, rfpower; - lcnphy_txgains_t gains; - phy_info_lcnphy_t *pi_lcn = pi->u.pi_lcnphy; + struct lcnphy_txgains gains; + struct phy_info_lcnphy *pi_lcn = pi->u.pi_lcnphy; pi_lcn->lcnphy_tx_power_idx_override = (s8) index; pi_lcn->lcnphy_current_index = (u8) index; @@ -2505,7 +2502,7 @@ static void wlc_lcnphy_set_trsw_override(phy_info_t *pi, bool tx, bool rx) static void wlc_lcnphy_clear_papd_comptable(phy_info_t *pi) { u32 j; - phytbl_info_t tab; + struct phytbl_info tab; u32 temp_offset[128]; tab.tbl_ptr = temp_offset; tab.tbl_len = 128; @@ -2720,8 +2717,8 @@ wlc_lcnphy_start_tx_tone(phy_info_t *pi, s32 f_kHz, u16 max_val, cs32 tone_samp; u32 data_buf[64]; u16 i_samp, q_samp; - phytbl_info_t tab; - phy_info_lcnphy_t *pi_lcn = pi->u.pi_lcnphy; + struct phytbl_info tab; + struct phy_info_lcnphy *pi_lcn = pi->u.pi_lcnphy; pi->phy_tx_tone_freq = f_kHz; @@ -2776,7 +2773,7 @@ wlc_lcnphy_start_tx_tone(phy_info_t *pi, s32 f_kHz, u16 max_val, void wlc_lcnphy_stop_tx_tone(phy_info_t *pi) { s16 playback_status; - phy_info_lcnphy_t *pi_lcn = pi->u.pi_lcnphy; + struct phy_info_lcnphy *pi_lcn = pi->u.pi_lcnphy; pi->phy_tx_tone_freq = 0; if (pi_lcn->lcnphy_spurmod) { @@ -2813,7 +2810,7 @@ static void wlc_lcnphy_clear_trsw_override(phy_info_t *pi) void wlc_lcnphy_get_tx_iqcc(phy_info_t *pi, u16 *a, u16 *b) { u16 iqcc[2]; - phytbl_info_t tab; + struct phytbl_info tab; tab.tbl_ptr = iqcc; tab.tbl_len = 2; @@ -2828,7 +2825,7 @@ void wlc_lcnphy_get_tx_iqcc(phy_info_t *pi, u16 *a, u16 *b) u16 wlc_lcnphy_get_tx_locc(phy_info_t *pi) { - phytbl_info_t tab; + struct phytbl_info tab; u16 didq; tab.tbl_id = 0; @@ -2844,15 +2841,15 @@ u16 wlc_lcnphy_get_tx_locc(phy_info_t *pi) static void wlc_lcnphy_txpwrtbl_iqlo_cal(phy_info_t *pi) { - lcnphy_txgains_t target_gains, old_gains; + struct lcnphy_txgains target_gains, old_gains; u8 save_bb_mult; u16 a, b, didq, save_pa_gain = 0; uint idx, SAVE_txpwrindex = 0xFF; u32 val; u16 SAVE_txpwrctrl = wlc_lcnphy_get_tx_pwr_ctrl(pi); - phytbl_info_t tab; + struct phytbl_info tab; u8 ei0, eq0, fi0, fq0; - phy_info_lcnphy_t *pi_lcn = pi->u.pi_lcnphy; + struct phy_info_lcnphy *pi_lcn = pi->u.pi_lcnphy; wlc_lcnphy_get_tx_gain(pi, &old_gains); save_pa_gain = wlc_lcnphy_get_pa_gain(pi); @@ -3006,7 +3003,7 @@ u16 wlc_lcnphy_tempsense(phy_info_t *pi, bool mode) s32 avg = 0; bool suspend = 0; u16 SAVE_txpwrctrl = wlc_lcnphy_get_tx_pwr_ctrl(pi); - phy_info_lcnphy_t *pi_lcn = pi->u.pi_lcnphy; + struct phy_info_lcnphy *pi_lcn = pi->u.pi_lcnphy; if (NORADIO_ENAB(pi->pubpi)) return -1; @@ -3123,7 +3120,7 @@ static void wlc_lcnphy_afe_clk_init(phy_info_t *pi, u8 mode) static bool wlc_lcnphy_rx_iq_est(phy_info_t *pi, u16 num_samps, - u8 wait_time, lcnphy_iq_est_t *iq_est) + u8 wait_time, struct lcnphy_iq_est *iq_est) { int wait_count = 0; bool result = true; @@ -3172,12 +3169,12 @@ static bool wlc_lcnphy_calc_rx_iq_comp(phy_info_t *pi, u16 num_samps) #define LCNPHY_MIN_RXIQ_PWR 2 bool result; u16 a0_new, b0_new; - lcnphy_iq_est_t iq_est = { 0, 0, 0 }; + struct lcnphy_iq_est iq_est = { 0, 0, 0 }; s32 a, b, temp; s16 iq_nbits, qq_nbits, arsh, brsh; s32 iq; u32 ii, qq; - phy_info_lcnphy_t *pi_lcn = pi->u.pi_lcnphy; + struct phy_info_lcnphy *pi_lcn = pi->u.pi_lcnphy; a0_new = ((read_phy_reg(pi, 0x645) & (0x3ff << 0)) >> 0); b0_new = ((read_phy_reg(pi, 0x646) & (0x3ff << 0)) >> 0); @@ -3253,11 +3250,11 @@ static bool wlc_lcnphy_calc_rx_iq_comp(phy_info_t *pi, u16 num_samps) } static bool -wlc_lcnphy_rx_iq_cal(phy_info_t *pi, const lcnphy_rx_iqcomp_t *iqcomp, +wlc_lcnphy_rx_iq_cal(phy_info_t *pi, const struct lcnphy_rx_iqcomp *iqcomp, int iqcomp_sz, bool tx_switch, bool rx_switch, int module, int tx_gain_idx) { - lcnphy_txgains_t old_gains; + struct lcnphy_txgains old_gains; u16 tx_pwr_ctrl; u8 tx_gain_index_old = 0; bool result = false, tx_gain_override_old = false; @@ -3270,7 +3267,7 @@ wlc_lcnphy_rx_iq_cal(phy_info_t *pi, const lcnphy_rx_iqcomp_t *iqcomp, u16 old_sslpnCalibClkEnCtrl, old_sslpnRxFeClkEnCtrl; u16 values_to_save[11]; s16 *ptr; - phy_info_lcnphy_t *pi_lcn = pi->u.pi_lcnphy; + struct phy_info_lcnphy *pi_lcn = pi->u.pi_lcnphy; ptr = kmalloc(sizeof(s16) * 131, GFP_ATOMIC); if (NULL == ptr) { @@ -3432,7 +3429,7 @@ static void wlc_lcnphy_glacial_timer_based_cal(phy_info_t *pi) bool suspend; s8 index; u16 SAVE_pwrctrl = wlc_lcnphy_get_tx_pwr_ctrl(pi); - phy_info_lcnphy_t *pi_lcn = pi->u.pi_lcnphy; + struct phy_info_lcnphy *pi_lcn = pi->u.pi_lcnphy; suspend = (0 == (R_REG(&pi->regs->maccontrol) & MCTL_EN_MAC)); if (!suspend) @@ -3455,14 +3452,14 @@ static void wlc_lcnphy_glacial_timer_based_cal(phy_info_t *pi) static void wlc_lcnphy_periodic_cal(phy_info_t *pi) { bool suspend, full_cal; - const lcnphy_rx_iqcomp_t *rx_iqcomp; + const struct lcnphy_rx_iqcomp *rx_iqcomp; int rx_iqcomp_sz; u16 SAVE_pwrctrl = wlc_lcnphy_get_tx_pwr_ctrl(pi); s8 index; - phytbl_info_t tab; + struct phytbl_info tab; s32 a1, b0, b1; s32 tssi, pwr, maxtargetpwr, mintargetpwr; - phy_info_lcnphy_t *pi_lcn = pi->u.pi_lcnphy; + struct phy_info_lcnphy *pi_lcn = pi->u.pi_lcnphy; if (NORADIO_ENAB(pi->pubpi)) return; @@ -3528,7 +3525,7 @@ void wlc_lcnphy_calib_modes(phy_info_t *pi, uint mode) { u16 temp_new; int temp1, temp2, temp_diff; - phy_info_lcnphy_t *pi_lcn = pi->u.pi_lcnphy; + struct phy_info_lcnphy *pi_lcn = pi->u.pi_lcnphy; switch (mode) { case PHY_PERICAL_CHAN: @@ -3594,7 +3591,7 @@ void WLBANDINITFN(wlc_phy_cal_init_lcnphy) (phy_info_t *pi) static void wlc_lcnphy_set_chanspec_tweaks(phy_info_t *pi, chanspec_t chanspec) { u8 channel = CHSPEC_CHANNEL(chanspec); - phy_info_lcnphy_t *pi_lcn = pi->u.pi_lcnphy; + struct phy_info_lcnphy *pi_lcn = pi->u.pi_lcnphy; if (NORADIO_ENAB(pi->pubpi)) return; @@ -3648,7 +3645,7 @@ void wlc_lcnphy_tx_power_adjustment(wlc_phy_t *ppi) s8 index; u16 index2; phy_info_t *pi = (phy_info_t *) ppi; - phy_info_lcnphy_t *pi_lcn = pi->u.pi_lcnphy; + struct phy_info_lcnphy *pi_lcn = pi->u.pi_lcnphy; u16 SAVE_txpwrctrl = wlc_lcnphy_get_tx_pwr_ctrl(pi); if (wlc_lcnphy_tempsense_based_pwr_ctrl_enabled(pi) && SAVE_txpwrctrl) { index = wlc_lcnphy_tempcompensated_txpwrctrl(pi); @@ -3679,7 +3676,7 @@ static void wlc_lcnphy_set_rx_iq_comp(phy_info_t *pi, u16 a, u16 b) void WLBANDINITFN(wlc_phy_init_lcnphy) (phy_info_t *pi) { u8 phybw40; - phy_info_lcnphy_t *pi_lcn = pi->u.pi_lcnphy; + struct phy_info_lcnphy *pi_lcn = pi->u.pi_lcnphy; phybw40 = CHSPEC_IS40(pi->radio_chanspec); pi_lcn->lcnphy_cal_counter = 0; @@ -3826,7 +3823,7 @@ wlc_lcnphy_samp_cap(phy_info_t *pi, int clip_detect_algo, u16 thresh, u16 sslpnCalibClkEnCtrl, timer; u16 old_sslpnCalibClkEnCtrl; s16 imag, real; - phy_info_lcnphy_t *pi_lcn = pi->u.pi_lcnphy; + struct phy_info_lcnphy *pi_lcn = pi->u.pi_lcnphy; timer = 0; old_sslpnCalibClkEnCtrl = read_phy_reg(pi, 0x6da); @@ -3897,7 +3894,7 @@ wlc_lcnphy_samp_cap(phy_info_t *pi, int clip_detect_algo, u16 thresh, static void wlc_lcnphy_tx_iqlo_soft_cal_full(phy_info_t *pi) { - lcnphy_unsign16_struct iqcc0, locc2, locc3, locc4; + struct lcnphy_unsign16_struct iqcc0, locc2, locc3, locc4; wlc_lcnphy_set_cc(pi, 0, 0, 0); wlc_lcnphy_set_cc(pi, 2, 0, 0); @@ -3962,11 +3959,12 @@ wlc_lcnphy_set_cc(phy_info_t *pi, int cal_type, s16 coeff_x, s16 coeff_y) } } -static lcnphy_unsign16_struct wlc_lcnphy_get_cc(phy_info_t *pi, int cal_type) +static struct lcnphy_unsign16_struct +wlc_lcnphy_get_cc(phy_info_t *pi, int cal_type) { u16 a, b, didq; u8 di0, dq0, ei, eq, fi, fq; - lcnphy_unsign16_struct cc; + struct lcnphy_unsign16_struct cc; cc.re = 0; cc.im = 0; switch (cal_type) { @@ -3999,9 +3997,9 @@ static lcnphy_unsign16_struct wlc_lcnphy_get_cc(phy_info_t *pi, int cal_type) static void wlc_lcnphy_a1(phy_info_t *pi, int cal_type, int num_levels, int step_size_lg2) { - const lcnphy_spb_tone_t *phy_c1; - lcnphy_spb_tone_t phy_c2; - lcnphy_unsign16_struct phy_c3; + const struct lcnphy_spb_tone *phy_c1; + struct lcnphy_spb_tone phy_c2; + struct lcnphy_unsign16_struct phy_c3; int phy_c4, phy_c5, k, l, j, phy_c6; u16 phy_c7, phy_c8, phy_c9; s16 phy_c10, phy_c11, phy_c12, phy_c13, phy_c14, phy_c15, phy_c16; @@ -4211,10 +4209,9 @@ wlc_lcnphy_tx_iqlo_loopback_cleanup(phy_info_t *pi, u16 *values_to_save) static void WLBANDINITFN(wlc_lcnphy_load_tx_gain_table) (phy_info_t *pi, - const lcnphy_tx_gain_tbl_entry * - gain_table) { + const struct lcnphy_tx_gain_tbl_entry *gain_table) { u32 j; - phytbl_info_t tab; + struct phytbl_info tab; u32 val; u16 pa_gain; u16 gm_gain; @@ -4248,7 +4245,7 @@ WLBANDINITFN(wlc_lcnphy_load_tx_gain_table) (phy_info_t *pi, static void wlc_lcnphy_load_rfpower(phy_info_t *pi) { - phytbl_info_t tab; + struct phytbl_info tab; u32 val, bbmult, rfgain; u8 index; u8 scale_factor = 1; @@ -4299,7 +4296,7 @@ static void WLBANDINITFN(wlc_lcnphy_tbl_init) (phy_info_t *pi) { uint idx; u8 phybw40; - phytbl_info_t tab; + struct phytbl_info tab; u32 val; phybw40 = CHSPEC_IS40(pi->radio_chanspec); @@ -4393,7 +4390,7 @@ static void WLBANDINITFN(wlc_lcnphy_tbl_init) (phy_info_t *pi) static void WLBANDINITFN(wlc_lcnphy_rev0_baseband_init) (phy_info_t *pi) { u16 afectrl1; - phy_info_lcnphy_t *pi_lcn = pi->u.pi_lcnphy; + struct phy_info_lcnphy *pi_lcn = pi->u.pi_lcnphy; write_radio_reg(pi, RADIO_2064_REG11C, 0x0); @@ -4449,9 +4446,9 @@ static void WLBANDINITFN(wlc_lcnphy_rev2_baseband_init) (phy_info_t *pi) static void wlc_lcnphy_agc_temp_init(phy_info_t *pi) { s16 temp; - phytbl_info_t tab; + struct phytbl_info tab; u32 tableBuffer[2]; - phy_info_lcnphy_t *pi_lcn = pi->u.pi_lcnphy; + struct phy_info_lcnphy *pi_lcn = pi->u.pi_lcnphy; if (NORADIO_ENAB(pi->pubpi)) return; @@ -4575,7 +4572,7 @@ static void WLBANDINITFN(wlc_lcnphy_baseband_init) (phy_info_t *pi) static void WLBANDINITFN(wlc_radio_2064_init) (phy_info_t *pi) { u32 i; - lcnphy_radio_regs_t *lcnphyregs = NULL; + struct lcnphy_radio_regs *lcnphyregs = NULL; lcnphyregs = lcnphy_radio_regs_2064; @@ -4699,7 +4696,7 @@ static bool wlc_phy_txpwr_srom_read_lcnphy(phy_info_t *pi) { s8 txpwr = 0; int i; - phy_info_lcnphy_t *pi_lcn = pi->u.pi_lcnphy; + struct phy_info_lcnphy *pi_lcn = pi->u.pi_lcnphy; if (CHSPEC_IS2G(pi->radio_chanspec)) { u16 cckpo = 0; @@ -4836,7 +4833,7 @@ static void wlc_lcnphy_radio_2064_channel_tune_4313(phy_info_t *pi, u8 channel) { uint i; - const chan_info_2064_lcnphy_t *ci; + const struct chan_info_2064_lcnphy *ci; u8 rfpll_doubler = 0; u8 pll_pwrup, pll_pwrup_ovr; fixed qFxtal, qFref, qFvco, qFcal; @@ -5030,9 +5027,9 @@ void wlc_phy_detach_lcnphy(phy_info_t *pi) bool wlc_phy_attach_lcnphy(phy_info_t *pi) { - phy_info_lcnphy_t *pi_lcn; + struct phy_info_lcnphy *pi_lcn; - pi->u.pi_lcnphy = kzalloc(sizeof(phy_info_lcnphy_t), GFP_ATOMIC); + pi->u.pi_lcnphy = kzalloc(sizeof(struct phy_info_lcnphy), GFP_ATOMIC); if (pi->u.pi_lcnphy == NULL) { return false; } @@ -5110,7 +5107,7 @@ static u32 wlc_lcnphy_get_receive_power(phy_info_t *pi, s32 *gain_index) u32 received_power = 0; s32 max_index = 0; u32 gain_code = 0; - phy_info_lcnphy_t *pi_lcn = pi->u.pi_lcnphy; + struct phy_info_lcnphy *pi_lcn = pi->u.pi_lcnphy; max_index = 36; if (*gain_index >= 0) @@ -5149,7 +5146,7 @@ s32 wlc_lcnphy_rx_signal_power(phy_info_t *pi, s32 gain_index) input_power_db; s32 received_power, temperature; uint freq; - phy_info_lcnphy_t *pi_lcn = pi->u.pi_lcnphy; + struct phy_info_lcnphy *pi_lcn = pi->u.pi_lcnphy; received_power = wlc_lcnphy_get_receive_power(pi, &gain_index); diff --git a/drivers/staging/brcm80211/brcmsmac/phy/phy_lcn.h b/drivers/staging/brcm80211/brcmsmac/phy/phy_lcn.h index d360714c561a..b21a29badbf2 100644 --- a/drivers/staging/brcm80211/brcmsmac/phy/phy_lcn.h +++ b/drivers/staging/brcm80211/brcmsmac/phy/phy_lcn.h @@ -100,7 +100,7 @@ struct phy_info_lcnphy { u16 lcnphy_extstxctrl1; s16 lcnphy_cck_dig_filt_type; s16 lcnphy_ofdm_dig_filt_type; - lcnphy_cal_results_t lcnphy_cal_results; + struct lcnphy_cal_results lcnphy_cal_results; u8 lcnphy_psat_pwr; u8 lcnphy_psat_indx; diff --git a/drivers/staging/brcm80211/brcmsmac/phy/phy_n.c b/drivers/staging/brcm80211/brcmsmac/phy/phy_n.c index c79c047f0474..e6fe8b777c86 100644 --- a/drivers/staging/brcm80211/brcmsmac/phy/phy_n.c +++ b/drivers/staging/brcm80211/brcmsmac/phy/phy_n.c @@ -141,7 +141,7 @@ #define CCTRL5357_EXTPA (1<<14) /* extPA in ChipControl 1, bit 14 */ #define CCTRL5357_ANT_MUX_2o3 (1<<15) /* 2o3 in ChipControl 1, bit 15 */ -typedef struct _nphy_iqcal_params { +struct nphy_iqcal_params { u16 txlpf; u16 txgm; u16 pga; @@ -149,20 +149,20 @@ typedef struct _nphy_iqcal_params { u16 ipa; u16 cal_gain; u16 ncorr[5]; -} nphy_iqcal_params_t; +}; -typedef struct _nphy_txiqcal_ladder { +struct nphy_txiqcal_ladder { u8 percent; u8 g_env; -} nphy_txiqcal_ladder_t; +}; -typedef struct { - nphy_txgains_t gains; +struct nphy_ipa_txcalgains { + struct nphy_txgains gains; bool useindex; u8 index; -} nphy_ipa_txcalgains_t; +}; -typedef struct nphy_papd_restore_state_t { +struct nphy_papd_restore_state { u16 fbmix[2]; u16 vga_master[2]; u16 intpa_master[2]; @@ -171,20 +171,20 @@ typedef struct nphy_papd_restore_state_t { u16 pwrup[2]; u16 atten[2]; u16 mm; -} nphy_papd_restore_state; +}; -typedef struct _nphy_ipa_txrxgain { +struct nphy_ipa_txrxgain { u16 hpvga; u16 lpf_biq1; u16 lpf_biq0; u16 lna2; u16 lna1; s8 txpwrindex; -} nphy_ipa_txrxgain_t; +}; #define NPHY_IPA_RXCAL_MAXGAININDEX (6 - 1) -nphy_ipa_txrxgain_t nphy_ipa_rxcal_gaintbl_5GHz[] = { {0, 0, 0, 0, 0, 100}, +struct nphy_ipa_txrxgain nphy_ipa_rxcal_gaintbl_5GHz[] = { {0, 0, 0, 0, 0, 100}, {0, 0, 0, 0, 0, 50}, {0, 0, 0, 0, 0, -1}, {0, 0, 0, 3, 0, -1}, @@ -192,7 +192,7 @@ nphy_ipa_txrxgain_t nphy_ipa_rxcal_gaintbl_5GHz[] = { {0, 0, 0, 0, 0, 100}, {0, 2, 3, 3, 0, -1} }; -nphy_ipa_txrxgain_t nphy_ipa_rxcal_gaintbl_2GHz[] = { {0, 0, 0, 0, 0, 128}, +struct nphy_ipa_txrxgain nphy_ipa_rxcal_gaintbl_2GHz[] = { {0, 0, 0, 0, 0, 128}, {0, 0, 0, 0, 0, 70}, {0, 0, 0, 0, 0, 20}, {0, 0, 0, 3, 0, 20}, @@ -200,7 +200,8 @@ nphy_ipa_txrxgain_t nphy_ipa_rxcal_gaintbl_2GHz[] = { {0, 0, 0, 0, 0, 128}, {0, 2, 3, 3, 0, 20} }; -nphy_ipa_txrxgain_t nphy_ipa_rxcal_gaintbl_5GHz_rev7[] = { {0, 0, 0, 0, 0, 100}, +struct nphy_ipa_txrxgain nphy_ipa_rxcal_gaintbl_5GHz_rev7[] = { +{0, 0, 0, 0, 0, 100}, {0, 0, 0, 0, 0, 50}, {0, 0, 0, 0, 0, -1}, {0, 0, 0, 3, 0, -1}, @@ -208,7 +209,8 @@ nphy_ipa_txrxgain_t nphy_ipa_rxcal_gaintbl_5GHz_rev7[] = { {0, 0, 0, 0, 0, 100}, {0, 0, 5, 3, 0, -1} }; -nphy_ipa_txrxgain_t nphy_ipa_rxcal_gaintbl_2GHz_rev7[] = { {0, 0, 0, 0, 0, 10}, +struct nphy_ipa_txrxgain nphy_ipa_rxcal_gaintbl_2GHz_rev7[] = { +{0, 0, 0, 0, 0, 10}, {0, 0, 0, 1, 0, 10}, {0, 0, 1, 2, 0, 10}, {0, 0, 1, 3, 0, 10}, @@ -255,7 +257,7 @@ u16 NPHY_IPA_REV4_txdigi_filtcoeffs[][NPHY_NUM_DIG_FILT_COEFFS] = { 0x97, 0x12d, 0x97, 0x25a, 0xd10, 0x25a} }; -typedef struct _chan_info_nphy_2055 { +struct chan_info_nphy_2055 { u16 chan; u16 freq; uint unknown; @@ -287,9 +289,9 @@ typedef struct _chan_info_nphy_2055 { u16 PHY_BW4; u16 PHY_BW5; u16 PHY_BW6; -} chan_info_nphy_2055_t; +}; -typedef struct _chan_info_nphy_radio205x { +struct chan_info_nphy_radio205x { u16 chan; u16 freq; u8 RF_SYN_pll_vcocal1; @@ -335,9 +337,9 @@ typedef struct _chan_info_nphy_radio205x { u16 PHY_BW4; u16 PHY_BW5; u16 PHY_BW6; -} chan_info_nphy_radio205x_t; +}; -typedef struct _chan_info_nphy_radio2057 { +struct chan_info_nphy_radio2057 { u16 chan; u16 freq; u8 RF_vcocal_countval0; @@ -374,9 +376,9 @@ typedef struct _chan_info_nphy_radio2057 { u16 PHY_BW4; u16 PHY_BW5; u16 PHY_BW6; -} chan_info_nphy_radio2057_t; +}; -typedef struct _chan_info_nphy_radio2057_rev5 { +struct chan_info_nphy_radio2057_rev5 { u16 chan; u16 freq; u8 RF_vcocal_countval0; @@ -403,18 +405,18 @@ typedef struct _chan_info_nphy_radio2057_rev5 { u16 PHY_BW4; u16 PHY_BW5; u16 PHY_BW6; -} chan_info_nphy_radio2057_rev5_t; +}; -typedef struct nphy_sfo_cfg { +struct nphy_sfo_cfg { u16 PHY_BW1a; u16 PHY_BW2; u16 PHY_BW3; u16 PHY_BW4; u16 PHY_BW5; u16 PHY_BW6; -} nphy_sfo_cfg_t; +}; -static chan_info_nphy_2055_t chan_info_nphy_2055[] = { +static struct chan_info_nphy_2055 chan_info_nphy_2055[] = { { 184, 4920, 3280, 0x71, 0x01, 0xEC, 0x0F, 0xFF, 0x01, 0x04, 0x0A, 0x00, 0x8F, 0xFF, 0xFF, 0xFF, 0x00, 0x0F, 0x0F, 0x8F, 0xFF, 0x00, 0x0F, @@ -913,7 +915,7 @@ static chan_info_nphy_2055_t chan_info_nphy_2055[] = { 0x01, 0x80, 0x3E6, 0x3E2, 0x3DE, 0x41B, 0x41F, 0x424} }; -static chan_info_nphy_radio205x_t chan_info_nphyrev3_2056[] = { +static struct chan_info_nphy_radio205x chan_info_nphyrev3_2056[] = { { 184, 4920, 0xff, 0x01, 0x01, 0x01, 0xec, 0x05, 0x05, 0x04, 0x0c, 0x01, 0x00, 0x00, 0x00, 0x8f, 0x0f, 0x00, 0xff, 0xff, 0x00, 0x08, 0x00, 0x7f, @@ -1536,7 +1538,7 @@ static chan_info_nphy_radio205x_t chan_info_nphyrev3_2056[] = { 0x0f, 0x00, 0x0d, 0x03e6, 0x03e2, 0x03de, 0x041b, 0x041f, 0x0424} }; -static chan_info_nphy_radio205x_t chan_info_nphyrev4_2056_A1[] = { +static struct chan_info_nphy_radio205x chan_info_nphyrev4_2056_A1[] = { { 184, 4920, 0xff, 0x01, 0x01, 0x01, 0xec, 0x05, 0x05, 0x04, 0x0c, 0x01, 0x00, 0x00, 0x00, 0x8f, 0x0f, 0x00, 0xff, 0xff, 0x00, 0x0e, 0x00, 0x7f, @@ -2159,7 +2161,7 @@ static chan_info_nphy_radio205x_t chan_info_nphyrev4_2056_A1[] = { 0x0f, 0x00, 0x0e, 0x03e6, 0x03e2, 0x03de, 0x041b, 0x041f, 0x0424} }; -static chan_info_nphy_radio205x_t chan_info_nphyrev5_2056v5[] = { +static struct chan_info_nphy_radio205x chan_info_nphyrev5_2056v5[] = { { 184, 4920, 0xff, 0x01, 0x01, 0x01, 0xec, 0x05, 0x05, 0x04, 0x0c, 0x01, 0x00, 0x00, 0x00, 0x8f, 0x0f, 0x00, 0xff, 0xff, 0x00, 0x0b, 0x00, 0x70, @@ -2782,7 +2784,7 @@ static chan_info_nphy_radio205x_t chan_info_nphyrev5_2056v5[] = { 0x0d, 0x00, 0x08, 0x03e6, 0x03e2, 0x03de, 0x041b, 0x041f, 0x0424} }; -static chan_info_nphy_radio205x_t chan_info_nphyrev6_2056v6[] = { +static struct chan_info_nphy_radio205x chan_info_nphyrev6_2056v6[] = { { 184, 4920, 0xff, 0x01, 0x01, 0x01, 0xec, 0x05, 0x05, 0x04, 0x0c, 0x01, 0x00, 0x00, 0x00, 0x8f, 0x0f, 0x00, 0xff, 0xfe, 0x00, 0x09, 0x00, 0x77, @@ -3405,7 +3407,7 @@ static chan_info_nphy_radio205x_t chan_info_nphyrev6_2056v6[] = { 0x09, 0x00, 0x09, 0x03e6, 0x03e2, 0x03de, 0x041b, 0x041f, 0x0424} }; -static chan_info_nphy_radio205x_t chan_info_nphyrev5n6_2056v7[] = { +static struct chan_info_nphy_radio205x chan_info_nphyrev5n6_2056v7[] = { { 184, 4920, 0xff, 0x01, 0x01, 0x01, 0xec, 0x05, 0x05, 0x04, 0x0c, 0x01, 0x00, 0x00, 0x00, 0x8f, 0x0f, 0x00, 0xff, 0xff, 0x00, 0x0b, 0x00, 0x70, @@ -4028,7 +4030,7 @@ static chan_info_nphy_radio205x_t chan_info_nphyrev5n6_2056v7[] = { 0x0d, 0x00, 0x08, 0x03e6, 0x03e2, 0x03de, 0x041b, 0x041f, 0x0424} }; -static chan_info_nphy_radio205x_t chan_info_nphyrev6_2056v8[] = { +static struct chan_info_nphy_radio205x chan_info_nphyrev6_2056v8[] = { { 184, 4920, 0xff, 0x01, 0x01, 0x01, 0xec, 0x05, 0x05, 0x04, 0x0c, 0x01, 0x00, 0x00, 0x00, 0x8f, 0x0f, 0x00, 0xff, 0xfe, 0x00, 0x09, 0x00, 0x77, @@ -4651,7 +4653,7 @@ static chan_info_nphy_radio205x_t chan_info_nphyrev6_2056v8[] = { 0x09, 0x00, 0x09, 0x03e6, 0x03e2, 0x03de, 0x041b, 0x041f, 0x0424} }; -static chan_info_nphy_radio205x_t chan_info_nphyrev6_2056v11[] = { +static struct chan_info_nphy_radio205x chan_info_nphyrev6_2056v11[] = { { 184, 4920, 0xff, 0x01, 0x01, 0x01, 0xec, 0x05, 0x05, 0x02, 0x0c, 0x01, 0x00, 0x00, 0x00, 0x8f, 0x0f, 0x00, 0xff, 0xfe, 0x00, 0x09, 0x00, 0x77, @@ -5274,7 +5276,7 @@ static chan_info_nphy_radio205x_t chan_info_nphyrev6_2056v11[] = { 0x09, 0x00, 0x09, 0x03e6, 0x03e2, 0x03de, 0x041b, 0x041f, 0x0424} }; -static chan_info_nphy_radio2057_t chan_info_nphyrev7_2057_rev4[] = { +static struct chan_info_nphy_radio2057 chan_info_nphyrev7_2057_rev4[] = { { 184, 4920, 0x68, 0x16, 0x10, 0x0c, 0x0c, 0x0c, 0x30, 0xec, 0x01, 0x0f, 0x00, 0x0f, 0x00, 0xff, 0x00, 0x00, 0x0f, 0x0f, 0xf3, 0x00, 0xef, 0x00, @@ -6137,7 +6139,7 @@ static chan_info_nphy_radio2057_t chan_info_nphyrev7_2057_rev4[] = { 0x0424} }; -static chan_info_nphy_radio2057_rev5_t chan_info_nphyrev8_2057_rev5[] = { +static struct chan_info_nphy_radio2057_rev5 chan_info_nphyrev8_2057_rev5[] = { { 1, 2412, 0x48, 0x16, 0x30, 0x1b, 0x0a, 0x0a, 0x30, 0x6c, 0x09, 0x0d, 0x08, 0x0e, 0x61, 0x03, 0xff, 0x61, 0x03, 0xff, 0x03c9, 0x03c5, 0x03c1, @@ -6196,7 +6198,7 @@ static chan_info_nphy_radio2057_rev5_t chan_info_nphyrev8_2057_rev5[] = { 0x041b, 0x041f, 0x0424} }; -static chan_info_nphy_radio2057_rev5_t chan_info_nphyrev9_2057_rev5v1[] = { +static struct chan_info_nphy_radio2057_rev5 chan_info_nphyrev9_2057_rev5v1[] = { { 1, 2412, 0x48, 0x16, 0x30, 0x1b, 0x0a, 0x0a, 0x30, 0x6c, 0x09, 0x0d, 0x08, 0x0e, 0x61, 0x03, 0xff, 0x61, 0x03, 0xff, 0x03c9, 0x03c5, 0x03c1, @@ -6255,7 +6257,7 @@ static chan_info_nphy_radio2057_rev5_t chan_info_nphyrev9_2057_rev5v1[] = { 0x041b, 0x041f, 0x0424} }; -static chan_info_nphy_radio2057_t chan_info_nphyrev8_2057_rev7[] = { +static struct chan_info_nphy_radio2057 chan_info_nphyrev8_2057_rev7[] = { { 184, 4920, 0x68, 0x16, 0x10, 0x0c, 0x0c, 0x0c, 0x30, 0xec, 0x01, 0x0f, 0x00, 0x0f, 0x00, 0xff, 0x00, 0xd3, 0x0f, 0x0f, 0xd3, 0x00, 0xff, 0x00, @@ -6996,7 +6998,7 @@ static chan_info_nphy_radio2057_t chan_info_nphyrev8_2057_rev7[] = { 0x0424} }; -static chan_info_nphy_radio2057_t chan_info_nphyrev8_2057_rev8[] = { +static struct chan_info_nphy_radio2057 chan_info_nphyrev8_2057_rev8[] = { { 186, 4930, 0x6b, 0x16, 0x10, 0x0c, 0x0c, 0x0c, 0x30, 0xed, 0x01, 0x0f, 0x00, 0x0f, 0x00, 0xff, 0x00, 0xd3, 0x0f, 0x0f, 0xd3, 0x00, 0xff, 0x00, @@ -7731,7 +7733,7 @@ static chan_info_nphy_radio2057_t chan_info_nphyrev8_2057_rev8[] = { 0x0424} }; -radio_regs_t regs_2055[] = { +struct radio_regs regs_2055[] = { {0x02, 0x80, 0x80, 0, 0}, {0x03, 0, 0, 0, 0}, {0x04, 0x27, 0x27, 0, 0}, @@ -7960,7 +7962,7 @@ radio_regs_t regs_2055[] = { {0xFFFF, 0, 0, 0, 0}, }; -radio_regs_t regs_SYN_2056[] = { +struct radio_regs regs_SYN_2056[] = { {0x02, 0, 0, 0, 0}, {0x03, 0, 0, 0, 0}, {0x04, 0, 0, 0, 0}, @@ -8145,7 +8147,7 @@ radio_regs_t regs_SYN_2056[] = { {0xFFFF, 0, 0, 0, 0} }; -radio_regs_t regs_TX_2056[] = { +struct radio_regs regs_TX_2056[] = { {0x02, 0, 0, 0, 0}, {0x03, 0, 0, 0, 0}, {0x04, 0, 0, 0, 0}, @@ -8294,7 +8296,7 @@ radio_regs_t regs_TX_2056[] = { {0xFFFF, 0, 0, 0, 0} }; -radio_regs_t regs_RX_2056[] = { +struct radio_regs regs_RX_2056[] = { {0x02, 0, 0, 0, 0}, {0x03, 0, 0, 0, 0}, {0x04, 0, 0, 0, 0}, @@ -8445,7 +8447,7 @@ radio_regs_t regs_RX_2056[] = { {0xFFFF, 0, 0, 0, 0} }; -radio_regs_t regs_SYN_2056_A1[] = { +struct radio_regs regs_SYN_2056_A1[] = { {0x02, 0, 0, 0, 0}, {0x03, 0, 0, 0, 0}, {0x04, 0, 0, 0, 0}, @@ -8630,7 +8632,7 @@ radio_regs_t regs_SYN_2056_A1[] = { {0xFFFF, 0, 0, 0, 0} }; -radio_regs_t regs_TX_2056_A1[] = { +struct radio_regs regs_TX_2056_A1[] = { {0x02, 0, 0, 0, 0}, {0x03, 0, 0, 0, 0}, {0x04, 0, 0, 0, 0}, @@ -8779,7 +8781,7 @@ radio_regs_t regs_TX_2056_A1[] = { {0xFFFF, 0, 0, 0, 0} }; -radio_regs_t regs_RX_2056_A1[] = { +struct radio_regs regs_RX_2056_A1[] = { {0x02, 0, 0, 0, 0}, {0x03, 0, 0, 0, 0}, {0x04, 0, 0, 0, 0}, @@ -8930,7 +8932,7 @@ radio_regs_t regs_RX_2056_A1[] = { {0xFFFF, 0, 0, 0, 0} }; -radio_regs_t regs_SYN_2056_rev5[] = { +struct radio_regs regs_SYN_2056_rev5[] = { {0x02, 0, 0, 0, 0}, {0x03, 0, 0, 0, 0}, {0x04, 0, 0, 0, 0}, @@ -9115,7 +9117,7 @@ radio_regs_t regs_SYN_2056_rev5[] = { {0xFFFF, 0, 0, 0, 0} }; -radio_regs_t regs_TX_2056_rev5[] = { +struct radio_regs regs_TX_2056_rev5[] = { {0x02, 0, 0, 0, 0}, {0x03, 0, 0, 0, 0}, {0x04, 0, 0, 0, 0}, @@ -9272,7 +9274,7 @@ radio_regs_t regs_TX_2056_rev5[] = { {0xFFFF, 0, 0, 0, 0} }; -radio_regs_t regs_RX_2056_rev5[] = { +struct radio_regs regs_RX_2056_rev5[] = { {0x02, 0, 0, 0, 0}, {0x03, 0, 0, 0, 0}, {0x04, 0, 0, 0, 0}, @@ -9423,7 +9425,7 @@ radio_regs_t regs_RX_2056_rev5[] = { {0xFFFF, 0, 0, 0, 0} }; -radio_regs_t regs_SYN_2056_rev6[] = { +struct radio_regs regs_SYN_2056_rev6[] = { {0x02, 0, 0, 0, 0}, {0x03, 0, 0, 0, 0}, {0x04, 0, 0, 0, 0}, @@ -9608,7 +9610,7 @@ radio_regs_t regs_SYN_2056_rev6[] = { {0xFFFF, 0, 0, 0, 0} }; -radio_regs_t regs_TX_2056_rev6[] = { +struct radio_regs regs_TX_2056_rev6[] = { {0x02, 0, 0, 0, 0}, {0x03, 0, 0, 0, 0}, {0x04, 0, 0, 0, 0}, @@ -9765,7 +9767,7 @@ radio_regs_t regs_TX_2056_rev6[] = { {0xFFFF, 0, 0, 0, 0} }; -radio_regs_t regs_RX_2056_rev6[] = { +struct radio_regs regs_RX_2056_rev6[] = { {0x02, 0, 0, 0, 0}, {0x03, 0, 0, 0, 0}, {0x04, 0, 0, 0, 0}, @@ -9916,7 +9918,7 @@ radio_regs_t regs_RX_2056_rev6[] = { {0xFFFF, 0, 0, 0, 0} }; -radio_regs_t regs_SYN_2056_rev7[] = { +struct radio_regs regs_SYN_2056_rev7[] = { {0x02, 0, 0, 0, 0}, {0x03, 0, 0, 0, 0}, {0x04, 0, 0, 0, 0}, @@ -10101,7 +10103,7 @@ radio_regs_t regs_SYN_2056_rev7[] = { {0xFFFF, 0, 0, 0, 0}, }; -radio_regs_t regs_TX_2056_rev7[] = { +struct radio_regs regs_TX_2056_rev7[] = { {0x02, 0, 0, 0, 0}, {0x03, 0, 0, 0, 0}, {0x04, 0, 0, 0, 0}, @@ -10258,7 +10260,7 @@ radio_regs_t regs_TX_2056_rev7[] = { {0xFFFF, 0, 0, 0, 0}, }; -radio_regs_t regs_RX_2056_rev7[] = { +struct radio_regs regs_RX_2056_rev7[] = { {0x02, 0, 0, 0, 0}, {0x03, 0, 0, 0, 0}, {0x04, 0, 0, 0, 0}, @@ -10409,7 +10411,7 @@ radio_regs_t regs_RX_2056_rev7[] = { {0xFFFF, 0, 0, 0, 0}, }; -radio_regs_t regs_SYN_2056_rev8[] = { +struct radio_regs regs_SYN_2056_rev8[] = { {0x02, 0, 0, 0, 0}, {0x03, 0, 0, 0, 0}, {0x04, 0, 0, 0, 0}, @@ -10594,7 +10596,7 @@ radio_regs_t regs_SYN_2056_rev8[] = { {0xFFFF, 0, 0, 0, 0}, }; -radio_regs_t regs_TX_2056_rev8[] = { +struct radio_regs regs_TX_2056_rev8[] = { {0x02, 0, 0, 0, 0}, {0x03, 0, 0, 0, 0}, {0x04, 0, 0, 0, 0}, @@ -10751,7 +10753,7 @@ radio_regs_t regs_TX_2056_rev8[] = { {0xFFFF, 0, 0, 0, 0}, }; -radio_regs_t regs_RX_2056_rev8[] = { +struct radio_regs regs_RX_2056_rev8[] = { {0x02, 0, 0, 0, 0}, {0x03, 0, 0, 0, 0}, {0x04, 0, 0, 0, 0}, @@ -10902,7 +10904,7 @@ radio_regs_t regs_RX_2056_rev8[] = { {0xFFFF, 0, 0, 0, 0}, }; -radio_regs_t regs_SYN_2056_rev11[] = { +struct radio_regs regs_SYN_2056_rev11[] = { {0x02, 0, 0, 0, 0}, {0x03, 0, 0, 0, 0}, {0x04, 0, 0, 0, 0}, @@ -11087,7 +11089,7 @@ radio_regs_t regs_SYN_2056_rev11[] = { {0xFFFF, 0, 0, 0, 0}, }; -radio_regs_t regs_TX_2056_rev11[] = { +struct radio_regs regs_TX_2056_rev11[] = { {0x02, 0, 0, 0, 0}, {0x03, 0, 0, 0, 0}, {0x04, 0, 0, 0, 0}, @@ -11244,7 +11246,7 @@ radio_regs_t regs_TX_2056_rev11[] = { {0xFFFF, 0, 0, 0, 0}, }; -radio_regs_t regs_RX_2056_rev11[] = { +struct radio_regs regs_RX_2056_rev11[] = { {0x02, 0, 0, 0, 0}, {0x03, 0, 0, 0, 0}, {0x04, 0, 0, 0, 0}, @@ -11395,7 +11397,7 @@ radio_regs_t regs_RX_2056_rev11[] = { {0xFFFF, 0, 0, 0, 0}, }; -radio_20xx_regs_t regs_2057_rev4[] = { +struct radio_20xx_regs regs_2057_rev4[] = { {0x00, 0x84, 0}, {0x01, 0, 0}, {0x02, 0x60, 0}, @@ -11785,7 +11787,7 @@ radio_20xx_regs_t regs_2057_rev4[] = { {0xFFFF, 0, 0}, }; -radio_20xx_regs_t regs_2057_rev5[] = { +struct radio_20xx_regs regs_2057_rev5[] = { {0x00, 0, 1}, {0x01, 0x57, 1}, {0x02, 0x20, 1}, @@ -12117,7 +12119,7 @@ radio_20xx_regs_t regs_2057_rev5[] = { {0xFFFF, 0, 0} }; -radio_20xx_regs_t regs_2057_rev5v1[] = { +struct radio_20xx_regs regs_2057_rev5v1[] = { {0x00, 0x15, 1}, {0x01, 0x57, 1}, {0x02, 0x20, 1}, @@ -12449,7 +12451,7 @@ radio_20xx_regs_t regs_2057_rev5v1[] = { {0xFFFF, 0, 0} }; -radio_20xx_regs_t regs_2057_rev7[] = { +struct radio_20xx_regs regs_2057_rev7[] = { {0x00, 0, 1}, {0x01, 0x57, 1}, {0x02, 0x20, 1}, @@ -12865,7 +12867,7 @@ radio_20xx_regs_t regs_2057_rev7[] = { {0xFFFF, 0, 0} }; -radio_20xx_regs_t regs_2057_rev8[] = { +struct radio_20xx_regs regs_2057_rev8[] = { {0x00, 0x8, 1}, {0x01, 0x57, 1}, {0x02, 0x20, 1}, @@ -14084,12 +14086,12 @@ static u8 ant_sw_ctrl_tbl_rev8_2057v7_core1[] = { 0x09, 0x0a, 0x09, 0x0a, 0x15, 0x16 }; static bool wlc_phy_chan2freq_nphy(phy_info_t *pi, uint channel, int *f, - chan_info_nphy_radio2057_t **t0, - chan_info_nphy_radio205x_t **t1, - chan_info_nphy_radio2057_rev5_t **t2, - chan_info_nphy_2055_t **t3); + struct chan_info_nphy_radio2057 **t0, + struct chan_info_nphy_radio205x **t1, + struct chan_info_nphy_radio2057_rev5 **t2, + struct chan_info_nphy_2055 **t3); static void wlc_phy_chanspec_nphy_setup(phy_info_t *pi, chanspec_t chans, - const nphy_sfo_cfg_t *c); + const struct nphy_sfo_cfg *c); static void wlc_phy_adjust_rx_analpfbw_nphy(phy_info_t *pi, u16 reduction_factr); @@ -14116,7 +14118,7 @@ static void wlc_phy_adjust_lnagaintbl_nphy(phy_info_t *pi); static void wlc_phy_restore_rssical_nphy(phy_info_t *pi); static void wlc_phy_reapply_txcal_coeffs_nphy(phy_info_t *pi); static void wlc_phy_tx_iq_war_nphy(phy_info_t *pi); -static int wlc_phy_cal_rxiq_nphy_rev3(phy_info_t *pi, nphy_txgains_t tg, +static int wlc_phy_cal_rxiq_nphy_rev3(phy_info_t *pi, struct nphy_txgains tg, u8 type, bool d); static void wlc_phy_rxcal_gainctrl_nphy_rev5(phy_info_t *pi, u8 rxcore, u16 *rg, u8 type); @@ -14140,12 +14142,12 @@ static u32 *wlc_phy_get_ipa_gaintbl_nphy(phy_info_t *pi); static void wlc_phy_a1_nphy(phy_info_t *pi, u8 core, u32 winsz, u32, u32 e); static u8 wlc_phy_a3_nphy(phy_info_t *pi, u8 start_gain, u8 core); -static void wlc_phy_a2_nphy(phy_info_t *pi, nphy_ipa_txcalgains_t *, - phy_cal_mode_t, u8); +static void wlc_phy_a2_nphy(phy_info_t *pi, struct nphy_ipa_txcalgains *, + enum phy_cal_mode, u8); static void wlc_phy_papd_cal_cleanup_nphy(phy_info_t *pi, - nphy_papd_restore_state *state); + struct nphy_papd_restore_state *state); static void wlc_phy_papd_cal_setup_nphy(phy_info_t *pi, - nphy_papd_restore_state *state, u8); + struct nphy_papd_restore_state *state, u8); static void wlc_phy_clip_det_nphy(phy_info_t *pi, u8 write, u16 *vals); @@ -14246,7 +14248,7 @@ void wlc_phy_table_write_nphy(phy_info_t *pi, u32 id, u32 len, u32 offset, u32 width, const void *data) { - mimophytbl_info_t tbl; + struct phytbl_info tbl; tbl.tbl_id = id; tbl.tbl_len = len; @@ -14260,7 +14262,7 @@ void wlc_phy_table_read_nphy(phy_info_t *pi, u32 id, u32 len, u32 offset, u32 width, void *data) { - mimophytbl_info_t tbl; + struct phytbl_info tbl; tbl.tbl_id = id; tbl.tbl_len = len; @@ -14525,7 +14527,7 @@ void WLBANDINITFN(wlc_phy_init_nphy) (phy_info_t *pi) { u16 val; u16 clip1_ths[2]; - nphy_txgains_t target_gain; + struct nphy_txgains target_gain; u8 tx_pwr_ctrl_state; bool do_nphy_cal = false; uint core; @@ -17442,9 +17444,9 @@ static void wlc_phy_radio_preinit_205x(phy_info_t *pi) static void wlc_phy_radio_init_2056(phy_info_t *pi) { - radio_regs_t *regs_SYN_2056_ptr = NULL; - radio_regs_t *regs_TX_2056_ptr = NULL; - radio_regs_t *regs_RX_2056_ptr = NULL; + struct radio_regs *regs_SYN_2056_ptr = NULL; + struct radio_regs *regs_TX_2056_ptr = NULL; + struct radio_regs *regs_RX_2056_ptr = NULL; if (NREV_IS(pi->pubpi.phy_rev, 3)) { regs_SYN_2056_ptr = regs_SYN_2056; @@ -17530,7 +17532,7 @@ static void wlc_phy_radio_postinit_2056(phy_info_t *pi) static void wlc_phy_radio_init_2057(phy_info_t *pi) { - radio_20xx_regs_t *regs_2057_ptr = NULL; + struct radio_20xx_regs *regs_2057_ptr = NULL; if (NREV_IS(pi->pubpi.phy_rev, 7)) { @@ -17590,15 +17592,15 @@ static void wlc_phy_radio_postinit_2057(phy_info_t *pi) static bool wlc_phy_chan2freq_nphy(phy_info_t *pi, uint channel, int *f, - chan_info_nphy_radio2057_t **t0, - chan_info_nphy_radio205x_t **t1, - chan_info_nphy_radio2057_rev5_t **t2, - chan_info_nphy_2055_t **t3) + struct chan_info_nphy_radio2057 **t0, + struct chan_info_nphy_radio205x **t1, + struct chan_info_nphy_radio2057_rev5 **t2, + struct chan_info_nphy_2055 **t3) { uint i; - chan_info_nphy_radio2057_t *chan_info_tbl_p_0 = NULL; - chan_info_nphy_radio205x_t *chan_info_tbl_p_1 = NULL; - chan_info_nphy_radio2057_rev5_t *chan_info_tbl_p_2 = NULL; + struct chan_info_nphy_radio2057 *chan_info_tbl_p_0 = NULL; + struct chan_info_nphy_radio205x *chan_info_tbl_p_1 = NULL; + struct chan_info_nphy_radio2057_rev5 *chan_info_tbl_p_2 = NULL; u32 tbl_len = 0; int freq = 0; @@ -17760,10 +17762,10 @@ wlc_phy_chan2freq_nphy(phy_info_t *pi, uint channel, int *f, u8 wlc_phy_get_chan_freq_range_nphy(phy_info_t *pi, uint channel) { int freq; - chan_info_nphy_radio2057_t *t0 = NULL; - chan_info_nphy_radio205x_t *t1 = NULL; - chan_info_nphy_radio2057_rev5_t *t2 = NULL; - chan_info_nphy_2055_t *t3 = NULL; + struct chan_info_nphy_radio2057 *t0 = NULL; + struct chan_info_nphy_radio205x *t1 = NULL; + struct chan_info_nphy_radio2057_rev5 *t2 = NULL; + struct chan_info_nphy_2055 *t3 = NULL; if (NORADIO_ENAB(pi->pubpi)) return WL_CHAN_FREQ_RANGE_2G; @@ -17786,7 +17788,7 @@ u8 wlc_phy_get_chan_freq_range_nphy(phy_info_t *pi, uint channel) } static void -wlc_phy_chanspec_radio2055_setup(phy_info_t *pi, chan_info_nphy_2055_t *ci) +wlc_phy_chanspec_radio2055_setup(phy_info_t *pi, struct chan_info_nphy_2055 *ci) { write_radio_reg(pi, RADIO_2055_PLL_REF, ci->RF_pll_ref); @@ -17849,9 +17851,9 @@ wlc_phy_chanspec_radio2055_setup(phy_info_t *pi, chan_info_nphy_2055_t *ci) static void wlc_phy_chanspec_radio2056_setup(phy_info_t *pi, - const chan_info_nphy_radio205x_t *ci) + const struct chan_info_nphy_radio205x *ci) { - radio_regs_t *regs_SYN_2056_ptr = NULL; + struct radio_regs *regs_SYN_2056_ptr = NULL; write_radio_reg(pi, RADIO_2056_SYN_PLL_VCOCAL1 | RADIO_2056_SYN, @@ -18292,8 +18294,8 @@ static u16 wlc_phy_radio205x_rcal(phy_info_t *pi) static void wlc_phy_chanspec_radio2057_setup(phy_info_t *pi, - const chan_info_nphy_radio2057_t *ci, - const chan_info_nphy_radio2057_rev5_t *ci2) + const struct chan_info_nphy_radio2057 *ci, + const struct chan_info_nphy_radio2057_rev5 *ci2) { int coreNum; u16 txmix2g_tune_boost_pu = 0; @@ -18910,7 +18912,7 @@ static void wlc_phy_spurwar_nphy(phy_info_t *pi) static void wlc_phy_chanspec_nphy_setup(phy_info_t *pi, chanspec_t chanspec, - const nphy_sfo_cfg_t *ci) + const struct nphy_sfo_cfg *ci) { u16 val; @@ -19047,10 +19049,10 @@ wlc_phy_chanspec_nphy_setup(phy_info_t *pi, chanspec_t chanspec, void wlc_phy_chanspec_set_nphy(phy_info_t *pi, chanspec_t chanspec) { int freq; - chan_info_nphy_radio2057_t *t0 = NULL; - chan_info_nphy_radio205x_t *t1 = NULL; - chan_info_nphy_radio2057_rev5_t *t2 = NULL; - chan_info_nphy_2055_t *t3 = NULL; + struct chan_info_nphy_radio2057 *t0 = NULL; + struct chan_info_nphy_radio205x *t1 = NULL; + struct chan_info_nphy_radio2057_rev5 *t2 = NULL; + struct chan_info_nphy_2055 *t3 = NULL; if (NORADIO_ENAB(pi->pubpi)) { return; @@ -19097,12 +19099,9 @@ void wlc_phy_chanspec_set_nphy(phy_info_t *pi, chanspec_t chanspec) wlc_phy_chanspec_radio2057_setup(pi, t0, t2); wlc_phy_chanspec_nphy_setup(pi, chanspec, - (pi->pubpi.radiorev == - 5) ? (const nphy_sfo_cfg_t - *)&(t2-> - PHY_BW1a) - : (const nphy_sfo_cfg_t *) - &(t0->PHY_BW1a)); + (pi->pubpi.radiorev == 5) ? + (const struct nphy_sfo_cfg *)&(t2->PHY_BW1a) : + (const struct nphy_sfo_cfg *)&(t0->PHY_BW1a)); } else { @@ -19113,8 +19112,7 @@ void wlc_phy_chanspec_set_nphy(phy_info_t *pi, chanspec_t chanspec) wlc_phy_chanspec_radio2056_setup(pi, t1); wlc_phy_chanspec_nphy_setup(pi, chanspec, - (const nphy_sfo_cfg_t *) - &(t1->PHY_BW1a)); + (const struct nphy_sfo_cfg *) &(t1->PHY_BW1a)); } } else { @@ -19125,7 +19123,7 @@ void wlc_phy_chanspec_set_nphy(phy_info_t *pi, chanspec_t chanspec) wlc_phy_chanspec_radio2055_setup(pi, t3); wlc_phy_chanspec_nphy_setup(pi, chanspec, - (const nphy_sfo_cfg_t *)&(t3-> + (const struct nphy_sfo_cfg *)&(t3-> PHY_BW1a)); } @@ -21369,9 +21367,9 @@ static void wlc_phy_rssi_cal_nphy_rev2(phy_info_t *pi, u8 rssi_type) } int -wlc_phy_rssi_compute_nphy(phy_info_t *pi, wlc_d11rxhdr_t *wlc_rxh) +wlc_phy_rssi_compute_nphy(phy_info_t *pi, struct brcms_d11rxhdr *wlc_rxh) { - d11rxhdr_t *rxh = &wlc_rxh->rxhdr; + struct d11rxhdr *rxh = &wlc_rxh->rxhdr; s16 rxpwr, rxpwr0, rxpwr1; s16 phyRx0_l, phyRx2_l; @@ -22464,11 +22462,11 @@ void wlc_phy_stopplayback_nphy(phy_info_t *pi) wlc_phy_stay_in_carriersearch_nphy(pi, false); } -nphy_txgains_t wlc_phy_get_tx_gain_nphy(phy_info_t *pi) +struct nphy_txgains wlc_phy_get_tx_gain_nphy(phy_info_t *pi) { u16 base_idx[2], curr_gain[2]; u8 core_no; - nphy_txgains_t target_gain; + struct nphy_txgains target_gain; u32 *tx_pwrctrl_tbl = NULL; if (pi->nphy_txpwrctrl == PHY_TPC_HW_OFF) { @@ -22623,8 +22621,8 @@ nphy_txgains_t wlc_phy_get_tx_gain_nphy(phy_info_t *pi) static void wlc_phy_iqcal_gainparams_nphy(phy_info_t *pi, u16 core_no, - nphy_txgains_t target_gain, - nphy_iqcal_params_t *params) + struct nphy_txgains target_gain, + struct nphy_iqcal_params *params) { u8 k; int idx; @@ -23700,13 +23698,13 @@ static void wlc_phy_update_txcal_ladder_nphy(phy_info_t *pi, u16 core) u16 bbmult; u16 tblentry; - nphy_txiqcal_ladder_t ladder_lo[] = { + struct nphy_txiqcal_ladder ladder_lo[] = { {3, 0}, {4, 0}, {6, 0}, {9, 0}, {13, 0}, {18, 0}, {25, 0}, {25, 1}, {25, 2}, {25, 3}, {25, 4}, {25, 5}, {25, 6}, {25, 7}, {35, 7}, {50, 7}, {71, 7}, {100, 7} }; - nphy_txiqcal_ladder_t ladder_iq[] = { + struct nphy_txiqcal_ladder ladder_iq[] = { {3, 0}, {4, 0}, {6, 0}, {9, 0}, {13, 0}, {18, 0}, {25, 0}, {35, 0}, {50, 0}, {71, 0}, {100, 0}, {100, 1}, {100, 2}, {100, 3}, {100, 4}, {100, 5}, {100, 6}, {100, 7} @@ -23737,7 +23735,7 @@ static void wlc_phy_update_txcal_ladder_nphy(phy_info_t *pi, u16 core) void wlc_phy_cal_perical_nphy_run(phy_info_t *pi, u8 caltype) { - nphy_txgains_t target_gain; + struct nphy_txgains target_gain; u8 tx_pwr_ctrl_state; bool fullcal = true; bool restore_tx_gain = false; @@ -23987,7 +23985,7 @@ void wlc_phy_cal_perical_nphy_run(phy_info_t *pi, u8 caltype) } int -wlc_phy_cal_txiqlo_nphy(phy_info_t *pi, nphy_txgains_t target_gain, +wlc_phy_cal_txiqlo_nphy(phy_info_t *pi, struct nphy_txgains target_gain, bool fullcal, bool mphase) { u16 val; @@ -24002,7 +24000,7 @@ wlc_phy_cal_txiqlo_nphy(phy_info_t *pi, nphy_txgains_t target_gain, u16 tone_freq; u16 gain_save[2]; u16 cal_gain[2]; - nphy_iqcal_params_t cal_params[2]; + struct nphy_iqcal_params cal_params[2]; u32 tbl_len; void *tbl_ptr; bool ladder_updated[2]; @@ -24394,7 +24392,7 @@ static void wlc_phy_reapply_txcal_coeffs_nphy(phy_info_t *pi) static void wlc_phy_tx_iq_war_nphy(phy_info_t *pi) { - nphy_iq_comp_t tx_comp; + struct nphy_iq_comp tx_comp; wlc_phy_table_read_nphy(pi, 15, 4, 0x50, 16, (void *)&tx_comp); @@ -24405,7 +24403,7 @@ static void wlc_phy_tx_iq_war_nphy(phy_info_t *pi) } void -wlc_phy_rx_iq_coeffs_nphy(phy_info_t *pi, u8 write, nphy_iq_comp_t *pcomp) +wlc_phy_rx_iq_coeffs_nphy(phy_info_t *pi, u8 write, struct nphy_iq_comp *pcomp) { if (write) { write_phy_reg(pi, 0x9a, pcomp->a0); @@ -24421,7 +24419,7 @@ wlc_phy_rx_iq_coeffs_nphy(phy_info_t *pi, u8 write, nphy_iq_comp_t *pcomp) } void -wlc_phy_rx_iq_est_nphy(phy_info_t *pi, phy_iq_est_t *est, u16 num_samps, +wlc_phy_rx_iq_est_nphy(phy_info_t *pi, struct phy_iq_est *est, u16 num_samps, u8 wait_time, u8 wait_for_crs) { u8 core; @@ -24458,8 +24456,8 @@ wlc_phy_rx_iq_est_nphy(phy_info_t *pi, phy_iq_est_t *est, u16 num_samps, static void wlc_phy_calc_rx_iq_comp_nphy(phy_info_t *pi, u8 core_mask) { u8 curr_core; - phy_iq_est_t est[PHY_CORE_MAX]; - nphy_iq_comp_t old_comp, new_comp; + struct phy_iq_est est[PHY_CORE_MAX]; + struct nphy_iq_comp old_comp, new_comp; s32 iq = 0; u32 ii = 0, qq = 0; s16 iq_nbits, qq_nbits, brsh, arsh; @@ -25205,9 +25203,9 @@ wlc_phy_rxcal_gainctrl_nphy_rev5(phy_info_t *pi, u8 rx_core, { u16 num_samps; - phy_iq_est_t est[PHY_CORE_MAX]; + struct phy_iq_est est[PHY_CORE_MAX]; u8 tx_core; - nphy_iq_comp_t save_comp, zero_comp; + struct nphy_iq_comp save_comp, zero_comp; u32 i_pwr, q_pwr, curr_pwr, optim_pwr = 0, prev_pwr = 0, thresh_pwr = 10000; s16 desired_log2_pwr, actual_log2_pwr, delta_pwr; @@ -25216,7 +25214,7 @@ wlc_phy_rxcal_gainctrl_nphy_rev5(phy_info_t *pi, u8 rx_core, s8 optim_gaintbl_index = 0, prev_gaintbl_index = 0; s8 curr_gaintbl_index = 3; u8 gainctrl_dirn = NPHY_RXCAL_GAIN_INIT; - nphy_ipa_txrxgain_t *nphy_rxcal_gaintbl; + struct nphy_ipa_txrxgain *nphy_rxcal_gaintbl; u16 hpvga, lpf_biq1, lpf_biq0, lna2, lna1; int fine_gain_idx; s8 txpwrindex; @@ -25447,7 +25445,7 @@ wlc_phy_rc_sweep_nphy(phy_info_t *pi, u8 core_idx, u8 loopback_type) u16 rccal_val, last_rccal_val = 0, best_rccal_val = 0; u32 ref_iq_vals = 0, target_iq_vals = 0; u16 num_samps, log_num_samps = 10; - phy_iq_est_t est[PHY_CORE_MAX]; + struct phy_iq_est est[PHY_CORE_MAX]; if (NREV_GE(pi->pubpi.phy_rev, 7)) { return 0; @@ -25656,7 +25654,7 @@ wlc_phy_rc_sweep_nphy(phy_info_t *pi, u8 core_idx, u8 loopback_type) #define WAIT_FOR_SCOPE 4000 static int -wlc_phy_cal_rxiq_nphy_rev3(phy_info_t *pi, nphy_txgains_t target_gain, +wlc_phy_cal_rxiq_nphy_rev3(phy_info_t *pi, struct nphy_txgains target_gain, u8 cal_type, bool debug) { u16 orig_BBConfig; @@ -25664,7 +25662,7 @@ wlc_phy_cal_rxiq_nphy_rev3(phy_info_t *pi, nphy_txgains_t target_gain, u8 best_rccal[2]; u16 gain_save[2]; u16 cal_gain[2]; - nphy_iqcal_params_t cal_params[2]; + struct nphy_iqcal_params cal_params[2]; u8 rxcore_state; s8 rxlpf_rccal_hpc, txlpf_rccal_lpc; s8 txlpf_idac; @@ -25813,10 +25811,10 @@ wlc_phy_cal_rxiq_nphy_rev3(phy_info_t *pi, nphy_txgains_t target_gain, } static int -wlc_phy_cal_rxiq_nphy_rev2(phy_info_t *pi, nphy_txgains_t target_gain, +wlc_phy_cal_rxiq_nphy_rev2(phy_info_t *pi, struct nphy_txgains target_gain, bool debug) { - phy_iq_est_t est[PHY_CORE_MAX]; + struct phy_iq_est est[PHY_CORE_MAX]; u8 core_num, rx_core, tx_core; u16 lna_vals[] = { 0x3, 0x3, 0x1 }; u16 hpf1_vals[] = { 0x7, 0x2, 0x0 }; @@ -25832,7 +25830,7 @@ wlc_phy_cal_rxiq_nphy_rev2(phy_info_t *pi, nphy_txgains_t target_gain, u16 core_no; u16 gain_save[2]; u16 cal_gain[2]; - nphy_iqcal_params_t cal_params[2]; + struct nphy_iqcal_params cal_params[2]; u8 phy_bw; int bcmerror = 0; bool first_playtone = true; @@ -26039,7 +26037,7 @@ wlc_phy_cal_rxiq_nphy_rev2(phy_info_t *pi, nphy_txgains_t target_gain, } int -wlc_phy_cal_rxiq_nphy(phy_info_t *pi, nphy_txgains_t target_gain, +wlc_phy_cal_rxiq_nphy(phy_info_t *pi, struct nphy_txgains target_gain, u8 cal_type, bool debug) { if (NREV_GE(pi->pubpi.phy_rev, 7)) { @@ -26200,8 +26198,8 @@ static u32 *wlc_phy_get_ipa_gaintbl_nphy(phy_info_t *pi) } static void -wlc_phy_papd_cal_setup_nphy(phy_info_t *pi, nphy_papd_restore_state *state, - u8 core) +wlc_phy_papd_cal_setup_nphy(phy_info_t *pi, + struct nphy_papd_restore_state *state, u8 core) { s32 tone_freq; u8 off_core; @@ -26470,7 +26468,8 @@ wlc_phy_papd_cal_setup_nphy(phy_info_t *pi, nphy_papd_restore_state *state, } static void -wlc_phy_papd_cal_cleanup_nphy(phy_info_t *pi, nphy_papd_restore_state *state) +wlc_phy_papd_cal_cleanup_nphy(phy_info_t *pi, + struct nphy_papd_restore_state *state) { u8 core; @@ -26648,15 +26647,15 @@ wlc_phy_a1_nphy(phy_info_t *pi, u8 core, u32 winsz, u32 start, } static void -wlc_phy_a2_nphy(phy_info_t *pi, nphy_ipa_txcalgains_t *txgains, - phy_cal_mode_t cal_mode, u8 core) +wlc_phy_a2_nphy(phy_info_t *pi, struct nphy_ipa_txcalgains *txgains, + enum phy_cal_mode cal_mode, u8 core) { u16 phy_a1, phy_a2, phy_a3; u16 phy_a4, phy_a5; bool phy_a6; u8 phy_a7, m[2]; u32 phy_a8 = 0; - nphy_txgains_t phy_a9; + struct nphy_txgains phy_a9; if (NREV_LT(pi->pubpi.phy_rev, 3)) return; @@ -26942,7 +26941,7 @@ static u8 wlc_phy_a3_nphy(phy_info_t *pi, u8 start_gain, u8 core) int phy_a1; int phy_a2; bool phy_a3; - nphy_ipa_txcalgains_t phy_a4; + struct nphy_ipa_txcalgains phy_a4; bool phy_a5 = false; bool phy_a6 = true; s32 phy_a7, phy_a8; @@ -27100,8 +27099,8 @@ static u8 wlc_phy_a3_nphy(phy_info_t *pi, u8 start_gain, u8 core) static void wlc_phy_a4(phy_info_t *pi, bool full_cal) { - nphy_ipa_txcalgains_t phy_b1[2]; - nphy_papd_restore_state phy_b2; + struct nphy_ipa_txcalgains phy_b1[2]; + struct nphy_papd_restore_state phy_b2; bool phy_b3; u8 phy_b4; u8 phy_b5; diff --git a/drivers/staging/brcm80211/brcmsmac/phy/phytbl_lcn.c b/drivers/staging/brcm80211/brcmsmac/phy/phytbl_lcn.c index 5b6538f20410..023d05aa97ad 100644 --- a/drivers/staging/brcm80211/brcmsmac/phy/phytbl_lcn.c +++ b/drivers/staging/brcm80211/brcmsmac/phy/phytbl_lcn.c @@ -1505,7 +1505,7 @@ const u32 dot11lcn_gain_tbl_5G[] = { 0x00000000 }; -const dot11lcnphytbl_info_t dot11lcnphytbl_rx_gain_info_rev0[] = { +const struct phytbl_info dot11lcnphytbl_rx_gain_info_rev0[] = { {&dot11lcn_gain_tbl_rev0, sizeof(dot11lcn_gain_tbl_rev0) / sizeof(dot11lcn_gain_tbl_rev0[0]), 18, 0, 32} @@ -1520,7 +1520,7 @@ const dot11lcnphytbl_info_t dot11lcnphytbl_rx_gain_info_rev0[] = { , }; -const dot11lcnphytbl_info_t dot11lcnphytbl_rx_gain_info_rev1[] = { +const struct phytbl_info dot11lcnphytbl_rx_gain_info_rev1[] = { {&dot11lcn_gain_tbl_rev1, sizeof(dot11lcn_gain_tbl_rev1) / sizeof(dot11lcn_gain_tbl_rev1[0]), 18, 0, 32} @@ -1535,7 +1535,7 @@ const dot11lcnphytbl_info_t dot11lcnphytbl_rx_gain_info_rev1[] = { , }; -const dot11lcnphytbl_info_t dot11lcnphytbl_rx_gain_info_2G_rev2[] = { +const struct phytbl_info dot11lcnphytbl_rx_gain_info_2G_rev2[] = { {&dot11lcn_gain_tbl_2G, sizeof(dot11lcn_gain_tbl_2G) / sizeof(dot11lcn_gain_tbl_2G[0]), 18, 0, 32} @@ -1553,7 +1553,7 @@ const dot11lcnphytbl_info_t dot11lcnphytbl_rx_gain_info_2G_rev2[] = { 17, 0, 8} }; -const dot11lcnphytbl_info_t dot11lcnphytbl_rx_gain_info_5G_rev2[] = { +const struct phytbl_info dot11lcnphytbl_rx_gain_info_5G_rev2[] = { {&dot11lcn_gain_tbl_5G, sizeof(dot11lcn_gain_tbl_5G) / sizeof(dot11lcn_gain_tbl_5G[0]), 18, 0, 32} @@ -1571,7 +1571,7 @@ const dot11lcnphytbl_info_t dot11lcnphytbl_rx_gain_info_5G_rev2[] = { 17, 0, 8} }; -const dot11lcnphytbl_info_t dot11lcnphytbl_rx_gain_info_extlna_2G_rev2[] = { +const struct phytbl_info dot11lcnphytbl_rx_gain_info_extlna_2G_rev2[] = { {&dot11lcn_gain_tbl_extlna_2G, sizeof(dot11lcn_gain_tbl_extlna_2G) / sizeof(dot11lcn_gain_tbl_extlna_2G[0]), 18, 0, 32} @@ -1589,7 +1589,7 @@ const dot11lcnphytbl_info_t dot11lcnphytbl_rx_gain_info_extlna_2G_rev2[] = { sizeof(dot11lcn_gain_val_tbl_extlna_2G[0]), 17, 0, 8} }; -const dot11lcnphytbl_info_t dot11lcnphytbl_rx_gain_info_extlna_5G_rev2[] = { +const struct phytbl_info dot11lcnphytbl_rx_gain_info_extlna_5G_rev2[] = { {&dot11lcn_gain_tbl_5G, sizeof(dot11lcn_gain_tbl_5G) / sizeof(dot11lcn_gain_tbl_5G[0]), 18, 0, 32} @@ -2773,7 +2773,7 @@ const u32 dot11lcn_papd_compdelta_tbl_rev0[] = { 0x00080000, }; -const dot11lcnphytbl_info_t dot11lcnphytbl_info_rev0[] = { +const struct phytbl_info dot11lcnphytbl_info_rev0[] = { {&dot11lcn_min_sig_sq_tbl_rev0, sizeof(dot11lcn_min_sig_sq_tbl_rev0) / sizeof(dot11lcn_min_sig_sq_tbl_rev0[0]), 2, 0, 16} @@ -2832,25 +2832,25 @@ const dot11lcnphytbl_info_t dot11lcnphytbl_info_rev0[] = { , }; -const dot11lcnphytbl_info_t dot11lcn_sw_ctrl_tbl_info_4313 = { +const struct phytbl_info dot11lcn_sw_ctrl_tbl_info_4313 = { &dot11lcn_sw_ctrl_tbl_4313_rev0, sizeof(dot11lcn_sw_ctrl_tbl_4313_rev0) / sizeof(dot11lcn_sw_ctrl_tbl_4313_rev0[0]), 15, 0, 16 }; -const dot11lcnphytbl_info_t dot11lcn_sw_ctrl_tbl_info_4313_epa = { +const struct phytbl_info dot11lcn_sw_ctrl_tbl_info_4313_epa = { &dot11lcn_sw_ctrl_tbl_4313_epa_rev0, sizeof(dot11lcn_sw_ctrl_tbl_4313_epa_rev0) / sizeof(dot11lcn_sw_ctrl_tbl_4313_epa_rev0[0]), 15, 0, 16 }; -const dot11lcnphytbl_info_t dot11lcn_sw_ctrl_tbl_info_4313_bt_epa = { +const struct phytbl_info dot11lcn_sw_ctrl_tbl_info_4313_bt_epa = { &dot11lcn_sw_ctrl_tbl_4313_epa_rev0_combo, sizeof(dot11lcn_sw_ctrl_tbl_4313_epa_rev0_combo) / sizeof(dot11lcn_sw_ctrl_tbl_4313_epa_rev0_combo[0]), 15, 0, 16 }; -const dot11lcnphytbl_info_t dot11lcn_sw_ctrl_tbl_info_4313_bt_epa_p250 = { +const struct phytbl_info dot11lcn_sw_ctrl_tbl_info_4313_bt_epa_p250 = { &dot11lcn_sw_ctrl_tbl_4313_bt_epa_p250_rev0, sizeof(dot11lcn_sw_ctrl_tbl_4313_bt_epa_p250_rev0) / sizeof(dot11lcn_sw_ctrl_tbl_4313_bt_epa_p250_rev0[0]), 15, 0, 16 @@ -2859,7 +2859,8 @@ const dot11lcnphytbl_info_t dot11lcn_sw_ctrl_tbl_info_4313_bt_epa_p250 = { const u32 dot11lcnphytbl_info_sz_rev0 = sizeof(dot11lcnphytbl_info_rev0) / sizeof(dot11lcnphytbl_info_rev0[0]); -const lcnphy_tx_gain_tbl_entry dot11lcnphy_2GHz_extPA_gaintable_rev0[128] = { +const struct lcnphy_tx_gain_tbl_entry +dot11lcnphy_2GHz_extPA_gaintable_rev0[128] = { {3, 0, 31, 0, 72,} , {3, 0, 31, 0, 70,} @@ -3118,7 +3119,7 @@ const lcnphy_tx_gain_tbl_entry dot11lcnphy_2GHz_extPA_gaintable_rev0[128] = { , }; -const lcnphy_tx_gain_tbl_entry dot11lcnphy_2GHz_gaintable_rev0[128] = { +const struct lcnphy_tx_gain_tbl_entry dot11lcnphy_2GHz_gaintable_rev0[128] = { {7, 0, 31, 0, 72,} , {7, 0, 31, 0, 70,} @@ -3377,7 +3378,7 @@ const lcnphy_tx_gain_tbl_entry dot11lcnphy_2GHz_gaintable_rev0[128] = { , }; -const lcnphy_tx_gain_tbl_entry dot11lcnphy_5GHz_gaintable_rev0[128] = { +const struct lcnphy_tx_gain_tbl_entry dot11lcnphy_5GHz_gaintable_rev0[128] = { {255, 255, 0xf0, 0, 152,} , {255, 255, 0xf0, 0, 147,} diff --git a/drivers/staging/brcm80211/brcmsmac/phy/phytbl_lcn.h b/drivers/staging/brcm80211/brcmsmac/phy/phytbl_lcn.h index 96f5a6867997..644389f0340a 100644 --- a/drivers/staging/brcm80211/brcmsmac/phy/phytbl_lcn.h +++ b/drivers/staging/brcm80211/brcmsmac/phy/phytbl_lcn.h @@ -17,26 +17,26 @@ #include <types.h> #include "phy_int.h" -extern const dot11lcnphytbl_info_t dot11lcnphytbl_rx_gain_info_rev0[]; +extern const struct phytbl_info dot11lcnphytbl_rx_gain_info_rev0[]; extern const u32 dot11lcnphytbl_rx_gain_info_sz_rev0; -extern const dot11lcnphytbl_info_t dot11lcn_sw_ctrl_tbl_info_4313; -extern const dot11lcnphytbl_info_t dot11lcn_sw_ctrl_tbl_info_4313_epa; -extern const dot11lcnphytbl_info_t dot11lcn_sw_ctrl_tbl_info_4313_epa_combo; +extern const struct phytbl_info dot11lcn_sw_ctrl_tbl_info_4313; +extern const struct phytbl_info dot11lcn_sw_ctrl_tbl_info_4313_epa; +extern const struct phytbl_info dot11lcn_sw_ctrl_tbl_info_4313_epa_combo; -extern const dot11lcnphytbl_info_t dot11lcnphytbl_info_rev0[]; +extern const struct phytbl_info dot11lcnphytbl_info_rev0[]; extern const u32 dot11lcnphytbl_info_sz_rev0; -extern const dot11lcnphytbl_info_t dot11lcnphytbl_rx_gain_info_2G_rev2[]; +extern const struct phytbl_info dot11lcnphytbl_rx_gain_info_2G_rev2[]; extern const u32 dot11lcnphytbl_rx_gain_info_2G_rev2_sz; -extern const dot11lcnphytbl_info_t dot11lcnphytbl_rx_gain_info_5G_rev2[]; +extern const struct phytbl_info dot11lcnphytbl_rx_gain_info_5G_rev2[]; extern const u32 dot11lcnphytbl_rx_gain_info_5G_rev2_sz; -extern const dot11lcnphytbl_info_t dot11lcnphytbl_rx_gain_info_extlna_2G_rev2[]; +extern const struct phytbl_info dot11lcnphytbl_rx_gain_info_extlna_2G_rev2[]; -extern const dot11lcnphytbl_info_t dot11lcnphytbl_rx_gain_info_extlna_5G_rev2[]; +extern const struct phytbl_info dot11lcnphytbl_rx_gain_info_extlna_5G_rev2[]; -struct _lcnphy_tx_gain_tbl_entry { +struct lcnphy_tx_gain_tbl_entry { unsigned char gm; unsigned char pga; unsigned char pad; @@ -44,7 +44,9 @@ struct _lcnphy_tx_gain_tbl_entry { unsigned char bb_mult; }; -extern const lcnphy_tx_gain_tbl_entry dot11lcnphy_2GHz_gaintable_rev0[]; -extern const lcnphy_tx_gain_tbl_entry dot11lcnphy_2GHz_extPA_gaintable_rev0[]; +extern const struct lcnphy_tx_gain_tbl_entry dot11lcnphy_2GHz_gaintable_rev0[]; -extern const lcnphy_tx_gain_tbl_entry dot11lcnphy_5GHz_gaintable_rev0[]; +extern const struct +lcnphy_tx_gain_tbl_entry dot11lcnphy_2GHz_extPA_gaintable_rev0[]; + +extern const struct lcnphy_tx_gain_tbl_entry dot11lcnphy_5GHz_gaintable_rev0[]; diff --git a/drivers/staging/brcm80211/brcmsmac/phy/phytbl_n.c b/drivers/staging/brcm80211/brcmsmac/phy/phytbl_n.c index 88353678548a..7f741f4868a6 100644 --- a/drivers/staging/brcm80211/brcmsmac/phy/phytbl_n.c +++ b/drivers/staging/brcm80211/brcmsmac/phy/phytbl_n.c @@ -4436,7 +4436,7 @@ const u16 loft_lut_core1_rev0[] = { 0x0103, }; -const mimophytbl_info_t mimophytbl_info_rev0_volatile[] = { +const struct phytbl_info mimophytbl_info_rev0_volatile[] = { {&bdi_tbl_rev0, sizeof(bdi_tbl_rev0) / sizeof(bdi_tbl_rev0[0]), 21, 0, 16} , @@ -4484,7 +4484,7 @@ const mimophytbl_info_t mimophytbl_info_rev0_volatile[] = { , }; -const mimophytbl_info_t mimophytbl_info_rev0[] = { +const struct phytbl_info mimophytbl_info_rev0[] = { {&frame_struct_rev0, sizeof(frame_struct_rev0) / sizeof(frame_struct_rev0[0]), 10, 0, 32} , @@ -9361,34 +9361,34 @@ const u32 papd_cal_scalars_tbl_core1_rev3[] = { 0x002606a4, }; -const mimophytbl_info_t mimophytbl_info_rev3_volatile[] = { +const struct phytbl_info mimophytbl_info_rev3_volatile[] = { {&ant_swctrl_tbl_rev3, sizeof(ant_swctrl_tbl_rev3) / sizeof(ant_swctrl_tbl_rev3[0]), 9, 0, 16} , }; -const mimophytbl_info_t mimophytbl_info_rev3_volatile1[] = { +const struct phytbl_info mimophytbl_info_rev3_volatile1[] = { {&ant_swctrl_tbl_rev3_1, sizeof(ant_swctrl_tbl_rev3_1) / sizeof(ant_swctrl_tbl_rev3_1[0]), 9, 0, 16} , }; -const mimophytbl_info_t mimophytbl_info_rev3_volatile2[] = { +const struct phytbl_info mimophytbl_info_rev3_volatile2[] = { {&ant_swctrl_tbl_rev3_2, sizeof(ant_swctrl_tbl_rev3_2) / sizeof(ant_swctrl_tbl_rev3_2[0]), 9, 0, 16} , }; -const mimophytbl_info_t mimophytbl_info_rev3_volatile3[] = { +const struct phytbl_info mimophytbl_info_rev3_volatile3[] = { {&ant_swctrl_tbl_rev3_3, sizeof(ant_swctrl_tbl_rev3_3) / sizeof(ant_swctrl_tbl_rev3_3[0]), 9, 0, 16} , }; -const mimophytbl_info_t mimophytbl_info_rev3[] = { +const struct phytbl_info mimophytbl_info_rev3[] = { {&frame_struct_rev3, sizeof(frame_struct_rev3) / sizeof(frame_struct_rev3[0]), 10, 0, 32} , @@ -10467,7 +10467,7 @@ const u32 papd_cal_scalars_tbl_core1_rev7[] = { 0x004e068c, }; -const mimophytbl_info_t mimophytbl_info_rev7[] = { +const struct phytbl_info mimophytbl_info_rev7[] = { {&frame_struct_rev3, sizeof(frame_struct_rev3) / sizeof(frame_struct_rev3[0]), 10, 0, 32} , @@ -10581,7 +10581,7 @@ const mimophytbl_info_t mimophytbl_info_rev7[] = { const u32 mimophytbl_info_sz_rev7 = sizeof(mimophytbl_info_rev7) / sizeof(mimophytbl_info_rev7[0]); -const mimophytbl_info_t mimophytbl_info_rev16[] = { +const struct phytbl_info mimophytbl_info_rev16[] = { {&noise_var_tbl_rev7, sizeof(noise_var_tbl_rev7) / sizeof(noise_var_tbl_rev7[0]), 16, 0, 32} , diff --git a/drivers/staging/brcm80211/brcmsmac/phy/phytbl_n.h b/drivers/staging/brcm80211/brcmsmac/phy/phytbl_n.h index 4b2a04dc6042..c5266cf23725 100644 --- a/drivers/staging/brcm80211/brcmsmac/phy/phytbl_n.h +++ b/drivers/staging/brcm80211/brcmsmac/phy/phytbl_n.h @@ -19,11 +19,11 @@ #include <types.h> #include "phy_int.h" -extern const mimophytbl_info_t mimophytbl_info_rev0[], +extern const struct phytbl_info mimophytbl_info_rev0[], mimophytbl_info_rev0_volatile[]; extern const u32 mimophytbl_info_sz_rev0, mimophytbl_info_sz_rev0_volatile; -extern const mimophytbl_info_t mimophytbl_info_rev3[], +extern const struct phytbl_info mimophytbl_info_rev3[], mimophytbl_info_rev3_volatile[], mimophytbl_info_rev3_volatile1[], mimophytbl_info_rev3_volatile2[], mimophytbl_info_rev3_volatile3[]; extern const u32 mimophytbl_info_sz_rev3, mimophytbl_info_sz_rev3_volatile, @@ -32,9 +32,9 @@ extern const u32 mimophytbl_info_sz_rev3, mimophytbl_info_sz_rev3_volatile, extern const u32 noise_var_tbl_rev3[]; -extern const mimophytbl_info_t mimophytbl_info_rev7[]; +extern const struct phytbl_info mimophytbl_info_rev7[]; extern const u32 mimophytbl_info_sz_rev7; extern const u32 noise_var_tbl_rev7[]; -extern const mimophytbl_info_t mimophytbl_info_rev16[]; +extern const struct phytbl_info mimophytbl_info_rev16[]; extern const u32 mimophytbl_info_sz_rev16; |