net: alteon: acenic: remove redundant pointer rxdesc
authorColin Ian King <colin.king@canonical.com>
Wed, 4 Jul 2018 07:01:35 +0000 (08:01 +0100)
committerDavid S. Miller <davem@davemloft.net>
Wed, 4 Jul 2018 13:39:10 +0000 (22:39 +0900)
Pointer rxdesc is being assigned but is never used hence it is
redundant and can be removed.

Cleans up clang warning:
warning: variable 'rxdesc' set but not used [-Wunused-but-set-variable]

Signed-off-by: Colin Ian King <colin.king@canonical.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/alteon/acenic.c

index 8f71b79b494900fa4c03564e4f88ded8aa8831c5..08945baee48ad45df9f4bbf83afebbe0ab15607c 100644 (file)
@@ -1933,7 +1933,7 @@ static void ace_rx_int(struct net_device *dev, u32 rxretprd, u32 rxretcsm)
        while (idx != rxretprd) {
                struct ring_info *rip;
                struct sk_buff *skb;
-               struct rx_desc *rxdesc, *retdesc;
+               struct rx_desc *retdesc;
                u32 skbidx;
                int bd_flags, desc_type, mapsize;
                u16 csum;
@@ -1959,19 +1959,16 @@ static void ace_rx_int(struct net_device *dev, u32 rxretprd, u32 rxretcsm)
                case 0:
                        rip = &ap->skb->rx_std_skbuff[skbidx];
                        mapsize = ACE_STD_BUFSIZE;
-                       rxdesc = &ap->rx_std_ring[skbidx];
                        std_count++;
                        break;
                case BD_FLG_JUMBO:
                        rip = &ap->skb->rx_jumbo_skbuff[skbidx];
                        mapsize = ACE_JUMBO_BUFSIZE;
-                       rxdesc = &ap->rx_jumbo_ring[skbidx];
                        atomic_dec(&ap->cur_jumbo_bufs);
                        break;
                case BD_FLG_MINI:
                        rip = &ap->skb->rx_mini_skbuff[skbidx];
                        mapsize = ACE_MINI_BUFSIZE;
-                       rxdesc = &ap->rx_mini_ring[skbidx];
                        mini_count++;
                        break;
                default: