Linux Kernel  3.7.1
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Macros | Functions
phy_shim.h File Reference
#include "types.h"

Go to the source code of this file.

Macros

#define RADAR_TYPE_NONE   0 /* Radar type None */
 
#define RADAR_TYPE_ETSI_1   1 /* ETSI 1 Radar type */
 
#define RADAR_TYPE_ETSI_2   2 /* ETSI 2 Radar type */
 
#define RADAR_TYPE_ETSI_3   3 /* ETSI 3 Radar type */
 
#define RADAR_TYPE_ITU_E   4 /* ITU E Radar type */
 
#define RADAR_TYPE_ITU_K   5 /* ITU K Radar type */
 
#define RADAR_TYPE_UNCLASSIFIED   6 /* Unclassified Radar type */
 
#define RADAR_TYPE_BIN5   7 /* long pulse radar type */
 
#define RADAR_TYPE_STG2   8 /* staggered-2 radar */
 
#define RADAR_TYPE_STG3   9 /* staggered-3 radar */
 
#define RADAR_TYPE_FRA   10 /* French radar */
 
#define FRA_T1_20MHZ   52770
 
#define FRA_T2_20MHZ   61538
 
#define FRA_T3_20MHZ   66002
 
#define FRA_T1_40MHZ   105541
 
#define FRA_T2_40MHZ   123077
 
#define FRA_T3_40MHZ   132004
 
#define FRA_ERR_20MHZ   60
 
#define FRA_ERR_40MHZ   120
 
#define ANTSEL_NA   0 /* No boardlevel selection available */
 
#define ANTSEL_2x4   1 /* 2x4 boardlevel selection available */
 
#define ANTSEL_2x3   2 /* 2x3 CB2 boardlevel selection available */
 
#define ANT_RX_DIV_FORCE_0   0 /* Use antenna 0 */
 
#define ANT_RX_DIV_FORCE_1   1 /* Use antenna 1 */
 
#define ANT_RX_DIV_START_1   2 /* Choose starting with 1 */
 
#define ANT_RX_DIV_START_0   3 /* Choose starting with 0 */
 
#define ANT_RX_DIV_ENABLE   3 /* APHY bbConfig Enable RX Diversity */
 
#define ANT_RX_DIV_DEF   ANT_RX_DIV_START_0 /* default antdiv setting */
 
#define WL_ANT_RX_MAX   2 /* max 2 receive antennas */
 
#define WL_ANT_HT_RX_MAX   3 /* max 3 receive antennas/cores */
 
#define WL_ANT_IDX_1   0 /* antenna index 1 */
 
#define WL_ANT_IDX_2   1 /* antenna index 2 */
 
#define BRCMS_N_PREAMBLE_MIXEDMODE   0
 
#define BRCMS_N_PREAMBLE_GF   1
 
#define BRCMS_N_PREAMBLE_GF_BRCM   2
 
#define WL_TX_POWER_RATES_LEGACY   45
 
#define WL_TX_POWER_MCS20_FIRST   12
 
#define WL_TX_POWER_MCS20_NUM   16
 
#define WL_TX_POWER_MCS40_FIRST   28
 
#define WL_TX_POWER_MCS40_NUM   17
 
#define WL_TX_POWER_RATES   101
 
#define WL_TX_POWER_CCK_FIRST   0
 
#define WL_TX_POWER_CCK_NUM   4
 
#define WL_TX_POWER_OFDM_FIRST   4
 
#define WL_TX_POWER_OFDM20_CDD_FIRST   12
 
#define WL_TX_POWER_OFDM40_SISO_FIRST   52
 
#define WL_TX_POWER_OFDM40_CDD_FIRST   60
 
#define WL_TX_POWER_OFDM_NUM   8
 
#define WL_TX_POWER_MCS20_SISO_FIRST   20
 
#define WL_TX_POWER_MCS20_CDD_FIRST   28
 
#define WL_TX_POWER_MCS20_STBC_FIRST   36
 
#define WL_TX_POWER_MCS20_SDM_FIRST   44
 
#define WL_TX_POWER_MCS40_SISO_FIRST   68
 
#define WL_TX_POWER_MCS40_CDD_FIRST   76
 
