netdev-dpdk: Do not add vhost-user ports with '/' or '\' in name.
This check prevents an obvious way for a vhost-user socket to escape the
intended directory.
There might be other ways to escape the directory (none comes to mind at
the moment), but this is a problem that should be properly solved by
mandatory access control.
A similar check is done for a bridge name, since that name is used as
part of a socket as well.
Signed-off-by: Daniele Di Proietto <diproiettod@vmware.com> Acked-by: Flavio Leitner <fbl@sysclose.org>
Mauricio Vásquez [Tue, 23 Feb 2016 22:06:38 +0000 (23:06 +0100)]
tests/dpdk/ring_client: extend range of supported dpdkr ports
Current implementation of the ring_client test only supports until the
dpdkr255 port, this patch extends it to support the full range of possible
dpdkr ports.
Signed-off-by: Mauricio Vasquez B <mauricio.vasquezbernal@studenti.polito.it> Signed-off-by: Daniele Di Proietto <diproiettod@vmware.com>
Lance Richardson [Mon, 15 Feb 2016 15:08:51 +0000 (10:08 -0500)]
lib: Fix netbsd compilation error.
NetBSD requires <netinet/in.h> to be included before <netinit/ip6.h>.
Without this fix we have:
In file included from lib/netdev-vport.c:25:0:
/usr/include/netinet/ip6.h:82:18: error: field 'ip6_src' has incomplete type
/usr/include/netinet/ip6.h:83:18: error: field 'ip6_dst' has incomplete type
Signed-off-by: Lance Richardson <lrichard@redhat.com> Signed-off-by: Ben Pfaff <blp@ovn.org>
ofproto-dpif-xlate: Fix crash when using multicast snooping.
The revalidator thread may set may_learn and call xlate_actions with no packet
data. If the revalidated flow is IGMPv3 or MLD, vswitchd will crash when trying
to access the NULL packet.
Only process IGMP and MLD flows when there is a packet. This is a similar
behavior than what we have for other special packets.
Signed-off-by: Thadeu Lima de Souza Cascardo <cascardo@redhat.com> Reported-by: Yi Ba <yby.developer@yahoo.com>
Reported-at: http://openvswitch.org/pipermail/discuss/2016-January/020023.html Fixes: 06994f879c9d ("mcast-snooping: Add Multicast Listener Discovery support") Signed-off-by: Ben Pfaff <blp@ovn.org>
Ilya Maximets [Mon, 8 Feb 2016 15:30:29 +0000 (18:30 +0300)]
dpif-netdev: Reload each thread only once in do_add_port.
While adding of pmd interface with multiple queues several queues
may be assigned to one thread and this thread will be reloaded
one time for each added queue.
Alin Serdean [Thu, 11 Feb 2016 03:09:32 +0000 (03:09 +0000)]
build-windows: Enable parallel jobs for msbuild
This patch enables parallel build from the command line.
If vstudio_config is defined change from:
make ovsext_make to make ovsext and also update the dependecy for it,
since the project requires OvsDpInterface.h to be built.
Signed-off-by: Alin Gabriel Serdean <aserdean@cloudbasesolutions.com> Acked-by: Sairam Venugopal <vsairam@vmware.com> Signed-off-by: Ben Pfaff <blp@ovn.org>
Russell Bryant [Fri, 18 Dec 2015 13:33:30 +0000 (08:33 -0500)]
ovsdb.at: Run Python tests for Python 2 and 3.
ovsdb.at includes some macros for running some identical test cases for
both C and Python. Update these macros to run the test case for both
Python 2 and 3. Retain the existing behavior for the direct use of the
_PY versions of these macros to only run against Python 2 without any
changes needed.
Signed-off-by: Russell Bryant <russell@ovn.org> Acked-by: Ben Pfaff <blp@ovn.org>
Russell Bryant [Fri, 18 Dec 2015 00:58:33 +0000 (19:58 -0500)]
configure: Check for presence of Python 3.
The configure script already checked for Python 2 (>=2.7). Add another
check for Python 3 (>=3.4). This will be used later for automatically
running tests with Python 3 as well if available.
Signed-off-by: Russell Bryant <russell@ovn.org> Acked-by: Ben Pfaff <blp@ovn.org>
Russell Bryant [Thu, 17 Dec 2015 17:22:31 +0000 (12:22 -0500)]
tests: Deal with Python output differences.
This test checks the output based on Python's string representation of
an array of two unicode strings. These strings have a "u" prefix in
Python 2, but not Python 3. In Python 3, all strings are unicode.
Use sed on the output to strip the "u" from Python 2 output when
checking for the expected result.
Signed-off-by: Russell Bryant <russell@ovn.org> Acked-by: Ben Pfaff <blp@ovn.org>
William Tu [Thu, 18 Feb 2016 02:00:22 +0000 (18:00 -0800)]
gcc: Fix compile errors due to anonymous union initilization.
gcc 4.4.7 lets you initialize named fields, and assign to anonymous union members,
but cannot statically initialize a named member of an anonymous union. This causes
errors when doing make:
fproto/fail-open.c: In function ‘send_bogus_packet_ins’:
ofproto/fail-open.c:130: error: unknown field ‘pin’ specified in initializer
ofproto/fail-open.c:131: error: unknown field ‘up’ specified in initializer
ofproto/fail-open.c:132: error: unknown field ‘packet’ specified in initializer
ofproto/fail-open.c:132: warning: missing braces around initializer
ofproto/fail-open.c:132: warning: (near initialization for ‘am.<anonymous>.pin.up’)
ofproto/fail-open.c:134: error: extra brace group at end of initializer
Examaple: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=42875
We can either assign a name to the union or, in this patch, remove the unnecessary union.
Signed-off-by: William Tu <u9012063@gmail.com> Signed-off-by: Ben Pfaff <blp@ovn.org>
Ben Pfaff [Tue, 16 Feb 2016 19:13:35 +0000 (11:13 -0800)]
tests: Better tolerate file system restriction on file name length.
ecryptfs on Linux restricts file names to 143 bytes, but these two tests
used a 150-byte name. This commit fixes the specific problem on ecryptfs
by reducing the name it test to 143 bytes. It also fixes the more general
problem of name length restrictions by skipping the test, rather than
failing it, if a directory with the 143-byte name cannot be created, since
the most likely problem is that the name is too long for the file system.
Reported-by: Zoltán Balogh <zoltan.balogh@ericsson.com> Signed-off-by: Ben Pfaff <blp@ovn.org>
Ben Pfaff [Tue, 9 Feb 2016 00:52:45 +0000 (16:52 -0800)]
hmap: Add extra build-time iteration checks for types derived from hmap.
Some of our data structures derived from hmap use the same member names.
This means it's possible to confuse them in iteration, e.g. to iterate a
shash with SIMAP_FOR_EACH. Of course this will crash at runtime, but it
seems even better to catch it at compile time.
An alternative would be to use unique member names, e.g. shash_map and
simap_map instead of just map. I like short names, though.
It's kind of nasty that we need support from the hmap code to do this.
An alternative would be to insert the build assertions as statements before
the for loop. But that would cause nasty surprises if someone forgets the
{} around a block of statements; even though the OVS coding style requires
them in all cases, I suspect that programmers doing debugging, etc. tend
to omit them sometimes.
It's not actually necessary to have multiple variants of these macros,
e.g. one can write a C99-compliant HMAP_FOR_EACH that accepts 3 or 4 or
more arguments. But such a macro is harder to read, so I don't know
whether this is a good tradeoff.
Signed-off-by: Ben Pfaff <blp@ovn.org> Acked-by: Andy Zhou <azhou@ovn.org>
Ben Pfaff [Thu, 18 Feb 2016 18:12:04 +0000 (10:12 -0800)]
ofp-actions: Introduce macro for padding struct members.
An upcoming commit will add another case where it's desirable to ensure
that a variable-length array is aligned on an 8-byte boundary. This macro
makes that a little easier.
Signed-off-by: Ben Pfaff <blp@ovn.org> CC: Joe Stringer <joe@ovn.org> Acked-by: Joe Stringer <joe@ovn.org>
Ben Pfaff [Sat, 20 Feb 2016 00:10:06 +0000 (16:10 -0800)]
Implement serializing the state of packet traversal in "continuations".
One purpose of OpenFlow packet-in messages is to allow a controller to
interpose on the path of a packet through the flow tables. If, for
example, the controller needs to modify a packet in some way that the
switch doesn't directly support, the controller should be able to
program the switch to send it the packet, then modify the packet and
send it back to the switch to continue through the flow table.
That's the theory. In practice, this doesn't work with any but the
simplest flow tables. Packet-in messages simply don't include enough
context to allow the flow table traversal to continue. For example:
* Via "resubmit" actions, an Open vSwitch packet can have an
effective "call stack", but a packet-in can't describe it, and
so it would be lost.
* A packet-in can't preserve the stack used by NXAST_PUSH and
NXAST_POP actions.
* A packet-in can't preserve the OpenFlow 1.1+ action set.
* A packet-in can't preserve the state of Open vSwitch mirroring
or connection tracking.
This commit introduces a solution called "continuations". A continuation
is the state of a packet's traversal through OpenFlow flow tables. A
"controller" action with the "pause" flag, which is newly implemented in
this commit, generates a continuation and sends it to the OpenFlow
controller in a packet-in asynchronous message (only NXT_PACKET_IN2
supports continuations, so the controller must configure them with
NXT_SET_PACKET_IN_FORMAT). The controller processes the packet-in,
possibly modifying some of its data, and sends it back to the switch with
an NXT_RESUME request, which causes flow table traversal to continue. In
principle, a single packet can be paused and resumed multiple times.
Another way to look at it is:
- "pause" is an extension of the existing OFPAT_CONTROLLER
action. It sends the packet to the controller, with full
pipeline context (some of which is switch implementation
dependent, and may thus vary from switch to switch).
- A continuation is an extension of OFPT_PACKET_IN, allowing for
implementation dependent metadata.
- NXT_RESUME is an extension of OFPT_PACKET_OUT, with the
semantics that the pipeline processing is continued with the
original translation context from where it was left at the time
it was paused.
Signed-off-by: Ben Pfaff <blp@ovn.org> Acked-by: Jarno Rajahalme <jarno@ovn.org>
Ben Pfaff [Fri, 19 Feb 2016 23:56:52 +0000 (15:56 -0800)]
ofp-prop: Add support for putting and parsing nested properties.
It hadn't occurred to me before that any special support was actually
necessary or useful for nested properties, but the functions introduced in
this commit are nice wrappers to deal with the extra 4-byte padding that
ensures that the nested properties begin on 8-byte boundaries just like
the outer properties.
Signed-off-by: Ben Pfaff <blp@ovn.org> Acked-by: Jarno Rajahalme <jarno@ovn.org>
Ben Pfaff [Thu, 18 Feb 2016 23:13:09 +0000 (15:13 -0800)]
ofpbuf: New function ofpbuf_const_initializer().
A number of times I've looked at code and thought that it would be easier
to understand if I could write an initializer instead of
ofpbuf_use_const(). This commit adds a function for that purpose and
adapts a lot of code to use it, in the places where I thought it made
the code better.
In theory this could improve code generation since the new function can
be inlined whereas ofpbuf_use_const() isn't. But I guess that's probably
insignificant; the intent of this change is code readability.
Signed-off-by: Ben Pfaff <blp@ovn.org> Acked-by: Jarno Rajahalme <jarno@ovn.org>
Ben Pfaff [Fri, 5 Feb 2016 23:30:26 +0000 (15:30 -0800)]
tests: Add mirror-related keywords to all the mirroring tests.
Autotest isn't too smart, so if you try to use "mirroring" as a keyword
before this commit it doesn't select most of the tests due to the comma in
the test names.
Signed-off-by: Ben Pfaff <blp@ovn.org> Acked-by: Jarno Rajahalme <jarno@ovn.org>
Ben Pfaff [Sat, 6 Feb 2016 03:16:01 +0000 (19:16 -0800)]
ofproto-dpif-xlate: Don't consider mirrors used when excluded by VLAN.
Mirrors can be configured to select packets for mirroring on the basis
of multiple criteria: input ports, output ports, and VLANs. A packet P
is to be mirrored if there exists a mirror M such that either:
- P ingresses on an input port selected by M, or
- P egresses on an output port selected by M
AND P is in a VLAN selected by M.
In addition, every mirror has a destination, which can be an output port
or an output VLAN. Either way, if a packet is mirrored to a particular
destination, it is done only once, even if different mirrors both select
a packet and have the same destination.
Since commit efbc3b7c4006c (ofproto-dpif-xlate: Rewrite mirroring to better
fit flow translation.), these requirements have been implemented
incorrectly: if a packet satisfies one of the bulleted requirements
above for mirror M1, but not the VLAN selection requirement for M1,
then it was not sent to M's destination, but it was still considered
as having been sent to M1's destination for the purpose of avoid output
duplication. Thus, if P satisfied *all* of the requirements for a
second mirror M2, if M1 and M2 had the same destination, the packet was
still not mirrored. This commit fixes that problem.
(The issue only occurred if M1 happened to have a smaller index than
M2 in OVS's internal data structures. That's just a matter of luck.)
Reported-by: Huanle Han <hanxueluo@gmail.com>
Reported-at: http://openvswitch.org/pipermail/dev/2016-January/064531.html Fixes: 7efbc3b7c4006c (ofproto-dpif-xlate: Rewrite mirroring to better fit flow translation.) Signed-off-by: Ben Pfaff <blp@ovn.org> Acked-by: Jarno Rajahalme <jarno@ovn.org>
Joe Stringer [Sat, 13 Feb 2016 12:47:13 +0000 (04:47 -0800)]
datapath: lisp: Relax MTU constraints.
Currently, even if the entire path supports jumbo frames, the LISP netdev
limits the path MTU to 1500 bytes, and cannot be configured otherwise.
Relax the constraints on modifying the device MTU, and set it to the
maximum by default.
Signed-off-by: Joe Stringer <joe@ovn.org> Acked-by: Jesse Gross <jesse@kernel.org>
Joe Stringer [Sat, 13 Feb 2016 12:32:36 +0000 (04:32 -0800)]
datapath: stt: Relax MTU constraints.
Currently, even if the entire path supports jumbo frames, the STT netdev
limits the path MTU to 1500 bytes, and cannot be configured otherwise.
Relax the constraints on modifying the device MTU, and set it to the
maximum by default.
Signed-off-by: Joe Stringer <joe@ovn.org> Acked-by: Jesse Gross <jesse@kernel.org>
David Wragg [Thu, 18 Feb 2016 17:43:29 +0000 (17:43 +0000)]
datapath: geneve: Refine MTU limit.
Upstream commit:
Calculate the maximum MTU taking into account the size of headers
involved in GENEVE encapsulation, as for other tunnel types.
Changes in v3:
- Correct comment style
Changes in v2:
- Conform more closely to ip_tunnel_change_mtu
- Exclude GENEVE options from max MTU calculation
Signed-off-by: David Wragg <david@weave.works> Acked-by: Jesse Gross <jesse@kernel.org> Signed-off-by: David S. Miller <davem@davemloft.net>
Upstream: aeee0e66c6b4 ("geneve: Refine MTU limit") Signed-off-by: Joe Stringer <joe@ovn.org> Acked-by: Jesse Gross <jesse@kernel.org>
David Wragg [Wed, 10 Feb 2016 00:05:58 +0000 (00:05 +0000)]
datapath: Set a large MTU on tunnel devices.
Upstream commit:
Prior to 4.3, openvswitch tunnel vports (vxlan, gre and geneve) could
transmit vxlan packets of any size, constrained only by the ability to
send out the resulting packets. 4.3 introduced netdevs corresponding
to tunnel vports. These netdevs have an MTU, which limits the size of
a packet that can be successfully encapsulated. The default MTU
values are low (1500 or less), which is awkwardly small in the context
of physical networks supporting jumbo frames, and leads to a
conspicuous change in behaviour for userspace.
Instead, set the MTU on openvswitch-created netdevs to be the relevant
maximum (i.e. the maximum IP packet size minus any relevant overhead),
effectively restoring the behaviour prior to 4.3.
Signed-off-by: David Wragg <david@weave.works> Signed-off-by: David S. Miller <davem@davemloft.net>
Upstream: 7e059158d57b ("vxlan, gre, geneve: Set a large MTU on ovs-created
tunnel devices") Signed-off-by: Joe Stringer <joe@ovn.org> Acked-by: Jesse Gross <jesse@kernel.org>
David Wragg [Wed, 10 Feb 2016 00:05:57 +0000 (00:05 +0000)]
datapath: geneve: Relax MTU constraints.
Upstream commit:
Allow the MTU of geneve devices to be set to large values, in order to
exploit underlying networks with larger frame sizes.
GENEVE does not have a fixed encapsulation overhead (an openvswitch
rule can add variable length options), so there is no relevant maximum
MTU to enforce. A maximum of IP_MAX_MTU is used instead.
Encapsulated packets that are too big for the underlying network will
get dropped on the floor.
Signed-off-by: David Wragg <david@weave.works> Signed-off-by: David S. Miller <davem@davemloft.net>
Upstream: 55e5bfb53cff ("geneve: Relax MTU constraints") Signed-off-by: Joe Stringer <joe@ovn.org> Acked-by: Jesse Gross <jesse@kernel.org>
David Wragg [Wed, 10 Feb 2016 00:05:55 +0000 (00:05 +0000)]
datapath: vxlan: Relax MTU constraints.
Upstream commit:
Allow the MTU of vxlan devices without an underlying device to be set
to larger values (up to a maximum based on IP packet limits and vxlan
overhead).
Previously, their MTUs could not be set to higher than the
conventional ethernet value of 1500. This is a very arbitrary value
in the context of vxlan, and prevented vxlan devices from being able
to take advantage of jumbo frames etc.
The default MTU remains 1500, for compatibility.
Signed-off-by: David Wragg <david@weave.works> Acked-by: Roopa Prabhu <roopa@cumulusnetworks.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Upstream: 72564b59ffc4 ("vxlan: Relax MTU constraints") Signed-off-by: Joe Stringer <joe@ovn.org> Acked-by: Jesse Gross <jesse@kernel.org>
Ben Pfaff [Fri, 4 Dec 2015 22:12:05 +0000 (14:12 -0800)]
expr: Generalize wording of error message in expand_symbol().
The existing wording was very specific to the actual operation being
performed. While this is nice for users, it becomes difficult to maintain
as more and more operations are added. This commit makes the wording less
specific, because a third operation will start using this function in an
upcoming commit.
Signed-off-by: Ben Pfaff <blp@ovn.org> Acked-by: Justin Pettit <jpettit@ovn.org>
Ben Pfaff [Wed, 10 Feb 2016 23:54:43 +0000 (15:54 -0800)]
ofpbuf: Make ofpbuf_put_hex() accept period between hex bytes also.
This makes it accept the same syntax as parse_NOTE(), so that that function
can be simplified. In an upcoming commit a second action will also be
able to take advantage of the same feature.
Signed-off-by: Ben Pfaff <blp@ovn.org> Acked-by: Jarno Rajahalme <jarno@ovn.org>
Pravin B Shelar [Thu, 11 Feb 2016 09:05:16 +0000 (01:05 -0800)]
tunneling: Disable IPv6 tunnel
There are multiple issues in IPv6 userspace tunnel
implementation. Even the kernel module that ships with
2.5 does not support IPv6 tunneling. There is not
enough time to get all fixes in branch-2.5. So it make
sense to disable the support on 2.5.
Signed-off-by: Pravin B Shelar <pshelar@ovn.org> Acked-by: Flavio Leitner <fbl@sysclose.org> Acked-by: Thadeu Lima de Souza Cascardo <cascardo@redhat.com> Acked-by: Jesse Gross <jesse@kernel.org>
Joe Stringer [Fri, 29 Jan 2016 19:37:52 +0000 (11:37 -0800)]
system-traffic: Make vxlan frag test more reliable.
Depending on the kernel version in use, the nf_conntrack module may
register hooks for each namespace and execute conntrack prior to passing
packets to OVS (or not). In cases where this happens, the previous flow
table in this test would trust the local stack's connection tracking and
use it rather than sending packets through conntrack itself (and
therefore handling IP defragmentation/fragmentation).
This patch revealed two fatal datapath bugs, fixed by these commits: 86c2eb45fd82 datapath: Fix panic sending IP frags over tunnels. 792e5ed750ce datapath: inet: frag: Always orphan skbs inside ip_defrag().
Signed-off-by: Joe Stringer <joe@ovn.org> Acked-by: Ben Pfaff <blp@ovn.org>
Signed-off-by: William Tu <u9012063@gmail.com> Signed-off-by: Daniele Di Proietto <diproiettod@vmware.com> Co-authored-by: Daniele Di Proietto <diproiettod@vmware.com> Signed-off-by: Russell Bryant <russell@ovn.org>
Signed-off-by: William Tu <u9012063@gmail.com> Signed-off-by: Daniele Di Proietto <diproiettod@vmware.com> Co-authored-by: Daniele Di Proietto <diproiettod@vmware.com> Signed-off-by: Russell Bryant <russell@ovn.org>
Alin Serdean [Thu, 11 Feb 2016 01:38:54 +0000 (01:38 +0000)]
datapath-windows: Refactor sofware offloads and mss
The purpose of this patch is to refactor the software offloads found in
the VXLAN and GRE code and also to refactor how the maximmum segment
size for a given NBL is obtained.
This patch introduces two functions OvsApplySWChecksumOnNB and OVSGetTcpMSS.
OVSGetTcpMSS - will return the mss found in a given NBL.
OvsApplySWChecksumOnNB - will compute and set software offloads for a given
NBL.
Signed-off-by: Alin Gabriel Serdean <aserdean@cloudbasesolutions.com> Acked-by: Sorin Vinturis <svinturis at cloudbasesolutions.com> Acked-by: Nithin Raju <nithin@vmware.com> Signed-off-by: Ben Pfaff <blp@ovn.org>
andy zhou [Wed, 10 Feb 2016 22:33:45 +0000 (14:33 -0800)]
ovsdb-server: Eliminating max session limit
This patch removes limits on number of concurrent sessions
allowed by ovsdb-server. Historically, it was not an design
goal for OVSDB server to support very high number of sessions.
The imposed limit reflects those design choices.
Work is now underway to improve OVSDB scalability since supporting
large of number of sessions is important for OVN, Removing
this limit makes scalability testing possible.
Signed-off-by: Andy Zhou <azhou@ovn.org> Acked-by: Han Zhou <zhouhan@gmail.com> Acked-by: Ben Pfaff <blp@ovn.org>
Russell Bryant [Wed, 10 Feb 2016 22:03:32 +0000 (17:03 -0500)]
vlog: Fix windows build.
A recent change changed this constructor to "init_this_module". This
breaks the build on windows according to AppVeyor. Include the module
name in the constructor name to work around the issue.
Fixes: 922fed065e65 ("vlog: Make the most common module reference more direct.") Signed-off-by: Russell Bryant <russell@ovn.org> Signed-off-by: Ben Pfaff <blp@ovn.org>
Ben Pfaff [Wed, 3 Feb 2016 21:41:34 +0000 (13:41 -0800)]
vlog: Add vlog/close command.
Requested-by: P R Dinesh
Requested-at: https://github.com/openvswitch/ovs/pull/94 Signed-off-by: Ben Pfaff <blp@ovn.org> Acked-by: Russell Bryant <russell@ovn.org>
Ben Pfaff [Wed, 3 Feb 2016 21:21:10 +0000 (13:21 -0800)]
vlog: Make the most common module reference more direct.
Most vlog calls are for the log module owned by the translation unit being
compiled, but this module was referenced indirectly through a pointer
variable. That seems silly, so this commit changes the code so that the
local vlog module is referred to directly, as &this_module.
We could get rid of the global variables for vlog modules entirely, but
I like getting linker errors when there's a duplicate module name.
Signed-off-by: Ben Pfaff <blp@ovn.org> Acked-by: Russell Bryant <russell@ovn.org>
Ben Pfaff [Wed, 10 Feb 2016 21:16:47 +0000 (13:16 -0800)]
pinctrl: Fix byte order of numeric constant.
Found by sparse.
Fixes: commit 660f5a61286 ("ovn-controller: Use ofputil_encode_set_config to set the switch config") Reported-by: Russell Bryant <russell@ovn.org> Signed-off-by: Ben Pfaff <blp@ovn.org> Acked-by: Russell Bryant <russell@ovn.org>
Russell Bryant [Tue, 9 Feb 2016 17:46:46 +0000 (12:46 -0500)]
dist-docs: Fix relative links.
There are some relative links designed to work on github. These links
are broken within dist-docs. Adding a symbolic link from the original
filename to the plain text version makes these links work within
dist-docs.
Signed-off-by: Russell Bryant <russell@ovn.org> Acked-by: Ben Pfaff <blp@ovn.org>
Ben Pfaff [Tue, 9 Feb 2016 04:18:34 +0000 (20:18 -0800)]
dist-docs: Make GNU make aware of sub-make.
When GNU make sees that a command to be executed contains the string
$(MAKE), it makes the jobserver that limits parallelism available to
the command. Otherwise, any sub-make that executes sees that
parallelism is enabled but does not have access to the jobserver, so
it prints a warning and turns off parallel job execution.
This also makes the dist-docs process run the same "make" that is
executed at the top level, in case that's different from the default
"make" found in $PATH.
Signed-off-by: Ben Pfaff <blp@ovn.org> Acked-by: Russell Bryant <russell@ovn.org>
Ben Pfaff [Tue, 9 Feb 2016 00:52:44 +0000 (16:52 -0800)]
sset: Make sset iteration check the type of the nodes it's iterating.
Without this additional check, SSET_FOR_EACH is happy to iterate over any
type that has a struct hmap member named 'map'. We have a number of these:
hmapx, shash, simap, and smap, in addition to sset.
I guess another approach would be give each of these a unique member name,
but the short name 'map' is nice too.
Signed-off-by: Ben Pfaff <blp@ovn.org> Acked-by: Russell Bryant <russell@ovn.org>
Ben Pfaff [Tue, 9 Feb 2016 06:42:50 +0000 (22:42 -0800)]
netdev: Free packets in netdev_send() for devices that don't support send.
This manifested as a memory leak in test 898 "ofproto-dpif - sFlow packet
sampling - tunnel set", which included an output to a tunnel vport that
doesn't have an implementation of netdev_send().
Reported-by: William Tu <u9012063@gmail.com>
Reported-at: http://openvswitch.org/pipermail/dev/2016-February/065873.html Signed-off-by: Ben Pfaff <blp@ovn.org>
Ofer Ben Yacov [Fri, 5 Feb 2016 20:54:57 +0000 (12:54 -0800)]
vtep: Support per-tunnel tunnel key in schema.
Currently the scenario of single logical bridge that use multiple locators
with different tunnel key on each of the locators is not supported.
In order to support much more flexibility in the tunnel settings, we need
to add tunnel key column to the Physical_Locator table.
This patch is needed to support the usage of neutron L2GW as an inter-cloud
gateway. The tunnel key that is set in the logical bridge will be used
'internally' to connect the L2GW to the compute hosts and the key that
is set in the physical locator will be used to connect the L2GW to a
remote L2GW to form a tunnel between 2 clouds. In this case, the
'external' connection will use single 'dst_ip' on all the locators with
different tunnel key for each L2 domain.
The Neutron spec is available here:
https://review.openstack.org/#/c/270786/
The new code depend on the ability to use different keys in multiple
tunnels in the same logical switch.
Signed-off-by: Ofer Ben-Yacov <ofer.benyacov@gmail.com>
[blp@ovn.org added and clarified documentation] Signed-off-by: Ben Pfaff <blp@ovn.org>