<feed xmlns='http://www.w3.org/2005/Atom'>
<title>delta/openvswitch.git/include/sparse/netinet, branch master</title>
<subtitle>github.com: openvswitch/ovs.git
</subtitle>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/openvswitch.git/'/>
<entry>
<title>userspace: Add SRv6 tunnel support.</title>
<updated>2023-03-29T20:16:04+00:00</updated>
<author>
<name>Nobuhiro MIKI</name>
<email>nmiki@yahoo-corp.jp</email>
</author>
<published>2023-03-29T05:51:17+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/openvswitch.git/commit/?id=03fc1ad78521544c7269355ec72fec8c2373b96d'/>
<id>03fc1ad78521544c7269355ec72fec8c2373b96d</id>
<content type='text'>
SRv6 (Segment Routing IPv6) tunnel vport is responsible
for encapsulation and decapsulation the inner packets with
IPv6 header and an extended header called SRH
(Segment Routing Header). See spec in:

https://datatracker.ietf.org/doc/html/rfc8754

This patch implements SRv6 tunneling in userspace datapath.
It uses `remote_ip` and `local_ip` options as with existing
tunnel protocols. It also adds a dedicated `srv6_segs` option
to define a sequence of routers called segment list.

Signed-off-by: Nobuhiro MIKI &lt;nmiki@yahoo-corp.jp&gt;
Signed-off-by: Ilya Maximets &lt;i.maximets@ovn.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
SRv6 (Segment Routing IPv6) tunnel vport is responsible
for encapsulation and decapsulation the inner packets with
IPv6 header and an extended header called SRH
(Segment Routing Header). See spec in:

https://datatracker.ietf.org/doc/html/rfc8754

This patch implements SRv6 tunneling in userspace datapath.
It uses `remote_ip` and `local_ip` options as with existing
tunnel protocols. It also adds a dedicated `srv6_segs` option
to define a sequence of routers called segment list.

Signed-off-by: Nobuhiro MIKI &lt;nmiki@yahoo-corp.jp&gt;
Signed-off-by: Ilya Maximets &lt;i.maximets@ovn.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>sparse: Add a guard for netinet/ip6.h header on FreeBSD.</title>
<updated>2022-10-06T19:58:16+00:00</updated>
<author>
<name>Ilya Maximets</name>
<email>i.maximets@ovn.org</email>
</author>
<published>2022-09-26T21:18:48+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/openvswitch.git/commit/?id=46606cb2d6089dc473025d681a45757343539c6b'/>
<id>46606cb2d6089dc473025d681a45757343539c6b</id>
<content type='text'>
Same as arpa/inet.h, the netinet/ip6.h on FreeBSD requires
netinet/in.h to be included first.  So, adding a similar guard.

Also fixing one instance where this is not respected at the moment.

We do have FreeBSD CI these days, but it is still nice to have
a more clear error message.

Fixes: b2befd5bb2db ("sparse: Add guards to prevent FreeBSD-incompatible #include order.")
Acked-by: Mike Pattrick &lt;mkp@redhat.com&gt;
Signed-off-by: Ilya Maximets &lt;i.maximets@ovn.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Same as arpa/inet.h, the netinet/ip6.h on FreeBSD requires
netinet/in.h to be included first.  So, adding a similar guard.

Also fixing one instance where this is not respected at the moment.

We do have FreeBSD CI these days, but it is still nice to have
a more clear error message.

Fixes: b2befd5bb2db ("sparse: Add guards to prevent FreeBSD-incompatible #include order.")
Acked-by: Mike Pattrick &lt;mkp@redhat.com&gt;
Signed-off-by: Ilya Maximets &lt;i.maximets@ovn.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>Userspace datapath: Add fragmentation handling.</title>
<updated>2019-02-14T22:18:56+00:00</updated>
<author>
<name>Darrell Ball</name>
<email>dlu998@gmail.com</email>
</author>
<published>2019-02-13T23:34:21+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/openvswitch.git/commit/?id=4ea96698f66792302b88b06c756862e24cc5b88e'/>
<id>4ea96698f66792302b88b06c756862e24cc5b88e</id>
<content type='text'>
Fragmentation handling is added for supporting conntrack.
Both v4 and v6 are supported.

