diff options
Diffstat (limited to 'drivers/net/wireless/iwlwifi/iwl-agn.c')
-rw-r--r-- | drivers/net/wireless/iwlwifi/iwl-agn.c | 50 |
1 files changed, 8 insertions, 42 deletions
diff --git a/drivers/net/wireless/iwlwifi/iwl-agn.c b/drivers/net/wireless/iwlwifi/iwl-agn.c index 310bc6aeb99b..00344d64635c 100644 --- a/drivers/net/wireless/iwlwifi/iwl-agn.c +++ b/drivers/net/wireless/iwlwifi/iwl-agn.c | |||
@@ -2174,7 +2174,7 @@ static void iwl_alive_start(struct iwl_priv *priv) | |||
2174 | } | 2174 | } |
2175 | 2175 | ||
2176 | /* Configure Bluetooth device coexistence support */ | 2176 | /* Configure Bluetooth device coexistence support */ |
2177 | iwl_send_bt_config(priv); | 2177 | priv->cfg->ops->hcmd->send_bt_config(priv); |
2178 | 2178 | ||
2179 | iwl_reset_run_time_calib(priv); | 2179 | iwl_reset_run_time_calib(priv); |
2180 | 2180 | ||
@@ -3178,44 +3178,6 @@ static ssize_t store_tx_power(struct device *d, | |||
3178 | 3178 | ||
3179 | static DEVICE_ATTR(tx_power, S_IWUSR | S_IRUGO, show_tx_power, store_tx_power); | 3179 | static DEVICE_ATTR(tx_power, S_IWUSR | S_IRUGO, show_tx_power, store_tx_power); |
3180 | 3180 | ||
3181 | static ssize_t show_statistics(struct device *d, | ||
3182 | struct device_attribute *attr, char *buf) | ||
3183 | { | ||
3184 | struct iwl_priv *priv = dev_get_drvdata(d); | ||
3185 | u32 size = sizeof(struct iwl_notif_statistics); | ||
3186 | u32 len = 0, ofs = 0; | ||
3187 | u8 *data = (u8 *)&priv->statistics; | ||
3188 | int rc = 0; | ||
3189 | |||
3190 | if (!iwl_is_alive(priv)) | ||
3191 | return -EAGAIN; | ||
3192 | |||
3193 | mutex_lock(&priv->mutex); | ||
3194 | rc = iwl_send_statistics_request(priv, CMD_SYNC, false); | ||
3195 | mutex_unlock(&priv->mutex); | ||
3196 | |||
3197 | if (rc) { | ||
3198 | len = sprintf(buf, | ||
3199 | "Error sending statistics request: 0x%08X\n", rc); | ||
3200 | return len; | ||
3201 | } | ||
3202 | |||
3203 | while (size && (PAGE_SIZE - len)) { | ||
3204 | hex_dump_to_buffer(data + ofs, size, 16, 1, buf + len, | ||
3205 | PAGE_SIZE - len, 1); | ||
3206 | len = strlen(buf); | ||
3207 | if (PAGE_SIZE - len) | ||
3208 | buf[len++] = '\n'; | ||
3209 | |||
3210 | ofs += 16; | ||
3211 | size -= min(size, 16U); | ||
3212 | } | ||
3213 | |||
3214 | return len; | ||
3215 | } | ||
3216 | |||
3217 | static DEVICE_ATTR(statistics, S_IRUGO, show_statistics, NULL); | ||
3218 | |||
3219 | static ssize_t show_rts_ht_protection(struct device *d, | 3181 | static ssize_t show_rts_ht_protection(struct device *d, |
3220 | struct device_attribute *attr, char *buf) | 3182 | struct device_attribute *attr, char *buf) |
3221 | { | 3183 | { |
@@ -3401,11 +3363,10 @@ static void iwl_uninit_drv(struct iwl_priv *priv) | |||
3401 | iwl_calib_free_results(priv); | 3363 | iwl_calib_free_results(priv); |
3402 | iwlcore_free_geos(priv); | 3364 | iwlcore_free_geos(priv); |
3403 | iwl_free_channel_map(priv); | 3365 | iwl_free_channel_map(priv); |
3404 | kfree(priv->scan); | 3366 | kfree(priv->scan_cmd); |
3405 | } | 3367 | } |
3406 | 3368 | ||
3407 | static struct attribute *iwl_sysfs_entries[] = { | 3369 | static struct attribute *iwl_sysfs_entries[] = { |
3408 | &dev_attr_statistics.attr, | ||
3409 | &dev_attr_temperature.attr, | 3370 | &dev_attr_temperature.attr, |
3410 | &dev_attr_tx_power.attr, | 3371 | &dev_attr_tx_power.attr, |
3411 | &dev_attr_rts_ht_protection.attr, | 3372 | &dev_attr_rts_ht_protection.attr, |
@@ -3836,7 +3797,12 @@ static DEFINE_PCI_DEVICE_TABLE(iwl_hw_card_ids) = { | |||
3836 | {IWL_PCI_DEVICE(0x4238, 0x1111, iwl6000_3agn_cfg)}, | 3797 | {IWL_PCI_DEVICE(0x4238, 0x1111, iwl6000_3agn_cfg)}, |
3837 | {IWL_PCI_DEVICE(0x4239, 0x1311, iwl6000i_2agn_cfg)}, | 3798 | {IWL_PCI_DEVICE(0x4239, 0x1311, iwl6000i_2agn_cfg)}, |
3838 | {IWL_PCI_DEVICE(0x4239, 0x1316, iwl6000i_2abg_cfg)}, | 3799 | {IWL_PCI_DEVICE(0x4239, 0x1316, iwl6000i_2abg_cfg)}, |
3839 | {IWL_PCI_DEVICE(0x0082, 0x1201, iwl6000i_g2_2agn_cfg)}, | 3800 | |
3801 | /* 6x00 Series Gen2 */ | ||
3802 | {IWL_PCI_DEVICE(0x0082, 0x1201, iwl6000g2_2agn_cfg)}, | ||
3803 | {IWL_PCI_DEVICE(0x0082, 0x1301, iwl6000g2_2agn_cfg)}, | ||
3804 | {IWL_PCI_DEVICE(0x0082, 0x1321, iwl6000g2_2agn_cfg)}, | ||
3805 | {IWL_PCI_DEVICE(0x0085, 0x1311, iwl6000g2_2agn_cfg)}, | ||
3840 | 3806 | ||
3841 | /* 6x50 WiFi/WiMax Series */ | 3807 | /* 6x50 WiFi/WiMax Series */ |
3842 | {IWL_PCI_DEVICE(0x0087, 0x1301, iwl6050_2agn_cfg)}, | 3808 | {IWL_PCI_DEVICE(0x0087, 0x1301, iwl6050_2agn_cfg)}, |