Search Linux Wireless

re: ath5k: fix tx status reporting issues

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

 



Hello Felix Fietkau,

The patch 6d7b97b23e11: "ath5k: fix tx status reporting issues" from 
Apr 9, 2011, leads to the following
static checker warning: "drivers/net/wireless/ath/ath5k/base.c:1683 
ath5k_tx_frame_completed()
	 error: buffer overflow 'info->status.rates' 4 <= 4"

drivers/net/wireless/ath/ath5k/base.c
  1675          for (i = 0; i < ts->ts_final_idx; i++) {
  1676                  struct ieee80211_tx_rate *r =
  1677                          &info->status.rates[i];
  1678  
  1679                  r->count = tries[i];
  1680          }
  1681  
  1682          info->status.rates[ts->ts_final_idx].count = ts->ts_final_retry;
  1683          info->status.rates[ts->ts_final_idx + 1].idx = -1;
                                   ^^^^^^^^^^^^^^^^^^^^
It's complaining about this.

  1684  

->ts_final_idx is set in ath5k_hw_proc_4word_tx_status() it comes from
the hardware but in theory it could be a number between 0-3...  I'm not
sure.

regards,
dan carpenter

--
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