Commit 6794f3ee authored by Johannes Berg's avatar Johannes Berg Committed by John W. Linville

iwlwifi: constify remaining config data

The HW configuration settings base_params, ht_params
and bt_params all should be const, make it so.
Signed-off-by: default avatarJohannes Berg <johannes.berg@intel.com>
Signed-off-by: default avatarWey-Yi Guy <wey-yi.w.guy@intel.com>
Signed-off-by: default avatarJohn W. Linville <linville@tuxdriver.com>
parent b9ad70da
...@@ -157,7 +157,7 @@ static struct iwl_lib_ops iwl1000_lib = { ...@@ -157,7 +157,7 @@ static struct iwl_lib_ops iwl1000_lib = {
.temperature = iwlagn_temperature, .temperature = iwlagn_temperature,
}; };
static struct iwl_base_params iwl1000_base_params = { static const struct iwl_base_params iwl1000_base_params = {
.num_of_queues = IWLAGN_NUM_QUEUES, .num_of_queues = IWLAGN_NUM_QUEUES,
.num_of_ampdu_queues = IWLAGN_NUM_AMPDU_QUEUES, .num_of_ampdu_queues = IWLAGN_NUM_AMPDU_QUEUES,
.eeprom_size = OTP_LOW_IMAGE_SIZE, .eeprom_size = OTP_LOW_IMAGE_SIZE,
...@@ -172,7 +172,8 @@ static struct iwl_base_params iwl1000_base_params = { ...@@ -172,7 +172,8 @@ static struct iwl_base_params iwl1000_base_params = {
.max_event_log_size = 128, .max_event_log_size = 128,
.wd_disable = true, .wd_disable = true,
}; };
static struct iwl_ht_params iwl1000_ht_params = {
static const struct iwl_ht_params iwl1000_ht_params = {
.ht_greenfield_support = true, .ht_greenfield_support = true,
.use_rts_for_aggregation = true, /* use rts/cts protection */ .use_rts_for_aggregation = true, /* use rts/cts protection */
.smps_mode = IEEE80211_SMPS_DYNAMIC, .smps_mode = IEEE80211_SMPS_DYNAMIC,
......
...@@ -175,7 +175,7 @@ static struct iwl_lib_ops iwl2030_lib = { ...@@ -175,7 +175,7 @@ static struct iwl_lib_ops iwl2030_lib = {
.temperature = iwlagn_temperature, .temperature = iwlagn_temperature,
}; };
static struct iwl_base_params iwl2000_base_params = { static const struct iwl_base_params iwl2000_base_params = {
.eeprom_size = OTP_LOW_IMAGE_SIZE, .eeprom_size = OTP_LOW_IMAGE_SIZE,
.num_of_queues = IWLAGN_NUM_QUEUES, .num_of_queues = IWLAGN_NUM_QUEUES,
.num_of_ampdu_queues = IWLAGN_NUM_AMPDU_QUEUES, .num_of_ampdu_queues = IWLAGN_NUM_AMPDU_QUEUES,
...@@ -194,7 +194,7 @@ static struct iwl_base_params iwl2000_base_params = { ...@@ -194,7 +194,7 @@ static struct iwl_base_params iwl2000_base_params = {
}; };
static struct iwl_base_params iwl2030_base_params = { static const struct iwl_base_params iwl2030_base_params = {
.eeprom_size = OTP_LOW_IMAGE_SIZE, .eeprom_size = OTP_LOW_IMAGE_SIZE,
.num_of_queues = IWLAGN_NUM_QUEUES, .num_of_queues = IWLAGN_NUM_QUEUES,
.num_of_ampdu_queues = IWLAGN_NUM_AMPDU_QUEUES, .num_of_ampdu_queues = IWLAGN_NUM_AMPDU_QUEUES,
...@@ -212,12 +212,12 @@ static struct iwl_base_params iwl2030_base_params = { ...@@ -212,12 +212,12 @@ static struct iwl_base_params iwl2030_base_params = {
.hd_v2 = true, .hd_v2 = true,
}; };
static struct iwl_ht_params iwl2000_ht_params = { static const struct iwl_ht_params iwl2000_ht_params = {
.ht_greenfield_support = true, .ht_greenfield_support = true,
.use_rts_for_aggregation = true, /* use rts/cts protection */ .use_rts_for_aggregation = true, /* use rts/cts protection */
}; };
static struct iwl_bt_params iwl2030_bt_params = { static const struct iwl_bt_params iwl2030_bt_params = {
/* Due to bluetooth, we transmit 2.4 GHz probes only on antenna A */ /* Due to bluetooth, we transmit 2.4 GHz probes only on antenna A */
.advanced_bt_coexist = true, .advanced_bt_coexist = true,
.agg_time_limit = BT_AGG_THRESHOLD_DEF, .agg_time_limit = BT_AGG_THRESHOLD_DEF,
......
...@@ -310,7 +310,7 @@ static struct iwl_lib_ops iwl5150_lib = { ...@@ -310,7 +310,7 @@ static struct iwl_lib_ops iwl5150_lib = {
.temperature = iwl5150_temperature, .temperature = iwl5150_temperature,
}; };
static struct iwl_base_params iwl5000_base_params = { static const struct iwl_base_params iwl5000_base_params = {
.eeprom_size = IWLAGN_EEPROM_IMG_SIZE, .eeprom_size = IWLAGN_EEPROM_IMG_SIZE,
.num_of_queues = IWLAGN_NUM_QUEUES, .num_of_queues = IWLAGN_NUM_QUEUES,
.num_of_ampdu_queues = IWLAGN_NUM_AMPDU_QUEUES, .num_of_ampdu_queues = IWLAGN_NUM_AMPDU_QUEUES,
...@@ -323,7 +323,8 @@ static struct iwl_base_params iwl5000_base_params = { ...@@ -323,7 +323,8 @@ static struct iwl_base_params iwl5000_base_params = {
.no_idle_support = true, .no_idle_support = true,
.wd_disable = true, .wd_disable = true,
}; };
static struct iwl_ht_params iwl5000_ht_params = {
static const struct iwl_ht_params iwl5000_ht_params = {
.ht_greenfield_support = true, .ht_greenfield_support = true,
}; };
......
...@@ -271,7 +271,7 @@ static struct iwl_lib_ops iwl6030_lib = { ...@@ -271,7 +271,7 @@ static struct iwl_lib_ops iwl6030_lib = {
.temperature = iwlagn_temperature, .temperature = iwlagn_temperature,
}; };
static struct iwl_base_params iwl6000_base_params = { static const struct iwl_base_params iwl6000_base_params = {
.eeprom_size = OTP_LOW_IMAGE_SIZE, .eeprom_size = OTP_LOW_IMAGE_SIZE,
.num_of_queues = IWLAGN_NUM_QUEUES, .num_of_queues = IWLAGN_NUM_QUEUES,
.num_of_ampdu_queues = IWLAGN_NUM_AMPDU_QUEUES, .num_of_ampdu_queues = IWLAGN_NUM_AMPDU_QUEUES,
...@@ -288,7 +288,7 @@ static struct iwl_base_params iwl6000_base_params = { ...@@ -288,7 +288,7 @@ static struct iwl_base_params iwl6000_base_params = {
.shadow_reg_enable = true, .shadow_reg_enable = true,
}; };
static struct iwl_base_params iwl6050_base_params = { static const struct iwl_base_params iwl6050_base_params = {
.eeprom_size = OTP_LOW_IMAGE_SIZE, .eeprom_size = OTP_LOW_IMAGE_SIZE,
.num_of_queues = IWLAGN_NUM_QUEUES, .num_of_queues = IWLAGN_NUM_QUEUES,
.num_of_ampdu_queues = IWLAGN_NUM_AMPDU_QUEUES, .num_of_ampdu_queues = IWLAGN_NUM_AMPDU_QUEUES,
...@@ -304,7 +304,8 @@ static struct iwl_base_params iwl6050_base_params = { ...@@ -304,7 +304,8 @@ static struct iwl_base_params iwl6050_base_params = {
.max_event_log_size = 1024, .max_event_log_size = 1024,
.shadow_reg_enable = true, .shadow_reg_enable = true,
}; };
static struct iwl_base_params iwl6000_g2_base_params = {
static const struct iwl_base_params iwl6000_g2_base_params = {
.eeprom_size = OTP_LOW_IMAGE_SIZE, .eeprom_size = OTP_LOW_IMAGE_SIZE,
.num_of_queues = IWLAGN_NUM_QUEUES, .num_of_queues = IWLAGN_NUM_QUEUES,
.num_of_ampdu_queues = IWLAGN_NUM_AMPDU_QUEUES, .num_of_ampdu_queues = IWLAGN_NUM_AMPDU_QUEUES,
...@@ -321,12 +322,12 @@ static struct iwl_base_params iwl6000_g2_base_params = { ...@@ -321,12 +322,12 @@ static struct iwl_base_params iwl6000_g2_base_params = {
.shadow_reg_enable = true, .shadow_reg_enable = true,
}; };
static struct iwl_ht_params iwl6000_ht_params = { static const struct iwl_ht_params iwl6000_ht_params = {
.ht_greenfield_support = true, .ht_greenfield_support = true,
.use_rts_for_aggregation = true, /* use rts/cts protection */ .use_rts_for_aggregation = true, /* use rts/cts protection */
}; };
static struct iwl_bt_params iwl6000_bt_params = { static const struct iwl_bt_params iwl6000_bt_params = {
/* Due to bluetooth, we transmit 2.4 GHz probes only on antenna A */ /* Due to bluetooth, we transmit 2.4 GHz probes only on antenna A */
.advanced_bt_coexist = true, .advanced_bt_coexist = true,
.agg_time_limit = BT_AGG_THRESHOLD_DEF, .agg_time_limit = BT_AGG_THRESHOLD_DEF,
......
...@@ -366,10 +366,10 @@ struct iwl_cfg { ...@@ -366,10 +366,10 @@ struct iwl_cfg {
const struct iwl_lib_ops *lib; const struct iwl_lib_ops *lib;
void (*additional_nic_config)(struct iwl_priv *priv); void (*additional_nic_config)(struct iwl_priv *priv);
/* params not likely to change within a device family */ /* params not likely to change within a device family */
struct iwl_base_params *base_params; const struct iwl_base_params *base_params;
/* params likely to change within a device family */ /* params likely to change within a device family */
struct iwl_ht_params *ht_params; const struct iwl_ht_params *ht_params;
struct iwl_bt_params *bt_params; const struct iwl_bt_params *bt_params;
enum iwl_pa_type pa_type; /* if used set to IWL_PA_SYSTEM */ enum iwl_pa_type pa_type; /* if used set to IWL_PA_SYSTEM */
const bool need_temp_offset_calib; /* if used set to true */ const bool need_temp_offset_calib; /* if used set to true */
const bool no_xtal_calib; const bool no_xtal_calib;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment