Pavel Roskin wrote: > Rate control algorithms are supposed to stop processing when they > encounter a rate with the index -1. Checking for rate->count not being > zero is not enough. Maybe it's a good idea to use an unsigned variable and check for the actual error condition when it can happen, instead of checking for an "overflow" after the fact? > +++ b/drivers/net/wireless/ath/ath9k/rc.c > @@ -1346,7 +1346,7 @@ static void ath_tx_status(void *priv, struct ieee80211_supported_band *sband, > fc = hdr->frame_control; > for (i = 0; i < sc->hw->max_rates; i++) { > struct ieee80211_tx_rate *rate = &tx_info->status.rates[i]; > - if (!rate->count) > + if (rate->idx < 0 || !rate->count) > break; At the very least this could test for <= 0. //Peter -- 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