diff options
author | Reinette Chatre <reinette.chatre@intel.com> | 2010-01-22 17:22:57 -0500 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2010-01-25 16:36:26 -0500 |
commit | 81963d68575d497d626ce13e42c84518a931cc12 (patch) | |
tree | c6f10d4fcdbc786f461315cf7d7b293ad2683cc6 /drivers/net/wireless/iwlwifi/iwl3945-base.c | |
parent | 65baa90d92097ce9b7c080697e6b370d335c2efc (diff) |
iwlwifi: cleanup spectrum measurement command support
In iwlagn the support for spectrum measurement command has been
disabled since v2.6.29 without any requests for it. In addition to this
when this command is indeed enabled it has been found to trigger firmware
SYSASSERT on at least 4965 and 5100 hardware (see
http://bugzilla.intellinuxwireless.org/show_bug.cgi?id=1952 ). Since then
this code has been bitrotting and cannot just be enabled without porting.
Remove support for spectrum measurement command from iwlagn. It can be
added back if there is a future need and the firmware problem it triggers
has been fixed. Support for the spectrim measurement notification remains
as it has been enabled all the time.
In addition to this remove the 3945 spectrum measurement command Kconfig
option and make this command always supported. The code added by this
enabling is minimal and only run when user triggers a spectrum measurement
request via sysfs.
Signed-off-by: Reinette Chatre <reinette.chatre@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless/iwlwifi/iwl3945-base.c')
-rw-r--r-- | drivers/net/wireless/iwlwifi/iwl3945-base.c | 27 |
1 files changed, 9 insertions, 18 deletions
diff --git a/drivers/net/wireless/iwlwifi/iwl3945-base.c b/drivers/net/wireless/iwlwifi/iwl3945-base.c index 9c0b6ebbdc59..cd42b5838b38 100644 --- a/drivers/net/wireless/iwlwifi/iwl3945-base.c +++ b/drivers/net/wireless/iwlwifi/iwl3945-base.c | |||
@@ -56,6 +56,7 @@ | |||
56 | #include "iwl-helpers.h" | 56 | #include "iwl-helpers.h" |
57 | #include "iwl-core.h" | 57 | #include "iwl-core.h" |
58 | #include "iwl-dev.h" | 58 | #include "iwl-dev.h" |
59 | #include "iwl-spectrum.h" | ||
59 | 60 | ||
60 | /* | 61 | /* |
61 | * module name, copyright, version, etc. | 62 | * module name, copyright, version, etc. |
@@ -70,13 +71,12 @@ | |||
70 | #define VD | 71 | #define VD |
71 | #endif | 72 | #endif |
72 | 73 | ||
73 | #ifdef CONFIG_IWL3945_SPECTRUM_MEASUREMENT | 74 | /* |
74 | #define VS "s" | 75 | * add "s" to indicate spectrum measurement included. |
75 | #else | 76 | * we add it here to be consistent with previous releases in which |
76 | #define VS | 77 | * this was configurable. |
77 | #endif | 78 | */ |
78 | 79 | #define DRV_VERSION IWLWIFI_VERSION VD "s" | |
79 | #define DRV_VERSION IWLWIFI_VERSION VD VS | ||
80 | #define DRV_COPYRIGHT "Copyright(c) 2003-2010 Intel Corporation" | 80 | #define DRV_COPYRIGHT "Copyright(c) 2003-2010 Intel Corporation" |
81 | #define DRV_AUTHOR "<ilw@linux.intel.com>" | 81 | #define DRV_AUTHOR "<ilw@linux.intel.com>" |
82 | 82 | ||
@@ -689,10 +689,6 @@ drop: | |||
689 | return -1; | 689 | return -1; |
690 | } | 690 | } |
691 | 691 | ||
692 | #ifdef CONFIG_IWL3945_SPECTRUM_MEASUREMENT | ||
693 | |||
694 | #include "iwl-spectrum.h" | ||
695 | |||
696 | #define BEACON_TIME_MASK_LOW 0x00FFFFFF | 692 | #define BEACON_TIME_MASK_LOW 0x00FFFFFF |
697 | #define BEACON_TIME_MASK_HIGH 0xFF000000 | 693 | #define BEACON_TIME_MASK_HIGH 0xFF000000 |
698 | #define TIME_UNIT 1024 | 694 | #define TIME_UNIT 1024 |
@@ -819,7 +815,6 @@ static int iwl3945_get_measurement(struct iwl_priv *priv, | |||
819 | 815 | ||
820 | return rc; | 816 | return rc; |
821 | } | 817 | } |
822 | #endif | ||
823 | 818 | ||
824 | static void iwl3945_rx_reply_alive(struct iwl_priv *priv, | 819 | static void iwl3945_rx_reply_alive(struct iwl_priv *priv, |
825 | struct iwl_rx_mem_buffer *rxb) | 820 | struct iwl_rx_mem_buffer *rxb) |
@@ -962,6 +957,8 @@ static void iwl3945_setup_rx_handlers(struct iwl_priv *priv) | |||
962 | priv->rx_handlers[REPLY_ADD_STA] = iwl3945_rx_reply_add_sta; | 957 | priv->rx_handlers[REPLY_ADD_STA] = iwl3945_rx_reply_add_sta; |
963 | priv->rx_handlers[REPLY_ERROR] = iwl_rx_reply_error; | 958 | priv->rx_handlers[REPLY_ERROR] = iwl_rx_reply_error; |
964 | priv->rx_handlers[CHANNEL_SWITCH_NOTIFICATION] = iwl_rx_csa; | 959 | priv->rx_handlers[CHANNEL_SWITCH_NOTIFICATION] = iwl_rx_csa; |
960 | priv->rx_handlers[SPECTRUM_MEASURE_NOTIFICATION] = | ||
961 | iwl_rx_spectrum_measure_notif; | ||
965 | priv->rx_handlers[PM_SLEEP_NOTIFICATION] = iwl_rx_pm_sleep_notif; | 962 | priv->rx_handlers[PM_SLEEP_NOTIFICATION] = iwl_rx_pm_sleep_notif; |
966 | priv->rx_handlers[PM_DEBUG_STATISTIC_NOTIFIC] = | 963 | priv->rx_handlers[PM_DEBUG_STATISTIC_NOTIFIC] = |
967 | iwl_rx_pm_debug_statistics_notif; | 964 | iwl_rx_pm_debug_statistics_notif; |
@@ -975,7 +972,6 @@ static void iwl3945_setup_rx_handlers(struct iwl_priv *priv) | |||
975 | priv->rx_handlers[REPLY_STATISTICS_CMD] = iwl3945_hw_rx_statistics; | 972 | priv->rx_handlers[REPLY_STATISTICS_CMD] = iwl3945_hw_rx_statistics; |
976 | priv->rx_handlers[STATISTICS_NOTIFICATION] = iwl3945_hw_rx_statistics; | 973 | priv->rx_handlers[STATISTICS_NOTIFICATION] = iwl3945_hw_rx_statistics; |
977 | 974 | ||
978 | iwl_setup_spectrum_handlers(priv); | ||
979 | iwl_setup_rx_scan_handlers(priv); | 975 | iwl_setup_rx_scan_handlers(priv); |
980 | priv->rx_handlers[CARD_STATE_NOTIFICATION] = iwl3945_rx_card_state_notif; | 976 | priv->rx_handlers[CARD_STATE_NOTIFICATION] = iwl3945_rx_card_state_notif; |
981 | 977 | ||
@@ -3569,8 +3565,6 @@ static ssize_t store_filter_flags(struct device *d, | |||
3569 | static DEVICE_ATTR(filter_flags, S_IWUSR | S_IRUGO, show_filter_flags, | 3565 | static DEVICE_ATTR(filter_flags, S_IWUSR | S_IRUGO, show_filter_flags, |
3570 | store_filter_flags); | 3566 | store_filter_flags); |
3571 | 3567 | ||
3572 | #ifdef CONFIG_IWL3945_SPECTRUM_MEASUREMENT | ||
3573 | |||
3574 | static ssize_t show_measurement(struct device *d, | 3568 | static ssize_t show_measurement(struct device *d, |
3575 | struct device_attribute *attr, char *buf) | 3569 | struct device_attribute *attr, char *buf) |
3576 | { | 3570 | { |
@@ -3640,7 +3634,6 @@ static ssize_t store_measurement(struct device *d, | |||
3640 | 3634 | ||
3641 | static DEVICE_ATTR(measurement, S_IRUSR | S_IWUSR, | 3635 | static DEVICE_ATTR(measurement, S_IRUSR | S_IWUSR, |
3642 | show_measurement, store_measurement); | 3636 | show_measurement, store_measurement); |
3643 | #endif /* CONFIG_IWL3945_SPECTRUM_MEASUREMENT */ | ||
3644 | 3637 | ||
3645 | static ssize_t store_retry_rate(struct device *d, | 3638 | static ssize_t store_retry_rate(struct device *d, |
3646 | struct device_attribute *attr, | 3639 | struct device_attribute *attr, |
@@ -3823,9 +3816,7 @@ static struct attribute *iwl3945_sysfs_entries[] = { | |||
3823 | &dev_attr_dump_errors.attr, | 3816 | &dev_attr_dump_errors.attr, |
3824 | &dev_attr_flags.attr, | 3817 | &dev_attr_flags.attr, |
3825 | &dev_attr_filter_flags.attr, | 3818 | &dev_attr_filter_flags.attr, |
3826 | #ifdef CONFIG_IWL3945_SPECTRUM_MEASUREMENT | ||
3827 | &dev_attr_measurement.attr, | 3819 | &dev_attr_measurement.attr, |
3828 | #endif | ||
3829 | &dev_attr_retry_rate.attr, | 3820 | &dev_attr_retry_rate.attr, |
3830 | &dev_attr_statistics.attr, | 3821 | &dev_attr_statistics.attr, |
3831 | &dev_attr_status.attr, | 3822 | &dev_attr_status.attr, |