]> git.baikalelectronics.ru Git - kernel.git/commit
net: Fix GRE RX to use skb_transport_header for GRE header offset
authorTom Herbert <therbert@google.com>
Mon, 8 Sep 2014 15:29:12 +0000 (08:29 -0700)
committerDavid S. Miller <davem@davemloft.net>
Mon, 8 Sep 2014 22:23:05 +0000 (15:23 -0700)
commit46a4c4b6c6d42413c7f8780a8afbe88acdc83659
treeffd2de95a203e68a1f070e80955738f1006dd826
parent2ea4cd89e0c25bdd72d7b133026740a6752a3a6f
net: Fix GRE RX to use skb_transport_header for GRE header offset

GRE assumes that the GRE header is at skb_network_header +
ip_hrdlen(skb). It is more general to use skb_transport_header
and this allows the possbility of inserting additional header
between IP and GRE (which is what we will done in Generic UDP
Encapsulation for GRE).

Signed-off-by: Tom Herbert <therbert@google.com>
Acked-by: Eric Dumazet <edumazet@google.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/ipv4/gre_demux.c