#define WL_TX_POWER_MCS40_STBC_FIRST   84
 
#define WL_TX_POWER_MCS40_SDM_FIRST   92
 
#define WL_TX_POWER_MCS_1_STREAM_NUM   8
 
#define WL_TX_POWER_MCS_2_STREAM_NUM   8
 
#define WL_TX_POWER_MCS_32   100
 
#define WL_TX_POWER_MCS_32_NUM   1
 
#define WL_TX_POWER_MCS20_SISO_FIRST_SSN   12
 
#define WL_TX_POWER_F_ENABLED   1
 
#define WL_TX_POWER_F_HW   2
 
#define WL_TX_POWER_F_MIMO   4
 
#define WL_TX_POWER_F_SISO   8
 
#define BRCMS_N_TXRX_CHAIN0   0
 
#define BRCMS_N_TXRX_CHAIN1   1
 

Functions

struct phy_shim_infowlc_phy_shim_attach (struct brcms_hardware *wlc_hw, struct brcms_info *wl, struct brcms_c_info *wlc)
 
void wlc_phy_shim_detach (struct phy_shim_info *physhim)
 
struct wlapi_timer * wlapi_init_timer (struct phy_shim_info *physhim, void(*fn)(struct brcms_phy *pi), void *arg, const char *name)
 
void wlapi_free_timer (struct wlapi_timer *t)
 
void wlapi_add_timer (struct wlapi_timer *t, uint ms, int periodic)
 
bool wlapi_del_timer (struct wlapi_timer *t)
 
void wlapi_intrson (struct phy_shim_info *physhim)
 
u32 wlapi_intrsoff (struct phy_shim_info *physhim)
 
void wlapi_intrsrestore (struct phy_shim_info *physhim, u32 macintmask)
 
void wlapi_bmac_write_shm (struct phy_shim_info *physhim, uint offset, u16 v)
 
u16 wlapi_bmac_read_shm (struct phy_shim_info *physhim, uint offset)
 
void wlapi_bmac_mhf (struct phy_shim_info *physhim, u8 idx, u16 mask, u16 val, int bands)
 
void wlapi_bmac_corereset (struct phy_shim_info *physhim, u32 flags)
 
void wlapi_suspend_mac_and_wait (struct phy_shim_info *physhim)
 
void wlapi_switch_macfreq (struct phy_shim_info *physhim, u8 spurmode)
 
void wlapi_enable_mac (struct phy_shim_info *physhim)
 
void wlapi_bmac_mctrl (struct phy_shim_info *physhim, u32 mask, u32 val)
 
void wlapi_bmac_phy_reset (struct phy_shim_info *physhim)
 
void wlapi_bmac_bw_set (struct phy_shim_info *physhim, u16 bw)
 
void wlapi_bmac_phyclk_fgc (struct phy_shim_info *physhim, bool clk)
 
void wlapi_bmac_macphyclk_set (struct phy_shim_info *physhim, bool clk)
 
void wlapi_bmac_core_phypll_ctl (struct phy_shim_info *physhim, bool on)
 
void wlapi_bmac_core_phypll_reset (struct phy_shim_info *physhim)
 
void wlapi_bmac_ucode_wake_override_phyreg_set (struct phy_shim_info *physhim)
 
void wlapi_bmac_ucode_wake_override_phyreg_clear (struct phy_shim_info *physhim)
 
void wlapi_bmac_write_template_ram (struct phy_shim_info *physhim, int o, int len, void *buf)
 
u16 wlapi_bmac_rate_shm_offset (struct phy_shim_info *physhim, u8 rate)
 
void wlapi_ucode_sample_init (struct phy_shim_info *physhim)
 
void wlapi_copyfrom_objmem (struct phy_shim_info *physhim, uint, void *buf, int, u32 sel)
 
void wlapi_copyto_objmem (struct phy_shim_info *physhim, uint, const void *buf, int, u32)
 
void wlapi_high_update_phy_mode (struct phy_shim_info *physhim, u32 phy_mode)
 
u16 wlapi_bmac_get_txant (struct phy_shim_info *physhim)
 

Macro Definition Documentation

