bnx2x: added 'likely' to fast-path skb existence
authorYuval Mintz <yuvalmin@broadcom.com>
Sun, 18 Mar 2012 10:33:37 +0000 (10:33 +0000)
committerDavid S. Miller <davem@davemloft.net>
Mon, 19 Mar 2012 20:52:18 +0000 (16:52 -0400)
Signed-off-by: Yuval Mintz <yuvalmin@broadcom.com>
Signed-off-by: Eilon Greenstein <eilong@broadcom.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/broadcom/bnx2x/bnx2x_cmn.c

index b814f4eaed19488132013d29c1d82d30374fd1dd..d888228d0787e9795602bb8403a4dc0205e13820 100644 (file)
@@ -120,10 +120,11 @@ static u16 bnx2x_free_tx_pkt(struct bnx2x *bp, struct bnx2x_fp_txdata *txdata,
 
        /* release skb */
        WARN_ON(!skb);
-       if (skb) {
+       if (likely(skb)) {
                (*pkts_compl)++;
                (*bytes_compl) += skb->len;
        }
+
        dev_kfree_skb_any(skb);
        tx_buf->first_bd = 0;
        tx_buf->skb = NULL;