diff options
author | Pravin B Shelar <pshelar@nicira.com> | 2012-10-09 16:08:39 -0700 |
---|---|---|
committer | Pravin B Shelar <pshelar@nicira.com> | 2012-10-09 16:08:39 -0700 |
commit | 685c931cff7c2f212dd82118ad1d97ccfc3a708d (patch) | |
tree | 69c3918f09cce00051283368cef5e0b897bbe1d7 /datapath/vport-gre.c | |
parent | 361906b1e2c6482d77280f345d3e42048d8c2700 (diff) | |
download | openvswitch-685c931cff7c2f212dd82118ad1d97ccfc3a708d.tar.gz |
datapath: Fix GRE tunnel without any key.
Commit 2de795adb96 (datapath: 64-bit GRE support) introduced a bug
for tunnels with no key. Following patch fixes it by setting tunnel
type to GRE type.
Bugs: 13511
Signed-off-by: Pravin B Shelar <pshelar@nicira.com>
Acked-by: Kyle Mestery <kmestery@cisco.com>
Diffstat (limited to 'datapath/vport-gre.c')
-rw-r--r-- | datapath/vport-gre.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/datapath/vport-gre.c b/datapath/vport-gre.c index 6f406bc9c..4000c749b 100644 --- a/datapath/vport-gre.c +++ b/datapath/vport-gre.c @@ -202,8 +202,11 @@ static int parse_header(struct iphdr *iph, __be16 *flags, __be64 *tun_id, *tunnel_type = TNL_T_PROTO_GRE; } *tun_id = key_to_tunnel_id(gre_key, seq); - } else + } else { *tun_id = 0; + /* Ignore GRE seq if there is no key present. */ + *tunnel_type = TNL_T_PROTO_GRE; + } if (greh->flags & GRE_SEQ) hdr_len += GRE_HEADER_SECTION; |