On 2011-04-11 8:29 AM, Kalle Valo wrote:
Felix Fietkau<nbd@xxxxxxxxxxx> writes:
Use local variables to reduce the number of load/store operations on uncached
memory.
A comment in the code would be nice as well. Otherwise later on
someone decides to "optimise" and remove the local variables :)
Makes sense.
/* Clear descriptor */
- memset(&desc->ud.ds_tx5212, 0, sizeof(struct ath5k_hw_5212_tx_desc));
+ memset(&desc->ud.ds_tx5212.tx_stat, 0,
+ sizeof(desc->ud.ds_tx5212.tx_stat));
Is this an unrelated change? Or maybe I just missed something.
This is related. After my change, all the control fields of the
descriptor are properly written to, so the memset only needs to cover
the status area.
- Felix
--
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