diff options
-rw-r--r-- | net/mac80211/rx.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/net/mac80211/rx.c b/net/mac80211/rx.c index 5dae166cb7f5..9fb8ce982c2d 100644 --- a/net/mac80211/rx.c +++ b/net/mac80211/rx.c | |||
@@ -1240,22 +1240,22 @@ static void sta_ps_end(struct sta_info *sta) | |||
1240 | ieee80211_sta_ps_deliver_wakeup(sta); | 1240 | ieee80211_sta_ps_deliver_wakeup(sta); |
1241 | } | 1241 | } |
1242 | 1242 | ||
1243 | int ieee80211_sta_ps_transition(struct ieee80211_sta *sta, bool start) | 1243 | int ieee80211_sta_ps_transition(struct ieee80211_sta *pubsta, bool start) |
1244 | { | 1244 | { |
1245 | struct sta_info *sta_inf = container_of(sta, struct sta_info, sta); | 1245 | struct sta_info *sta = container_of(pubsta, struct sta_info, sta); |
1246 | bool in_ps; | 1246 | bool in_ps; |
1247 | 1247 | ||
1248 | WARN_ON(!ieee80211_hw_check(&sta_inf->local->hw, AP_LINK_PS)); | 1248 | WARN_ON(!ieee80211_hw_check(&sta->local->hw, AP_LINK_PS)); |
1249 | 1249 | ||
1250 | /* Don't let the same PS state be set twice */ | 1250 | /* Don't let the same PS state be set twice */ |
1251 | in_ps = test_sta_flag(sta_inf, WLAN_STA_PS_STA); | 1251 | in_ps = test_sta_flag(sta, WLAN_STA_PS_STA); |
1252 | if ((start && in_ps) || (!start && !in_ps)) | 1252 | if ((start && in_ps) || (!start && !in_ps)) |
1253 | return -EINVAL; | 1253 | return -EINVAL; |
1254 | 1254 | ||
1255 | if (start) | 1255 | if (start) |
1256 | sta_ps_start(sta_inf); | 1256 | sta_ps_start(sta); |
1257 | else | 1257 | else |
1258 | sta_ps_end(sta_inf); | 1258 | sta_ps_end(sta); |
1259 | 1259 | ||
1260 | return 0; | 1260 | return 0; |
1261 | } | 1261 | } |