Commit f6993174 authored by Eliad Peller's avatar Eliad Peller Committed by Johannes Berg

mac80211: set smps_mode according to ap params

Take the requested smps mode from the ap params
(instead of always starting with SMPS_OFF)
Signed-off-by: default avatarEliad Peller <eliad@wizery.com>
Signed-off-by: default avatarEmmanuel Grumbach <emmanuel.grumbach@intel.com>
Signed-off-by: default avatarJohannes Berg <johannes.berg@intel.com>
parent 18998c38
...@@ -683,8 +683,19 @@ static int ieee80211_start_ap(struct wiphy *wiphy, struct net_device *dev, ...@@ -683,8 +683,19 @@ static int ieee80211_start_ap(struct wiphy *wiphy, struct net_device *dev,
if (old) if (old)
return -EALREADY; return -EALREADY;
/* TODO: make hostapd tell us what it wants */ switch (params->smps_mode) {
sdata->smps_mode = IEEE80211_SMPS_OFF; case NL80211_SMPS_OFF:
sdata->smps_mode = IEEE80211_SMPS_OFF;
break;
case NL80211_SMPS_STATIC:
sdata->smps_mode = IEEE80211_SMPS_STATIC;
break;
case NL80211_SMPS_DYNAMIC:
sdata->smps_mode = IEEE80211_SMPS_DYNAMIC;
break;
default:
return -EINVAL;
}
sdata->needed_rx_chains = sdata->local->rx_chains; sdata->needed_rx_chains = sdata->local->rx_chains;
mutex_lock(&local->mtx); mutex_lock(&local->mtx);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment