Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 225286
b: refs/heads/master
c: 4fb3324
h: refs/heads/master
v: v3
  • Loading branch information
Wey-Yi Guy committed Dec 13, 2010
1 parent d09d133 commit 41da1fe
Show file tree
Hide file tree
Showing 57 changed files with 24 additions and 23,536 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 1fcfe76a760e78d7774a254608557c84071b0cfb
refs/heads/master: 4fb33244d17b973f17cbc7cf8b7efd0875950474
6 changes: 2 additions & 4 deletions trunk/drivers/bluetooth/hci_ldisc.c
Original file line number Diff line number Diff line change
Expand Up @@ -311,10 +311,8 @@ static void hci_uart_tty_close(struct tty_struct *tty)

if (test_and_clear_bit(HCI_UART_PROTO_SET, &hu->flags)) {
hu->proto->close(hu);
if (hdev) {
hci_unregister_dev(hdev);
hci_free_dev(hdev);
}
hci_unregister_dev(hdev);
hci_free_dev(hdev);
}
}
}
Expand Down
1 change: 0 additions & 1 deletion trunk/drivers/net/wireless/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -279,7 +279,6 @@ source "drivers/net/wireless/libertas/Kconfig"
source "drivers/net/wireless/orinoco/Kconfig"
source "drivers/net/wireless/p54/Kconfig"
source "drivers/net/wireless/rt2x00/Kconfig"
source "drivers/net/wireless/rtlwifi/Kconfig"
source "drivers/net/wireless/wl1251/Kconfig"
source "drivers/net/wireless/wl12xx/Kconfig"
source "drivers/net/wireless/zd1211rw/Kconfig"
Expand Down
1 change: 0 additions & 1 deletion trunk/drivers/net/wireless/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,6 @@ obj-$(CONFIG_B43LEGACY) += b43legacy/
obj-$(CONFIG_ZD1211RW) += zd1211rw/
obj-$(CONFIG_RTL8180) += rtl818x/
obj-$(CONFIG_RTL8187) += rtl818x/
obj-$(CONFIG_RTL8192CE) += rtlwifi/

# 16-bit wireless PCMCIA client drivers
obj-$(CONFIG_PCMCIA_RAYCS) += ray_cs.o
Expand Down
2 changes: 0 additions & 2 deletions trunk/drivers/net/wireless/iwlwifi/iwl-1000.c
Original file line number Diff line number Diff line change
Expand Up @@ -311,7 +311,6 @@ struct iwl_cfg iwl100_bgn_cfg = {
.base_params = &iwl1000_base_params,
.ht_params = &iwl1000_ht_params,
.led_mode = IWL_LED_RF_STATE,
.use_new_eeprom_reading = true,
};