#define ANT_RX_DIV_DEF   ANT_RX_DIV_START_0 /* default antdiv setting */

Definition at line 58 of file phy_shim.h.

#define ANT_RX_DIV_ENABLE   3 /* APHY bbConfig Enable RX Diversity */

Definition at line 57 of file phy_shim.h.

#define ANT_RX_DIV_FORCE_0   0 /* Use antenna 0 */

Definition at line 53 of file phy_shim.h.

#define ANT_RX_DIV_FORCE_1   1 /* Use antenna 1 */

Definition at line 54 of file phy_shim.h.

#define ANT_RX_DIV_START_0   3 /* Choose starting with 0 */

Definition at line 56 of file phy_shim.h.

#define ANT_RX_DIV_START_1   2 /* Choose starting with 1 */

Definition at line 55 of file phy_shim.h.

#define ANTSEL_2x3   2 /* 2x3 CB2 boardlevel selection available */

Definition at line 50 of file phy_shim.h.

#define ANTSEL_2x4   1 /* 2x4 boardlevel selection available */

Definition at line 49 of file phy_shim.h.

#define ANTSEL_NA   0 /* No boardlevel selection available */

Definition at line 48 of file phy_shim.h.

#define BRCMS_N_PREAMBLE_GF   1

Definition at line 67 of file phy_shim.h.

#define BRCMS_N_PREAMBLE_GF_BRCM   2

Definition at line 68 of file phy_shim.h.

#define BRCMS_N_PREAMBLE_MIXEDMODE   0

Definition at line 66 of file phy_shim.h.

#define BRCMS_N_TXRX_CHAIN0   0

Definition at line 122 of file phy_shim.h.

#define BRCMS_N_TXRX_CHAIN1   1

Definition at line 123 of file phy_shim.h.

#define FRA_ERR_20MHZ   60

Definition at line 45 of file phy_shim.h.

#define FRA_ERR_40MHZ   120

Definition at line 46 of file phy_shim.h.

#define FRA_T1_20MHZ   52770

Definition at line 39 of file phy_shim.h.

#define FRA_T1_40MHZ   105541

Definition at line 42 of file phy_shim.h.

#define FRA_T2_20MHZ   61538

Definition at line 40 of file phy_shim.h.

#define FRA_T2_40MHZ   123077

Definition at line 43 of file phy_shim.h.

#define FRA_T3_20MHZ   66002

Definition at line 41 of file phy_shim.h.

#define FRA_T3_40MHZ   132004

Definition at line 44 of file phy_shim.h.

#define RADAR_TYPE_BIN5   7 /* long pulse radar type */

Definition at line 33 of file phy_shim.h.

#define RADAR_TYPE_ETSI_1   1 /* ETSI 1 Radar type */

Definition at line 27 of file phy_shim.h.

#define RADAR_TYPE_ETSI_2   2 /* ETSI 2 Radar type */

Definition at line 28 of file phy_shim.h.

#define RADAR_TYPE_ETSI_3   3 /* ETSI 3 Radar type */

Definition at line 29 of file phy_shim.h.

#define RADAR_TYPE_FRA   10 /* French radar */

Definition at line 36 of file phy_shim.h.

#define RADAR_TYPE_ITU_E   4 /* ITU E Radar type */

Definition at line 30 of file phy_shim.h.

#define RADAR_TYPE_ITU_K   5 /* ITU K Radar type */

Definition at line 31 of file phy_shim.h.

#define RADAR_TYPE_NONE   0 /* Radar type None */

Definition at line 26 of file phy_shim.h.

#define RADAR_TYPE_STG2   8 /* staggered-2 radar */

Definition at line 34 of file phy_shim.h.

#define RADAR_TYPE_STG3   9 /* staggered-3 radar */

Definition at line 35 of file phy_shim.h.

#define RADAR_TYPE_UNCLASSIFIED   6 /* Unclassified Radar type */

Definition at line 32 of file phy_shim.h.

#define WL_ANT_HT_RX_MAX   3 /* max 3 receive antennas/cores */

Definition at line 61 of file phy_shim.h.

#define WL_ANT_IDX_1   0 /* antenna index 1 */

Definition at line 62 of file phy_shim.h.

