Skip to content

Commit

Permalink
mac80211: fix rx_nss calculation for drivers with hw rc
Browse files Browse the repository at this point in the history
Drivers with hardware rate control were given
sta->rx_nss set to 0. This was because rx_nss
calculation procedure was protected by hw/sw rate
control check.

Signed-off-by: Michal Kazior <michal.kazior@tieto.com>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
  • Loading branch information
Michal Kazior authored and Johannes Berg committed Dec 2, 2013
1 parent 1f3b8a2 commit ddcc347
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions net/mac80211/rate.h
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,8 @@ static inline void rate_control_rate_init(struct sta_info *sta)
struct ieee80211_supported_band *sband;
struct ieee80211_chanctx_conf *chanctx_conf;

ieee80211_sta_set_rx_nss(sta);

if (!ref)
return;

Expand All @@ -67,8 +69,6 @@ static inline void rate_control_rate_init(struct sta_info *sta)

sband = local->hw.wiphy->bands[chanctx_conf->def.chan->band];

ieee80211_sta_set_rx_nss(sta);

ref->ops->rate_init(ref->priv, sband, &chanctx_conf->def, ista,
priv_sta);
rcu_read_unlock();
Expand Down

0 comments on commit ddcc347

Please sign in to comment.