diff options
author | Tomas Winkler <tomas.winkler@intel.com> | 2008-09-02 23:26:42 -0400 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2008-09-11 15:53:31 -0400 |
commit | 00c5ae2fa0f8191a1b204e71f0ee11359e3b2c06 (patch) | |
tree | 06ebdd29be276ef829e270497781db43783a8710 | |
parent | 1e493d1946a0b26b79001c18d7312d536156ff5a (diff) |
mac80211: change MIMO_PS to SM_PS
This patch follows 11n spec naming more rigorously replacing MIMO_PS
with SM_PS (Spatial Multiplexing Power Save).
(Originally submitted as 4 patches, "mac80211: change MIMO_PS to SM_PS",
"iwlwifi: change MIMO_PS to SM_PS", "ath9k: change MIMO_PS to SM_PS",
and "iwlwifi: remove double definition of SM PS". -- JWL)
Signed-off-by: Ron Rindjunsky <ron.rindjunsky@intel.com>
Signed-off-by: Tomas Winkler <tomas.winkler@intel.com>
Signed-off-by: Zhu Yi <yi.zhu@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
-rw-r--r-- | drivers/net/wireless/ath9k/main.c | 2 | ||||
-rw-r--r-- | drivers/net/wireless/iwlwifi/iwl-agn-rs.c | 4 | ||||
-rw-r--r-- | drivers/net/wireless/iwlwifi/iwl-agn.c | 2 | ||||
-rw-r--r-- | drivers/net/wireless/iwlwifi/iwl-core.c | 16 | ||||
-rw-r--r-- | drivers/net/wireless/iwlwifi/iwl-dev.h | 5 | ||||
-rw-r--r-- | drivers/net/wireless/iwlwifi/iwl-sta.c | 8 | ||||
-rw-r--r-- | include/linux/ieee80211.h | 12 | ||||
-rw-r--r-- | net/mac80211/main.c | 4 |
8 files changed, 24 insertions, 29 deletions
diff --git a/drivers/net/wireless/ath9k/main.c b/drivers/net/wireless/ath9k/main.c index 245b7308a9ad..57d7cc87cb0f 100644 --- a/drivers/net/wireless/ath9k/main.c +++ b/drivers/net/wireless/ath9k/main.c | |||
@@ -224,7 +224,7 @@ static void setup_ht_cap(struct ieee80211_ht_info *ht_info) | |||
224 | 224 | ||
225 | ht_info->ht_supported = 1; | 225 | ht_info->ht_supported = 1; |
226 | ht_info->cap = (u16)IEEE80211_HT_CAP_SUP_WIDTH | 226 | ht_info->cap = (u16)IEEE80211_HT_CAP_SUP_WIDTH |
227 | |(u16)IEEE80211_HT_CAP_MIMO_PS | 227 | |(u16)IEEE80211_HT_CAP_SM_PS |
228 | |(u16)IEEE80211_HT_CAP_SGI_40 | 228 | |(u16)IEEE80211_HT_CAP_SGI_40 |
229 | |(u16)IEEE80211_HT_CAP_DSSSCCK40; | 229 | |(u16)IEEE80211_HT_CAP_DSSSCCK40; |
230 | 230 | ||
diff --git a/drivers/net/wireless/iwlwifi/iwl-agn-rs.c b/drivers/net/wireless/iwlwifi/iwl-agn-rs.c index 98f2c843b99e..4fc3a0f1d8f1 100644 --- a/drivers/net/wireless/iwlwifi/iwl-agn-rs.c +++ b/drivers/net/wireless/iwlwifi/iwl-agn-rs.c | |||
@@ -1153,8 +1153,8 @@ static int rs_switch_to_mimo2(struct iwl_priv *priv, | |||
1153 | !sta->ht_info.ht_supported) | 1153 | !sta->ht_info.ht_supported) |
1154 | return -1; | 1154 | return -1; |
1155 | 1155 | ||
1156 | if (((sta->ht_info.cap & IEEE80211_HT_CAP_MIMO_PS) >> 2) | 1156 | if (((sta->ht_info.cap & IEEE80211_HT_CAP_SM_PS) >> 2) |
1157 | == IWL_MIMO_PS_STATIC) | 1157 | == WLAN_HT_CAP_SM_PS_STATIC) |
1158 | return -1; | 1158 | return -1; |
1159 | 1159 | ||
1160 | /* Need both Tx chains/antennas to support MIMO */ | 1160 | /* Need both Tx chains/antennas to support MIMO */ |
diff --git a/drivers/net/wireless/iwlwifi/iwl-agn.c b/drivers/net/wireless/iwlwifi/iwl-agn.c index 1547122e66fa..27ddf6cb1c6e 100644 --- a/drivers/net/wireless/iwlwifi/iwl-agn.c +++ b/drivers/net/wireless/iwlwifi/iwl-agn.c | |||
@@ -564,7 +564,7 @@ static void iwl4965_ht_conf(struct iwl_priv *priv, | |||
564 | if (!iwl_conf->is_ht) | 564 | if (!iwl_conf->is_ht) |
565 | return; | 565 | return; |
566 | 566 | ||
567 | priv->ps_mode = (u8)((ht_conf->cap & IEEE80211_HT_CAP_MIMO_PS) >> 2); | 567 | priv->ps_mode = (u8)((ht_conf->cap & IEEE80211_HT_CAP_SM_PS) >> 2); |
568 | 568 | ||
569 | if (ht_conf->cap & IEEE80211_HT_CAP_SGI_20) | 569 | if (ht_conf->cap & IEEE80211_HT_CAP_SGI_20) |
570 | iwl_conf->sgf |= HT_SHORT_GI_20MHZ; | 570 | iwl_conf->sgf |= HT_SHORT_GI_20MHZ; |
diff --git a/drivers/net/wireless/iwlwifi/iwl-core.c b/drivers/net/wireless/iwlwifi/iwl-core.c index a0b86af25c83..789556db6842 100644 --- a/drivers/net/wireless/iwlwifi/iwl-core.c +++ b/drivers/net/wireless/iwlwifi/iwl-core.c | |||
@@ -399,8 +399,8 @@ static void iwlcore_init_ht_hw_capab(const struct iwl_priv *priv, | |||
399 | 399 | ||
400 | ht_info->cap |= (u16)IEEE80211_HT_CAP_GRN_FLD; | 400 | ht_info->cap |= (u16)IEEE80211_HT_CAP_GRN_FLD; |
401 | ht_info->cap |= (u16)IEEE80211_HT_CAP_SGI_20; | 401 | ht_info->cap |= (u16)IEEE80211_HT_CAP_SGI_20; |
402 | ht_info->cap |= (u16)(IEEE80211_HT_CAP_MIMO_PS & | 402 | ht_info->cap |= (u16)(IEEE80211_HT_CAP_SM_PS & |
403 | (IWL_MIMO_PS_NONE << 2)); | 403 | (WLAN_HT_CAP_SM_PS_DISABLED << 2)); |
404 | 404 | ||
405 | max_bit_rate = MAX_BIT_RATE_20_MHZ; | 405 | max_bit_rate = MAX_BIT_RATE_20_MHZ; |
406 | if (priv->hw_params.fat_channel & BIT(band)) { | 406 | if (priv->hw_params.fat_channel & BIT(band)) { |
@@ -709,7 +709,7 @@ static int iwl_get_active_rx_chain_count(struct iwl_priv *priv) | |||
709 | bool is_cam = !test_bit(STATUS_POWER_PMI, &priv->status); | 709 | bool is_cam = !test_bit(STATUS_POWER_PMI, &priv->status); |
710 | 710 | ||
711 | /* # of Rx chains to use when expecting MIMO. */ | 711 | /* # of Rx chains to use when expecting MIMO. */ |
712 | if (is_single || (!is_cam && (priv->ps_mode == IWL_MIMO_PS_STATIC))) | 712 | if (is_single || (!is_cam && (priv->ps_mode == WLAN_HT_CAP_SM_PS_STATIC))) |
713 | return 2; | 713 | return 2; |
714 | else | 714 | else |
715 | return 3; | 715 | return 3; |
@@ -721,14 +721,14 @@ static int iwl_get_idle_rx_chain_count(struct iwl_priv *priv, int active_cnt) | |||
721 | bool is_cam = !test_bit(STATUS_POWER_PMI, &priv->status); | 721 | bool is_cam = !test_bit(STATUS_POWER_PMI, &priv->status); |
722 | /* # Rx chains when idling and maybe trying to save power */ | 722 | /* # Rx chains when idling and maybe trying to save power */ |
723 | switch (priv->ps_mode) { | 723 | switch (priv->ps_mode) { |
724 | case IWL_MIMO_PS_STATIC: | 724 | case WLAN_HT_CAP_SM_PS_STATIC: |
725 | case IWL_MIMO_PS_DYNAMIC: | 725 | case WLAN_HT_CAP_SM_PS_DYNAMIC: |
726 | idle_cnt = (is_cam) ? 2 : 1; | 726 | idle_cnt = (is_cam) ? 2 : 1; |
727 | break; | 727 | break; |
728 | case IWL_MIMO_PS_NONE: | 728 | case WLAN_HT_CAP_SM_PS_DISABLED: |
729 | idle_cnt = (is_cam) ? active_cnt : 1; | 729 | idle_cnt = (is_cam) ? active_cnt : 1; |
730 | break; | 730 | break; |
731 | case IWL_MIMO_PS_INVALID: | 731 | case WLAN_HT_CAP_SM_PS_INVALID: |
732 | default: | 732 | default: |
733 | IWL_ERROR("invalide mimo ps mode %d\n", priv->ps_mode); | 733 | IWL_ERROR("invalide mimo ps mode %d\n", priv->ps_mode); |
734 | WARN_ON(1); | 734 | WARN_ON(1); |
@@ -912,7 +912,7 @@ int iwl_init_drv(struct iwl_priv *priv) | |||
912 | priv->iw_mode = IEEE80211_IF_TYPE_STA; | 912 | priv->iw_mode = IEEE80211_IF_TYPE_STA; |
913 | 913 | ||
914 | priv->use_ant_b_for_management_frame = 1; /* start with ant B */ | 914 | priv->use_ant_b_for_management_frame = 1; /* start with ant B */ |
915 | priv->ps_mode = IWL_MIMO_PS_NONE; | 915 | priv->ps_mode = WLAN_HT_CAP_SM_PS_DISABLED; |
916 | 916 | ||
917 | /* Choose which receivers/antennas to use */ | 917 | /* Choose which receivers/antennas to use */ |
918 | iwl_set_rxon_chain(priv); | 918 | iwl_set_rxon_chain(priv); |
diff --git a/drivers/net/wireless/iwlwifi/iwl-dev.h b/drivers/net/wireless/iwlwifi/iwl-dev.h index 640ceea913c7..f302e93b7798 100644 --- a/drivers/net/wireless/iwlwifi/iwl-dev.h +++ b/drivers/net/wireless/iwlwifi/iwl-dev.h | |||
@@ -644,11 +644,6 @@ struct iwl_kw { | |||
644 | #define IWL_CHANNEL_WIDTH_20MHZ 0 | 644 | #define IWL_CHANNEL_WIDTH_20MHZ 0 |
645 | #define IWL_CHANNEL_WIDTH_40MHZ 1 | 645 | #define IWL_CHANNEL_WIDTH_40MHZ 1 |
646 | 646 | ||
647 | #define IWL_MIMO_PS_STATIC 0 | ||
648 | #define IWL_MIMO_PS_NONE 3 | ||
649 | #define IWL_MIMO_PS_DYNAMIC 1 | ||
650 | #define IWL_MIMO_PS_INVALID 2 | ||
651 | |||
652 | #define IWL_OPERATION_MODE_AUTO 0 | 647 | #define IWL_OPERATION_MODE_AUTO 0 |
653 | #define IWL_OPERATION_MODE_HT_ONLY 1 | 648 | #define IWL_OPERATION_MODE_HT_ONLY 1 |
654 | #define IWL_OPERATION_MODE_MIXED 2 | 649 | #define IWL_OPERATION_MODE_MIXED 2 |
diff --git a/drivers/net/wireless/iwlwifi/iwl-sta.c b/drivers/net/wireless/iwlwifi/iwl-sta.c index 5b7b05c8773f..a72569f1acb5 100644 --- a/drivers/net/wireless/iwlwifi/iwl-sta.c +++ b/drivers/net/wireless/iwlwifi/iwl-sta.c | |||
@@ -191,20 +191,20 @@ static void iwl_set_ht_add_station(struct iwl_priv *priv, u8 index, | |||
191 | if (!sta_ht_inf || !sta_ht_inf->ht_supported) | 191 | if (!sta_ht_inf || !sta_ht_inf->ht_supported) |
192 | goto done; | 192 | goto done; |
193 | 193 | ||
194 | mimo_ps_mode = (sta_ht_inf->cap & IEEE80211_HT_CAP_MIMO_PS) >> 2; | 194 | mimo_ps_mode = (sta_ht_inf->cap & IEEE80211_HT_CAP_SM_PS) >> 2; |
195 | 195 | ||
196 | sta_flags = priv->stations[index].sta.station_flags; | 196 | sta_flags = priv->stations[index].sta.station_flags; |
197 | 197 | ||
198 | sta_flags &= ~(STA_FLG_RTS_MIMO_PROT_MSK | STA_FLG_MIMO_DIS_MSK); | 198 | sta_flags &= ~(STA_FLG_RTS_MIMO_PROT_MSK | STA_FLG_MIMO_DIS_MSK); |
199 | 199 | ||
200 | switch (mimo_ps_mode) { | 200 | switch (mimo_ps_mode) { |
201 | case WLAN_HT_CAP_MIMO_PS_STATIC: | 201 | case WLAN_HT_CAP_SM_PS_STATIC: |
202 | sta_flags |= STA_FLG_MIMO_DIS_MSK; | 202 | sta_flags |= STA_FLG_MIMO_DIS_MSK; |
203 | break; | 203 | break; |
204 | case WLAN_HT_CAP_MIMO_PS_DYNAMIC: | 204 | case WLAN_HT_CAP_SM_PS_DYNAMIC: |
205 | sta_flags |= STA_FLG_RTS_MIMO_PROT_MSK; | 205 | sta_flags |= STA_FLG_RTS_MIMO_PROT_MSK; |
206 | break; | 206 | break; |
207 | case WLAN_HT_CAP_MIMO_PS_DISABLED: | 207 | case WLAN_HT_CAP_SM_PS_DISABLED: |
208 | break; | 208 | break; |
209 | default: | 209 | default: |
210 | IWL_WARNING("Invalid MIMO PS mode %d\n", mimo_ps_mode); | 210 | IWL_WARNING("Invalid MIMO PS mode %d\n", mimo_ps_mode); |
diff --git a/include/linux/ieee80211.h b/include/linux/ieee80211.h index be456450cd2e..333d3ae76883 100644 --- a/include/linux/ieee80211.h +++ b/include/linux/ieee80211.h | |||
@@ -708,7 +708,7 @@ struct ieee80211_ht_addt_info { | |||
708 | 708 | ||
709 | /* 802.11n HT capabilities masks */ | 709 | /* 802.11n HT capabilities masks */ |
710 | #define IEEE80211_HT_CAP_SUP_WIDTH 0x0002 | 710 | #define IEEE80211_HT_CAP_SUP_WIDTH 0x0002 |
711 | #define IEEE80211_HT_CAP_MIMO_PS 0x000C | 711 | #define IEEE80211_HT_CAP_SM_PS 0x000C |
712 | #define IEEE80211_HT_CAP_GRN_FLD 0x0010 | 712 | #define IEEE80211_HT_CAP_GRN_FLD 0x0010 |
713 | #define IEEE80211_HT_CAP_SGI_20 0x0020 | 713 | #define IEEE80211_HT_CAP_SGI_20 0x0020 |
714 | #define IEEE80211_HT_CAP_SGI_40 0x0040 | 714 | #define IEEE80211_HT_CAP_SGI_40 0x0040 |
@@ -737,11 +737,11 @@ struct ieee80211_ht_addt_info { | |||
737 | #define IEEE80211_HT_IE_NON_GF_STA_PRSNT 0x0004 | 737 | #define IEEE80211_HT_IE_NON_GF_STA_PRSNT 0x0004 |
738 | #define IEEE80211_HT_IE_NON_HT_STA_PRSNT 0x0010 | 738 | #define IEEE80211_HT_IE_NON_HT_STA_PRSNT 0x0010 |
739 | 739 | ||
740 | /* MIMO Power Save Modes */ | 740 | /* Spatial Multiplexing Power Save Modes */ |
741 | #define WLAN_HT_CAP_MIMO_PS_STATIC 0 | 741 | #define WLAN_HT_CAP_SM_PS_STATIC 0 |
742 | #define WLAN_HT_CAP_MIMO_PS_DYNAMIC 1 | 742 | #define WLAN_HT_CAP_SM_PS_DYNAMIC 1 |
743 | #define WLAN_HT_CAP_MIMO_PS_INVALID 2 | 743 | #define WLAN_HT_CAP_SM_PS_INVALID 2 |
744 | #define WLAN_HT_CAP_MIMO_PS_DISABLED 3 | 744 | #define WLAN_HT_CAP_SM_PS_DISABLED 3 |
745 | 745 | ||
746 | /* Authentication algorithms */ | 746 | /* Authentication algorithms */ |
747 | #define WLAN_AUTH_OPEN 0 | 747 | #define WLAN_AUTH_OPEN 0 |
diff --git a/net/mac80211/main.c b/net/mac80211/main.c index 396cfb2d0f46..7dc063197259 100644 --- a/net/mac80211/main.c +++ b/net/mac80211/main.c | |||
@@ -1140,8 +1140,8 @@ u32 ieee80211_handle_ht(struct ieee80211_local *local, int enable_ht, | |||
1140 | ht_conf.ht_supported = 1; | 1140 | ht_conf.ht_supported = 1; |
1141 | 1141 | ||
1142 | ht_conf.cap = req_ht_cap->cap & sband->ht_info.cap; | 1142 | ht_conf.cap = req_ht_cap->cap & sband->ht_info.cap; |
1143 | ht_conf.cap &= ~(IEEE80211_HT_CAP_MIMO_PS); | 1143 | ht_conf.cap &= ~(IEEE80211_HT_CAP_SM_PS); |
1144 | ht_conf.cap |= sband->ht_info.cap & IEEE80211_HT_CAP_MIMO_PS; | 1144 | ht_conf.cap |= sband->ht_info.cap & IEEE80211_HT_CAP_SM_PS; |
1145 | ht_bss_conf.primary_channel = req_bss_cap->primary_channel; | 1145 | ht_bss_conf.primary_channel = req_bss_cap->primary_channel; |
1146 | ht_bss_conf.bss_cap = req_bss_cap->bss_cap; | 1146 | ht_bss_conf.bss_cap = req_bss_cap->bss_cap; |
1147 | ht_bss_conf.bss_op_mode = req_bss_cap->bss_op_mode; | 1147 | ht_bss_conf.bss_op_mode = req_bss_cap->bss_op_mode; |