diff options
author | Helmut Schaa <helmut.schaa@googlemail.com> | 2010-10-09 07:34:43 -0400 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2010-10-11 15:04:22 -0400 |
commit | c6084d5fa2e70a436ab944066146de01819f5493 (patch) | |
tree | 3c0d854e6f9795680c95c6faee1e4a54e5de404d /drivers/net/wireless/rt2x00/rt2x00queue.c | |
parent | ff6133becae9ae1657fcff339a160a21448fa11c (diff) |
rt2x00: Use unlikely for error case in rt2x00queue_write_tx_frame
This is an error condition that is not supposed to happen. Hence, it is
safe to add unlikely to this check.
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>
Diffstat (limited to 'drivers/net/wireless/rt2x00/rt2x00queue.c')
-rw-r--r-- | drivers/net/wireless/rt2x00/rt2x00queue.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/net/wireless/rt2x00/rt2x00queue.c b/drivers/net/wireless/rt2x00/rt2x00queue.c index 4436ff72c864..83630f16dc64 100644 --- a/drivers/net/wireless/rt2x00/rt2x00queue.c +++ b/drivers/net/wireless/rt2x00/rt2x00queue.c | |||
@@ -489,7 +489,8 @@ int rt2x00queue_write_tx_frame(struct data_queue *queue, struct sk_buff *skb, | |||
489 | if (unlikely(rt2x00queue_full(queue))) | 489 | if (unlikely(rt2x00queue_full(queue))) |
490 | return -ENOBUFS; | 490 | return -ENOBUFS; |
491 | 491 | ||
492 | if (test_and_set_bit(ENTRY_OWNER_DEVICE_DATA, &entry->flags)) { | 492 | if (unlikely(test_and_set_bit(ENTRY_OWNER_DEVICE_DATA, |
493 | &entry->flags))) { | ||
493 | ERROR(queue->rt2x00dev, | 494 | ERROR(queue->rt2x00dev, |
494 | "Arrived at non-free entry in the non-full queue %d.\n" | 495 | "Arrived at non-free entry in the non-full queue %d.\n" |
495 | "Please file bug report to %s.\n", | 496 | "Please file bug report to %s.\n", |