qede: use reset to set network header
authorZhang Shengju <zhangshengju@cmss.chinamobile.com>
Fri, 2 Dec 2016 01:51:03 +0000 (09:51 +0800)
committerDavid S. Miller <davem@davemloft.net>
Sat, 3 Dec 2016 20:49:16 +0000 (15:49 -0500)
Since offset is zero, it's not necessary to use set function. Reset
function is straightforward, and will remove the unnecessary add
operation in set function.

Signed-off-by: Zhang Shengju <zhangshengju@cmss.chinamobile.com>
Acked-by: Yuval Mintz <Yuval.Mintz@cavium.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/qlogic/qede/qede_main.c

index faeaa9f3b197b58422f4d0308230f95e328ea0fb..cf1dd1436d939b337100b36a5ce8c04a75f919d2 100644 (file)
@@ -1312,7 +1312,7 @@ static void qede_gro_receive(struct qede_dev *edev,
 
 #ifdef CONFIG_INET
        if (skb_shinfo(skb)->gso_size) {
-               skb_set_network_header(skb, 0);
+               skb_reset_network_header(skb);
 
                switch (skb->protocol) {
                case htons(ETH_P_IP):