After discussion with several people, I decided to not store
configuration state in the database to be more consistent with
the kernel in future, similarity with other conntrack configuration
which will not be in the database as well and overall simplicity.
Accordingly, fragmentation handling is enabled by default.

This patch enables fragmentation tests for the userspace datapath.

Signed-off-by: Darrell Ball &lt;dlu998@gmail.com&gt;
Signed-off-by: Ben Pfaff &lt;blp@ovn.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Fragmentation handling is added for supporting conntrack.
Both v4 and v6 are supported.

After discussion with several people, I decided to not store
configuration state in the database to be more consistent with
the kernel in future, similarity with other conntrack configuration
which will not be in the database as well and overall simplicity.
Accordingly, fragmentation handling is enabled by default.

This patch enables fragmentation tests for the userspace datapath.

Signed-off-by: Darrell Ball &lt;dlu998@gmail.com&gt;
Signed-off-by: Ben Pfaff &lt;blp@ovn.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>sparse: Make IN6_IS_ADDR_MC_LINKLOCAL and IN6_ARE_ADDR_EQUAL pickier.</title>
<updated>2018-07-11T15:28:33+00:00</updated>
<author>
<name>Ben Pfaff</name>
<email>blp@ovn.org</email>
</author>
<published>2018-07-10T16:27:18+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/openvswitch.git/commit/?id=0b9cf44914cbe959427124c7e24de575bac782e6'/>
<id>0b9cf44914cbe959427124c7e24de575bac782e6</id>
<content type='text'>
On GNU systems these macros work with arbitrary pointers, but the relevant
standards only require IN6_IS_ADDR_MC_LINKLOCAL to work with in6_addr (and
don't specify IN6_ARE_ADDR_EQUAL at all).  Make the "sparse"
implementations correspondingly pickier so that we catch any introduced
problems more quickly.

CC: Aaron Conole &lt;aconole@redhat.com&gt;
Signed-off-by: Ben Pfaff &lt;blp@ovn.org&gt;
Acked-by: Aaron Conole &lt;aconole@redhat.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
On GNU systems these macros work with arbitrary pointers, but the relevant
standards only require IN6_IS_ADDR_MC_LINKLOCAL to work with in6_addr (and
don't specify IN6_ARE_ADDR_EQUAL at all).  Make the "sparse"
implementations correspondingly pickier so that we catch any introduced
problems more quickly.

CC: Aaron Conole &lt;aconole@redhat.com&gt;
Signed-off-by: Ben Pfaff &lt;blp@ovn.org&gt;
Acked-by: Aaron Conole &lt;aconole@redhat.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>xlate: Move tnl_neigh_snoop() to terminate_native_tunnel()</title>
<updated>2018-04-18T23:38:26+00:00</updated>
<author>
<name>Zoltan Balogh</name>
<email>zoltan.balogh.eth@gmail.com</email>
</author>
<published>2018-04-04T21:57:54+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/openvswitch.git/commit/?id=83c2757bd16e86f6a2d5a69e94f890087e8df294'/>
<id>83c2757bd16e86f6a2d5a69e94f890087e8df294</id>
<content type='text'>
Currently OVS snoops any ARP or ND packets in any bridge and populates
the tunnel neighbor cache with the retreived data. For instance, when
an ARP reply originated by a tenant is received in an overlay bridge, the
ARP packet is snooped and tunnel neighbor cache is filled with tenant
address information. This is at best useless as tunnel endpoints can only
reside on an underlay bridge.

The real problem starts if different tenants on the overlay bridge have
overlapping IP addresses such that they keep overwriting each other's
pseudo tunnel neighbor entries. These frequent updates are treated as
configuration changes and trigger revalidation each time, thus causing
a lot of useless revalidation load on the system.

To keep the ARP neighbor cache clean, this patch moves tunnel neighbor
snooping from the generic function do_xlate_actions() to the specific
funtion terminate_native_tunnel() in compose_output_action(). Thus,
only ARP and Neighbor Advertisement packets addressing a local
tunnel endpoint (on the LOCAL port of the underlay bridge) are snooped.

In order to achieve this, IP addresses of the bridge ports are retrieved
and then stored in xbridge by calling xlate_xbridge_set(). The
destination address extracted from the ARP or Neighbor Advertisement
packet is then matched against the known xbridge addresses in
is_neighbor_reply_correct() to filter the snooped packets further.

Signed-off-by: Zoltan Balogh &lt;zoltan.balogh.eth@gmail.com&gt;
Co-authored-by: Jan Scheurich &lt;jan.scheurich@ericsson.com&gt;
Signed-off-by: Jan Scheurich &lt;jan.scheurich@ericsson.com&gt;
Signed-off-by: Ben Pfaff &lt;blp@ovn.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Currently OVS snoops any ARP or ND packets in any bridge and populates
the tunnel neighbor cache with the retreived data. For instance, when
an ARP reply originated by a tenant is received in an overlay bridge, the
ARP packet is snooped and tunnel neighbor cache is filled with tenant
address information. This is at best useless as tunnel endpoints can only
reside on an underlay bridge.

The real problem starts if different tenants on the overlay bridge have
overlapping IP addresses such that they keep overwriting each other's
pseudo tunnel neighbor entries. These frequent updates are treated as
configuration changes and trigger revalidation each time, thus causing
a lot of useless revalidation load on the system.

To keep the ARP neighbor cache clean, this patch moves tunnel neighbor
snooping from the generic function do_xlate_actions() to the specific
funtion terminate_native_tunnel() in compose_output_action(). Thus,
only ARP and Neighbor Advertisement packets addressing a local
tunnel endpoint (on the LOCAL port of the underlay bridge) are snooped.

In order to achieve this, IP addresses of the bridge ports are retrieved
and then stored in xbridge by calling xlate_xbridge_set(). The
destination address extracted from the ARP or Neighbor Advertisement
packet is then matched against the known xbridge addresses in
is_neighbor_reply_correct() to filter the snooped packets further.

Signed-off-by: Zoltan Balogh &lt;zoltan.balogh.eth@gmail.com&gt;
Co-authored-by: Jan Scheurich &lt;jan.scheurich@ericsson.com&gt;
Signed-off-by: Jan Scheurich &lt;jan.scheurich@ericsson.com&gt;
Signed-off-by: Ben Pfaff &lt;blp@ovn.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>sparse: Add guards to prevent FreeBSD-incompatible #include order.</title>
<updated>2017-12-22T20:58:02+00:00</updated>
<author>
<name>Ben Pfaff</name>
<email>blp@ovn.org</email>
</author>
<published>2017-11-06T22:42:32+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/openvswitch.git/commit/?id=b2befd5bb2db811ac0273bc52be158d3476a5ff7'/>
<id>b2befd5bb2db811ac0273bc52be158d3476a5ff7</id>
<content type='text'>
FreeBSD insists that &lt;sys/types.h&gt; be included before &lt;netinet/in.h&gt; and
that &lt;netinet/in.h&gt; be included before &lt;arpa/inet.h&gt;.  This adds guards to
the "sparse" headers to yield a warning if this order is violated.  This
commit also adjusts the order of many #includes to suit this requirement.

Signed-off-by: Ben Pfaff &lt;blp@ovn.org&gt;
Acked-by: Justin Pettit &lt;jpettit@ovn.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
FreeBSD insists that &lt;sys/types.h&gt; be included before &lt;netinet/in.h&gt; and
that &lt;netinet/in.h&gt; be included before &lt;arpa/inet.h&gt;.  This adds guards to
the "sparse" headers to yield a warning if this order is violated.  This
commit also adjusts the order of many #includes to suit this requirement.

Signed-off-by: Ben Pfaff &lt;blp@ovn.org&gt;
Acked-by: Justin Pettit &lt;jpettit@ovn.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>Userspace Datapath: Add TFTP support.</title>
<updated>2017-08-07T18:17:42+00:00</updated>
<author>
<name>Darrell Ball</name>
<email>dlu998@gmail.com</email>
</author>
<published>2017-08-06T17:51:15+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/openvswitch.git/commit/?id=7be77cb0d3378a71a18b0d1d0f3513da16f071c6'/>
<id>7be77cb0d3378a71a18b0d1d0f3513da16f071c6</id>
<content type='text'>
Both ipv4 and ipv6 are supported. Also, NAT support is included.

Signed-off-by: Darrell Ball &lt;dlu998@gmail.com&gt;
Signed-off-by: Ben Pfaff &lt;blp@ovn.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Both ipv4 and ipv6 are supported. Also, NAT support is included.

Signed-off-by: Darrell Ball &lt;dlu998@gmail.com&gt;
Signed-off-by: Ben Pfaff &lt;blp@ovn.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>sparse: Fix conflict between netinet/in.h and linux/in.h</title>
<updated>2016-06-08T20:39:43+00:00</updated>
<author>
<name>Daniele Di Proietto</name>
<email>diproiettod@vmware.com</email>
</author>
<published>2016-06-02T01:35:55+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/openvswitch.git/commit/?id=c663749d398fa1cd2ea5ad9ff96996c4356c3db6'/>
<id>c663749d398fa1cd2ea5ad9ff96996c4356c3db6</id>
<content type='text'>
linux/in.h (from linux uapi headers) carries many of the same
definitions as netinet/in.h (from glibc).

If linux/in.h is included after netinet/in.h, conflicts are avoided in
two ways:

1) linux/libc-compat.h (included by linux/in.h) detects the include
   guard of netinet/in.h and defines some macros (e.g.
   __UAPI_DEF_IN_IPPROTO) to 0.  linux/in.h avoids exporting the same
   enums if those macros are 0.

2) The two files are allowed to redefine the same macros as long as the
   values are the same.

