aboutsummaryrefslogtreecommitdiffstats
path: root/net/mac80211/ht.c
diff options
context:
space:
mode:
authortamizhr@codeaurora.org <tamizhr@codeaurora.org>2018-03-27 09:46:16 -0400
committerJohannes Berg <johannes.berg@intel.com>2018-03-29 04:19:55 -0400
commit57566b20033f23bdc9f25d5fa4c36a7287aa08d2 (patch)
tree305656d75bf16a8f45fdb7ce429543ab9fdcb0c5 /net/mac80211/ht.c
parent5e78abd075e562fd5748ac3bfb067941e8baf6c7 (diff)
mac80211: Use proper smps_mode enum in sta opmode event
SMPS_MODE change value notified via nl80211 contains mac80211 specific value(ieee80211_smps_mode) and user space application will not know those values. This patch add support to map the mac80211 enum value to nl80211_smps_mode which will be understood by the userspace application. Signed-off-by: Tamizh chelvam <tamizhr@codeaurora.org> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Diffstat (limited to 'net/mac80211/ht.c')
-rw-r--r--net/mac80211/ht.c15
1 files changed, 15 insertions, 0 deletions
diff --git a/net/mac80211/ht.c b/net/mac80211/ht.c
index d7523530d3f8..c78036a0ac94 100644
--- a/net/mac80211/ht.c
+++ b/net/mac80211/ht.c
@@ -466,6 +466,21 @@ void ieee80211_process_delba(struct ieee80211_sub_if_data *sdata,
466 __ieee80211_stop_tx_ba_session(sta, tid, AGG_STOP_PEER_REQUEST); 466 __ieee80211_stop_tx_ba_session(sta, tid, AGG_STOP_PEER_REQUEST);
467} 467}
468 468
469enum nl80211_smps_mode
470ieee80211_smps_mode_to_smps_mode(enum ieee80211_smps_mode smps)
471{
472 switch (smps) {
473 case IEEE80211_SMPS_OFF:
474 return NL80211_SMPS_OFF;
475 case IEEE80211_SMPS_STATIC:
476 return NL80211_SMPS_STATIC;
477 case IEEE80211_SMPS_DYNAMIC:
478 return NL80211_SMPS_DYNAMIC;
479 default:
480 return NL80211_SMPS_OFF;
481 }
482}
483
469int ieee80211_send_smps_action(struct ieee80211_sub_if_data *sdata, 484int ieee80211_send_smps_action(struct ieee80211_sub_if_data *sdata,
470 enum ieee80211_smps_mode smps, const u8 *da, 485 enum ieee80211_smps_mode smps, const u8 *da,
471 const u8 *bssid) 486 const u8 *bssid)