#define WL_ANT_IDX_2   1 /* antenna index 2 */

Definition at line 63 of file phy_shim.h.

#define WL_ANT_RX_MAX   2 /* max 2 receive antennas */

Definition at line 60 of file phy_shim.h.

#define WL_TX_POWER_CCK_FIRST   0

Definition at line 78 of file phy_shim.h.

#define WL_TX_POWER_CCK_NUM   4

Definition at line 79 of file phy_shim.h.

#define WL_TX_POWER_F_ENABLED   1

Definition at line 116 of file phy_shim.h.

#define WL_TX_POWER_F_HW   2

Definition at line 117 of file phy_shim.h.

#define WL_TX_POWER_F_MIMO   4

Definition at line 118 of file phy_shim.h.

#define WL_TX_POWER_F_SISO   8

Definition at line 119 of file phy_shim.h.

#define WL_TX_POWER_MCS20_CDD_FIRST   28

Definition at line 92 of file phy_shim.h.

#define WL_TX_POWER_MCS20_FIRST   12

Definition at line 71 of file phy_shim.h.

#define WL_TX_POWER_MCS20_NUM   16

Definition at line 72 of file phy_shim.h.

#define WL_TX_POWER_MCS20_SDM_FIRST   44

Definition at line 96 of file phy_shim.h.

#define WL_TX_POWER_MCS20_SISO_FIRST   20

Definition at line 90 of file phy_shim.h.

#define WL_TX_POWER_MCS20_SISO_FIRST_SSN   12

Definition at line 113 of file phy_shim.h.

#define WL_TX_POWER_MCS20_STBC_FIRST   36

Definition at line 94 of file phy_shim.h.

#define WL_TX_POWER_MCS40_CDD_FIRST   76

Definition at line 100 of file phy_shim.h.

#define WL_TX_POWER_MCS40_FIRST   28

Definition at line 73 of file phy_shim.h.

#define WL_TX_POWER_MCS40_NUM   17

Definition at line 74 of file phy_shim.h.

#define WL_TX_POWER_MCS40_SDM_FIRST   92

Definition at line 104 of file phy_shim.h.

#define WL_TX_POWER_MCS40_SISO_FIRST   68

Definition at line 98 of file phy_shim.h.

#define WL_TX_POWER_MCS40_STBC_FIRST   84

Definition at line 102 of file phy_shim.h.

#define WL_TX_POWER_MCS_1_STREAM_NUM   8

Definition at line 105 of file phy_shim.h.

#define WL_TX_POWER_MCS_2_STREAM_NUM   8

Definition at line 106 of file phy_shim.h.

#define WL_TX_POWER_MCS_32   100

Definition at line 108 of file phy_shim.h.

#define WL_TX_POWER_MCS_32_NUM   1

Definition at line 109 of file phy_shim.h.

#define WL_TX_POWER_OFDM20_CDD_FIRST   12

Definition at line 83 of file phy_shim.h.

#define WL_TX_POWER_OFDM40_CDD_FIRST   60

Definition at line 87 of file phy_shim.h.

#define WL_TX_POWER_OFDM40_SISO_FIRST   52

Definition at line 85 of file phy_shim.h.

#define WL_TX_POWER_OFDM_FIRST   4

Definition at line 81 of file phy_shim.h.

#define WL_TX_POWER_OFDM_NUM   8

Definition at line 88 of file phy_shim.h.

#define WL_TX_POWER_RATES   101

Definition at line 77 of file phy_shim.h.

#define WL_TX_POWER_RATES_LEGACY   45

Definition at line 70 of file phy_shim.h.

Function Documentation

void wlapi_add_timer ( struct wlapi_timer *  t,
uint  ms,
int  periodic 
)

Definition at line 74 of file phy_shim.c.

void wlapi_bmac_bw_set ( struct phy_shim_info physhim,
u16  bw 
)

Definition at line 146 of file phy_shim.c.

void wlapi_bmac_core_phypll_ctl ( struct phy_shim_info physhim,
bool  on 
)

Definition at line 166 of file phy_shim.c.

void wlapi_bmac_core_phypll_reset ( struct phy_shim_info physhim)

Definition at line 171 of file phy_shim.c.

