vxlan: add unlikely to vxlan_remcsum check

small optimization around checking as it's being done in all
receptions

Signed-off-by: Fabian Frederick <fabf@skynet.be>
Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
Fabian Frederick 2020-09-25 15:16:18 +02:00 committed by David S. Miller
parent 2ae2904b5b
commit 0189399cbb
1 changed files with 1 additions and 1 deletions

View File

@ -1876,7 +1876,7 @@ static int vxlan_rcv(struct sock *sk, struct sk_buff *skb)
goto drop;
if (vs->flags & VXLAN_F_REMCSUM_RX)
if (!vxlan_remcsum(&unparsed, skb, vs->flags))
if (unlikely(!vxlan_remcsum(&unparsed, skb, vs->flags)))
goto drop;
if (vxlan_collect_metadata(vs)) {