K 10 svn:author V 6 adrian K 8 svn:date V 27 2011-09-05T00:10:37.463436Z K 7 svn:log V 1181 Migrate the rate control selection out from the packet setup code and instead call it just before the packet is TXed. For non-aggregate packets, call it just before the frame is queued to hardware. For aggregate packets, call it on the first frame in the aggregate list so the aggregate code itself has a rate control selection to use when building the aggregate. This allows for some useful behaviour: * rate selection is now not done per-frame when doing aggregation. Aggregation only requires a rate lookup for the first frame. The rest are ignored. * The rate control module now gets a more "balanced" idea of how many times findrate is called versus completion. Beforehand, findrate would be called for each frame, but completion would be called for the entire aggregate. * software retransmission now allows for a new rate lookup - that way the retransmits aren't done using the same failing rates. This improves the aggregate throughput stability but it doesn't fix things entirely - primarily because ath_rate_sample is still making some very poor rate control decisions (eg dipping down to single-stream rates and trying MCS14/15 when it doesn't work.) END