diff options
Diffstat (limited to 'drivers/net/wireless/brcm80211/brcmsmac')
-rw-r--r-- | drivers/net/wireless/brcm80211/brcmsmac/aiutils.h | 18 | ||||
-rw-r--r-- | drivers/net/wireless/brcm80211/brcmsmac/ampdu.h | 22 | ||||
-rw-r--r-- | drivers/net/wireless/brcm80211/brcmsmac/antsel.h | 14 | ||||
-rw-r--r-- | drivers/net/wireless/brcm80211/brcmsmac/channel.h | 20 | ||||
-rw-r--r-- | drivers/net/wireless/brcm80211/brcmsmac/mac80211_if.h | 38 | ||||
-rw-r--r-- | drivers/net/wireless/brcm80211/brcmsmac/main.c | 8 | ||||
-rw-r--r-- | drivers/net/wireless/brcm80211/brcmsmac/main.h | 110 | ||||
-rw-r--r-- | drivers/net/wireless/brcm80211/brcmsmac/phy/phy_hal.h | 219 | ||||
-rw-r--r-- | drivers/net/wireless/brcm80211/brcmsmac/phy/phy_int.h | 371 | ||||
-rw-r--r-- | drivers/net/wireless/brcm80211/brcmsmac/phy_shim.h | 91 | ||||
-rw-r--r-- | drivers/net/wireless/brcm80211/brcmsmac/pmu.h | 4 | ||||
-rw-r--r-- | drivers/net/wireless/brcm80211/brcmsmac/pub.h | 145 | ||||
-rw-r--r-- | drivers/net/wireless/brcm80211/brcmsmac/rate.h | 48 | ||||
-rw-r--r-- | drivers/net/wireless/brcm80211/brcmsmac/stf.h | 31 | ||||
-rw-r--r-- | drivers/net/wireless/brcm80211/brcmsmac/ucode_loader.h | 16 |
15 files changed, 539 insertions, 616 deletions
diff --git a/drivers/net/wireless/brcm80211/brcmsmac/aiutils.h b/drivers/net/wireless/brcm80211/brcmsmac/aiutils.h index a8a267b5b87a..2d08c155c23b 100644 --- a/drivers/net/wireless/brcm80211/brcmsmac/aiutils.h +++ b/drivers/net/wireless/brcm80211/brcmsmac/aiutils.h | |||
@@ -172,19 +172,19 @@ struct si_info { | |||
172 | 172 | ||
173 | 173 | ||
174 | /* AMBA Interconnect exported externs */ | 174 | /* AMBA Interconnect exported externs */ |
175 | extern u32 ai_core_cflags(struct bcma_device *core, u32 mask, u32 val); | 175 | u32 ai_core_cflags(struct bcma_device *core, u32 mask, u32 val); |
176 | 176 | ||
177 | /* === exported functions === */ | 177 | /* === exported functions === */ |
178 | extern struct si_pub *ai_attach(struct bcma_bus *pbus); | 178 | struct si_pub *ai_attach(struct bcma_bus *pbus); |
179 | extern void ai_detach(struct si_pub *sih); | 179 | void ai_detach(struct si_pub *sih); |
180 | extern uint ai_cc_reg(struct si_pub *sih, uint regoff, u32 mask, u32 val); | 180 | uint ai_cc_reg(struct si_pub *sih, uint regoff, u32 mask, u32 val); |
181 | extern void ai_clkctl_init(struct si_pub *sih); | 181 | void ai_clkctl_init(struct si_pub *sih); |
182 | extern u16 ai_clkctl_fast_pwrup_delay(struct si_pub *sih); | 182 | u16 ai_clkctl_fast_pwrup_delay(struct si_pub *sih); |
183 | extern bool ai_clkctl_cc(struct si_pub *sih, enum bcma_clkmode mode); | 183 | bool ai_clkctl_cc(struct si_pub *sih, enum bcma_clkmode mode); |
184 | extern bool ai_deviceremoved(struct si_pub *sih); | 184 | bool ai_deviceremoved(struct si_pub *sih); |
185 | 185 | ||
186 | /* Enable Ex-PA for 4313 */ | 186 | /* Enable Ex-PA for 4313 */ |
187 | extern void ai_epa_4313war(struct si_pub *sih); | 187 | void ai_epa_4313war(struct si_pub *sih); |
188 | 188 | ||
189 | static inline u32 ai_get_cccaps(struct si_pub *sih) | 189 | static inline u32 ai_get_cccaps(struct si_pub *sih) |
190 | { | 190 | { |
diff --git a/drivers/net/wireless/brcm80211/brcmsmac/ampdu.h b/drivers/net/wireless/brcm80211/brcmsmac/ampdu.h index 73d01e586109..03bdcf29bd50 100644 --- a/drivers/net/wireless/brcm80211/brcmsmac/ampdu.h +++ b/drivers/net/wireless/brcm80211/brcmsmac/ampdu.h | |||
@@ -37,17 +37,17 @@ struct brcms_ampdu_session { | |||
37 | u16 dma_len; | 37 | u16 dma_len; |
38 | }; | 38 | }; |
39 | 39 | ||
40 | extern void brcms_c_ampdu_reset_session(struct brcms_ampdu_session *session, | 40 | void brcms_c_ampdu_reset_session(struct brcms_ampdu_session *session, |
41 | struct brcms_c_info *wlc); | 41 | struct brcms_c_info *wlc); |
42 | extern int brcms_c_ampdu_add_frame(struct brcms_ampdu_session *session, | 42 | int brcms_c_ampdu_add_frame(struct brcms_ampdu_session *session, |
43 | struct sk_buff *p); | 43 | struct sk_buff *p); |
44 | extern void brcms_c_ampdu_finalize(struct brcms_ampdu_session *session); | 44 | void brcms_c_ampdu_finalize(struct brcms_ampdu_session *session); |
45 | 45 | ||
46 | extern struct ampdu_info *brcms_c_ampdu_attach(struct brcms_c_info *wlc); | 46 | struct ampdu_info *brcms_c_ampdu_attach(struct brcms_c_info *wlc); |
47 | extern void brcms_c_ampdu_detach(struct ampdu_info *ampdu); | 47 | void brcms_c_ampdu_detach(struct ampdu_info *ampdu); |
48 | extern void brcms_c_ampdu_dotxstatus(struct ampdu_info *ampdu, struct scb *scb, | 48 | void brcms_c_ampdu_dotxstatus(struct ampdu_info *ampdu, struct scb *scb, |
49 | struct sk_buff *p, struct tx_status *txs); | 49 | struct sk_buff *p, struct tx_status *txs); |
50 | extern void brcms_c_ampdu_macaddr_upd(struct brcms_c_info *wlc); | 50 | void brcms_c_ampdu_macaddr_upd(struct brcms_c_info *wlc); |
51 | extern void brcms_c_ampdu_shm_upd(struct ampdu_info *ampdu); | 51 | void brcms_c_ampdu_shm_upd(struct ampdu_info *ampdu); |
52 | 52 | ||
53 | #endif /* _BRCM_AMPDU_H_ */ | 53 | #endif /* _BRCM_AMPDU_H_ */ |
diff --git a/drivers/net/wireless/brcm80211/brcmsmac/antsel.h b/drivers/net/wireless/brcm80211/brcmsmac/antsel.h index 97ea3881a8ec..a3d487ab1964 100644 --- a/drivers/net/wireless/brcm80211/brcmsmac/antsel.h +++ b/drivers/net/wireless/brcm80211/brcmsmac/antsel.h | |||
@@ -17,13 +17,11 @@ | |||
17 | #ifndef _BRCM_ANTSEL_H_ | 17 | #ifndef _BRCM_ANTSEL_H_ |
18 | #define _BRCM_ANTSEL_H_ | 18 | #define _BRCM_ANTSEL_H_ |
19 | 19 | ||
20 | extern struct antsel_info *brcms_c_antsel_attach(struct brcms_c_info *wlc); | 20 | struct antsel_info *brcms_c_antsel_attach(struct brcms_c_info *wlc); |
21 | extern void brcms_c_antsel_detach(struct antsel_info *asi); | 21 | void brcms_c_antsel_detach(struct antsel_info *asi); |
22 | extern void brcms_c_antsel_init(struct antsel_info *asi); | 22 | void brcms_c_antsel_init(struct antsel_info *asi); |
23 | extern void brcms_c_antsel_antcfg_get(struct antsel_info *asi, bool usedef, | 23 | void brcms_c_antsel_antcfg_get(struct antsel_info *asi, bool usedef, bool sel, |
24 | bool sel, | 24 | u8 id, u8 fbid, u8 *antcfg, u8 *fbantcfg); |
25 | u8 id, u8 fbid, u8 *antcfg, | 25 | u8 brcms_c_antsel_antsel2id(struct antsel_info *asi, u16 antsel); |
26 | u8 *fbantcfg); | ||
27 | extern u8 brcms_c_antsel_antsel2id(struct antsel_info *asi, u16 antsel); | ||
28 | 26 | ||
29 | #endif /* _BRCM_ANTSEL_H_ */ | 27 | #endif /* _BRCM_ANTSEL_H_ */ |
diff --git a/drivers/net/wireless/brcm80211/brcmsmac/channel.h b/drivers/net/wireless/brcm80211/brcmsmac/channel.h index 006483a0abe6..39dd3a5b2979 100644 --- a/drivers/net/wireless/brcm80211/brcmsmac/channel.h +++ b/drivers/net/wireless/brcm80211/brcmsmac/channel.h | |||
@@ -32,20 +32,16 @@ | |||
32 | 32 | ||
33 | #define BRCMS_DFS_EU (BRCMS_DFS_TPC | BRCMS_RADAR_TYPE_EU) /* Flag for DFS EU */ | 33 | #define BRCMS_DFS_EU (BRCMS_DFS_TPC | BRCMS_RADAR_TYPE_EU) /* Flag for DFS EU */ |
34 | 34 | ||
35 | extern struct brcms_cm_info * | 35 | struct brcms_cm_info *brcms_c_channel_mgr_attach(struct brcms_c_info *wlc); |
36 | brcms_c_channel_mgr_attach(struct brcms_c_info *wlc); | ||
37 | 36 | ||
38 | extern void brcms_c_channel_mgr_detach(struct brcms_cm_info *wlc_cm); | 37 | void brcms_c_channel_mgr_detach(struct brcms_cm_info *wlc_cm); |
39 | 38 | ||
40 | extern bool brcms_c_valid_chanspec_db(struct brcms_cm_info *wlc_cm, | 39 | bool brcms_c_valid_chanspec_db(struct brcms_cm_info *wlc_cm, u16 chspec); |
41 | u16 chspec); | ||
42 | 40 | ||
43 | extern void brcms_c_channel_reg_limits(struct brcms_cm_info *wlc_cm, | 41 | void brcms_c_channel_reg_limits(struct brcms_cm_info *wlc_cm, u16 chanspec, |
44 | u16 chanspec, | 42 | struct txpwr_limits *txpwr); |
45 | struct txpwr_limits *txpwr); | 43 | void brcms_c_channel_set_chanspec(struct brcms_cm_info *wlc_cm, u16 chanspec, |
46 | extern void brcms_c_channel_set_chanspec(struct brcms_cm_info *wlc_cm, | 44 | u8 local_constraint_qdbm); |
47 | u16 chanspec, | 45 | void brcms_c_regd_init(struct brcms_c_info *wlc); |
48 | u8 local_constraint_qdbm); | ||
49 | extern void brcms_c_regd_init(struct brcms_c_info *wlc); | ||
50 | 46 | ||
51 | #endif /* _WLC_CHANNEL_H */ | 47 | #endif /* _WLC_CHANNEL_H */ |
diff --git a/drivers/net/wireless/brcm80211/brcmsmac/mac80211_if.h b/drivers/net/wireless/brcm80211/brcmsmac/mac80211_if.h index 4090032e81a2..198053dfc310 100644 --- a/drivers/net/wireless/brcm80211/brcmsmac/mac80211_if.h +++ b/drivers/net/wireless/brcm80211/brcmsmac/mac80211_if.h | |||
@@ -88,26 +88,26 @@ struct brcms_info { | |||
88 | }; | 88 | }; |
89 | 89 | ||
90 | /* misc callbacks */ | 90 | /* misc callbacks */ |
91 | extern void brcms_init(struct brcms_info *wl); | 91 | void brcms_init(struct brcms_info *wl); |
92 | extern uint brcms_reset(struct brcms_info *wl); | 92 | uint brcms_reset(struct brcms_info *wl); |
93 | extern void brcms_intrson(struct brcms_info *wl); | 93 | void brcms_intrson(struct brcms_info *wl); |
94 | extern u32 brcms_intrsoff(struct brcms_info *wl); | 94 | u32 brcms_intrsoff(struct brcms_info *wl); |
95 | extern void brcms_intrsrestore(struct brcms_info *wl, u32 macintmask); | 95 | void brcms_intrsrestore(struct brcms_info *wl, u32 macintmask); |
96 | extern int brcms_up(struct brcms_info *wl); | 96 | int brcms_up(struct brcms_info *wl); |
97 | extern void brcms_down(struct brcms_info *wl); | 97 | void brcms_down(struct brcms_info *wl); |
98 | extern void brcms_txflowcontrol(struct brcms_info *wl, struct brcms_if *wlif, | 98 | void brcms_txflowcontrol(struct brcms_info *wl, struct brcms_if *wlif, |
99 | bool state, int prio); | 99 | bool state, int prio); |
100 | extern bool brcms_rfkill_set_hw_state(struct brcms_info *wl); | 100 | bool brcms_rfkill_set_hw_state(struct brcms_info *wl); |
101 | 101 | ||
102 | /* timer functions */ | 102 | /* timer functions */ |
103 | extern struct brcms_timer *brcms_init_timer(struct brcms_info *wl, | 103 | struct brcms_timer *brcms_init_timer(struct brcms_info *wl, |
104 | void (*fn) (void *arg), void *arg, | 104 | void (*fn) (void *arg), void *arg, |
105 | const char *name); | 105 | const char *name); |
106 | extern void brcms_free_timer(struct brcms_timer *timer); | 106 | void brcms_free_timer(struct brcms_timer *timer); |
107 | extern void brcms_add_timer(struct brcms_timer *timer, uint ms, int periodic); | 107 | void brcms_add_timer(struct brcms_timer *timer, uint ms, int periodic); |
108 | extern bool brcms_del_timer(struct brcms_timer *timer); | 108 | bool brcms_del_timer(struct brcms_timer *timer); |
109 | extern void brcms_dpc(unsigned long data); | 109 | void brcms_dpc(unsigned long data); |
110 | extern void brcms_timer(struct brcms_timer *t); | 110 | void brcms_timer(struct brcms_timer *t); |
111 | extern void brcms_fatal_error(struct brcms_info *wl); | 111 | void brcms_fatal_error(struct brcms_info *wl); |
112 | 112 | ||
113 | #endif /* _BRCM_MAC80211_IF_H_ */ | 113 | #endif /* _BRCM_MAC80211_IF_H_ */ |
diff --git a/drivers/net/wireless/brcm80211/brcmsmac/main.c b/drivers/net/wireless/brcm80211/brcmsmac/main.c index 4608e0eb1493..8138f1cff4e5 100644 --- a/drivers/net/wireless/brcm80211/brcmsmac/main.c +++ b/drivers/net/wireless/brcm80211/brcmsmac/main.c | |||
@@ -1906,14 +1906,14 @@ static void brcms_c_get_macaddr(struct brcms_hardware *wlc_hw, u8 etheraddr[ETH_ | |||
1906 | 1906 | ||
1907 | /* If macaddr exists, use it (Sromrev4, CIS, ...). */ | 1907 | /* If macaddr exists, use it (Sromrev4, CIS, ...). */ |
1908 | if (!is_zero_ether_addr(sprom->il0mac)) { | 1908 | if (!is_zero_ether_addr(sprom->il0mac)) { |
1909 | memcpy(etheraddr, sprom->il0mac, 6); | 1909 | memcpy(etheraddr, sprom->il0mac, ETH_ALEN); |
1910 | return; | 1910 | return; |
1911 | } | 1911 | } |
1912 | 1912 | ||
1913 | if (wlc_hw->_nbands > 1) | 1913 | if (wlc_hw->_nbands > 1) |
1914 | memcpy(etheraddr, sprom->et1mac, 6); | 1914 | memcpy(etheraddr, sprom->et1mac, ETH_ALEN); |
1915 | else | 1915 | else |
1916 | memcpy(etheraddr, sprom->il0mac, 6); | 1916 | memcpy(etheraddr, sprom->il0mac, ETH_ALEN); |
1917 | } | 1917 | } |
1918 | 1918 | ||
1919 | /* power both the pll and external oscillator on/off */ | 1919 | /* power both the pll and external oscillator on/off */ |
@@ -5695,7 +5695,7 @@ static bool brcms_c_chipmatch_pci(struct bcma_device *core) | |||
5695 | return true; | 5695 | return true; |
5696 | if ((device == BCM43224_D11N_ID) || (device == BCM43225_D11N2G_ID)) | 5696 | if ((device == BCM43224_D11N_ID) || (device == BCM43225_D11N2G_ID)) |
5697 | return true; | 5697 | return true; |
5698 | if (device == BCM4313_D11N2G_ID) | 5698 | if (device == BCM4313_D11N2G_ID || device == BCM4313_CHIP_ID) |
5699 | return true; | 5699 | return true; |
5700 | if ((device == BCM43236_D11N_ID) || (device == BCM43236_D11N2G_ID)) | 5700 | if ((device == BCM43236_D11N_ID) || (device == BCM43236_D11N2G_ID)) |
5701 | return true; | 5701 | return true; |
diff --git a/drivers/net/wireless/brcm80211/brcmsmac/main.h b/drivers/net/wireless/brcm80211/brcmsmac/main.h index b5d7a38b53fe..c4d135cff04a 100644 --- a/drivers/net/wireless/brcm80211/brcmsmac/main.h +++ b/drivers/net/wireless/brcm80211/brcmsmac/main.h | |||
@@ -616,66 +616,54 @@ struct brcms_bss_cfg { | |||
616 | struct brcms_bss_info *current_bss; | 616 | struct brcms_bss_info *current_bss; |
617 | }; | 617 | }; |
618 | 618 | ||
619 | extern int brcms_c_txfifo(struct brcms_c_info *wlc, uint fifo, | 619 | int brcms_c_txfifo(struct brcms_c_info *wlc, uint fifo, struct sk_buff *p); |
620 | struct sk_buff *p); | 620 | int brcms_b_xmtfifo_sz_get(struct brcms_hardware *wlc_hw, uint fifo, |
621 | extern int brcms_b_xmtfifo_sz_get(struct brcms_hardware *wlc_hw, uint fifo, | 621 | uint *blocks); |
622 | uint *blocks); | 622 | |
623 | 623 | int brcms_c_set_gmode(struct brcms_c_info *wlc, u8 gmode, bool config); | |
624 | extern int brcms_c_set_gmode(struct brcms_c_info *wlc, u8 gmode, bool config); | 624 | void brcms_c_mac_promisc(struct brcms_c_info *wlc, uint filter_flags); |
625 | extern void brcms_c_mac_promisc(struct brcms_c_info *wlc, uint filter_flags); | 625 | u16 brcms_c_calc_lsig_len(struct brcms_c_info *wlc, u32 ratespec, uint mac_len); |
626 | extern u16 brcms_c_calc_lsig_len(struct brcms_c_info *wlc, u32 ratespec, | 626 | u32 brcms_c_rspec_to_rts_rspec(struct brcms_c_info *wlc, u32 rspec, |
627 | uint mac_len); | 627 | bool use_rspec, u16 mimo_ctlchbw); |
628 | extern u32 brcms_c_rspec_to_rts_rspec(struct brcms_c_info *wlc, | 628 | u16 brcms_c_compute_rtscts_dur(struct brcms_c_info *wlc, bool cts_only, |
629 | u32 rspec, | 629 | u32 rts_rate, u32 frame_rate, |
630 | bool use_rspec, u16 mimo_ctlchbw); | 630 | u8 rts_preamble_type, u8 frame_preamble_type, |
631 | extern u16 brcms_c_compute_rtscts_dur(struct brcms_c_info *wlc, bool cts_only, | 631 | uint frame_len, bool ba); |
632 | u32 rts_rate, | 632 | void brcms_c_inval_dma_pkts(struct brcms_hardware *hw, |
633 | u32 frame_rate, | 633 | struct ieee80211_sta *sta, void (*dma_callback_fn)); |
634 | u8 rts_preamble_type, | 634 | void brcms_c_update_probe_resp(struct brcms_c_info *wlc, bool suspend); |
635 | u8 frame_preamble_type, uint frame_len, | 635 | int brcms_c_set_nmode(struct brcms_c_info *wlc); |
636 | bool ba); | 636 | void brcms_c_beacon_phytxctl_txant_upd(struct brcms_c_info *wlc, u32 bcn_rate); |
637 | extern void brcms_c_inval_dma_pkts(struct brcms_hardware *hw, | 637 | void brcms_b_antsel_type_set(struct brcms_hardware *wlc_hw, u8 antsel_type); |
638 | struct ieee80211_sta *sta, | 638 | void brcms_b_set_chanspec(struct brcms_hardware *wlc_hw, u16 chanspec, |
639 | void (*dma_callback_fn)); | 639 | bool mute, struct txpwr_limits *txpwr); |
640 | extern void brcms_c_update_probe_resp(struct brcms_c_info *wlc, bool suspend); | 640 | void brcms_b_write_shm(struct brcms_hardware *wlc_hw, uint offset, u16 v); |
641 | extern int brcms_c_set_nmode(struct brcms_c_info *wlc); | 641 | u16 brcms_b_read_shm(struct brcms_hardware *wlc_hw, uint offset); |
642 | extern void brcms_c_beacon_phytxctl_txant_upd(struct brcms_c_info *wlc, | 642 | void brcms_b_mhf(struct brcms_hardware *wlc_hw, u8 idx, u16 mask, u16 val, |
643 | u32 bcn_rate); | 643 | int bands); |
644 | extern void brcms_b_antsel_type_set(struct brcms_hardware *wlc_hw, | 644 | void brcms_b_corereset(struct brcms_hardware *wlc_hw, u32 flags); |
645 | u8 antsel_type); | 645 | void brcms_b_mctrl(struct brcms_hardware *wlc_hw, u32 mask, u32 val); |
646 | extern void brcms_b_set_chanspec(struct brcms_hardware *wlc_hw, | 646 | void brcms_b_phy_reset(struct brcms_hardware *wlc_hw); |
647 | u16 chanspec, | 647 | void brcms_b_bw_set(struct brcms_hardware *wlc_hw, u16 bw); |
648 | bool mute, struct txpwr_limits *txpwr); | 648 | void brcms_b_core_phypll_reset(struct brcms_hardware *wlc_hw); |
649 | extern void brcms_b_write_shm(struct brcms_hardware *wlc_hw, uint offset, | 649 | void brcms_c_ucode_wake_override_set(struct brcms_hardware *wlc_hw, |
650 | u16 v); | 650 | u32 override_bit); |
651 | extern u16 brcms_b_read_shm(struct brcms_hardware *wlc_hw, uint offset); | 651 | void brcms_c_ucode_wake_override_clear(struct brcms_hardware *wlc_hw, |
652 | extern void brcms_b_mhf(struct brcms_hardware *wlc_hw, u8 idx, u16 mask, | 652 | u32 override_bit); |
653 | u16 val, int bands); | 653 | void brcms_b_write_template_ram(struct brcms_hardware *wlc_hw, int offset, |
654 | extern void brcms_b_corereset(struct brcms_hardware *wlc_hw, u32 flags); | 654 | int len, void *buf); |
655 | extern void brcms_b_mctrl(struct brcms_hardware *wlc_hw, u32 mask, u32 val); | 655 | u16 brcms_b_rate_shm_offset(struct brcms_hardware *wlc_hw, u8 rate); |
656 | extern void brcms_b_phy_reset(struct brcms_hardware *wlc_hw); | 656 | void brcms_b_copyto_objmem(struct brcms_hardware *wlc_hw, uint offset, |
657 | extern void brcms_b_bw_set(struct brcms_hardware *wlc_hw, u16 bw); | 657 | const void *buf, int len, u32 sel); |
658 | extern void brcms_b_core_phypll_reset(struct brcms_hardware *wlc_hw); | 658 | void brcms_b_copyfrom_objmem(struct brcms_hardware *wlc_hw, uint offset, |
659 | extern void brcms_c_ucode_wake_override_set(struct brcms_hardware *wlc_hw, | 659 | void *buf, int len, u32 sel); |
660 | u32 override_bit); | 660 | void brcms_b_switch_macfreq(struct brcms_hardware *wlc_hw, u8 spurmode); |
661 | extern void brcms_c_ucode_wake_override_clear(struct brcms_hardware *wlc_hw, | 661 | u16 brcms_b_get_txant(struct brcms_hardware *wlc_hw); |
662 | u32 override_bit); | 662 | void brcms_b_phyclk_fgc(struct brcms_hardware *wlc_hw, bool clk); |
663 | extern void brcms_b_write_template_ram(struct brcms_hardware *wlc_hw, | 663 | void brcms_b_macphyclk_set(struct brcms_hardware *wlc_hw, bool clk); |
664 | int offset, int len, void *buf); | 664 | void brcms_b_core_phypll_ctl(struct brcms_hardware *wlc_hw, bool on); |
665 | extern u16 brcms_b_rate_shm_offset(struct brcms_hardware *wlc_hw, u8 rate); | 665 | void brcms_b_txant_set(struct brcms_hardware *wlc_hw, u16 phytxant); |
666 | extern void brcms_b_copyto_objmem(struct brcms_hardware *wlc_hw, | 666 | void brcms_b_band_stf_ss_set(struct brcms_hardware *wlc_hw, u8 stf_mode); |
667 | uint offset, const void *buf, int len, | 667 | void brcms_c_init_scb(struct scb *scb); |
668 | u32 sel); | ||
669 | extern void brcms_b_copyfrom_objmem(struct brcms_hardware *wlc_hw, uint offset, | ||
670 | void *buf, int len, u32 sel); | ||
671 | extern void brcms_b_switch_macfreq(struct brcms_hardware *wlc_hw, u8 spurmode); | ||
672 | extern u16 brcms_b_get_txant(struct brcms_hardware *wlc_hw); | ||
673 | extern void brcms_b_phyclk_fgc(struct brcms_hardware *wlc_hw, bool clk); | ||
674 | extern void brcms_b_macphyclk_set(struct brcms_hardware *wlc_hw, bool clk); | ||
675 | extern void brcms_b_core_phypll_ctl(struct brcms_hardware *wlc_hw, bool on); | ||
676 | extern void brcms_b_txant_set(struct brcms_hardware *wlc_hw, u16 phytxant); | ||
677 | extern void brcms_b_band_stf_ss_set(struct brcms_hardware *wlc_hw, | ||
678 | u8 stf_mode); | ||
679 | extern void brcms_c_init_scb(struct scb *scb); | ||
680 | 668 | ||
681 | #endif /* _BRCM_MAIN_H_ */ | 669 | #endif /* _BRCM_MAIN_H_ */ |
diff --git a/drivers/net/wireless/brcm80211/brcmsmac/phy/phy_hal.h b/drivers/net/wireless/brcm80211/brcmsmac/phy/phy_hal.h index e34a71e7d242..4d3734f48d9c 100644 --- a/drivers/net/wireless/brcm80211/brcmsmac/phy/phy_hal.h +++ b/drivers/net/wireless/brcm80211/brcmsmac/phy/phy_hal.h | |||
@@ -179,121 +179,106 @@ struct shared_phy_params { | |||
179 | }; | 179 | }; |
180 | 180 | ||
181 | 181 | ||
182 | extern struct shared_phy *wlc_phy_shared_attach(struct shared_phy_params *shp); | 182 | struct shared_phy *wlc_phy_shared_attach(struct shared_phy_params *shp); |
183 | extern struct brcms_phy_pub *wlc_phy_attach(struct shared_phy *sh, | 183 | struct brcms_phy_pub *wlc_phy_attach(struct shared_phy *sh, |
184 | struct bcma_device *d11core, | 184 | struct bcma_device *d11core, int bandtype, |
185 | int bandtype, struct wiphy *wiphy); | 185 | struct wiphy *wiphy); |
186 | extern void wlc_phy_detach(struct brcms_phy_pub *ppi); | 186 | void wlc_phy_detach(struct brcms_phy_pub *ppi); |
187 | 187 | ||
188 | extern bool wlc_phy_get_phyversion(struct brcms_phy_pub *pih, u16 *phytype, | 188 | bool wlc_phy_get_phyversion(struct brcms_phy_pub *pih, u16 *phytype, |
189 | u16 *phyrev, u16 *radioid, | 189 | u16 *phyrev, u16 *radioid, u16 *radiover); |
190 | u16 *radiover); | 190 | bool wlc_phy_get_encore(struct brcms_phy_pub *pih); |
191 | extern bool wlc_phy_get_encore(struct brcms_phy_pub *pih); | 191 | u32 wlc_phy_get_coreflags(struct brcms_phy_pub *pih); |
192 | extern u32 wlc_phy_get_coreflags(struct brcms_phy_pub *pih); | 192 | |
193 | 193 | void wlc_phy_hw_clk_state_upd(struct brcms_phy_pub *ppi, bool newstate); | |
194 | extern void wlc_phy_hw_clk_state_upd(struct brcms_phy_pub *ppi, bool newstate); | 194 | void wlc_phy_hw_state_upd(struct brcms_phy_pub *ppi, bool newstate); |
195 | extern void wlc_phy_hw_state_upd(struct brcms_phy_pub *ppi, bool newstate); | 195 | void wlc_phy_init(struct brcms_phy_pub *ppi, u16 chanspec); |
196 | extern void wlc_phy_init(struct brcms_phy_pub *ppi, u16 chanspec); | 196 | void wlc_phy_watchdog(struct brcms_phy_pub *ppi); |
197 | extern void wlc_phy_watchdog(struct brcms_phy_pub *ppi); | 197 | int wlc_phy_down(struct brcms_phy_pub *ppi); |
198 | extern int wlc_phy_down(struct brcms_phy_pub *ppi); | 198 | u32 wlc_phy_clk_bwbits(struct brcms_phy_pub *pih); |
199 | extern u32 wlc_phy_clk_bwbits(struct brcms_phy_pub *pih); | 199 | void wlc_phy_cal_init(struct brcms_phy_pub *ppi); |
200 | extern void wlc_phy_cal_init(struct brcms_phy_pub *ppi); | 200 | void wlc_phy_antsel_init(struct brcms_phy_pub *ppi, bool lut_init); |
201 | extern void wlc_phy_antsel_init(struct brcms_phy_pub *ppi, bool lut_init); | 201 | |
202 | 202 | void wlc_phy_chanspec_set(struct brcms_phy_pub *ppi, u16 chanspec); | |
203 | extern void wlc_phy_chanspec_set(struct brcms_phy_pub *ppi, | 203 | u16 wlc_phy_chanspec_get(struct brcms_phy_pub *ppi); |
204 | u16 chanspec); | 204 | void wlc_phy_chanspec_radio_set(struct brcms_phy_pub *ppi, u16 newch); |
205 | extern u16 wlc_phy_chanspec_get(struct brcms_phy_pub *ppi); | 205 | u16 wlc_phy_bw_state_get(struct brcms_phy_pub *ppi); |
206 | extern void wlc_phy_chanspec_radio_set(struct brcms_phy_pub *ppi, | 206 | void wlc_phy_bw_state_set(struct brcms_phy_pub *ppi, u16 bw); |
207 | u16 newch); | 207 | |
208 | extern u16 wlc_phy_bw_state_get(struct brcms_phy_pub *ppi); | 208 | int wlc_phy_rssi_compute(struct brcms_phy_pub *pih, struct d11rxhdr *rxh); |
209 | extern void wlc_phy_bw_state_set(struct brcms_phy_pub *ppi, u16 bw); | 209 | void wlc_phy_por_inform(struct brcms_phy_pub *ppi); |
210 | 210 | void wlc_phy_noise_sample_intr(struct brcms_phy_pub *ppi); | |
211 | extern int wlc_phy_rssi_compute(struct brcms_phy_pub *pih, | 211 | bool wlc_phy_bist_check_phy(struct brcms_phy_pub *ppi); |
212 | struct d11rxhdr *rxh); | 212 | |
213 | extern void wlc_phy_por_inform(struct brcms_phy_pub *ppi); | 213 | void wlc_phy_set_deaf(struct brcms_phy_pub *ppi, bool user_flag); |
214 | extern void wlc_phy_noise_sample_intr(struct brcms_phy_pub *ppi); | 214 | |
215 | extern bool wlc_phy_bist_check_phy(struct brcms_phy_pub *ppi); | 215 | void wlc_phy_switch_radio(struct brcms_phy_pub *ppi, bool on); |
216 | 216 | void wlc_phy_anacore(struct brcms_phy_pub *ppi, bool on); | |
217 | extern void wlc_phy_set_deaf(struct brcms_phy_pub *ppi, bool user_flag); | 217 | |
218 | 218 | ||
219 | extern void wlc_phy_switch_radio(struct brcms_phy_pub *ppi, bool on); | 219 | void wlc_phy_BSSinit(struct brcms_phy_pub *ppi, bool bonlyap, int rssi); |
220 | extern void wlc_phy_anacore(struct brcms_phy_pub *ppi, bool on); | 220 | |
221 | 221 | void wlc_phy_chanspec_ch14_widefilter_set(struct brcms_phy_pub *ppi, | |
222 | 222 | bool wide_filter); | |
223 | extern void wlc_phy_BSSinit(struct brcms_phy_pub *ppi, bool bonlyap, int rssi); | 223 | void wlc_phy_chanspec_band_validch(struct brcms_phy_pub *ppi, uint band, |
224 | 224 | struct brcms_chanvec *channels); | |
225 | extern void wlc_phy_chanspec_ch14_widefilter_set(struct brcms_phy_pub *ppi, | 225 | u16 wlc_phy_chanspec_band_firstch(struct brcms_phy_pub *ppi, uint band); |
226 | bool wide_filter); | 226 | |
227 | extern void wlc_phy_chanspec_band_validch(struct brcms_phy_pub *ppi, uint band, | 227 | void wlc_phy_txpower_sromlimit(struct brcms_phy_pub *ppi, uint chan, u8 *_min_, |
228 | struct brcms_chanvec *channels); | 228 | u8 *_max_, int rate); |
229 | extern u16 wlc_phy_chanspec_band_firstch(struct brcms_phy_pub *ppi, | 229 | void wlc_phy_txpower_sromlimit_max_get(struct brcms_phy_pub *ppi, uint chan, |
230 | uint band); | 230 | u8 *_max_, u8 *_min_); |
231 | 231 | void wlc_phy_txpower_boardlimit_band(struct brcms_phy_pub *ppi, uint band, | |
232 | extern void wlc_phy_txpower_sromlimit(struct brcms_phy_pub *ppi, uint chan, | 232 | s32 *, s32 *, u32 *); |
233 | u8 *_min_, u8 *_max_, int rate); | 233 | void wlc_phy_txpower_limit_set(struct brcms_phy_pub *ppi, struct txpwr_limits *, |
234 | extern void wlc_phy_txpower_sromlimit_max_get(struct brcms_phy_pub *ppi, | 234 | u16 chanspec); |
235 | uint chan, u8 *_max_, u8 *_min_); | 235 | int wlc_phy_txpower_get(struct brcms_phy_pub *ppi, uint *qdbm, bool *override); |
236 | extern void wlc_phy_txpower_boardlimit_band(struct brcms_phy_pub *ppi, | 236 | int wlc_phy_txpower_set(struct brcms_phy_pub *ppi, uint qdbm, bool override); |
237 | uint band, s32 *, s32 *, u32 *); | 237 | void wlc_phy_txpower_target_set(struct brcms_phy_pub *ppi, |
238 | extern void wlc_phy_txpower_limit_set(struct brcms_phy_pub *ppi, | 238 | struct txpwr_limits *); |
239 | struct txpwr_limits *, | 239 | bool wlc_phy_txpower_hw_ctrl_get(struct brcms_phy_pub *ppi); |
240 | u16 chanspec); | 240 | void wlc_phy_txpower_hw_ctrl_set(struct brcms_phy_pub *ppi, bool hwpwrctrl); |
241 | extern int wlc_phy_txpower_get(struct brcms_phy_pub *ppi, uint *qdbm, | 241 | u8 wlc_phy_txpower_get_target_min(struct brcms_phy_pub *ppi); |
242 | bool *override); | 242 | u8 wlc_phy_txpower_get_target_max(struct brcms_phy_pub *ppi); |
243 | extern int wlc_phy_txpower_set(struct brcms_phy_pub *ppi, uint qdbm, | 243 | bool wlc_phy_txpower_ipa_ison(struct brcms_phy_pub *pih); |
244 | bool override); | 244 | |
245 | extern void wlc_phy_txpower_target_set(struct brcms_phy_pub *ppi, | 245 | void wlc_phy_stf_chain_init(struct brcms_phy_pub *pih, u8 txchain, u8 rxchain); |
246 | struct txpwr_limits *); | 246 | void wlc_phy_stf_chain_set(struct brcms_phy_pub *pih, u8 txchain, u8 rxchain); |
247 | extern bool wlc_phy_txpower_hw_ctrl_get(struct brcms_phy_pub *ppi); | 247 | void wlc_phy_stf_chain_get(struct brcms_phy_pub *pih, u8 *txchain, u8 *rxchain); |
248 | extern void wlc_phy_txpower_hw_ctrl_set(struct brcms_phy_pub *ppi, | 248 | u8 wlc_phy_stf_chain_active_get(struct brcms_phy_pub *pih); |
249 | bool hwpwrctrl); | 249 | s8 wlc_phy_stf_ssmode_get(struct brcms_phy_pub *pih, u16 chanspec); |
250 | extern u8 wlc_phy_txpower_get_target_min(struct brcms_phy_pub *ppi); | 250 | void wlc_phy_ldpc_override_set(struct brcms_phy_pub *ppi, bool val); |
251 | extern u8 wlc_phy_txpower_get_target_max(struct brcms_phy_pub *ppi); | 251 | |
252 | extern bool wlc_phy_txpower_ipa_ison(struct brcms_phy_pub *pih); | 252 | void wlc_phy_cal_perical(struct brcms_phy_pub *ppi, u8 reason); |
253 | 253 | void wlc_phy_noise_sample_request_external(struct brcms_phy_pub *ppi); | |
254 | extern void wlc_phy_stf_chain_init(struct brcms_phy_pub *pih, u8 txchain, | 254 | void wlc_phy_edcrs_lock(struct brcms_phy_pub *pih, bool lock); |
255 | u8 rxchain); | 255 | void wlc_phy_cal_papd_recal(struct brcms_phy_pub *ppi); |
256 | extern void wlc_phy_stf_chain_set(struct brcms_phy_pub *pih, u8 txchain, | 256 | |
257 | u8 rxchain); | 257 | void wlc_phy_ant_rxdiv_set(struct brcms_phy_pub *ppi, u8 val); |
258 | extern void wlc_phy_stf_chain_get(struct brcms_phy_pub *pih, u8 *txchain, | 258 | void wlc_phy_clear_tssi(struct brcms_phy_pub *ppi); |
259 | u8 *rxchain); | 259 | void wlc_phy_hold_upd(struct brcms_phy_pub *ppi, u32 id, bool val); |
260 | extern u8 wlc_phy_stf_chain_active_get(struct brcms_phy_pub *pih); | 260 | void wlc_phy_mute_upd(struct brcms_phy_pub *ppi, bool val, u32 flags); |
261 | extern s8 wlc_phy_stf_ssmode_get(struct brcms_phy_pub *pih, | 261 | |
262 | u16 chanspec); | 262 | void wlc_phy_antsel_type_set(struct brcms_phy_pub *ppi, u8 antsel_type); |
263 | extern void wlc_phy_ldpc_override_set(struct brcms_phy_pub *ppi, bool val); | 263 | |
264 | 264 | void wlc_phy_txpower_get_current(struct brcms_phy_pub *ppi, | |
265 | extern void wlc_phy_cal_perical(struct brcms_phy_pub *ppi, u8 reason); | 265 | struct tx_power *power, uint channel); |
266 | extern void wlc_phy_noise_sample_request_external(struct brcms_phy_pub *ppi); | 266 | |
267 | extern void wlc_phy_edcrs_lock(struct brcms_phy_pub *pih, bool lock); | 267 | void wlc_phy_initcal_enable(struct brcms_phy_pub *pih, bool initcal); |
268 | extern void wlc_phy_cal_papd_recal(struct brcms_phy_pub *ppi); | 268 | bool wlc_phy_test_ison(struct brcms_phy_pub *ppi); |
269 | 269 | void wlc_phy_txpwr_percent_set(struct brcms_phy_pub *ppi, u8 txpwr_percent); | |
270 | extern void wlc_phy_ant_rxdiv_set(struct brcms_phy_pub *ppi, u8 val); | 270 | void wlc_phy_ofdm_rateset_war(struct brcms_phy_pub *pih, bool war); |
271 | extern void wlc_phy_clear_tssi(struct brcms_phy_pub *ppi); | 271 | void wlc_phy_bf_preempt_enable(struct brcms_phy_pub *pih, bool bf_preempt); |
272 | extern void wlc_phy_hold_upd(struct brcms_phy_pub *ppi, u32 id, bool val); | 272 | void wlc_phy_machwcap_set(struct brcms_phy_pub *ppi, u32 machwcap); |
273 | extern void wlc_phy_mute_upd(struct brcms_phy_pub *ppi, bool val, u32 flags); | 273 | |
274 | 274 | void wlc_phy_runbist_config(struct brcms_phy_pub *ppi, bool start_end); | |
275 | extern void wlc_phy_antsel_type_set(struct brcms_phy_pub *ppi, u8 antsel_type); | 275 | |
276 | 276 | void wlc_phy_freqtrack_start(struct brcms_phy_pub *ppi); | |
277 | extern void wlc_phy_txpower_get_current(struct brcms_phy_pub *ppi, | 277 | void wlc_phy_freqtrack_end(struct brcms_phy_pub *ppi); |
278 | struct tx_power *power, uint channel); | 278 | |
279 | 279 | const u8 *wlc_phy_get_ofdm_rate_lookup(void); | |
280 | extern void wlc_phy_initcal_enable(struct brcms_phy_pub *pih, bool initcal); | 280 | |
281 | extern bool wlc_phy_test_ison(struct brcms_phy_pub *ppi); | 281 | s8 wlc_phy_get_tx_power_offset_by_mcs(struct brcms_phy_pub *ppi, |
282 | extern void wlc_phy_txpwr_percent_set(struct brcms_phy_pub *ppi, | 282 | u8 mcs_offset); |
283 | u8 txpwr_percent); | 283 | s8 wlc_phy_get_tx_power_offset(struct brcms_phy_pub *ppi, u8 tbl_offset); |
284 | extern void wlc_phy_ofdm_rateset_war(struct brcms_phy_pub *pih, bool war); | ||
285 | extern void wlc_phy_bf_preempt_enable(struct brcms_phy_pub *pih, | ||
286 | bool bf_preempt); | ||
287 | extern void wlc_phy_machwcap_set(struct brcms_phy_pub *ppi, u32 machwcap); | ||
288 | |||
289 | extern void wlc_phy_runbist_config(struct brcms_phy_pub *ppi, bool start_end); | ||
290 | |||
291 | extern void wlc_phy_freqtrack_start(struct brcms_phy_pub *ppi); | ||
292 | extern void wlc_phy_freqtrack_end(struct brcms_phy_pub *ppi); | ||
293 | |||
294 | extern const u8 *wlc_phy_get_ofdm_rate_lookup(void); | ||
295 | |||
296 | extern s8 wlc_phy_get_tx_power_offset_by_mcs(struct brcms_phy_pub *ppi, | ||
297 | u8 mcs_offset); | ||
298 | extern s8 wlc_phy_get_tx_power_offset(struct brcms_phy_pub *ppi, u8 tbl_offset); | ||
299 | #endif /* _BRCM_PHY_HAL_H_ */ | 284 | #endif /* _BRCM_PHY_HAL_H_ */ |
diff --git a/drivers/net/wireless/brcm80211/brcmsmac/phy/phy_int.h b/drivers/net/wireless/brcm80211/brcmsmac/phy/phy_int.h index 1dc767c31653..4960f7d26804 100644 --- a/drivers/net/wireless/brcm80211/brcmsmac/phy/phy_int.h +++ b/drivers/net/wireless/brcm80211/brcmsmac/phy/phy_int.h | |||
@@ -910,113 +910,103 @@ struct lcnphy_radio_regs { | |||
910 | u8 do_init_g; | 910 | u8 do_init_g; |
911 | }; | 911 | }; |
912 | 912 | ||
913 | extern u16 read_phy_reg(struct brcms_phy *pi, u16 addr); | 913 | u16 read_phy_reg(struct brcms_phy *pi, u16 addr); |
914 | extern void write_phy_reg(struct brcms_phy *pi, u16 addr, u16 val); | 914 | void write_phy_reg(struct brcms_phy *pi, u16 addr, u16 val); |
915 | extern void and_phy_reg(struct brcms_phy *pi, u16 addr, u16 val); | 915 | void and_phy_reg(struct brcms_phy *pi, u16 addr, u16 val); |
916 | extern void or_phy_reg(struct brcms_phy *pi, u16 addr, u16 val); | 916 | void or_phy_reg(struct brcms_phy *pi, u16 addr, u16 val); |
917 | extern void mod_phy_reg(struct brcms_phy *pi, u16 addr, u16 mask, u16 val); | 917 | void mod_phy_reg(struct brcms_phy *pi, u16 addr, u16 mask, u16 val); |
918 | 918 | ||
919 | extern u16 read_radio_reg(struct brcms_phy *pi, u16 addr); | 919 | u16 read_radio_reg(struct brcms_phy *pi, u16 addr); |
920 | extern void or_radio_reg(struct brcms_phy *pi, u16 addr, u16 val); | 920 | void or_radio_reg(struct brcms_phy *pi, u16 addr, u16 val); |
921 | extern void and_radio_reg(struct brcms_phy *pi, u16 addr, u16 val); | 921 | void and_radio_reg(struct brcms_phy *pi, u16 addr, u16 val); |
922 | extern void mod_radio_reg(struct brcms_phy *pi, u16 addr, u16 mask, | 922 | void mod_radio_reg(struct brcms_phy *pi, u16 addr, u16 mask, u16 val); |
923 | u16 val); | 923 | void xor_radio_reg(struct brcms_phy *pi, u16 addr, u16 mask); |
924 | extern void xor_radio_reg(struct brcms_phy *pi, u16 addr, u16 mask); | 924 | |
925 | 925 | void write_radio_reg(struct brcms_phy *pi, u16 addr, u16 val); | |
926 | extern void write_radio_reg(struct brcms_phy *pi, u16 addr, u16 val); | 926 | |
927 | 927 | void wlc_phyreg_enter(struct brcms_phy_pub *pih); | |
928 | extern void wlc_phyreg_enter(struct brcms_phy_pub *pih); | 928 | void wlc_phyreg_exit(struct brcms_phy_pub *pih); |
929 | extern void wlc_phyreg_exit(struct brcms_phy_pub *pih); | 929 | void wlc_radioreg_enter(struct brcms_phy_pub *pih); |
930 | extern void wlc_radioreg_enter(struct brcms_phy_pub *pih); | 930 | void wlc_radioreg_exit(struct brcms_phy_pub *pih); |
931 | extern void wlc_radioreg_exit(struct brcms_phy_pub *pih); | 931 | |
932 | 932 | void wlc_phy_read_table(struct brcms_phy *pi, | |
933 | extern void wlc_phy_read_table(struct brcms_phy *pi, | 933 | const struct phytbl_info *ptbl_info, |
934 | const struct phytbl_info *ptbl_info, | 934 | u16 tblAddr, u16 tblDataHi, u16 tblDatalo); |
935 | u16 tblAddr, u16 tblDataHi, | 935 | void wlc_phy_write_table(struct brcms_phy *pi, |
936 | u16 tblDatalo); | 936 | const struct phytbl_info *ptbl_info, |
937 | extern void wlc_phy_write_table(struct brcms_phy *pi, | 937 | u16 tblAddr, u16 tblDataHi, u16 tblDatalo); |
938 | const struct phytbl_info *ptbl_info, | 938 | void wlc_phy_table_addr(struct brcms_phy *pi, uint tbl_id, uint tbl_offset, |
939 | u16 tblAddr, u16 tblDataHi, u16 tblDatalo); | 939 | u16 tblAddr, u16 tblDataHi, u16 tblDataLo); |
940 | extern void wlc_phy_table_addr(struct brcms_phy *pi, uint tbl_id, | 940 | void wlc_phy_table_data_write(struct brcms_phy *pi, uint width, u32 val); |
941 | uint tbl_offset, u16 tblAddr, u16 tblDataHi, | 941 | |
942 | u16 tblDataLo); | 942 | void write_phy_channel_reg(struct brcms_phy *pi, uint val); |
943 | extern void wlc_phy_table_data_write(struct brcms_phy *pi, uint width, u32 val); | 943 | void wlc_phy_txpower_update_shm(struct brcms_phy *pi); |
944 | 944 | ||
945 | extern void write_phy_channel_reg(struct brcms_phy *pi, uint val); | 945 | u8 wlc_phy_nbits(s32 value); |
946 | extern void wlc_phy_txpower_update_shm(struct brcms_phy *pi); | 946 | void wlc_phy_compute_dB(u32 *cmplx_pwr, s8 *p_dB, u8 core); |
947 | 947 | ||
948 | extern u8 wlc_phy_nbits(s32 value); | 948 | uint wlc_phy_init_radio_regs_allbands(struct brcms_phy *pi, |
949 | extern void wlc_phy_compute_dB(u32 *cmplx_pwr, s8 *p_dB, u8 core); | 949 | struct radio_20xx_regs *radioregs); |
950 | 950 | uint wlc_phy_init_radio_regs(struct brcms_phy *pi, | |
951 | extern uint wlc_phy_init_radio_regs_allbands(struct brcms_phy *pi, | 951 | const struct radio_regs *radioregs, |
952 | struct radio_20xx_regs *radioregs); | 952 | u16 core_offset); |
953 | extern uint wlc_phy_init_radio_regs(struct brcms_phy *pi, | 953 | |
954 | const struct radio_regs *radioregs, | 954 | void wlc_phy_txpower_ipa_upd(struct brcms_phy *pi); |
955 | u16 core_offset); | 955 | |
956 | 956 | void wlc_phy_do_dummy_tx(struct brcms_phy *pi, bool ofdm, bool pa_on); | |
957 | extern void wlc_phy_txpower_ipa_upd(struct brcms_phy *pi); | 957 | void wlc_phy_papd_decode_epsilon(u32 epsilon, s32 *eps_real, s32 *eps_imag); |
958 | 958 | ||
959 | extern void wlc_phy_do_dummy_tx(struct brcms_phy *pi, bool ofdm, bool pa_on); | 959 | void wlc_phy_cal_perical_mphase_reset(struct brcms_phy *pi); |
960 | extern void wlc_phy_papd_decode_epsilon(u32 epsilon, s32 *eps_real, | 960 | void wlc_phy_cal_perical_mphase_restart(struct brcms_phy *pi); |
961 | s32 *eps_imag); | 961 | |
962 | 962 | bool wlc_phy_attach_nphy(struct brcms_phy *pi); | |
963 | extern void wlc_phy_cal_perical_mphase_reset(struct brcms_phy *pi); | 963 | bool wlc_phy_attach_lcnphy(struct brcms_phy *pi); |
964 | extern void wlc_phy_cal_perical_mphase_restart(struct brcms_phy *pi); | 964 | |
965 | 965 | void wlc_phy_detach_lcnphy(struct brcms_phy *pi); | |
966 | extern bool wlc_phy_attach_nphy(struct brcms_phy *pi); | 966 | |
967 | extern bool wlc_phy_attach_lcnphy(struct brcms_phy *pi); | 967 | void wlc_phy_init_nphy(struct brcms_phy *pi); |
968 | 968 | void wlc_phy_init_lcnphy(struct brcms_phy *pi); | |
969 | extern void wlc_phy_detach_lcnphy(struct brcms_phy *pi); | 969 | |
970 | 970 | void wlc_phy_cal_init_nphy(struct brcms_phy *pi); | |
971 | extern void wlc_phy_init_nphy(struct brcms_phy *pi); | 971 | void wlc_phy_cal_init_lcnphy(struct brcms_phy *pi); |
972 | extern void wlc_phy_init_lcnphy(struct brcms_phy *pi); | 972 | |
973 | 973 | void wlc_phy_chanspec_set_nphy(struct brcms_phy *pi, u16 chanspec); | |
974 | extern void wlc_phy_cal_init_nphy(struct brcms_phy *pi); | 974 | void wlc_phy_chanspec_set_lcnphy(struct brcms_phy *pi, u16 chanspec); |
975 | extern void wlc_phy_cal_init_lcnphy(struct brcms_phy *pi); | 975 | void wlc_phy_chanspec_set_fixup_lcnphy(struct brcms_phy *pi, u16 chanspec); |
976 | 976 | int wlc_phy_channel2freq(uint channel); | |
977 | extern void wlc_phy_chanspec_set_nphy(struct brcms_phy *pi, | 977 | int wlc_phy_chanspec_freq2bandrange_lpssn(uint); |
978 | u16 chanspec); | 978 | int wlc_phy_chanspec_bandrange_get(struct brcms_phy *, u16 chanspec); |
979 | extern void wlc_phy_chanspec_set_lcnphy(struct brcms_phy *pi, | 979 | |
980 | u16 chanspec); | 980 | void wlc_lcnphy_set_tx_pwr_ctrl(struct brcms_phy *pi, u16 mode); |
981 | extern void wlc_phy_chanspec_set_fixup_lcnphy(struct brcms_phy *pi, | 981 | s8 wlc_lcnphy_get_current_tx_pwr_idx(struct brcms_phy *pi); |
982 | u16 chanspec); | 982 | |
983 | extern int wlc_phy_channel2freq(uint channel); | 983 | void wlc_phy_txpower_recalc_target_nphy(struct brcms_phy *pi); |
984 | extern int wlc_phy_chanspec_freq2bandrange_lpssn(uint); | 984 | void wlc_lcnphy_txpower_recalc_target(struct brcms_phy *pi); |
985 | extern int wlc_phy_chanspec_bandrange_get(struct brcms_phy *, u16 chanspec); | 985 | void wlc_phy_txpower_recalc_target_lcnphy(struct brcms_phy *pi); |
986 | 986 | ||
987 | extern void wlc_lcnphy_set_tx_pwr_ctrl(struct brcms_phy *pi, u16 mode); | 987 | void wlc_lcnphy_set_tx_pwr_by_index(struct brcms_phy *pi, int index); |
988 | extern s8 wlc_lcnphy_get_current_tx_pwr_idx(struct brcms_phy *pi); | 988 | void wlc_lcnphy_tx_pu(struct brcms_phy *pi, bool bEnable); |
989 | 989 | void wlc_lcnphy_stop_tx_tone(struct brcms_phy *pi); | |
990 | extern void wlc_phy_txpower_recalc_target_nphy(struct brcms_phy *pi); | 990 | void wlc_lcnphy_start_tx_tone(struct brcms_phy *pi, s32 f_kHz, u16 max_val, |
991 | extern void wlc_lcnphy_txpower_recalc_target(struct brcms_phy *pi); | 991 | bool iqcalmode); |
992 | extern void wlc_phy_txpower_recalc_target_lcnphy(struct brcms_phy *pi); | 992 | |
993 | 993 | void wlc_phy_txpower_sromlimit_get_nphy(struct brcms_phy *pi, uint chan, | |
994 | extern void wlc_lcnphy_set_tx_pwr_by_index(struct brcms_phy *pi, int index); | 994 | u8 *max_pwr, u8 rate_id); |
995 | extern void wlc_lcnphy_tx_pu(struct brcms_phy *pi, bool bEnable); | 995 | void wlc_phy_ofdm_to_mcs_powers_nphy(u8 *power, u8 rate_mcs_start, |
996 | extern void wlc_lcnphy_stop_tx_tone(struct brcms_phy *pi); | 996 | u8 rate_mcs_end, u8 rate_ofdm_start); |
997 | extern void wlc_lcnphy_start_tx_tone(struct brcms_phy *pi, s32 f_kHz, | 997 | void wlc_phy_mcs_to_ofdm_powers_nphy(u8 *power, u8 rate_ofdm_start, |
998 | u16 max_val, bool iqcalmode); | 998 | u8 rate_ofdm_end, u8 rate_mcs_start); |
999 | 999 | ||
1000 | extern void wlc_phy_txpower_sromlimit_get_nphy(struct brcms_phy *pi, uint chan, | 1000 | u16 wlc_lcnphy_tempsense(struct brcms_phy *pi, bool mode); |
1001 | u8 *max_pwr, u8 rate_id); | 1001 | s16 wlc_lcnphy_tempsense_new(struct brcms_phy *pi, bool mode); |
1002 | extern void wlc_phy_ofdm_to_mcs_powers_nphy(u8 *power, u8 rate_mcs_start, | 1002 | s8 wlc_lcnphy_tempsense_degree(struct brcms_phy *pi, bool mode); |
1003 | u8 rate_mcs_end, | 1003 | s8 wlc_lcnphy_vbatsense(struct brcms_phy *pi, bool mode); |
1004 | u8 rate_ofdm_start); | 1004 | void wlc_phy_carrier_suppress_lcnphy(struct brcms_phy *pi); |
1005 | extern void wlc_phy_mcs_to_ofdm_powers_nphy(u8 *power, | 1005 | void wlc_lcnphy_crsuprs(struct brcms_phy *pi, int channel); |
1006 | u8 rate_ofdm_start, | 1006 | void wlc_lcnphy_epa_switch(struct brcms_phy *pi, bool mode); |
1007 | u8 rate_ofdm_end, | 1007 | void wlc_2064_vco_cal(struct brcms_phy *pi); |
1008 | u8 rate_mcs_start); | 1008 | |
1009 | 1009 | void wlc_phy_txpower_recalc_target(struct brcms_phy *pi); | |
1010 | extern u16 wlc_lcnphy_tempsense(struct brcms_phy *pi, bool mode); | ||
1011 | extern s16 wlc_lcnphy_tempsense_new(struct brcms_phy *pi, bool mode); | ||
1012 | extern s8 wlc_lcnphy_tempsense_degree(struct brcms_phy *pi, bool mode); | ||
1013 | extern s8 wlc_lcnphy_vbatsense(struct brcms_phy *pi, bool mode); | ||
1014 | extern void wlc_phy_carrier_suppress_lcnphy(struct brcms_phy *pi); | ||
1015 | extern void wlc_lcnphy_crsuprs(struct brcms_phy *pi, int channel); | ||
1016 | extern void wlc_lcnphy_epa_switch(struct brcms_phy *pi, bool mode); | ||
1017 | extern void wlc_2064_vco_cal(struct brcms_phy *pi); | ||
1018 | |||
1019 | extern void wlc_phy_txpower_recalc_target(struct brcms_phy *pi); | ||
1020 | 1010 | ||
1021 | #define LCNPHY_TBL_ID_PAPDCOMPDELTATBL 0x18 | 1011 | #define LCNPHY_TBL_ID_PAPDCOMPDELTATBL 0x18 |
1022 | #define LCNPHY_TX_POWER_TABLE_SIZE 128 | 1012 | #define LCNPHY_TX_POWER_TABLE_SIZE 128 |
@@ -1030,26 +1020,24 @@ extern void wlc_phy_txpower_recalc_target(struct brcms_phy *pi); | |||
1030 | 1020 | ||
1031 | #define LCNPHY_TX_PWR_CTRL_TEMPBASED 0xE001 | 1021 | #define LCNPHY_TX_PWR_CTRL_TEMPBASED 0xE001 |
1032 | 1022 | ||
1033 | extern void wlc_lcnphy_write_table(struct brcms_phy *pi, | 1023 | void wlc_lcnphy_write_table(struct brcms_phy *pi, |
1034 | const struct phytbl_info *pti); | 1024 | const struct phytbl_info *pti); |
1035 | extern void wlc_lcnphy_read_table(struct brcms_phy *pi, | 1025 | void wlc_lcnphy_read_table(struct brcms_phy *pi, struct phytbl_info *pti); |
1036 | struct phytbl_info *pti); | 1026 | void wlc_lcnphy_set_tx_iqcc(struct brcms_phy *pi, u16 a, u16 b); |
1037 | extern void wlc_lcnphy_set_tx_iqcc(struct brcms_phy *pi, u16 a, u16 b); | 1027 | void wlc_lcnphy_set_tx_locc(struct brcms_phy *pi, u16 didq); |
1038 | extern void wlc_lcnphy_set_tx_locc(struct brcms_phy *pi, u16 didq); | 1028 | void wlc_lcnphy_get_tx_iqcc(struct brcms_phy *pi, u16 *a, u16 *b); |
1039 | extern void wlc_lcnphy_get_tx_iqcc(struct brcms_phy *pi, u16 *a, u16 *b); | 1029 | u16 wlc_lcnphy_get_tx_locc(struct brcms_phy *pi); |
1040 | extern u16 wlc_lcnphy_get_tx_locc(struct brcms_phy *pi); | 1030 | void wlc_lcnphy_get_radio_loft(struct brcms_phy *pi, u8 *ei0, u8 *eq0, u8 *fi0, |
1041 | extern void wlc_lcnphy_get_radio_loft(struct brcms_phy *pi, u8 *ei0, | 1031 | u8 *fq0); |
1042 | u8 *eq0, u8 *fi0, u8 *fq0); | 1032 | void wlc_lcnphy_calib_modes(struct brcms_phy *pi, uint mode); |
1043 | extern void wlc_lcnphy_calib_modes(struct brcms_phy *pi, uint mode); | 1033 | void wlc_lcnphy_deaf_mode(struct brcms_phy *pi, bool mode); |
1044 | extern void wlc_lcnphy_deaf_mode(struct brcms_phy *pi, bool mode); | 1034 | bool wlc_phy_tpc_isenabled_lcnphy(struct brcms_phy *pi); |
1045 | extern bool wlc_phy_tpc_isenabled_lcnphy(struct brcms_phy *pi); | 1035 | void wlc_lcnphy_tx_pwr_update_npt(struct brcms_phy *pi); |
1046 | extern void wlc_lcnphy_tx_pwr_update_npt(struct brcms_phy *pi); | 1036 | s32 wlc_lcnphy_tssi2dbm(s32 tssi, s32 a1, s32 b0, s32 b1); |
1047 | extern s32 wlc_lcnphy_tssi2dbm(s32 tssi, s32 a1, s32 b0, s32 b1); | 1037 | void wlc_lcnphy_get_tssi(struct brcms_phy *pi, s8 *ofdm_pwr, s8 *cck_pwr); |
1048 | extern void wlc_lcnphy_get_tssi(struct brcms_phy *pi, s8 *ofdm_pwr, | 1038 | void wlc_lcnphy_tx_power_adjustment(struct brcms_phy_pub *ppi); |
1049 | s8 *cck_pwr); | 1039 | |
1050 | extern void wlc_lcnphy_tx_power_adjustment(struct brcms_phy_pub *ppi); | 1040 | s32 wlc_lcnphy_rx_signal_power(struct brcms_phy *pi, s32 gain_index); |
1051 | |||
1052 | extern s32 wlc_lcnphy_rx_signal_power(struct brcms_phy *pi, s32 gain_index); | ||
1053 | 1041 | ||
1054 | #define NPHY_MAX_HPVGA1_INDEX 10 | 1042 | #define NPHY_MAX_HPVGA1_INDEX 10 |
1055 | #define NPHY_DEF_HPVGA1_INDEXLIMIT 7 | 1043 | #define NPHY_DEF_HPVGA1_INDEXLIMIT 7 |
@@ -1060,9 +1048,8 @@ struct phy_iq_est { | |||
1060 | u32 q_pwr; | 1048 | u32 q_pwr; |
1061 | }; | 1049 | }; |
1062 | 1050 | ||
1063 | extern void wlc_phy_stay_in_carriersearch_nphy(struct brcms_phy *pi, | 1051 | void wlc_phy_stay_in_carriersearch_nphy(struct brcms_phy *pi, bool enable); |
1064 | bool enable); | 1052 | void wlc_nphy_deaf_mode(struct brcms_phy *pi, bool mode); |
1065 | extern void wlc_nphy_deaf_mode(struct brcms_phy *pi, bool mode); | ||
1066 | 1053 | ||
1067 | #define wlc_phy_write_table_nphy(pi, pti) \ | 1054 | #define wlc_phy_write_table_nphy(pi, pti) \ |
1068 | wlc_phy_write_table(pi, pti, 0x72, 0x74, 0x73) | 1055 | wlc_phy_write_table(pi, pti, 0x72, 0x74, 0x73) |
@@ -1076,10 +1063,10 @@ extern void wlc_nphy_deaf_mode(struct brcms_phy *pi, bool mode); | |||
1076 | #define wlc_nphy_table_data_write(pi, w, v) \ | 1063 | #define wlc_nphy_table_data_write(pi, w, v) \ |
1077 | wlc_phy_table_data_write((pi), (w), (v)) | 1064 | wlc_phy_table_data_write((pi), (w), (v)) |
1078 | 1065 | ||
1079 | extern void wlc_phy_table_read_nphy(struct brcms_phy *pi, u32, u32 l, u32 o, | 1066 | void wlc_phy_table_read_nphy(struct brcms_phy *pi, u32, u32 l, u32 o, u32 w, |
1080 | u32 w, void *d); | 1067 | void *d); |
1081 | extern void wlc_phy_table_write_nphy(struct brcms_phy *pi, u32, u32, u32, | 1068 | void wlc_phy_table_write_nphy(struct brcms_phy *pi, u32, u32, u32, u32, |
1082 | u32, const void *); | 1069 | const void *); |
1083 | 1070 | ||
1084 | #define PHY_IPA(pi) \ | 1071 | #define PHY_IPA(pi) \ |
1085 | ((pi->ipa2g_on && CHSPEC_IS2G(pi->radio_chanspec)) || \ | 1072 | ((pi->ipa2g_on && CHSPEC_IS2G(pi->radio_chanspec)) || \ |
@@ -1089,73 +1076,67 @@ extern void wlc_phy_table_write_nphy(struct brcms_phy *pi, u32, u32, u32, | |||
1089 | if (NREV_LT((pi)->pubpi.phy_rev, 3)) \ | 1076 | if (NREV_LT((pi)->pubpi.phy_rev, 3)) \ |
1090 | (void)bcma_read32(pi->d11core, D11REGOFFS(maccontrol)) | 1077 | (void)bcma_read32(pi->d11core, D11REGOFFS(maccontrol)) |
1091 | 1078 | ||
1092 | extern void wlc_phy_cal_perical_nphy_run(struct brcms_phy *pi, u8 caltype); | 1079 | void wlc_phy_cal_perical_nphy_run(struct brcms_phy *pi, u8 caltype); |
1093 | extern void wlc_phy_aci_reset_nphy(struct brcms_phy *pi); | 1080 | void wlc_phy_aci_reset_nphy(struct brcms_phy *pi); |
1094 | extern void wlc_phy_pa_override_nphy(struct brcms_phy *pi, bool en); | 1081 | void wlc_phy_pa_override_nphy(struct brcms_phy *pi, bool en); |
1095 | 1082 | ||
1096 | extern u8 wlc_phy_get_chan_freq_range_nphy(struct brcms_phy *pi, uint chan); | 1083 | u8 wlc_phy_get_chan_freq_range_nphy(struct brcms_phy *pi, uint chan); |
1097 | extern void wlc_phy_switch_radio_nphy(struct brcms_phy *pi, bool on); | 1084 | void wlc_phy_switch_radio_nphy(struct brcms_phy *pi, bool on); |
1098 | 1085 | ||
1099 | extern void wlc_phy_stf_chain_upd_nphy(struct brcms_phy *pi); | 1086 | void wlc_phy_stf_chain_upd_nphy(struct brcms_phy *pi); |
1100 | 1087 | ||
1101 | extern void wlc_phy_force_rfseq_nphy(struct brcms_phy *pi, u8 cmd); | 1088 | void wlc_phy_force_rfseq_nphy(struct brcms_phy *pi, u8 cmd); |
1102 | extern s16 wlc_phy_tempsense_nphy(struct brcms_phy *pi); | 1089 | s16 wlc_phy_tempsense_nphy(struct brcms_phy *pi); |
1103 | 1090 | ||
1104 | extern u16 wlc_phy_classifier_nphy(struct brcms_phy *pi, u16 mask, u16 val); | 1091 | u16 wlc_phy_classifier_nphy(struct brcms_phy *pi, u16 mask, u16 val); |
1105 | 1092 | ||
1106 | extern void wlc_phy_rx_iq_est_nphy(struct brcms_phy *pi, struct phy_iq_est *est, | 1093 | void wlc_phy_rx_iq_est_nphy(struct brcms_phy *pi, struct phy_iq_est *est, |
1107 | u16 num_samps, u8 wait_time, | 1094 | u16 num_samps, u8 wait_time, u8 wait_for_crs); |
1108 | u8 wait_for_crs); | 1095 | |
1109 | 1096 | void wlc_phy_rx_iq_coeffs_nphy(struct brcms_phy *pi, u8 write, | |
1110 | extern void wlc_phy_rx_iq_coeffs_nphy(struct brcms_phy *pi, u8 write, | 1097 | struct nphy_iq_comp *comp); |
1111 | struct nphy_iq_comp *comp); | 1098 | void wlc_phy_aci_and_noise_reduction_nphy(struct brcms_phy *pi); |
1112 | extern void wlc_phy_aci_and_noise_reduction_nphy(struct brcms_phy *pi); | 1099 | |
1113 | 1100 | void wlc_phy_rxcore_setstate_nphy(struct brcms_phy_pub *pih, u8 rxcore_bitmask); | |
1114 | extern void wlc_phy_rxcore_setstate_nphy(struct brcms_phy_pub *pih, | 1101 | u8 wlc_phy_rxcore_getstate_nphy(struct brcms_phy_pub *pih); |
1115 | u8 rxcore_bitmask); | 1102 | |
1116 | extern u8 wlc_phy_rxcore_getstate_nphy(struct brcms_phy_pub *pih); | 1103 | void wlc_phy_txpwrctrl_enable_nphy(struct brcms_phy *pi, u8 ctrl_type); |
1117 | 1104 | void wlc_phy_txpwr_fixpower_nphy(struct brcms_phy *pi); | |
1118 | extern void wlc_phy_txpwrctrl_enable_nphy(struct brcms_phy *pi, u8 ctrl_type); | 1105 | void wlc_phy_txpwr_apply_nphy(struct brcms_phy *pi); |
1119 | extern void wlc_phy_txpwr_fixpower_nphy(struct brcms_phy *pi); | 1106 | void wlc_phy_txpwr_papd_cal_nphy(struct brcms_phy *pi); |
1120 | extern void wlc_phy_txpwr_apply_nphy(struct brcms_phy *pi); | 1107 | u16 wlc_phy_txpwr_idx_get_nphy(struct brcms_phy *pi); |
1121 | extern void wlc_phy_txpwr_papd_cal_nphy(struct brcms_phy *pi); | 1108 | |
1122 | extern u16 wlc_phy_txpwr_idx_get_nphy(struct brcms_phy *pi); | 1109 | struct nphy_txgains wlc_phy_get_tx_gain_nphy(struct brcms_phy *pi); |
1123 | 1110 | int wlc_phy_cal_txiqlo_nphy(struct brcms_phy *pi, | |
1124 | extern struct nphy_txgains wlc_phy_get_tx_gain_nphy(struct brcms_phy *pi); | 1111 | struct nphy_txgains target_gain, bool full, bool m); |
1125 | extern int wlc_phy_cal_txiqlo_nphy(struct brcms_phy *pi, | 1112 | int wlc_phy_cal_rxiq_nphy(struct brcms_phy *pi, struct nphy_txgains target_gain, |
1126 | struct nphy_txgains target_gain, | 1113 | u8 type, bool d); |
1127 | bool full, bool m); | 1114 | void wlc_phy_txpwr_index_nphy(struct brcms_phy *pi, u8 core_mask, |
1128 | extern int wlc_phy_cal_rxiq_nphy(struct brcms_phy *pi, | 1115 | s8 txpwrindex, bool res); |
1129 | struct nphy_txgains target_gain, | 1116 | void wlc_phy_rssisel_nphy(struct brcms_phy *pi, u8 core, u8 rssi_type); |
1130 | u8 type, bool d); | 1117 | int wlc_phy_poll_rssi_nphy(struct brcms_phy *pi, u8 rssi_type, |
1131 | extern void wlc_phy_txpwr_index_nphy(struct brcms_phy *pi, u8 core_mask, | 1118 | s32 *rssi_buf, u8 nsamps); |
1132 | s8 txpwrindex, bool res); | 1119 | void wlc_phy_rssi_cal_nphy(struct brcms_phy *pi); |
1133 | extern void wlc_phy_rssisel_nphy(struct brcms_phy *pi, u8 core, u8 rssi_type); | 1120 | int wlc_phy_aci_scan_nphy(struct brcms_phy *pi); |
1134 | extern int wlc_phy_poll_rssi_nphy(struct brcms_phy *pi, u8 rssi_type, | 1121 | void wlc_phy_cal_txgainctrl_nphy(struct brcms_phy *pi, s32 dBm_targetpower, |
1135 | s32 *rssi_buf, u8 nsamps); | 1122 | bool debug); |
1136 | extern void wlc_phy_rssi_cal_nphy(struct brcms_phy *pi); | 1123 | int wlc_phy_tx_tone_nphy(struct brcms_phy *pi, u32 f_kHz, u16 max_val, u8 mode, |
1137 | extern int wlc_phy_aci_scan_nphy(struct brcms_phy *pi); | 1124 | u8, bool); |
1138 | extern void wlc_phy_cal_txgainctrl_nphy(struct brcms_phy *pi, | 1125 | void wlc_phy_stopplayback_nphy(struct brcms_phy *pi); |
1139 | s32 dBm_targetpower, bool debug); | 1126 | void wlc_phy_est_tonepwr_nphy(struct brcms_phy *pi, s32 *qdBm_pwrbuf, |
1140 | extern int wlc_phy_tx_tone_nphy(struct brcms_phy *pi, u32 f_kHz, u16 max_val, | 1127 | u8 num_samps); |
1141 | u8 mode, u8, bool); | 1128 | void wlc_phy_radio205x_vcocal_nphy(struct brcms_phy *pi); |
1142 | extern void wlc_phy_stopplayback_nphy(struct brcms_phy *pi); | 1129 | |
1143 | extern void wlc_phy_est_tonepwr_nphy(struct brcms_phy *pi, s32 *qdBm_pwrbuf, | 1130 | int wlc_phy_rssi_compute_nphy(struct brcms_phy *pi, struct d11rxhdr *rxh); |
1144 | u8 num_samps); | ||
1145 | extern void wlc_phy_radio205x_vcocal_nphy(struct brcms_phy *pi); | ||
1146 | |||
1147 | extern int wlc_phy_rssi_compute_nphy(struct brcms_phy *pi, | ||
1148 | struct d11rxhdr *rxh); | ||
1149 | 1131 | ||
1150 | #define NPHY_TESTPATTERN_BPHY_EVM 0 | 1132 | #define NPHY_TESTPATTERN_BPHY_EVM 0 |
1151 | #define NPHY_TESTPATTERN_BPHY_RFCS 1 | 1133 | #define NPHY_TESTPATTERN_BPHY_RFCS 1 |
1152 | 1134 | ||
1153 | extern void wlc_phy_nphy_tkip_rifs_war(struct brcms_phy *pi, u8 rifs); | 1135 | void wlc_phy_nphy_tkip_rifs_war(struct brcms_phy *pi, u8 rifs); |
1154 | 1136 | ||
1155 | void wlc_phy_get_pwrdet_offsets(struct brcms_phy *pi, s8 *cckoffset, | 1137 | void wlc_phy_get_pwrdet_offsets(struct brcms_phy *pi, s8 *cckoffset, |
1156 | s8 *ofdmoffset); | 1138 | s8 *ofdmoffset); |
1157 | extern s8 wlc_phy_upd_rssi_offset(struct brcms_phy *pi, s8 rssi, | 1139 | s8 wlc_phy_upd_rssi_offset(struct brcms_phy *pi, s8 rssi, u16 chanspec); |
1158 | u16 chanspec); | ||
1159 | 1140 | ||
1160 | extern bool wlc_phy_n_txpower_ipa_ison(struct brcms_phy *pih); | 1141 | bool wlc_phy_n_txpower_ipa_ison(struct brcms_phy *pih); |
1161 | #endif /* _BRCM_PHY_INT_H_ */ | 1142 | #endif /* _BRCM_PHY_INT_H_ */ |
diff --git a/drivers/net/wireless/brcm80211/brcmsmac/phy_shim.h b/drivers/net/wireless/brcm80211/brcmsmac/phy_shim.h index 2c5b66b75970..dd8774717ade 100644 --- a/drivers/net/wireless/brcm80211/brcmsmac/phy_shim.h +++ b/drivers/net/wireless/brcm80211/brcmsmac/phy_shim.h | |||
@@ -124,56 +124,49 @@ | |||
124 | 124 | ||
125 | struct brcms_phy; | 125 | struct brcms_phy; |
126 | 126 | ||
127 | extern struct phy_shim_info *wlc_phy_shim_attach(struct brcms_hardware *wlc_hw, | 127 | struct phy_shim_info *wlc_phy_shim_attach(struct brcms_hardware *wlc_hw, |
128 | struct brcms_info *wl, | 128 | struct brcms_info *wl, |
129 | struct brcms_c_info *wlc); | 129 | struct brcms_c_info *wlc); |
130 | extern void wlc_phy_shim_detach(struct phy_shim_info *physhim); | 130 | void wlc_phy_shim_detach(struct phy_shim_info *physhim); |
131 | 131 | ||
132 | /* PHY to WL utility functions */ | 132 | /* PHY to WL utility functions */ |
133 | extern struct wlapi_timer *wlapi_init_timer(struct phy_shim_info *physhim, | 133 | struct wlapi_timer *wlapi_init_timer(struct phy_shim_info *physhim, |
134 | void (*fn) (struct brcms_phy *pi), | 134 | void (*fn)(struct brcms_phy *pi), |
135 | void *arg, const char *name); | 135 | void *arg, const char *name); |
136 | extern void wlapi_free_timer(struct wlapi_timer *t); | 136 | void wlapi_free_timer(struct wlapi_timer *t); |
137 | extern void wlapi_add_timer(struct wlapi_timer *t, uint ms, int periodic); | 137 | void wlapi_add_timer(struct wlapi_timer *t, uint ms, int periodic); |
138 | extern bool wlapi_del_timer(struct wlapi_timer *t); | 138 | bool wlapi_del_timer(struct wlapi_timer *t); |
139 | extern void wlapi_intrson(struct phy_shim_info *physhim); | 139 | void wlapi_intrson(struct phy_shim_info *physhim); |
140 | extern u32 wlapi_intrsoff(struct phy_shim_info *physhim); | 140 | u32 wlapi_intrsoff(struct phy_shim_info *physhim); |
141 | extern void wlapi_intrsrestore(struct phy_shim_info *physhim, | 141 | void wlapi_intrsrestore(struct phy_shim_info *physhim, u32 macintmask); |
142 | u32 macintmask); | 142 | |
143 | 143 | void wlapi_bmac_write_shm(struct phy_shim_info *physhim, uint offset, u16 v); | |
144 | extern void wlapi_bmac_write_shm(struct phy_shim_info *physhim, uint offset, | 144 | u16 wlapi_bmac_read_shm(struct phy_shim_info *physhim, uint offset); |
145 | u16 v); | 145 | void wlapi_bmac_mhf(struct phy_shim_info *physhim, u8 idx, u16 mask, u16 val, |
146 | extern u16 wlapi_bmac_read_shm(struct phy_shim_info *physhim, uint offset); | 146 | int bands); |
147 | extern void wlapi_bmac_mhf(struct phy_shim_info *physhim, u8 idx, | 147 | void wlapi_bmac_corereset(struct phy_shim_info *physhim, u32 flags); |
148 | u16 mask, u16 val, int bands); | 148 | void wlapi_suspend_mac_and_wait(struct phy_shim_info *physhim); |
149 | extern void wlapi_bmac_corereset(struct phy_shim_info *physhim, u32 flags); | 149 | void wlapi_switch_macfreq(struct phy_shim_info *physhim, u8 spurmode); |
150 | extern void wlapi_suspend_mac_and_wait(struct phy_shim_info *physhim); | 150 | void wlapi_enable_mac(struct phy_shim_info *physhim); |
151 | extern void wlapi_switch_macfreq(struct phy_shim_info *physhim, u8 spurmode); | 151 | void wlapi_bmac_mctrl(struct phy_shim_info *physhim, u32 mask, u32 val); |
152 | extern void wlapi_enable_mac(struct phy_shim_info *physhim); | 152 | void wlapi_bmac_phy_reset(struct phy_shim_info *physhim); |
153 | extern void wlapi_bmac_mctrl(struct phy_shim_info *physhim, u32 mask, | 153 | void wlapi_bmac_bw_set(struct phy_shim_info *physhim, u16 bw); |
154 | u32 val); | 154 | void wlapi_bmac_phyclk_fgc(struct phy_shim_info *physhim, bool clk); |
155 | extern void wlapi_bmac_phy_reset(struct phy_shim_info *physhim); | 155 | void wlapi_bmac_macphyclk_set(struct phy_shim_info *physhim, bool clk); |
156 | extern void wlapi_bmac_bw_set(struct phy_shim_info *physhim, u16 bw); | 156 | void wlapi_bmac_core_phypll_ctl(struct phy_shim_info *physhim, bool on); |
157 | extern void wlapi_bmac_phyclk_fgc(struct phy_shim_info *physhim, bool clk); | 157 | void wlapi_bmac_core_phypll_reset(struct phy_shim_info *physhim); |
158 | extern void wlapi_bmac_macphyclk_set(struct phy_shim_info *physhim, bool clk); | 158 | void wlapi_bmac_ucode_wake_override_phyreg_set(struct phy_shim_info *physhim); |
159 | extern void wlapi_bmac_core_phypll_ctl(struct phy_shim_info *physhim, bool on); | 159 | void wlapi_bmac_ucode_wake_override_phyreg_clear(struct phy_shim_info *physhim); |
160 | extern void wlapi_bmac_core_phypll_reset(struct phy_shim_info *physhim); | 160 | void wlapi_bmac_write_template_ram(struct phy_shim_info *physhim, int o, |
161 | extern void wlapi_bmac_ucode_wake_override_phyreg_set(struct phy_shim_info * | 161 | int len, void *buf); |
162 | physhim); | 162 | u16 wlapi_bmac_rate_shm_offset(struct phy_shim_info *physhim, u8 rate); |
163 | extern void wlapi_bmac_ucode_wake_override_phyreg_clear(struct phy_shim_info * | 163 | void wlapi_ucode_sample_init(struct phy_shim_info *physhim); |
164 | physhim); | 164 | void wlapi_copyfrom_objmem(struct phy_shim_info *physhim, uint, void *buf, |
165 | extern void wlapi_bmac_write_template_ram(struct phy_shim_info *physhim, int o, | 165 | int, u32 sel); |
166 | int len, void *buf); | 166 | void wlapi_copyto_objmem(struct phy_shim_info *physhim, uint, const void *buf, |
167 | extern u16 wlapi_bmac_rate_shm_offset(struct phy_shim_info *physhim, | 167 | int, u32); |
168 | u8 rate); | 168 | |
169 | extern void wlapi_ucode_sample_init(struct phy_shim_info *physhim); | 169 | void wlapi_high_update_phy_mode(struct phy_shim_info *physhim, u32 phy_mode); |
170 | extern void wlapi_copyfrom_objmem(struct phy_shim_info *physhim, uint, | 170 | u16 wlapi_bmac_get_txant(struct phy_shim_info *physhim); |
171 | void *buf, int, u32 sel); | ||
172 | extern void wlapi_copyto_objmem(struct phy_shim_info *physhim, uint, | ||
173 | const void *buf, int, u32); | ||
174 | |||
175 | extern void wlapi_high_update_phy_mode(struct phy_shim_info *physhim, | ||
176 | u32 phy_mode); | ||
177 | extern u16 wlapi_bmac_get_txant(struct phy_shim_info *physhim); | ||
178 | 171 | ||
179 | #endif /* _BRCM_PHY_SHIM_H_ */ | 172 | #endif /* _BRCM_PHY_SHIM_H_ */ |
diff --git a/drivers/net/wireless/brcm80211/brcmsmac/pmu.h b/drivers/net/wireless/brcm80211/brcmsmac/pmu.h index 20e2012d5a3a..a014bbc4f935 100644 --- a/drivers/net/wireless/brcm80211/brcmsmac/pmu.h +++ b/drivers/net/wireless/brcm80211/brcmsmac/pmu.h | |||
@@ -20,7 +20,7 @@ | |||
20 | 20 | ||
21 | #include "types.h" | 21 | #include "types.h" |
22 | 22 | ||
23 | extern u16 si_pmu_fast_pwrup_delay(struct si_pub *sih); | 23 | u16 si_pmu_fast_pwrup_delay(struct si_pub *sih); |
24 | extern u32 si_pmu_measure_alpclk(struct si_pub *sih); | 24 | u32 si_pmu_measure_alpclk(struct si_pub *sih); |
25 | 25 | ||
26 | #endif /* _BRCM_PMU_H_ */ | 26 | #endif /* _BRCM_PMU_H_ */ |
diff --git a/drivers/net/wireless/brcm80211/brcmsmac/pub.h b/drivers/net/wireless/brcm80211/brcmsmac/pub.h index d36ea5e1cc49..4da38cb4f318 100644 --- a/drivers/net/wireless/brcm80211/brcmsmac/pub.h +++ b/drivers/net/wireless/brcm80211/brcmsmac/pub.h | |||
@@ -266,83 +266,76 @@ struct brcms_antselcfg { | |||
266 | }; | 266 | }; |
267 | 267 | ||
268 | /* common functions for every port */ | 268 | /* common functions for every port */ |
269 | extern struct brcms_c_info * | 269 | struct brcms_c_info *brcms_c_attach(struct brcms_info *wl, |
270 | brcms_c_attach(struct brcms_info *wl, struct bcma_device *core, uint unit, | 270 | struct bcma_device *core, uint unit, |
271 | bool piomode, uint *perr); | 271 | bool piomode, uint *perr); |
272 | extern uint brcms_c_detach(struct brcms_c_info *wlc); | 272 | uint brcms_c_detach(struct brcms_c_info *wlc); |
273 | extern int brcms_c_up(struct brcms_c_info *wlc); | 273 | int brcms_c_up(struct brcms_c_info *wlc); |
274 | extern uint brcms_c_down(struct brcms_c_info *wlc); | 274 | uint brcms_c_down(struct brcms_c_info *wlc); |
275 | 275 | ||
276 | extern bool brcms_c_chipmatch(struct bcma_device *core); | 276 | bool brcms_c_chipmatch(struct bcma_device *core); |
277 | extern void brcms_c_init(struct brcms_c_info *wlc, bool mute_tx); | 277 | void brcms_c_init(struct brcms_c_info *wlc, bool mute_tx); |
278 | extern void brcms_c_reset(struct brcms_c_info *wlc); | 278 | void brcms_c_reset(struct brcms_c_info *wlc); |
279 | 279 | ||
280 | extern void brcms_c_intrson(struct brcms_c_info *wlc); | 280 | void brcms_c_intrson(struct brcms_c_info *wlc); |
281 | extern u32 brcms_c_intrsoff(struct brcms_c_info *wlc); | 281 | u32 brcms_c_intrsoff(struct brcms_c_info *wlc); |
282 | extern void brcms_c_intrsrestore(struct brcms_c_info *wlc, u32 macintmask); | 282 | void brcms_c_intrsrestore(struct brcms_c_info *wlc, u32 macintmask); |
283 | extern bool brcms_c_intrsupd(struct brcms_c_info *wlc); | 283 | bool brcms_c_intrsupd(struct brcms_c_info *wlc); |
284 | extern bool brcms_c_isr(struct brcms_c_info *wlc); | 284 | bool brcms_c_isr(struct brcms_c_info *wlc); |
285 | extern bool brcms_c_dpc(struct brcms_c_info *wlc, bool bounded); | 285 | bool brcms_c_dpc(struct brcms_c_info *wlc, bool bounded); |
286 | extern bool brcms_c_sendpkt_mac80211(struct brcms_c_info *wlc, | 286 | bool brcms_c_sendpkt_mac80211(struct brcms_c_info *wlc, struct sk_buff *sdu, |
287 | struct sk_buff *sdu, | 287 | struct ieee80211_hw *hw); |
288 | struct ieee80211_hw *hw); | 288 | bool brcms_c_aggregatable(struct brcms_c_info *wlc, u8 tid); |
289 | extern bool brcms_c_aggregatable(struct brcms_c_info *wlc, u8 tid); | 289 | void brcms_c_protection_upd(struct brcms_c_info *wlc, uint idx, int val); |
290 | extern void brcms_c_protection_upd(struct brcms_c_info *wlc, uint idx, | 290 | int brcms_c_get_header_len(void); |
291 | int val); | 291 | void brcms_c_set_addrmatch(struct brcms_c_info *wlc, int match_reg_offset, |
292 | extern int brcms_c_get_header_len(void); | 292 | const u8 *addr); |
293 | extern void brcms_c_set_addrmatch(struct brcms_c_info *wlc, | 293 | void brcms_c_wme_setparams(struct brcms_c_info *wlc, u16 aci, |
294 | int match_reg_offset, | 294 | const struct ieee80211_tx_queue_params *arg, |
295 | const u8 *addr); | 295 | bool suspend); |
296 | extern void brcms_c_wme_setparams(struct brcms_c_info *wlc, u16 aci, | 296 | struct brcms_pub *brcms_c_pub(struct brcms_c_info *wlc); |
297 | const struct ieee80211_tx_queue_params *arg, | 297 | void brcms_c_ampdu_flush(struct brcms_c_info *wlc, struct ieee80211_sta *sta, |
298 | bool suspend); | 298 | u16 tid); |
299 | extern struct brcms_pub *brcms_c_pub(struct brcms_c_info *wlc); | 299 | void brcms_c_ampdu_tx_operational(struct brcms_c_info *wlc, u8 tid, |
300 | extern void brcms_c_ampdu_flush(struct brcms_c_info *wlc, | 300 | u8 ba_wsize, uint max_rx_ampdu_bytes); |
301 | struct ieee80211_sta *sta, u16 tid); | 301 | int brcms_c_module_register(struct brcms_pub *pub, const char *name, |
302 | extern void brcms_c_ampdu_tx_operational(struct brcms_c_info *wlc, u8 tid, | 302 | struct brcms_info *hdl, |
303 | u8 ba_wsize, uint max_rx_ampdu_bytes); | 303 | int (*down_fn)(void *handle)); |
304 | extern int brcms_c_module_register(struct brcms_pub *pub, | 304 | int brcms_c_module_unregister(struct brcms_pub *pub, const char *name, |
305 | const char *name, struct brcms_info *hdl, | 305 | struct brcms_info *hdl); |
306 | int (*down_fn)(void *handle)); | 306 | void brcms_c_suspend_mac_and_wait(struct brcms_c_info *wlc); |
307 | extern int brcms_c_module_unregister(struct brcms_pub *pub, const char *name, | 307 | void brcms_c_enable_mac(struct brcms_c_info *wlc); |
308 | struct brcms_info *hdl); | 308 | void brcms_c_associate_upd(struct brcms_c_info *wlc, bool state); |
309 | extern void brcms_c_suspend_mac_and_wait(struct brcms_c_info *wlc); | 309 | void brcms_c_scan_start(struct brcms_c_info *wlc); |
310 | extern void brcms_c_enable_mac(struct brcms_c_info *wlc); | 310 | void brcms_c_scan_stop(struct brcms_c_info *wlc); |
311 | extern void brcms_c_associate_upd(struct brcms_c_info *wlc, bool state); | 311 | int brcms_c_get_curband(struct brcms_c_info *wlc); |
312 | extern void brcms_c_scan_start(struct brcms_c_info *wlc); | 312 | int brcms_c_set_channel(struct brcms_c_info *wlc, u16 channel); |
313 | extern void brcms_c_scan_stop(struct brcms_c_info *wlc); | 313 | int brcms_c_set_rate_limit(struct brcms_c_info *wlc, u16 srl, u16 lrl); |
314 | extern int brcms_c_get_curband(struct brcms_c_info *wlc); | 314 | void brcms_c_get_current_rateset(struct brcms_c_info *wlc, |
315 | extern int brcms_c_set_channel(struct brcms_c_info *wlc, u16 channel); | ||
316 | extern int brcms_c_set_rate_limit(struct brcms_c_info *wlc, u16 srl, u16 lrl); | ||
317 | extern void brcms_c_get_current_rateset(struct brcms_c_info *wlc, | ||
318 | struct brcm_rateset *currs); | 315 | struct brcm_rateset *currs); |
319 | extern int brcms_c_set_rateset(struct brcms_c_info *wlc, | 316 | int brcms_c_set_rateset(struct brcms_c_info *wlc, struct brcm_rateset *rs); |
320 | struct brcm_rateset *rs); | 317 | int brcms_c_set_beacon_period(struct brcms_c_info *wlc, u16 period); |
321 | extern int brcms_c_set_beacon_period(struct brcms_c_info *wlc, u16 period); | 318 | u16 brcms_c_get_phy_type(struct brcms_c_info *wlc, int phyidx); |
322 | extern u16 brcms_c_get_phy_type(struct brcms_c_info *wlc, int phyidx); | 319 | void brcms_c_set_shortslot_override(struct brcms_c_info *wlc, |
323 | extern void brcms_c_set_shortslot_override(struct brcms_c_info *wlc, | ||
324 | s8 sslot_override); | 320 | s8 sslot_override); |
325 | extern void brcms_c_set_beacon_listen_interval(struct brcms_c_info *wlc, | 321 | void brcms_c_set_beacon_listen_interval(struct brcms_c_info *wlc, u8 interval); |
326 | u8 interval); | 322 | u64 brcms_c_tsf_get(struct brcms_c_info *wlc); |
327 | extern u64 brcms_c_tsf_get(struct brcms_c_info *wlc); | 323 | void brcms_c_tsf_set(struct brcms_c_info *wlc, u64 tsf); |
328 | extern void brcms_c_tsf_set(struct brcms_c_info *wlc, u64 tsf); | 324 | int brcms_c_set_tx_power(struct brcms_c_info *wlc, int txpwr); |
329 | extern int brcms_c_set_tx_power(struct brcms_c_info *wlc, int txpwr); | 325 | int brcms_c_get_tx_power(struct brcms_c_info *wlc); |
330 | extern int brcms_c_get_tx_power(struct brcms_c_info *wlc); | 326 | bool brcms_c_check_radio_disabled(struct brcms_c_info *wlc); |
331 | extern bool brcms_c_check_radio_disabled(struct brcms_c_info *wlc); | 327 | void brcms_c_mute(struct brcms_c_info *wlc, bool on); |
332 | extern void brcms_c_mute(struct brcms_c_info *wlc, bool on); | 328 | bool brcms_c_tx_flush_completed(struct brcms_c_info *wlc); |
333 | extern bool brcms_c_tx_flush_completed(struct brcms_c_info *wlc); | 329 | void brcms_c_start_station(struct brcms_c_info *wlc, u8 *addr); |
334 | extern void brcms_c_start_station(struct brcms_c_info *wlc, u8 *addr); | 330 | void brcms_c_start_ap(struct brcms_c_info *wlc, u8 *addr, const u8 *bssid, |
335 | extern void brcms_c_start_ap(struct brcms_c_info *wlc, u8 *addr, | 331 | u8 *ssid, size_t ssid_len); |
336 | const u8 *bssid, u8 *ssid, size_t ssid_len); | 332 | void brcms_c_start_adhoc(struct brcms_c_info *wlc, u8 *addr); |
337 | extern void brcms_c_start_adhoc(struct brcms_c_info *wlc, u8 *addr); | 333 | void brcms_c_update_beacon(struct brcms_c_info *wlc); |
338 | extern void brcms_c_update_beacon(struct brcms_c_info *wlc); | 334 | void brcms_c_set_new_beacon(struct brcms_c_info *wlc, struct sk_buff *beacon, |
339 | extern void brcms_c_set_new_beacon(struct brcms_c_info *wlc, | 335 | u16 tim_offset, u16 dtim_period); |
340 | struct sk_buff *beacon, u16 tim_offset, | 336 | void brcms_c_set_new_probe_resp(struct brcms_c_info *wlc, |
341 | u16 dtim_period); | 337 | struct sk_buff *probe_resp); |
342 | extern void brcms_c_set_new_probe_resp(struct brcms_c_info *wlc, | 338 | void brcms_c_enable_probe_resp(struct brcms_c_info *wlc, bool enable); |
343 | struct sk_buff *probe_resp); | 339 | void brcms_c_set_ssid(struct brcms_c_info *wlc, u8 *ssid, size_t ssid_len); |
344 | extern void brcms_c_enable_probe_resp(struct brcms_c_info *wlc, bool enable); | ||
345 | extern void brcms_c_set_ssid(struct brcms_c_info *wlc, u8 *ssid, | ||
346 | size_t ssid_len); | ||
347 | 340 | ||
348 | #endif /* _BRCM_PUB_H_ */ | 341 | #endif /* _BRCM_PUB_H_ */ |
diff --git a/drivers/net/wireless/brcm80211/brcmsmac/rate.h b/drivers/net/wireless/brcm80211/brcmsmac/rate.h index 980d578825cc..5bb88b78ed64 100644 --- a/drivers/net/wireless/brcm80211/brcmsmac/rate.h +++ b/drivers/net/wireless/brcm80211/brcmsmac/rate.h | |||
@@ -216,34 +216,30 @@ static inline u8 cck_phy2mac_rate(u8 signal) | |||
216 | 216 | ||
217 | /* sanitize, and sort a rateset with the basic bit(s) preserved, validate | 217 | /* sanitize, and sort a rateset with the basic bit(s) preserved, validate |
218 | * rateset */ | 218 | * rateset */ |
219 | extern bool | 219 | bool brcms_c_rate_hwrs_filter_sort_validate(struct brcms_c_rateset *rs, |
220 | brcms_c_rate_hwrs_filter_sort_validate(struct brcms_c_rateset *rs, | 220 | const struct brcms_c_rateset *hw_rs, |
221 | const struct brcms_c_rateset *hw_rs, | 221 | bool check_brate, u8 txstreams); |
222 | bool check_brate, u8 txstreams); | ||
223 | /* copy rateset src to dst as-is (no masking or sorting) */ | 222 | /* copy rateset src to dst as-is (no masking or sorting) */ |
224 | extern void brcms_c_rateset_copy(const struct brcms_c_rateset *src, | 223 | void brcms_c_rateset_copy(const struct brcms_c_rateset *src, |
225 | struct brcms_c_rateset *dst); | 224 | struct brcms_c_rateset *dst); |
226 | 225 | ||
227 | /* would be nice to have these documented ... */ | 226 | /* would be nice to have these documented ... */ |
228 | extern u32 brcms_c_compute_rspec(struct d11rxhdr *rxh, u8 *plcp); | 227 | u32 brcms_c_compute_rspec(struct d11rxhdr *rxh, u8 *plcp); |
229 | 228 | ||
230 | extern void brcms_c_rateset_filter(struct brcms_c_rateset *src, | 229 | void brcms_c_rateset_filter(struct brcms_c_rateset *src, |
231 | struct brcms_c_rateset *dst, bool basic_only, u8 rates, uint xmask, | 230 | struct brcms_c_rateset *dst, bool basic_only, |
232 | bool mcsallow); | 231 | u8 rates, uint xmask, bool mcsallow); |
233 | 232 | ||
234 | extern void | 233 | void brcms_c_rateset_default(struct brcms_c_rateset *rs_tgt, |
235 | brcms_c_rateset_default(struct brcms_c_rateset *rs_tgt, | 234 | const struct brcms_c_rateset *rs_hw, uint phy_type, |
236 | const struct brcms_c_rateset *rs_hw, uint phy_type, | 235 | int bandtype, bool cck_only, uint rate_mask, |
237 | int bandtype, bool cck_only, uint rate_mask, | 236 | bool mcsallow, u8 bw, u8 txstreams); |
238 | bool mcsallow, u8 bw, u8 txstreams); | 237 | |
239 | 238 | s16 brcms_c_rate_legacy_phyctl(uint rate); | |
240 | extern s16 brcms_c_rate_legacy_phyctl(uint rate); | 239 | |
241 | 240 | void brcms_c_rateset_mcs_upd(struct brcms_c_rateset *rs, u8 txstreams); | |
242 | extern void brcms_c_rateset_mcs_upd(struct brcms_c_rateset *rs, u8 txstreams); | 241 | void brcms_c_rateset_mcs_clear(struct brcms_c_rateset *rateset); |
243 | extern void brcms_c_rateset_mcs_clear(struct brcms_c_rateset *rateset); | 242 | void brcms_c_rateset_mcs_build(struct brcms_c_rateset *rateset, u8 txstreams); |
244 | extern void brcms_c_rateset_mcs_build(struct brcms_c_rateset *rateset, | 243 | void brcms_c_rateset_bw_mcs_filter(struct brcms_c_rateset *rateset, u8 bw); |
245 | u8 txstreams); | ||
246 | extern void brcms_c_rateset_bw_mcs_filter(struct brcms_c_rateset *rateset, | ||
247 | u8 bw); | ||
248 | 244 | ||
249 | #endif /* _BRCM_RATE_H_ */ | 245 | #endif /* _BRCM_RATE_H_ */ |
diff --git a/drivers/net/wireless/brcm80211/brcmsmac/stf.h b/drivers/net/wireless/brcm80211/brcmsmac/stf.h index 19f6580f69be..ba9493009a33 100644 --- a/drivers/net/wireless/brcm80211/brcmsmac/stf.h +++ b/drivers/net/wireless/brcm80211/brcmsmac/stf.h | |||
@@ -19,24 +19,19 @@ | |||
19 | 19 | ||
20 | #include "types.h" | 20 | #include "types.h" |
21 | 21 | ||
22 | extern int brcms_c_stf_attach(struct brcms_c_info *wlc); | 22 | int brcms_c_stf_attach(struct brcms_c_info *wlc); |
23 | extern void brcms_c_stf_detach(struct brcms_c_info *wlc); | 23 | void brcms_c_stf_detach(struct brcms_c_info *wlc); |
24 | 24 | ||
25 | extern void brcms_c_tempsense_upd(struct brcms_c_info *wlc); | 25 | void brcms_c_tempsense_upd(struct brcms_c_info *wlc); |
26 | extern void brcms_c_stf_ss_algo_channel_get(struct brcms_c_info *wlc, | 26 | void brcms_c_stf_ss_algo_channel_get(struct brcms_c_info *wlc, |
27 | u16 *ss_algo_channel, | 27 | u16 *ss_algo_channel, u16 chanspec); |
28 | u16 chanspec); | 28 | int brcms_c_stf_ss_update(struct brcms_c_info *wlc, struct brcms_band *band); |
29 | extern int brcms_c_stf_ss_update(struct brcms_c_info *wlc, | 29 | void brcms_c_stf_phy_txant_upd(struct brcms_c_info *wlc); |
30 | struct brcms_band *band); | 30 | int brcms_c_stf_txchain_set(struct brcms_c_info *wlc, s32 int_val, bool force); |
31 | extern void brcms_c_stf_phy_txant_upd(struct brcms_c_info *wlc); | 31 | bool brcms_c_stf_stbc_rx_set(struct brcms_c_info *wlc, s32 int_val); |
32 | extern int brcms_c_stf_txchain_set(struct brcms_c_info *wlc, s32 int_val, | 32 | void brcms_c_stf_phy_txant_upd(struct brcms_c_info *wlc); |
33 | bool force); | 33 | void brcms_c_stf_phy_chain_calc(struct brcms_c_info *wlc); |
34 | extern bool brcms_c_stf_stbc_rx_set(struct brcms_c_info *wlc, s32 int_val); | 34 | u16 brcms_c_stf_phytxchain_sel(struct brcms_c_info *wlc, u32 rspec); |
35 | extern void brcms_c_stf_phy_txant_upd(struct brcms_c_info *wlc); | 35 | u16 brcms_c_stf_d11hdrs_phyctl_txant(struct brcms_c_info *wlc, u32 rspec); |
36 | extern void brcms_c_stf_phy_chain_calc(struct brcms_c_info *wlc); | ||
37 | extern u16 brcms_c_stf_phytxchain_sel(struct brcms_c_info *wlc, | ||
38 | u32 rspec); | ||
39 | extern u16 brcms_c_stf_d11hdrs_phyctl_txant(struct brcms_c_info *wlc, | ||
40 | u32 rspec); | ||
41 | 36 | ||
42 | #endif /* _BRCM_STF_H_ */ | 37 | #endif /* _BRCM_STF_H_ */ |
diff --git a/drivers/net/wireless/brcm80211/brcmsmac/ucode_loader.h b/drivers/net/wireless/brcm80211/brcmsmac/ucode_loader.h index 18750a814b4f..c87dd89bcb78 100644 --- a/drivers/net/wireless/brcm80211/brcmsmac/ucode_loader.h +++ b/drivers/net/wireless/brcm80211/brcmsmac/ucode_loader.h | |||
@@ -43,16 +43,14 @@ struct brcms_ucode { | |||
43 | u32 *bcm43xx_bomminor; | 43 | u32 *bcm43xx_bomminor; |
44 | }; | 44 | }; |
45 | 45 | ||
46 | extern int | 46 | int brcms_ucode_data_init(struct brcms_info *wl, struct brcms_ucode *ucode); |
47 | brcms_ucode_data_init(struct brcms_info *wl, struct brcms_ucode *ucode); | ||
48 | 47 | ||
49 | extern void brcms_ucode_data_free(struct brcms_ucode *ucode); | 48 | void brcms_ucode_data_free(struct brcms_ucode *ucode); |
50 | 49 | ||
51 | extern int brcms_ucode_init_buf(struct brcms_info *wl, void **pbuf, | 50 | int brcms_ucode_init_buf(struct brcms_info *wl, void **pbuf, unsigned int idx); |
52 | unsigned int idx); | 51 | int brcms_ucode_init_uint(struct brcms_info *wl, size_t *n_bytes, |
53 | extern int brcms_ucode_init_uint(struct brcms_info *wl, size_t *n_bytes, | 52 | unsigned int idx); |
54 | unsigned int idx); | 53 | void brcms_ucode_free_buf(void *); |
55 | extern void brcms_ucode_free_buf(void *); | 54 | int brcms_check_firmwares(struct brcms_info *wl); |
56 | extern int brcms_check_firmwares(struct brcms_info *wl); | ||
57 | 55 | ||
58 | #endif /* _BRCM_UCODE_H_ */ | 56 | #endif /* _BRCM_UCODE_H_ */ |