net: ip_gre: use erspan key field for tunnel lookup
authorLorenzo Bianconi <lorenzo.bianconi@redhat.com>
Fri, 18 Jan 2019 11:05:39 +0000 (12:05 +0100)
committerDavid S. Miller <davem@davemloft.net>
Tue, 22 Jan 2019 19:52:17 +0000 (11:52 -0800)
commitcb73ee40b1b381eaf3749e6dbeed567bb38e5258
tree4a46c80cac3f7bb0f044f1cbf2d73a66129a9456
parent56cb4e5034998b5522a657957321ca64ca2ea0a0
net: ip_gre: use erspan key field for tunnel lookup

Use ERSPAN key header field as tunnel key in gre_parse_header routine
since ERSPAN protocol sets the key field of the external GRE header to
0 resulting in a tunnel lookup fail in ip6gre_err.
In addition remove key field parsing and pskb_may_pull check in
erspan_rcv and ip6erspan_rcv

Fixes: 5a963eb61b7c ("ip6_gre: Add ERSPAN native tunnel support")
Signed-off-by: Lorenzo Bianconi <lorenzo.bianconi@redhat.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/ipv4/gre_demux.c
net/ipv4/ip_gre.c
net/ipv6/ip6_gre.c