diff options
Diffstat (limited to 'net/mac80211/cfg.c')
-rw-r--r-- | net/mac80211/cfg.c | 15 |
1 files changed, 11 insertions, 4 deletions
diff --git a/net/mac80211/cfg.c b/net/mac80211/cfg.c index 09c90627fd19..03216b0408c7 100644 --- a/net/mac80211/cfg.c +++ b/net/mac80211/cfg.c | |||
@@ -884,6 +884,10 @@ static int ieee80211_start_ap(struct wiphy *wiphy, struct net_device *dev, | |||
884 | if (old) | 884 | if (old) |
885 | return -EALREADY; | 885 | return -EALREADY; |
886 | 886 | ||
887 | /* TODO: make hostapd tell us what it wants */ | ||
888 | sdata->smps_mode = IEEE80211_SMPS_OFF; | ||
889 | sdata->needed_rx_chains = sdata->local->rx_chains; | ||
890 | |||
887 | err = ieee80211_vif_use_channel(sdata, params->channel, | 891 | err = ieee80211_vif_use_channel(sdata, params->channel, |
888 | params->channel_type, | 892 | params->channel_type, |
889 | IEEE80211_CHANCTX_SHARED); | 893 | IEEE80211_CHANCTX_SHARED); |
@@ -1673,6 +1677,10 @@ static int ieee80211_join_mesh(struct wiphy *wiphy, struct net_device *dev, | |||
1673 | if (err) | 1677 | if (err) |
1674 | return err; | 1678 | return err; |
1675 | 1679 | ||
1680 | /* can mesh use other SMPS modes? */ | ||
1681 | sdata->smps_mode = IEEE80211_SMPS_OFF; | ||
1682 | sdata->needed_rx_chains = sdata->local->rx_chains; | ||
1683 | |||
1676 | err = ieee80211_vif_use_channel(sdata, setup->channel, | 1684 | err = ieee80211_vif_use_channel(sdata, setup->channel, |
1677 | setup->channel_type, | 1685 | setup->channel_type, |
1678 | IEEE80211_CHANCTX_SHARED); | 1686 | IEEE80211_CHANCTX_SHARED); |
@@ -2052,13 +2060,12 @@ int __ieee80211_request_smps(struct ieee80211_sub_if_data *sdata, | |||
2052 | 2060 | ||
2053 | /* | 2061 | /* |
2054 | * If not associated, or current association is not an HT | 2062 | * If not associated, or current association is not an HT |
2055 | * association, there's no need to send an action frame. | 2063 | * association, there's no need to do anything, just store |
2064 | * the new value until we associate. | ||
2056 | */ | 2065 | */ |
2057 | if (!sdata->u.mgd.associated || | 2066 | if (!sdata->u.mgd.associated || |
2058 | sdata->vif.bss_conf.channel_type == NL80211_CHAN_NO_HT) { | 2067 | sdata->vif.bss_conf.channel_type == NL80211_CHAN_NO_HT) |
2059 | ieee80211_recalc_smps(sdata->local); | ||
2060 | return 0; | 2068 | return 0; |
2061 | } | ||
2062 | 2069 | ||
2063 | ap = sdata->u.mgd.associated->bssid; | 2070 | ap = sdata->u.mgd.associated->bssid; |
2064 | 2071 | ||