]> git.baikalelectronics.ru Git - kernel.git/commit
gre: build header correctly for collect metadata tunnels
authorJiri Benc <jbenc@redhat.com>
Wed, 27 Apr 2016 09:29:07 +0000 (11:29 +0200)
committerDavid S. Miller <davem@davemloft.net>
Thu, 28 Apr 2016 21:02:45 +0000 (17:02 -0400)
commita57ff1e352e7b5b41939509ccda4e1bdedacb28f
treef8745a471e54642e31bd682dc16eadc1b09ff568
parent7115dd04c1c5e947ac8348e4a0394c25c3ca01c2
gre: build header correctly for collect metadata tunnels

In ipgre (i.e. not gretap) + collect metadata mode, the skb was assumed to
contain Ethernet header and was encapsulated as ETH_P_TEB. This is not the
case, the interface is ARPHRD_IPGRE and the protocol to be used for
encapsulation is skb->protocol.

Fixes: 5a9e833d5d2a2 ("ip_gre: Add support to collect tunnel metadata.")
Signed-off-by: Jiri Benc <jbenc@redhat.com>
Acked-by: Pravin B Shelar <pshelar@ovn.org>
Reviewed-by: Simon Horman <simon.horman@netronome.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/ipv4/ip_gre.c