diff options
author | Christophe JAILLET <christophe.jaillet@wanadoo.fr> | 2021-04-04 09:11:03 +0200 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2021-04-04 10:43:02 +0200 |
commit | 7d42e84eb99daf9b7feef37e8f2ea1eaf975346b (patch) | |
tree | a1c4c52998a03949aab068aaf071e2e98b6a69ca /net/openvswitch/vport-netdev.c | |
parent | Merge tag 'mlx5-updates-2021-04-02' of git://git.kernel.org/pub/scm/linux/ker... (diff) | |
download | linux-7d42e84eb99daf9b7feef37e8f2ea1eaf975346b.tar.xz linux-7d42e84eb99daf9b7feef37e8f2ea1eaf975346b.zip |
net: openvswitch: Use 'skb_push_rcsum()' instead of hand coding it
'skb_push()'/'skb_postpush_rcsum()' can be replaced by an equivalent
'skb_push_rcsum()' which is less verbose.
Signed-off-by: Christophe JAILLET <christophe.jaillet@wanadoo.fr>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/openvswitch/vport-netdev.c')
-rw-r--r-- | net/openvswitch/vport-netdev.c | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/net/openvswitch/vport-netdev.c b/net/openvswitch/vport-netdev.c index 57d6436e6f6a..8e1a88f13622 100644 --- a/net/openvswitch/vport-netdev.c +++ b/net/openvswitch/vport-netdev.c @@ -44,10 +44,9 @@ static void netdev_port_receive(struct sk_buff *skb) if (unlikely(!skb)) return; - if (skb->dev->type == ARPHRD_ETHER) { - skb_push(skb, ETH_HLEN); - skb_postpush_rcsum(skb, skb->data, ETH_HLEN); - } + if (skb->dev->type == ARPHRD_ETHER) + skb_push_rcsum(skb, ETH_HLEN); + ovs_vport_receive(vport, skb, skb_tunnel_info(skb)); return; error: |