aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorHelmut Schaa <helmut.schaa@googlemail.com>2011-03-03 13:39:27 -0500
committerJohn W. Linville <linville@tuxdriver.com>2011-03-04 14:06:46 -0500
commit87443e875c8ad1f0c25b1255bdeb88de934e151e (patch)
tree6d63f853ec2973003e36b463981a3eccdf2856c1
parent11f818e0eb50864c7e6f8af38d8f8822f992906a (diff)
rt2x00: Make use of unlikely during tx status processing
These conditions are unlikely to happen, tell the compiler. Signed-off-by: Helmut Schaa <helmut.schaa@googlemail.com> Signed-off-by: Ivo van Doorn <IvDoorn@gmail.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
-rw-r--r--drivers/net/wireless/rt2x00/rt2800pci.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/net/wireless/rt2x00/rt2800pci.c b/drivers/net/wireless/rt2x00/rt2800pci.c
index 5b53d005559b..046a7b7d1241 100644
--- a/drivers/net/wireless/rt2x00/rt2800pci.c
+++ b/drivers/net/wireless/rt2x00/rt2800pci.c
@@ -726,7 +726,7 @@ static void rt2800pci_txdone(struct rt2x00_dev *rt2x00dev)
726 726
727 while (kfifo_get(&rt2x00dev->txstatus_fifo, &status)) { 727 while (kfifo_get(&rt2x00dev->txstatus_fifo, &status)) {
728 qid = rt2x00_get_field32(status, TX_STA_FIFO_PID_QUEUE); 728 qid = rt2x00_get_field32(status, TX_STA_FIFO_PID_QUEUE);
729 if (qid >= QID_RX) { 729 if (unlikely(qid >= QID_RX)) {
730 /* 730 /*
731 * Unknown queue, this shouldn't happen. Just drop 731 * Unknown queue, this shouldn't happen. Just drop
732 * this tx status. 732 * this tx status.
@@ -747,7 +747,7 @@ static void rt2800pci_txdone(struct rt2x00_dev *rt2x00dev)
747 break; 747 break;
748 } 748 }
749 749
750 if (rt2x00queue_empty(queue)) { 750 if (unlikely(rt2x00queue_empty(queue))) {
751 /* 751 /*
752 * The queue is empty. Stop processing here 752 * The queue is empty. Stop processing here
753 * and drop the tx status. 753 * and drop the tx status.