Our include/sparse/netinet/in.h creates problems, because:

1) It uses a custom include guard
2) It uses dummy values for some macros.

This commit changes include/sparse/netinet/in.h to use the same include
guard as glibc netinet/in.h, and to use the same values for some macros.

I think this problem is present with linux headers after
a263653ed798("netfilter: don't pull include/linux/netfilter.h from netns
headers") which cause our lib/netlink-conntrack.c to include linux/in.h
after netinet/in.h.

sample output from sparse:

/usr/include/linux/in.h:29:9: warning: preprocessor token IPPROTO_IP
redefined
../include/sparse/netinet/in.h:60:9: this was the original definition
/usr/include/linux/in.h:31:9: warning: preprocessor token IPPROTO_ICMP
redefined
../include/sparse/netinet/in.h:63:9: this was the original definition
[...]
/usr/include/linux/in.h:28:3: error: bad enum definition
/usr/include/linux/in.h:28:3: error: Expected } at end of specifier
/usr/include/linux/in.h:28:3: error: got 0
/usr/include/linux/in.h:84:16: error: redefinition of struct in_addr

Signed-off-by: Daniele Di Proietto &lt;diproiettod@vmware.com&gt;
Tested-by: Joe Stringer &lt;joe@ovn.org&gt;
Acked-by: Ben Pfaff &lt;blp@ovn.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
linux/in.h (from linux uapi headers) carries many of the same
definitions as netinet/in.h (from glibc).

