Search Linux Wireless

Re: [PATCH v2 2/2] mac80211: improve minstrel_ht rate sorting by throughput & probability

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

 



Hi,

On Tue, Sep 09, 2014 at 11:22:14PM +0200, Thomas Huehn wrote:
> @@ -260,13 +399,14 @@ minstrel_ht_update_stats(struct minstrel_priv *mp, struct minstrel_ht_sta *mi)
>  	mi->sample_slow = 0;
>  	mi->sample_count = 0;
>  
> -	for (group = 0; group < ARRAY_SIZE(minstrel_mcs_groups); group++) {
> -		bool mg_rates_valid = false;
> +	/* Initialize global rate indexes */
> +	for(j = 0; j < MAX_THR_RATES; j++){
> +		tmp_mcs_tp_rate[j] = 0;
> +		tmp_cck_tp_rate[j] = 0;
> +	}
>  

Pb if a driver doesn't support the first entry it. 
Maybe using a mi->min_ridx set in minstrel_ht_update_caps would be
practical.

> @@ -274,24 +414,16 @@ minstrel_ht_update_stats(struct minstrel_priv *mp, struct minstrel_ht_sta *mi)
>  
>  		mi->sample_count++;
>  
> +		/* (re)Initialize group rate indexes */
> +		for(j = 0; j < MAX_THR_RATES; j++)
> +			tmp_group_tp_rate[j] = group;
> +

You meant group * MCS_GROUP_RATES, no ?
And group * MCS_GROUP_RATES + ffs(mg->supported) - 1 would be correct
but this corner case is not easily triggerable, ATM.

-- 
Karl
--
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 Wireless Personal Area Network]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [Linux Kernel]     [IDE]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite Hiking]     [MIPS Linux]     [ARM Linux]     [Linux RAID]

  Powered by Linux