]> bbs.cooldavid.org Git - net-next-2.6.git/commitdiff
iwlwifi: move 3945 clip groups to 3945 data
authorJohannes Berg <johannes.berg@intel.com>
Wed, 17 Feb 2010 10:39:19 +0000 (02:39 -0800)
committerReinette Chatre <reinette.chatre@intel.com>
Wed, 10 Mar 2010 00:05:42 +0000 (16:05 -0800)
Only used on 3945, so it can be in the
3945-specific part of the data.

Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Reinette Chatre <reinette.chatre@intel.com>
drivers/net/wireless/iwlwifi/iwl-3945.c
drivers/net/wireless/iwlwifi/iwl-dev.h

index 9a5a7b100e6bb1ac808adf1f1758f8217b469d4f..ed59e2744ca4360885223bc45da1d2c6bd69af50 100644 (file)
@@ -1607,7 +1607,7 @@ static int iwl3945_hw_reg_set_new_power(struct iwl_priv *priv,
        int power;
 
        /* Get this chnlgrp's rate-to-max/clip-powers table */
-       clip_pwrs = priv->clip39_groups[ch_info->group_index].clip_powers;
+       clip_pwrs = priv->_3945.clip_groups[ch_info->group_index].clip_powers;
 
        /* Get this channel's rate-to-current-power settings table */
        power_info = ch_info->power_info;
@@ -1733,7 +1733,7 @@ static int iwl3945_hw_reg_comp_txpower_temp(struct iwl_priv *priv)
                }
 
                /* Get this chnlgrp's rate-to-max/clip-powers table */
-               clip_pwrs = priv->clip39_groups[ch_info->group_index].clip_powers;
+               clip_pwrs = priv->_3945.clip_groups[ch_info->group_index].clip_powers;
 
                /* set scan tx power, 1Mbit for CCK, 6Mbit for OFDM */
                for (scan_tbl_index = 0;
@@ -2140,7 +2140,7 @@ static void iwl3945_hw_reg_init_channel_groups(struct iwl_priv *priv)
                 *   power peaks, without too much distortion (clipping).
                 */
                /* we'll fill in this array with h/w max power levels */
-               clip_pwrs = (s8 *) priv->clip39_groups[i].clip_powers;
+               clip_pwrs = (s8 *) priv->_3945.clip_groups[i].clip_powers;
 
                /* divide factory saturation power by 2 to find -3dB level */
                satur_pwr = (s8) (group->saturation_power >> 1);
@@ -2224,7 +2224,7 @@ int iwl3945_txpower_set_from_eeprom(struct iwl_priv *priv)
                        iwl3945_hw_reg_get_ch_grp_index(priv, ch_info);
 
                /* Get this chnlgrp's rate->max/clip-powers table */
-               clip_pwrs = priv->clip39_groups[ch_info->group_index].clip_powers;
+               clip_pwrs = priv->_3945.clip_groups[ch_info->group_index].clip_powers;
 
                /* calculate power index *adjustment* value according to
                 *  diff between current temperature and factory temperature */
index ba404b99f4fecfd09f84fa3b84166daa23ce5e86..90d2b6e0df76568ffd46188cd969e960083a6558 100644 (file)
@@ -1092,10 +1092,6 @@ struct iwl_priv {
        struct iwl_channel_info *channel_info;  /* channel info array */
        u8 channel_count;       /* # of channels */
 
-       /* each calibration channel group in the EEPROM has a derived
-        * clip setting for each rate. 3945 only.*/
-       const struct iwl3945_clip_group clip39_groups[5];
-
        /* thermal calibration */
        s32 temperature;        /* degrees Kelvin */
        s32 last_temperature;
@@ -1271,6 +1267,14 @@ struct iwl_priv {
                        /* Rx'd packet timing information */
                        u32 last_beacon_time;
                        u64 last_tsf;
+
+                       /*
+                        * each calibration channel group in the
+                        * EEPROM has a derived clip setting for
+                        * each rate.
+                        */
+                       const struct iwl3945_clip_group clip_groups[5];
+
                } _3945;
 #endif
 #if defined(CONFIG_IWLAGN) || defined(CONFIG_IWLAGN_MODULE)