Take a look at netdev_tnl_ip_build_header(…), for example.

From: <[email protected]> on behalf of Ranjith Kumar D 
<[email protected]>
Date: Monday, September 25, 2017 at 11:37 PM
To: "[email protected]" <[email protected]>
Subject: [ovs-discuss] IPv4 address support for port configuration in OVS 2.8.0 
version

Hello All,

I had recently downloaded the OVS 2.8.0 version code and was performing the 
code walkthrough for ovs-vsctl command handling for adding port to bridge. I 
see that structures related to port configuration takes only IPv6 address. 
Hence kindly let me know whether we will be able to set the interface of a port 
in a bridge with IPv4 remote and local IP.


ovs-vsctl set interface <bridge:pdn-port> type=gre/rte  
option:remote_ip=172.20.1.1 option:local_ip=172.24.1.0

Code snippet under concern is

OVS 2.4 version
----------------------
/* Configuration specific to tunnels. */
struct netdev_tunnel_config {
    bool in_key_present;
    bool in_key_flow;
    ovs_be64 in_key;

    bool out_key_present;
    bool out_key_flow;
    ovs_be64 out_key;

    ovs_be16 dst_port;

    bool ip_src_flow;
    bool ip_dst_flow;
    ovs_be32 ip_src;
    ovs_be32 ip_dst;

    uint32_t exts;

    uint8_t ttl;
    bool ttl_inherit;

    uint8_t tos;
    bool tos_inherit;

    bool csum;
    bool ipsec;
    bool dont_fragment;
};



OVS 2.8 Version
----------------------
* Configuration specific to tunnels. */
struct netdev_tunnel_config {
    bool in_key_present;
    bool in_key_flow;
    ovs_be64 in_key;

    bool out_key_present;
    bool out_key_flow;
    ovs_be64 out_key;

    ovs_be16 dst_port;

    bool ip_src_flow;
    bool ip_dst_flow;
    struct in6_addr ipv6_src;
    struct in6_addr ipv6_dst;

    uint32_t exts;
    bool set_egress_pkt_mark;
    uint32_t egress_pkt_mark;

    uint8_t ttl;
    bool ttl_inherit;

    uint8_t tos;
    bool tos_inherit;

    bool csum;
    bool dont_fragment;
    enum netdev_pt_mode pt_mode;
};

Regards,
Ranjith
_______________________________________________
discuss mailing list
[email protected]
https://mail.openvswitch.org/mailman/listinfo/ovs-discuss

Reply via email to