void wlapi_bmac_corereset ( struct phy_shim_info physhim,
u32  flags 
)

Definition at line 116 of file phy_shim.c.

u16 wlapi_bmac_get_txant ( struct phy_shim_info physhim)

Definition at line 151 of file phy_shim.c.

void wlapi_bmac_macphyclk_set ( struct phy_shim_info physhim,
bool  clk 
)

Definition at line 161 of file phy_shim.c.

void wlapi_bmac_mctrl ( struct phy_shim_info physhim,
u32  mask,
u32  val 
)

Definition at line 136 of file phy_shim.c.

void wlapi_bmac_mhf ( struct phy_shim_info physhim,
u8  idx,
u16  mask,
u16  val,
int  bands 
)

Definition at line 110 of file phy_shim.c.

void wlapi_bmac_phy_reset ( struct phy_shim_info physhim)

Definition at line 141 of file phy_shim.c.

void wlapi_bmac_phyclk_fgc ( struct phy_shim_info physhim,
bool  clk 
)

Definition at line 156 of file phy_shim.c.

u16 wlapi_bmac_rate_shm_offset ( struct phy_shim_info physhim,
u8  rate 
)

Definition at line 195 of file phy_shim.c.

u16 wlapi_bmac_read_shm ( struct phy_shim_info physhim,
uint  offset 
)

Definition at line 104 of file phy_shim.c.

void wlapi_bmac_ucode_wake_override_phyreg_clear ( struct phy_shim_info physhim)

Definition at line 182 of file phy_shim.c.

void wlapi_bmac_ucode_wake_override_phyreg_set ( struct phy_shim_info physhim)

Definition at line 176 of file phy_shim.c.

void wlapi_bmac_write_shm ( struct phy_shim_info physhim,
uint  offset,
u16  v 
)

Definition at line 99 of file phy_shim.c.

void wlapi_bmac_write_template_ram ( struct phy_shim_info physhim,
int  o,
int  len,
void buf 
)

Definition at line 189 of file phy_shim.c.

void wlapi_copyfrom_objmem ( struct phy_shim_info physhim,
uint  ,
void buf,
int  ,
u32  sel 
)

Definition at line 205 of file phy_shim.c.

void wlapi_copyto_objmem ( struct phy_shim_info physhim,
uint  ,
const void buf,
int  ,
u32   
)

Definition at line 212 of file phy_shim.c.

bool wlapi_del_timer ( struct wlapi_timer *  t)

Definition at line 79 of file phy_shim.c.

void wlapi_enable_mac ( struct phy_shim_info physhim)

Definition at line 131 of file phy_shim.c.

void wlapi_free_timer ( struct wlapi_timer *  t)

Definition at line 68 of file phy_shim.c.

void wlapi_high_update_phy_mode ( struct phy_shim_info physhim,
u32  phy_mode 
)
struct wlapi_timer* wlapi_init_timer ( struct phy_shim_info physhim,
void(*)(struct brcms_phy *pi)  fn,
void arg,
const char name 
)
read

Definition at line 59 of file phy_shim.c.

u32 wlapi_intrsoff ( struct phy_shim_info physhim)

Definition at line 89 of file phy_shim.c.

void wlapi_intrson ( struct phy_shim_info physhim)

Definition at line 84 of file phy_shim.c.

void wlapi_intrsrestore ( struct phy_shim_info physhim,
u32  macintmask 
)

Definition at line 94 of file phy_shim.c.

void wlapi_suspend_mac_and_wait ( struct phy_shim_info physhim)

Definition at line 121 of file phy_shim.c.

void wlapi_switch_macfreq ( struct phy_shim_info physhim,
u8  spurmode 
)

Definition at line 126 of file phy_shim.c.

void wlapi_ucode_sample_init ( struct phy_shim_info physhim)

Definition at line 200 of file phy_shim.c.

struct phy_shim_info* wlc_phy_shim_attach ( struct brcms_hardware wlc_hw,
struct brcms_info wl,
struct brcms_c_info wlc 
)
read

Definition at line 38 of file phy_shim.c.

void wlc_phy_shim_detach ( struct phy_shim_info physhim)

Definition at line 54 of file phy_shim.c.