Search Linux Wireless

Re: [PATCH 2/2] mac80211: Add support for CQM tx bitrate monitoring

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Am Donnerstag 21 Oktober 2010 schrieb Paul Stewart:
> Add state, work proc and debugging parameters for monitoring
> transmit-rate changes.
> 
> Signed-off-by: Paul Stewart <pstew@xxxxxxxxxx>
> ---

[...]

> diff --git a/net/mac80211/status.c b/net/mac80211/status.c
> index 3153c19..564aa2e 100644
> --- a/net/mac80211/status.c
> +++ b/net/mac80211/status.c
> @@ -154,6 +154,24 @@ static void ieee80211_frame_acked(struct sta_info *sta, struct sk_buff *skb)
>  		}
>  
>  		ieee80211_queue_work(&local->hw, &local->recalc_smps);
> +	} else if (ieee80211_is_data(mgmt->frame_control) &&
> +		   sdata->vif.type == NL80211_IFTYPE_STATION) {
> +		struct ieee80211_if_managed *ifmgd;
> +		ifmgd = &sta->sdata->u.mgd;
> +		if (ifmgd->cqm_bitrate_thold != 0 &&
> +		    (ifmgd->last_cqm_tx_rate.idx != sta->last_tx_rate.idx ||
> +		     (ifmgd->last_cqm_tx_rate.flags &
> +		      (IEEE80211_TX_RC_MCS | IEEE80211_TX_RC_40_MHZ_WIDTH |
> +		       IEEE80211_TX_RC_SHORT_GI)) !=
> +		     (sta->last_tx_rate.flags &
> +		      (IEEE80211_TX_RC_MCS | IEEE80211_TX_RC_40_MHZ_WIDTH |
> +		       IEEE80211_TX_RC_SHORT_GI)) ||
> +		     sdata->u.mgd.last_cqm_bitrate == 0)) {
> +			ifmgd->last_cqm_tx_rate = sta->last_tx_rate;
> +			ifmgd->tx_bitrate_changed = true;
> +			ieee80211_queue_work(&local->hw,
> +					     &ifmgd->bitrate_notify_work);
> +		}
>  	}
>  }

Not sure but wouldn't that trigger a lot of unnecessary processing when a rate
gets probed by the rc algortihm? You might want to filter out probe frames
based on IEEE80211_TX_CTL_RATE_CTRL_PROBE as otherwise you could end up with
sending a huge number of events to userspace ...

Helmut
--
To unsubscribe from this list: send the line "unsubscribe linux-wireless" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Host AP]     [ATH6KL]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [Linux Kernel]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Samba]     [Device Mapper]
  Powered by Linux