From: Or Gerlitz <[email protected]>

Upstream commit:
    net/openvswitch: Set the ipv6 source tunnel key address attribute correctly

    When dealing with ipv6 source tunnel key address attribute
    (OVS_TUNNEL_KEY_ATTR_IPV6_SRC) we are wrongly setting the tunnel
    dst ip, fix that.

    Fixes: 6b26ba3a7d95 ('openvswitch: netlink attributes for IPv6 tunneling')
    Signed-off-by: Or Gerlitz <[email protected]>
    Reported-by: Paul Blakey <[email protected]>
    Acked-by: Jiri Benc <[email protected]>
    Acked-by: Joe Stringer <[email protected]>
    Signed-off-by: David S. Miller <[email protected]>

Upstream: 3d20f1f7bd575 ("net/openvswitch: Set the ipv6 source tunnel key 
address attribute correctly")

Fixes: 8a2d4905a00f ("datapath: Add support for IPv6 tunnels.")

Signed-off-by: Andy Zhou <[email protected]>
Acked-by: Joe Stringer <[email protected]>

---
v1->v2:  Add OVS tree fixes mesasge to commit message.
         Need to backport to 2.6+
---
 AUTHORS.rst             | 1 +
 datapath/flow_netlink.c | 2 +-
 2 files changed, 2 insertions(+), 1 deletion(-)

diff --git a/AUTHORS.rst b/AUTHORS.rst
index bbe5b363ed9b..36df68b270e6 100644
--- a/AUTHORS.rst
+++ b/AUTHORS.rst
@@ -226,6 +226,7 @@ Nithin Raju                     [email protected]
 Niti Rohilla                    [email protected]
 Numan Siddique                  [email protected]
 Ofer Ben-Yacov                  [email protected]
+Or Gerlitz                      [email protected]
 Ori Shoshan                     [email protected]
 Padmanabhan Krishnan            [email protected]
 Panu Matilainen                 [email protected]
diff --git a/datapath/flow_netlink.c b/datapath/flow_netlink.c
index e2b17fb935ab..e31852ebb421 100644
--- a/datapath/flow_netlink.c
+++ b/datapath/flow_netlink.c
@@ -606,7 +606,7 @@ static int ip_tun_from_nlattr(const struct nlattr *attr,
                        ipv4 = true;
                        break;
                case OVS_TUNNEL_KEY_ATTR_IPV6_SRC:
-                       SW_FLOW_KEY_PUT(match, tun_key.u.ipv6.dst,
+                       SW_FLOW_KEY_PUT(match, tun_key.u.ipv6.src,
                                        nla_get_in6_addr(a), is_mask);
                        ipv6 = true;
                        break;
-- 
1.8.3.1

_______________________________________________
dev mailing list
[email protected]
https://mail.openvswitch.org/mailman/listinfo/ovs-dev

Reply via email to