struct iwl_cfg iwl100_bg_cfg = {
Expand All @@ -325,7 +324,6 @@ struct iwl_cfg iwl100_bg_cfg = {
.mod_params = &iwlagn_mod_params,
.base_params = &iwl1000_base_params,
.led_mode = IWL_LED_RF_STATE,
.use_new_eeprom_reading = true,
};

MODULE_FIRMWARE(IWL1000_MODULE_FIRMWARE(IWL1000_UCODE_API_MAX));
Expand Down
38 changes: 13 additions & 25 deletions trunk/drivers/net/wireless/iwlwifi/iwl-6000.c
Original file line number Diff line number Diff line change
Expand Up @@ -511,7 +511,7 @@ static struct iwl_base_params iwl6050_base_params = {
.chain_noise_calib_by_driver = true,
.shadow_reg_enable = true,
};
static struct iwl_base_params iwl6000_coex_base_params = {
static struct iwl_base_params iwl6000_g2_base_params = {
.eeprom_size = OTP_LOW_IMAGE_SIZE,
.num_of_queues = IWLAGN_NUM_QUEUES,
.num_of_ampdu_queues = IWLAGN_NUM_AMPDU_QUEUES,
Expand All @@ -520,7 +520,7 @@ static struct iwl_base_params iwl6000_coex_base_params = {
.use_bsm = false,
.max_ll_items = OTP_MAX_LL_ITEMS_6x00,
.shadow_ram_support = true,
.led_compensation = 51,
.led_compensation = 57,
.chain_noise_num_beacons = IWL_CAL_NUM_BEACONS,
.supports_idle = true,
.adv_thermal_throttle = true,
Expand Down Expand Up @@ -559,12 +559,11 @@ struct iwl_cfg iwl6005_2agn_cfg = {
.eeprom_calib_ver = EEPROM_6000G2_TX_POWER_VERSION,
.ops = &iwl6000_ops,
.mod_params = &iwlagn_mod_params,
.base_params = &iwl6000_base_params,
.base_params = &iwl6000_g2_base_params,
.ht_params = &iwl6000_ht_params,
.need_dc_calib = true,
.need_temp_offset_calib = true,
.led_mode = IWL_LED_RF_STATE,
.use_new_eeprom_reading = true,
};

struct iwl_cfg iwl6005_2abg_cfg = {
Expand All @@ -576,11 +575,10 @@ struct iwl_cfg iwl6005_2abg_cfg = {
.eeprom_calib_ver = EEPROM_6000G2_TX_POWER_VERSION,
.ops = &iwl6000_ops,
.mod_params = &iwlagn_mod_params,
.base_params = &iwl6000_base_params,
.base_params = &iwl6000_g2_base_params,
.need_dc_calib = true,
.need_temp_offset_calib = true,
.led_mode = IWL_LED_RF_STATE,
.use_new_eeprom_reading = true,
};

struct iwl_cfg iwl6005_2bg_cfg = {
Expand All @@ -592,11 +590,10 @@ struct iwl_cfg iwl6005_2bg_cfg = {
.eeprom_calib_ver = EEPROM_6000G2_TX_POWER_VERSION,
.ops = &iwl6000_ops,
.mod_params = &iwlagn_mod_params,
.base_params = &iwl6000_base_params,
.base_params = &iwl6000_g2_base_params,
.need_dc_calib = true,
.need_temp_offset_calib = true,
.led_mode = IWL_LED_RF_STATE,
.use_new_eeprom_reading = true,
};

struct iwl_cfg iwl6030_2agn_cfg = {
Expand All @@ -608,7 +605,7 @@ struct iwl_cfg iwl6030_2agn_cfg = {
.eeprom_calib_ver = EEPROM_6000G2_TX_POWER_VERSION,
.ops = &iwl6000g2b_ops,
.mod_params = &iwlagn_mod_params,
.base_params = &iwl6000_coex_base_params,
.base_params = &iwl6000_g2_base_params,
.bt_params = &iwl6000_bt_params,
.ht_params = &iwl6000_ht_params,
.need_dc_calib = true,
Expand All @@ -617,7 +614,6 @@ struct iwl_cfg iwl6030_2agn_cfg = {
.adv_pm = true,
/* Due to bluetooth, we transmit 2.4 GHz probes only on antenna A */
.scan_tx_antennas[IEEE80211_BAND_2GHZ] = ANT_A,
.use_new_eeprom_reading = true,
};

struct iwl_cfg iwl6030_2abg_cfg = {
Expand All @@ -629,15 +625,14 @@ struct iwl_cfg iwl6030_2abg_cfg = {
.eeprom_calib_ver = EEPROM_6000G2_TX_POWER_VERSION,
.ops = &iwl6000g2b_ops,
.mod_params = &iwlagn_mod_params,
.base_params = &iwl6000_coex_base_params,
.base_params = &iwl6000_g2_base_params,
.bt_params = &iwl6000_bt_params,
.need_dc_calib = true,
.need_temp_offset_calib = true,
.led_mode = IWL_LED_RF_STATE,
.adv_pm = true,
/* Due to bluetooth, we transmit 2.4 GHz probes only on antenna A */
.scan_tx_antennas[IEEE80211_BAND_2GHZ] = ANT_A,
.use_new_eeprom_reading = true,
};

struct iwl_cfg iwl6030_2bgn_cfg = {
Expand All @@ -649,7 +644,7 @@ struct iwl_cfg iwl6030_2bgn_cfg = {
.eeprom_calib_ver = EEPROM_6000G2_TX_POWER_VERSION,
.ops = &iwl6000g2b_ops,
.mod_params = &iwlagn_mod_params,
.base_params = &iwl6000_coex_base_params,
.base_params = &iwl6000_g2_base_params,
.bt_params = &iwl6000_bt_params,
.ht_params = &iwl6000_ht_params,
.need_dc_calib = true,
Expand All @@ -658,7 +653,6 @@ struct iwl_cfg iwl6030_2bgn_cfg = {
.adv_pm = true,
/* Due to bluetooth, we transmit 2.4 GHz probes only on antenna A */
.scan_tx_antennas[IEEE80211_BAND_2GHZ] = ANT_A,
.use_new_eeprom_reading = true,
};

struct iwl_cfg iwl6030_2bg_cfg = {
Expand All @@ -670,15 +664,14 @@ struct iwl_cfg iwl6030_2bg_cfg = {
.eeprom_calib_ver = EEPROM_6000G2_TX_POWER_VERSION,
.ops = &iwl6000g2b_ops,
.mod_params = &iwlagn_mod_params,
.base_params = &iwl6000_coex_base_params,
.base_params = &iwl6000_g2_base_params,
.bt_params = &iwl6000_bt_params,
.need_dc_calib = true,
.need_temp_offset_calib = true,
.led_mode = IWL_LED_RF_STATE,
.adv_pm = true,
/* Due to bluetooth, we transmit 2.4 GHz probes only on antenna A */
.scan_tx_antennas[IEEE80211_BAND_2GHZ] = ANT_A,
.use_new_eeprom_reading = true,
};

struct iwl_cfg iwl1030_bgn_cfg = {
Expand All @@ -690,7 +683,7 @@ struct iwl_cfg iwl1030_bgn_cfg = {
.eeprom_calib_ver = EEPROM_6000G2_TX_POWER_VERSION,
.ops = &iwl6000g2b_ops,
.mod_params = &iwlagn_mod_params,
.base_params = &iwl6000_coex_base_params,
.base_params = &iwl6000_g2_base_params,
.bt_params = &iwl6000_bt_params,
.ht_params = &iwl6000_ht_params,
.need_dc_calib = true,
Expand All @@ -699,7 +692,6 @@ struct iwl_cfg iwl1030_bgn_cfg = {
.adv_pm = true,
/* Due to bluetooth, we transmit 2.4 GHz probes only on antenna A */
.scan_tx_antennas[IEEE80211_BAND_2GHZ] = ANT_A,
.use_new_eeprom_reading = true,
};

struct iwl_cfg iwl1030_bg_cfg = {
Expand All @@ -711,15 +703,14 @@ struct iwl_cfg iwl1030_bg_cfg = {
.eeprom_calib_ver = EEPROM_6000G2_TX_POWER_VERSION,
.ops = &iwl6000g2b_ops,
.mod_params = &iwlagn_mod_params,
.base_params = &iwl6000_coex_base_params,
.base_params = &iwl6000_g2_base_params,
.bt_params = &iwl6000_bt_params,
.need_dc_calib = true,
.need_temp_offset_calib = true,
.led_mode = IWL_LED_RF_STATE,
.adv_pm = true,
/* Due to bluetooth, we transmit 2.4 GHz probes only on antenna A */
.scan_tx_antennas[IEEE80211_BAND_2GHZ] = ANT_A,
.use_new_eeprom_reading = true,
};

/*
Expand Down Expand Up @@ -802,7 +793,6 @@ struct iwl_cfg iwl6150_bgn_cfg = {
.ht_params = &iwl6000_ht_params,
.need_dc_calib = true,
.led_mode = IWL_LED_RF_STATE,
.use_new_eeprom_reading = true,
};

struct iwl_cfg iwl6050_2abg_cfg = {
Expand Down Expand Up @@ -843,15 +833,14 @@ struct iwl_cfg iwl130_bgn_cfg = {
.eeprom_calib_ver = EEPROM_6000G2_TX_POWER_VERSION,
.ops = &iwl6000g2b_ops,
.mod_params = &iwlagn_mod_params,
.base_params = &iwl6000_coex_base_params,
.base_params = &iwl6000_g2_base_params,
.bt_params = &iwl6000_bt_params,
.ht_params = &iwl6000_ht_params,
.need_dc_calib = true,
.led_mode = IWL_LED_RF_STATE,
.adv_pm = true,
/* Due to bluetooth, we transmit 2.4 GHz probes only on antenna A */
.scan_tx_antennas[IEEE80211_BAND_2GHZ] = ANT_A,
.use_new_eeprom_reading = true,
};

struct iwl_cfg iwl130_bg_cfg = {
Expand All @@ -863,14 +852,13 @@ struct iwl_cfg iwl130_bg_cfg = {
.eeprom_calib_ver = EEPROM_6000G2_TX_POWER_VERSION,
.ops = &iwl6000g2b_ops,
.mod_params = &iwlagn_mod_params,
.base_params = &iwl6000_coex_base_params,
.base_params = &iwl6000_g2_base_params,
.bt_params = &iwl6000_bt_params,
.need_dc_calib = true,
.led_mode = IWL_LED_RF_STATE,
.adv_pm = true,
/* Due to bluetooth, we transmit 2.4 GHz probes only on antenna A */
.scan_tx_antennas[IEEE80211_BAND_2GHZ] = ANT_A,
.use_new_eeprom_reading = true,
};

MODULE_FIRMWARE(IWL6000_MODULE_FIRMWARE(IWL6000_UCODE_API_MAX));
Expand Down
88 changes: 2 additions & 86 deletions trunk/drivers/net/wireless/iwlwifi/iwl-agn-eeprom.c
Original file line number Diff line number Diff line change
Expand Up @@ -433,7 +433,7 @@ static s8 iwl_update_channel_txpower(struct iwl_priv *priv,
/**
* iwlcore_eeprom_enhanced_txpower: process enhanced tx power info
*/
static void iwlcore_eeprom_enhanced_txpower_old(struct iwl_priv *priv)
void iwlcore_eeprom_enhanced_txpower(struct iwl_priv *priv)
{
int eeprom_section_count = 0;
int section, element;
Expand All @@ -460,8 +460,7 @@ static void iwlcore_eeprom_enhanced_txpower_old(struct iwl_priv *priv)
* always check for valid entry before process
* the information
*/
if (!(enhanced_txpower->flags || enhanced_txpower->channel) ||
enhanced_txpower->delta_20_in_40)
if (!enhanced_txpower->common || enhanced_txpower->reserved)
continue;

for (element = 0; element < eeprom_section_count; element++) {
Expand Down Expand Up @@ -494,86 +493,3 @@ static void iwlcore_eeprom_enhanced_txpower_old(struct iwl_priv *priv)
}
}
}

static void
iwlcore_eeprom_enh_txp_read_element(struct iwl_priv *priv,
struct iwl_eeprom_enhanced_txpwr *txp,
s8 max_txpower_avg)
{
int ch_idx;
bool is_ht40 = txp->flags & IWL_EEPROM_ENH_TXP_FL_40MHZ;
enum ieee80211_band band;

band = txp->flags & IWL_EEPROM_ENH_TXP_FL_BAND_52G ?
IEEE80211_BAND_5GHZ : IEEE80211_BAND_2GHZ;

for (ch_idx = 0; ch_idx < priv->channel_count; ch_idx++) {
struct iwl_channel_info *ch_info = &priv->channel_info[ch_idx];

/* update matching channel or from common data only */
if (txp->channel != 0 && ch_info->channel != txp->channel)
continue;

/* update matching band only */
if (band != ch_info->band)
continue;

if (ch_info->max_power_avg < max_txpower_avg && !is_ht40) {
ch_info->max_power_avg = max_txpower_avg;
ch_info->curr_txpow = max_txpower_avg;
ch_info->scan_power = max_txpower_avg;
}

if (is_ht40 && ch_info->ht40_max_power_avg < max_txpower_avg)
ch_info->ht40_max_power_avg = max_txpower_avg;
}
}

#define EEPROM_TXP_OFFS (0x00 | INDIRECT_ADDRESS | INDIRECT_TXP_LIMIT)
#define EEPROM_TXP_ENTRY_LEN sizeof(struct iwl_eeprom_enhanced_txpwr)
#define EEPROM_TXP_SZ_OFFS (0x00 | INDIRECT_ADDRESS | INDIRECT_TXP_LIMIT_SIZE)

static void iwlcore_eeprom_enhanced_txpower_new(struct iwl_priv *priv)
{
struct iwl_eeprom_enhanced_txpwr *txp_array, *txp;
int idx, entries;
__le16 *txp_len;
s8 max_txp_avg, max_txp_avg_halfdbm;

BUILD_BUG_ON(sizeof(struct iwl_eeprom_enhanced_txpwr) != 8);

/* the length is in 16-bit words, but we want entries */
txp_len = (__le16 *) iwlagn_eeprom_query_addr(priv, EEPROM_TXP_SZ_OFFS);
entries = le16_to_cpup(txp_len) * 2 / EEPROM_TXP_ENTRY_LEN;

txp_array = (void *) iwlagn_eeprom_query_addr(priv, EEPROM_TXP_OFFS);
for (idx = 0; idx < entries; idx++) {
txp = &txp_array[idx];

/* skip invalid entries */
if (!(txp->flags & IWL_EEPROM_ENH_TXP_FL_VALID))
continue;

max_txp_avg = iwl_get_max_txpower_avg(priv, txp_array, idx,
&max_txp_avg_halfdbm);

/*
* Update the user limit values values to the highest
* power supported by any channel
*/
if (max_txp_avg > priv->tx_power_user_lmt)
priv->tx_power_user_lmt = max_txp_avg;
if (max_txp_avg_halfdbm > priv->tx_power_lmt_in_half_dbm)
priv->tx_power_lmt_in_half_dbm = max_txp_avg_halfdbm;

iwlcore_eeprom_enh_txp_read_element(priv, txp, max_txp_avg);
}
}

void iwlcore_eeprom_enhanced_txpower(struct iwl_priv *priv)
{
if (priv->cfg->use_new_eeprom_reading)
iwlcore_eeprom_enhanced_txpower_new(priv);
else
iwlcore_eeprom_enhanced_txpower_old(priv);
}
6 changes: 0 additions & 6 deletions trunk/drivers/net/wireless/iwlwifi/iwl-agn-lib.c
Original file line number Diff line number Diff line change
Expand Up @@ -568,12 +568,6 @@ static u32 eeprom_indirect_address(const struct iwl_priv *priv, u32 address)
case INDIRECT_REGULATORY:
offset = iwl_eeprom_query16(priv, EEPROM_LINK_REGULATORY);
break;
case INDIRECT_TXP_LIMIT:
offset = iwl_eeprom_query16(priv, EEPROM_LINK_TXP_LIMIT);
break;
case INDIRECT_TXP_LIMIT_SIZE:
offset = iwl_eeprom_query16(priv, EEPROM_LINK_TXP_LIMIT_SIZE);
break;
case INDIRECT_CALIBRATION:
offset = iwl_eeprom_query16(priv, EEPROM_LINK_CALIBRATION);
break;
Expand Down
1 change: 0 additions & 1 deletion trunk/drivers/net/wireless/iwlwifi/iwl-core.h
Original file line number Diff line number Diff line change
Expand Up @@ -412,7 +412,6 @@ struct iwl_cfg {
u8 scan_tx_antennas[IEEE80211_NUM_BANDS];
enum iwl_led_mode led_mode;
const bool adv_pm;
const bool use_new_eeprom_reading; /* temporary, remove later */
};

/***************************
Expand Down
Loading

0 comments on commit 41da1fe

Please sign in to comment.