diff options
author | Wey-Yi Guy <wey-yi.w.guy@intel.com> | 2010-08-23 10:57:12 -0400 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2010-08-25 14:34:53 -0400 |
commit | f37837c962c309f1d90636626c779497b614be42 (patch) | |
tree | 6383da8eb1af7811e8fce026d7a4fada39f7c040 /drivers | |
parent | 22bf59a03aacc221483e5aad1af903fc191ae958 (diff) |
iwlagn: add bt_ch_announce module parameter
Add bt_ch_announce module parameter to enable/disable BT channel
announcement mode; default is "enable"
Based on the bt channel announcement module parameter to configure the
bt_config host command.
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/net/wireless/iwlwifi/iwl-6000.c | 6 | ||||
-rw-r--r-- | drivers/net/wireless/iwlwifi/iwl-agn.c | 11 | ||||
-rw-r--r-- | drivers/net/wireless/iwlwifi/iwl-dev.h | 1 |
3 files changed, 16 insertions, 2 deletions
diff --git a/drivers/net/wireless/iwlwifi/iwl-6000.c b/drivers/net/wireless/iwlwifi/iwl-6000.c index e4873cc2a57a..ebf0c7ecef4e 100644 --- a/drivers/net/wireless/iwlwifi/iwl-6000.c +++ b/drivers/net/wireless/iwlwifi/iwl-6000.c | |||
@@ -242,9 +242,11 @@ static void iwl6000g2b_send_bt_config(struct iwl_priv *priv) | |||
242 | if (!bt_coex_active || priv->iw_mode == NL80211_IFTYPE_ADHOC) { | 242 | if (!bt_coex_active || priv->iw_mode == NL80211_IFTYPE_ADHOC) { |
243 | bt_cmd.flags = 0; | 243 | bt_cmd.flags = 0; |
244 | } else { | 244 | } else { |
245 | bt_cmd.flags = IWL6000G2B_BT_FLAG_CHANNEL_INHIBITION | | 245 | bt_cmd.flags = IWL6000G2B_BT_FLAG_COEX_MODE_3W << |
246 | IWL6000G2B_BT_FLAG_COEX_MODE_3W << | ||
247 | IWL6000G2B_BT_FLAG_COEX_MODE_SHIFT; | 246 | IWL6000G2B_BT_FLAG_COEX_MODE_SHIFT; |
247 | if (priv->bt_ch_announce) | ||
248 | bt_cmd.flags |= IWL6000G2B_BT_FLAG_CHANNEL_INHIBITION; | ||
249 | IWL_DEBUG_INFO(priv, "BT coex flag: 0X%x\n", bt_cmd.flags); | ||
248 | } | 250 | } |
249 | 251 | ||
250 | if (priv->bt_full_concurrent) | 252 | if (priv->bt_full_concurrent) |
diff --git a/drivers/net/wireless/iwlwifi/iwl-agn.c b/drivers/net/wireless/iwlwifi/iwl-agn.c index e8098a798240..989e4a702602 100644 --- a/drivers/net/wireless/iwlwifi/iwl-agn.c +++ b/drivers/net/wireless/iwlwifi/iwl-agn.c | |||
@@ -88,6 +88,7 @@ MODULE_LICENSE("GPL"); | |||
88 | MODULE_ALIAS("iwl4965"); | 88 | MODULE_ALIAS("iwl4965"); |
89 | 89 | ||
90 | static int iwlagn_ant_coupling; | 90 | static int iwlagn_ant_coupling; |
91 | static bool iwlagn_bt_ch_announce = 1; | ||
91 | 92 | ||
92 | /** | 93 | /** |
93 | * iwl_commit_rxon - commit staging_rxon to hardware | 94 | * iwl_commit_rxon - commit staging_rxon to hardware |
@@ -2606,6 +2607,9 @@ int iwl_dump_nic_event_log(struct iwl_priv *priv, bool full_log, | |||
2606 | return pos; | 2607 | return pos; |
2607 | } | 2608 | } |
2608 | 2609 | ||
2610 | /* enable/disable bt channel announcement */ | ||
2611 | priv->bt_ch_announce = iwlagn_bt_ch_announce; | ||
2612 | |||
2609 | #ifdef CONFIG_IWLWIFI_DEBUG | 2613 | #ifdef CONFIG_IWLWIFI_DEBUG |
2610 | if (!(iwl_get_debug_level(priv) & IWL_DL_FW_ERRORS) && !full_log) | 2614 | if (!(iwl_get_debug_level(priv) & IWL_DL_FW_ERRORS) && !full_log) |
2611 | size = (size > DEFAULT_DUMP_EVENT_LOG_ENTRIES) | 2615 | size = (size > DEFAULT_DUMP_EVENT_LOG_ENTRIES) |
@@ -4150,6 +4154,9 @@ static int iwl_pci_probe(struct pci_dev *pdev, const struct pci_device_id *ent) | |||
4150 | (iwlagn_ant_coupling > IWL_BT_ANTENNA_COUPLING_THRESHOLD) ? | 4154 | (iwlagn_ant_coupling > IWL_BT_ANTENNA_COUPLING_THRESHOLD) ? |
4151 | true : false; | 4155 | true : false; |
4152 | 4156 | ||
4157 | /* enable/disable bt channel announcement */ | ||
4158 | priv->bt_ch_announce = iwlagn_bt_ch_announce; | ||
4159 | |||
4153 | if (iwl_alloc_traffic_mem(priv)) | 4160 | if (iwl_alloc_traffic_mem(priv)) |
4154 | IWL_ERR(priv, "Not enough memory to generate traffic log\n"); | 4161 | IWL_ERR(priv, "Not enough memory to generate traffic log\n"); |
4155 | 4162 | ||
@@ -4687,3 +4694,7 @@ MODULE_PARM_DESC(ucode_alternative, | |||
4687 | module_param_named(antenna_coupling, iwlagn_ant_coupling, int, S_IRUGO); | 4694 | module_param_named(antenna_coupling, iwlagn_ant_coupling, int, S_IRUGO); |
4688 | MODULE_PARM_DESC(antenna_coupling, | 4695 | MODULE_PARM_DESC(antenna_coupling, |
4689 | "specify antenna coupling in dB (defualt: 0 dB)"); | 4696 | "specify antenna coupling in dB (defualt: 0 dB)"); |
4697 | |||
4698 | module_param_named(bt_ch_announce, iwlagn_bt_ch_announce, bool, S_IRUGO); | ||
4699 | MODULE_PARM_DESC(bt_ch_announce, | ||
4700 | "Enable BT channel announcement mode (default: enable)"); | ||
diff --git a/drivers/net/wireless/iwlwifi/iwl-dev.h b/drivers/net/wireless/iwlwifi/iwl-dev.h index 836fe2762464..1adb68e92e8d 100644 --- a/drivers/net/wireless/iwlwifi/iwl-dev.h +++ b/drivers/net/wireless/iwlwifi/iwl-dev.h | |||
@@ -1368,6 +1368,7 @@ struct iwl_priv { | |||
1368 | 1368 | ||
1369 | /* bt coex */ | 1369 | /* bt coex */ |
1370 | u8 bt_traffic_load, notif_bt_traffic_load; | 1370 | u8 bt_traffic_load, notif_bt_traffic_load; |
1371 | bool bt_ch_announce; | ||
1371 | bool bt_sco_active; | 1372 | bool bt_sco_active; |
1372 | bool bt_full_concurrent; | 1373 | bool bt_full_concurrent; |
1373 | bool bt_ant_couple_ok; | 1374 | bool bt_ant_couple_ok; |