From: Helmut Schaa Date: Thu, 3 Mar 2011 18:40:33 +0000 (+0100) Subject: rt2x00: Add unlikely macro to special case tx status handling X-Git-Tag: v3.0~349^2~16^2~578^2~64 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=5356d963304638735b4b53dfbded7a1c4ae0818d;p=platform%2Fkernel%2Flinux-amlogic.git rt2x00: Add unlikely macro to special case tx status handling This special case shouldn't happen very often. Only if a frame that is not intended to be aggregated ends up in an AMPDU _and_ was intended to be sent at a different MCS rate as the aggregate. Hence, using unlikely is justified. Signed-off-by: Helmut Schaa Signed-off-by: Ivo van Doorn Signed-off-by: John W. Linville --- diff --git a/drivers/net/wireless/rt2x00/rt2800lib.c b/drivers/net/wireless/rt2x00/rt2800lib.c index 76ced6d..ad90c86 100644 --- a/drivers/net/wireless/rt2x00/rt2800lib.c +++ b/drivers/net/wireless/rt2x00/rt2800lib.c @@ -681,7 +681,7 @@ void rt2800_txdone_entry(struct queue_entry *entry, u32 status) * confuse the rate control algortihm by providing clearly wrong * data. */ - if (aggr == 1 && ampdu == 0 && real_mcs != mcs) { + if (unlikely(aggr == 1 && ampdu == 0 && real_mcs != mcs)) { skbdesc->tx_rate_idx = real_mcs; mcs = real_mcs; }