If linux/in.h is included after netinet/in.h, conflicts are avoided in
two ways:

1) linux/libc-compat.h (included by linux/in.h) detects the include
   guard of netinet/in.h and defines some macros (e.g.
   __UAPI_DEF_IN_IPPROTO) to 0.  linux/in.h avoids exporting the same
   enums if those macros are 0.

2) The two files are allowed to redefine the same macros as long as the
   values are the same.

Our include/sparse/netinet/in.h creates problems, because:

1) It uses a custom include guard
2) It uses dummy values for some macros.

This commit changes include/sparse/netinet/in.h to use the same include
guard as glibc netinet/in.h, and to use the same values for some macros.

I think this problem is present with linux headers after
a263653ed798("netfilter: don't pull include/linux/netfilter.h from netns
headers") which cause our lib/netlink-conntrack.c to include linux/in.h
after netinet/in.h.

sample output from sparse:

/usr/include/linux/in.h:29:9: warning: preprocessor token IPPROTO_IP
redefined
../include/sparse/netinet/in.h:60:9: this was the original definition
/usr/include/linux/in.h:31:9: warning: preprocessor token IPPROTO_ICMP
redefined
../include/sparse/netinet/in.h:63:9: this was the original definition
[...]
/usr/include/linux/in.h:28:3: error: bad enum definition
/usr/include/linux/in.h:28:3: error: Expected } at end of specifier
/usr/include/linux/in.h:28:3: error: got 0
/usr/include/linux/in.h:84:16: error: redefinition of struct in_addr

