net: Add vxlan_gso_check() helper
authorJoe Stringer <joestringer@nicira.com>
Fri, 14 Nov 2014 00:38:12 +0000 (16:38 -0800)
committerDavid S. Miller <davem@davemloft.net>
Fri, 14 Nov 2014 22:12:48 +0000 (17:12 -0500)
Most NICs that report NETIF_F_GSO_UDP_TUNNEL support VXLAN, and not
other UDP-based encapsulation protocols where the format and size of the
header differs. This patch implements a generic ndo_gso_check() for
VXLAN which will only advertise GSO support when the skb looks like it
contains VXLAN (or no UDP tunnelling at all).

Implementation shamelessly stolen from Tom Herbert:
http://thread.gmane.org/gmane.linux.network/332428/focus=333111

Signed-off-by: Joe Stringer <joestringer@nicira.com>
Signed-off-by: David S. Miller <davem@davemloft.net>

No differences found