46#include <sys/sysctl.h>
47#include <sys/kernel.h>
49#include <sys/malloc.h>
52#include <machine/bus.h>
53#include <machine/resource.h>
57#include <sys/socket.h>
60#include <net/if_var.h>
61#include <net/if_media.h>
62#include <net/if_arp.h>
63#include <net/ethernet.h>
65#include <net80211/ieee80211_var.h>
70#include <netinet/in.h>
71#include <netinet/if_ether.h>
99 bzero(&btinfo,
sizeof(btinfo));
100 bzero(&btconfig,
sizeof(btconfig));
102 device_printf(sc->
sc_dev,
"Enabling WB195 BTCOEX\n");
155 bzero(&btinfo,
sizeof(btinfo));
156 bzero(&btconfig,
sizeof(btconfig));
158 device_printf(sc->
sc_dev,
"Enabling WB225 BTCOEX\n");
206 bzero(&btinfo,
sizeof(btinfo));
207 bzero(&btconfig,
sizeof(btconfig));
212 device_printf(sc->
sc_dev,
"Failed to setup btcoex\n");
275 device_printf(sc->
sc_dev,
"Enabling WB222 BTCOEX\n");
300 flags &= ~ATH_MCI_CONFIG_ANT_ARCH;
304 flags &= ~ATH_MCI_CONFIG_ANT_ARCH;
313 device_printf(sc->
sc_dev,
"Enabling WB335 BTCOEX\n");
329ath_btcoex_aspm_wb195(
struct ath_softc *sc)
349 const char *profname;
361 ret = resource_string_value(device_get_name(sc->
sc_dev),
362 device_get_unit(sc->
sc_dev),
370 if (strncmp(profname,
"wb195", 5) == 0) {
372 }
else if (strncmp(profname,
"wb222", 5) == 0) {
374 }
else if (strncmp(profname,
"wb225", 5) == 0) {
376 }
else if (strncmp(profname,
"wb335", 5) == 0) {
435 void *outdata = NULL;
445 indata = malloc(insize, M_TEMP, M_NOWAIT);
446 if (indata == NULL) {
450 error = copyin(ad->
ad_in_data, indata, insize);
462 outdata = malloc(outsize, M_TEMP, M_NOWAIT | M_ZERO);
463 if (outdata == NULL) {
473 if (outsize < ad->ad_out_size)
479 free(indata, M_TEMP);
481 free(outdata, M_TEMP);
#define ATH_MCI_CONFIG_ANT_ARCH_S
#define ATH_MCI_ANT_ARCH_2_ANT_PA_LNA_NON_SHARED
#define ATH_MCI_ANT_ARCH_1_ANT_PA_LNA_SHARED
@ HAL_BT_COEX_MODE_SLOTTED
@ HAL_BT_COEX_ANTENNA_DIVERSITY
int ath_btcoex_detach(struct ath_softc *sc)
static int ath_btcoex_cfg_wb335b(struct ath_softc *sc)
int ath_btcoex_enable(struct ath_softc *sc, const struct ieee80211_channel *chan)
int ath_btcoex_ioctl(struct ath_softc *sc, struct ath_diag *ad)
int ath_btcoex_attach(struct ath_softc *sc)
static int ath_btcoex_cfg_wb225(struct ath_softc *sc)
static int ath_btcoex_cfg_mci(struct ath_softc *sc, uint32_t mci_cfg, int do_btdiv)
static int ath_btcoex_cfg_wb195(struct ath_softc *sc)
static int ath_btcoex_cfg_wb222(struct ath_softc *sc)
int ath_btcoex_mci_enable(struct ath_softc *sc, const struct ieee80211_channel *chan)
int ath_btcoex_mci_detach(struct ath_softc *sc)
int ath_btcoex_mci_attach(struct ath_softc *sc)
#define ATH_PCI_AR9565_1ANT
#define ATH_PCI_BT_ANT_DIV
#define ATH_PCI_AR9565_2ANT
#define ath_hal_btcoex_set_weights(_ah, _weight)
#define ath_hal_btcoex_set_config(_ah, _cfg)
#define ath_hal_btcoex_enable(_ah)
#define ath_hal_btcoex_set_parameter(_ah, _attrib, _val)
#define ath_hal_btcoex_supported(_ah)
#define ath_hal_btcoex_set_info(_ah, _info)
HAL_BOOL bt_rxclear_polarity
u_int8_t bt_priority_time
HAL_BOOL bt_quiet_collision
u_int8_t bt_first_slot_time
HAL_BOOL bt_txframe_extend
HAL_BOOL bt_txstate_extend
u_int8_t bt_gpio_bt_priority
u_int8_t bt_active_polarity
u_int8_t bt_gpio_bt_active
u_int8_t bt_gpio_wlan_active
uint32_t ath_hal_mci_config