aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless/iwlwifi/iwl3945-base.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/net/wireless/iwlwifi/iwl3945-base.c')
-rw-r--r--drivers/net/wireless/iwlwifi/iwl3945-base.c20
1 files changed, 2 insertions, 18 deletions
diff --git a/drivers/net/wireless/iwlwifi/iwl3945-base.c b/drivers/net/wireless/iwlwifi/iwl3945-base.c
index 271e5d1f8425..c32ec809053f 100644
--- a/drivers/net/wireless/iwlwifi/iwl3945-base.c
+++ b/drivers/net/wireless/iwlwifi/iwl3945-base.c
@@ -3845,26 +3845,11 @@ static ssize_t show_power_level(struct device *d,
3845{ 3845{
3846 struct iwl_priv *priv = dev_get_drvdata(d); 3846 struct iwl_priv *priv = dev_get_drvdata(d);
3847 int mode = priv->power_data.user_power_setting; 3847 int mode = priv->power_data.user_power_setting;
3848 int system = priv->power_data.system_power_setting;
3849 int level = priv->power_data.power_mode; 3848 int level = priv->power_data.power_mode;
3850 char *p = buf; 3849 char *p = buf;
3851 3850
3852 switch (system) { 3851 p += sprintf(p, "INDEX:%d\t", level);
3853 case IWL_POWER_SYS_AUTO: 3852 p += sprintf(p, "USER:%d\n", mode);
3854 p += sprintf(p, "SYSTEM:auto");
3855 break;
3856 case IWL_POWER_SYS_AC:
3857 p += sprintf(p, "SYSTEM:ac");
3858 break;
3859 case IWL_POWER_SYS_BATTERY:
3860 p += sprintf(p, "SYSTEM:battery");
3861 break;
3862 }
3863
3864 p += sprintf(p, "\tMODE:%s", (mode < IWL_POWER_AUTO) ?
3865 "fixed" : "auto");
3866 p += sprintf(p, "\tINDEX:%d", level);
3867 p += sprintf(p, "\n");
3868 return p - buf + 1; 3853 return p - buf + 1;
3869} 3854}
3870 3855
@@ -4108,7 +4093,6 @@ static int iwl3945_init_drv(struct iwl_priv *priv)
4108 priv->ibss_beacon = NULL; 4093 priv->ibss_beacon = NULL;
4109 4094
4110 spin_lock_init(&priv->lock); 4095 spin_lock_init(&priv->lock);
4111 spin_lock_init(&priv->power_data.lock);
4112 spin_lock_init(&priv->sta_lock); 4096 spin_lock_init(&priv->sta_lock);
4113 spin_lock_init(&priv->hcmd_lock); 4097 spin_lock_init(&priv->hcmd_lock);
4114 4098