iwlwifi: set correct 32 bit boost register value
authorWey-Yi Guy <wey-yi.w.guy@intel.com>
Sat, 23 Jun 2012 16:06:19 +0000 (09:06 -0700)
committerJohannes Berg <johannes.berg@intel.com>
Mon, 9 Jul 2012 12:55:30 +0000 (14:55 +0200)
Newer devices use 32 bit for boost register,
set the correct value for it.

Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Reviewed-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
drivers/net/wireless/iwlwifi/dvm/commands.h
drivers/net/wireless/iwlwifi/dvm/lib.c
drivers/net/wireless/iwlwifi/iwl-config.h
drivers/net/wireless/iwlwifi/pcie/2000.c

index 97bea16..4a361c5 100644 (file)
@@ -1905,6 +1905,7 @@ struct iwl_bt_cmd {
 #define IWLAGN_BT_PRIO_BOOST_MAX       0xFF
 #define IWLAGN_BT_PRIO_BOOST_MIN       0x00
 #define IWLAGN_BT_PRIO_BOOST_DEFAULT   0xF0
+#define IWLAGN_BT_PRIO_BOOST_DEFAULT32 0xF0F0F0F0
 
 #define IWLAGN_BT_MAX_KILL_DEFAULT     5
 
index 207ae91..bef88c1 100644 (file)
@@ -265,6 +265,8 @@ void iwlagn_send_advance_bt_config(struct iwl_priv *priv)
                        bt_cmd_v2.tx_prio_boost = 0;
                        bt_cmd_v2.rx_prio_boost = 0;
                } else {
+                       /* older version only has 8 bits */
+                       WARN_ON(priv->cfg->bt_params->bt_prio_boost & ~0xFF);
                        bt_cmd_v1.prio_boost =
                                priv->cfg->bt_params->bt_prio_boost;
                        bt_cmd_v1.tx_prio_boost = 0;
index 10e4793..87f465a 100644 (file)
@@ -177,7 +177,7 @@ struct iwl_base_params {
 struct iwl_bt_params {
        bool advanced_bt_coexist;
        u8 bt_init_traffic_load;
-       u8 bt_prio_boost;
+       u32 bt_prio_boost;
        u16 agg_time_limit;
        bool bt_sco_disable;
        bool bt_session_2;
index fd4e78f..9fbde32 100644 (file)
@@ -112,7 +112,7 @@ static const struct iwl_bt_params iwl2030_bt_params = {
        .advanced_bt_coexist = true,
        .agg_time_limit = BT_AGG_THRESHOLD_DEF,
        .bt_init_traffic_load = IWL_BT_COEX_TRAFFIC_LOAD_NONE,
-       .bt_prio_boost = IWLAGN_BT_PRIO_BOOST_DEFAULT,
+       .bt_prio_boost = IWLAGN_BT_PRIO_BOOST_DEFAULT32,
        .bt_sco_disable = true,
        .bt_session_2 = true,
 };