RDMA/nes: don't leak skb if carrier down
authorFlorian Westphal <fw@strlen.de>
Sun, 24 Apr 2016 20:18:59 +0000 (22:18 +0200)
committerDoug Ledford <dledford@redhat.com>
Fri, 29 Apr 2016 01:11:09 +0000 (21:11 -0400)
Alternatively one could free the skb, OTOH I don't think this test is
useful so just remove it.

Cc: <linux-rdma@vger.kernel.org>
Signed-off-by: Florian Westphal <fw@strlen.de>
Signed-off-by: Doug Ledford <dledford@redhat.com>
drivers/infiniband/hw/nes/nes_nic.c

index 3ea9e055fdd37f27be5f8accad68aca74caa3780..92914539edc7c2b5eaff94820744bacf2b41b79a 100644 (file)
@@ -500,9 +500,6 @@ static int nes_netdev_start_xmit(struct sk_buff *skb, struct net_device *netdev)
         *              skb_shinfo(skb)->nr_frags, skb_is_gso(skb));
         */
 
-       if (!netif_carrier_ok(netdev))
-               return NETDEV_TX_OK;
-
        if (netif_queue_stopped(netdev))
                return NETDEV_TX_BUSY;