Signed-off-by: Daniele Di Proietto &lt;diproiettod@vmware.com&gt;
Tested-by: Joe Stringer &lt;joe@ovn.org&gt;
Acked-by: Ben Pfaff &lt;blp@ovn.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>sparse: Define INET_ADDRSTRLEN.</title>
<updated>2015-12-16T02:00:10+00:00</updated>
<author>
<name>Ben Pfaff</name>
<email>blp@ovn.org</email>
</author>
<published>2015-12-03T02:04:35+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/openvswitch.git/commit/?id=1f632fff5e88abe28f9a8642c318d8927e51ea1e'/>
<id>1f632fff5e88abe28f9a8642c318d8927e51ea1e</id>
<content type='text'>
POSIX defines this but it was missing from the OVS header file definitions
for "sparse".

Signed-off-by: Ben Pfaff &lt;blp@ovn.org&gt;
Acked-by: Justin Pettit &lt;jpettit@ovn.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
POSIX defines this but it was missing from the OVS header file definitions
for "sparse".

Signed-off-by: Ben Pfaff &lt;blp@ovn.org&gt;
Acked-by: Justin Pettit &lt;jpettit@ovn.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>Add support for connection tracking helper/ALGs.</title>
<updated>2015-10-13T22:34:16+00:00</updated>
<author>
<name>Joe Stringer</name>
<email>joestringer@nicira.com</email>
</author>
<published>2015-09-15T21:29:16+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/openvswitch.git/commit/?id=d787ad39b8eb8fb9136837e1c65d0a18a1056eda'/>
<id>d787ad39b8eb8fb9136837e1c65d0a18a1056eda</id>
<content type='text'>
This patch adds support for specifying a "helper" or ALG to assist
connection tracking for protocols that consist of multiple streams.
Initially, only support for FTP is included.

Below is an example set of flows to allow FTP control connections from
port 1-&gt;2 to establish active data connections in the reverse direction:

    table=0,priority=1,action=drop
    table=0,arp,action=normal
    table=0,in_port=1,tcp,action=ct(alg=ftp,commit),2
    table=0,in_port=2,tcp,ct_state=-trk,action=ct(table=1)
    table=1,in_port=2,tcp,ct_state=+trk+est,action=1
    table=1,in_port=2,tcp,ct_state=+trk+rel,action=ct(commit),1

Signed-off-by: Joe Stringer &lt;joestringer@nicira.com&gt;
Acked-by: Jarno Rajahalme &lt;jrajahalme@nicira.com&gt;
Acked-by: Ben Pfaff &lt;blp@nicira.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This patch adds support for specifying a "helper" or ALG to assist
connection tracking for protocols that consist of multiple streams.
Initially, only support for FTP is included.

Below is an example set of flows to allow FTP control connections from
port 1-&gt;2 to establish active data connections in the reverse direction:

    table=0,priority=1,action=drop
    table=0,arp,action=normal
    table=0,in_port=1,tcp,action=ct(alg=ftp,commit),2
    table=0,in_port=2,tcp,ct_state=-trk,action=ct(table=1)
    table=1,in_port=2,tcp,ct_state=+trk+est,action=1
    table=1,in_port=2,tcp,ct_state=+trk+rel,action=ct(commit),1

Signed-off-by: Joe Stringer &lt;joestringer@nicira.com&gt;
Acked-by: Jarno Rajahalme &lt;jrajahalme@nicira.com&gt;
Acked-by: Ben Pfaff &lt;blp@nicira.com&gt;
</pre>
</div>
</content>
</entry>
</feed>
