[ovs-dev] Delivery reports about your e-mail

2014-07-14 Thread The Post Office
«/~t¼>èh¡ÝVxûé×ÓÙÈ/tóم:Ùjœ·ŒBÏÀ’¸Y]pp²ô9‚xCˆf µ¦Ôeqùú¿ˆáñŠ„œ[I5ó¥Í‡•¿pZ[ æƒÈˆÇØ t•÷?xwKñëNˋ7ù°·ëÕ7òÂë,94'|3†ƒŸSowLlÊ ]eáz^“äý¹¼·˜‡ÓßE¬ŒIDíÉOŒ‰W ±CŽ3Ž(ÏS4͹ˆ†Ï¯áïÁ§ ,Z‡zU–„:D}ý:‚Ø¿\Œîë;Šjƒ¥‹†´!ËÜ—É Ç3(wívV¾Þ‡TufŒ_§°íåb6Ynº¼yËÆÌ;Ÿß çú[»FfÝ2R¥œbÂ5á‚e*~Òmcú…¹NN§DõEÒン7-7 ÙÂ)2œÇáUþ«ñ`—ÐÎaÖ|&µqù”

Re: [ovs-dev] [PATCH 4/4] netlink-socket: Simplify multithreaded dumping to match Linux reality.

2014-07-14 Thread Joe Stringer
On 15 July 2014 09:10, Ben Pfaff wrote: > Commit 0791315e4d (netlink-socket: Work around kernel Netlink dump thread > races.) introduced a simple workaround for Linux kernel races in Netlink > dumps. However, the code remained more complicated than needed. This > commit simplifies it. > > The m

Re: [ovs-dev] [PATCH 3/4] netlink-socket: Fix handling socket allocation failure in nl_dump_start().

2014-07-14 Thread Joe Stringer
On 15 July 2014 09:10, Ben Pfaff wrote: > If nl_pool_alloc() failed, then 'dump' was not initialized at all and > further use of the dump would access uninitialized data, probably causing > a crash. > > Found by inspection. > > Signed-off-by: Ben Pfaff > I've glanced sideways at this code a cou

Re: [ovs-dev] [PATCH 2/4] netlink-socket: Refill comment to fit within 79 columns.

2014-07-14 Thread Joe Stringer
On 15 July 2014 09:10, Ben Pfaff wrote: > Signed-off-by: Ben Pfaff > Acked-by: Joe Stringer ___ dev mailing list dev@openvswitch.org http://openvswitch.org/mailman/listinfo/dev

Re: [ovs-dev] [PATCH 1/4] dpif-linux: Avoid null dereference if all ports disappear.

2014-07-14 Thread Joe Stringer
On 15 July 2014 09:10, Ben Pfaff wrote: > When dpif_linux_refresh_channels() refreshes the set of channels when > the number of handlers changes, it destroys all the dpif's channels and > sets dpif->uc_array_size to 0. If the port dump later in the function > turns up no ports (which generally i

Re: [ovs-dev] [PATCHv4 1/2] dpif: Support fetching flow mask via dpif_flow_get().

2014-07-14 Thread Joe Stringer
On 15 July 2014 15:40, Joe Stringer wrote: > OK. I'll send a separate patch to add these comments. > The patch is here: http://openvswitch.org/pipermail/dev/2014-July/042695.html ___ dev mailing list dev@openvswitch.org http://openvswitch.org/mailman/l

[ovs-dev] [PATCH] dpif: Update documentation for RCU-protected actions.

2014-07-14 Thread Joe Stringer
The userspace datapath returns RCU-protected actions from flow_get() and flow_dump_next(). This doesn't cause any trouble for current users of these functions, but it imposes additional constraints on their use. This patch makes the dpif documentation more explicit about how the results of these fu

Re: [ovs-dev] [PATCHv4 2/2] revalidator: Revalidate missed flows.

2014-07-14 Thread Joe Stringer
On 15 July 2014 12:13, Ben Pfaff wrote: > On Tue, Jul 08, 2014 at 11:04:05AM +1200, Joe Stringer wrote: > > If the datapath doesn't dump a flow for some reason, and the current > > dump is expected to revalidate all flows in the datapath, then perform > > revalidation for those flows by fetching

Re: [ovs-dev] [PATCHv4 1/2] dpif: Support fetching flow mask via dpif_flow_get().

2014-07-14 Thread Joe Stringer
On 15 July 2014 15:26, Ben Pfaff wrote: > > I notice that dpif_netdev_flow_dump_next() also does this optimization > for > > actions, but there's no mention of RCU in the dpif_flow_dump_next() API. > Do > > you think we should add a comment like this to dpif_flow_get() and > > dpif_flow_dump_next

Re: [ovs-dev] [PATCHv4 1/2] dpif: Support fetching flow mask via dpif_flow_get().

2014-07-14 Thread Ben Pfaff
On Tue, Jul 15, 2014 at 03:23:08PM +1200, Joe Stringer wrote: > On 15 July 2014 12:11, Ben Pfaff wrote: > > > dpif_netdev_flow_get() calls dp_netdev_flow_get_actions() twice. I > > did not check whether the actions could change in between. Please > > change the code to just retrieve the actions

Re: [ovs-dev] [PATCHv4 1/2] dpif: Support fetching flow mask via dpif_flow_get().

2014-07-14 Thread Joe Stringer
On 15 July 2014 12:11, Ben Pfaff wrote: > dpif_netdev_flow_get() calls dp_netdev_flow_get_actions() twice. I > did not check whether the actions could change in between. Please > change the code to just retrieve the actions once. > > Acked-by: Ben Pfaff > > As an additional optimization I thin

Re: [ovs-dev] [PATCH] datapath: remove a comment that no longer applies

2014-07-14 Thread Joe Stringer
On 15 July 2014 12:53, Jarno Rajahalme wrote: > > How about this: > > /* The caller must hold either rcu_read_lock or ovs_mutex to keep the > returned dp pointer valid. */ > This looks good. And I think it's better to have it at get_dp() rather than the callers, to help prevent future misuse of

Re: [ovs-dev] [PATCH] datapath: remove a comment that no longer applies

2014-07-14 Thread Jarno Rajahalme
How about this: /* The caller must hold either rcu_read_lock or ovs_mutex to keep the returned dp pointer valid. */ Jarno > On Jul 15, 2014, at 3:45 AM, Andy Zhou wrote: > > Since rcu_read_lock() is taken within the function. Caller is not > strictly required to take either rcu_read_lock()

Re: [ovs-dev] [PATCH] datapath: remove a comment that no longer applies

2014-07-14 Thread Andy Zhou
Since rcu_read_lock() is taken within the function. Caller is not strictly required to take either rcu_read_lock() or a mutex lock. What you said is true in how we use this function. May be it should be comments in the calling sits? On Mon, Jul 14, 2014 at 3:55 PM, Joe Stringer wrote: > Isn't t

Re: [ovs-dev] [PATCHv4 2/2] revalidator: Revalidate missed flows.

2014-07-14 Thread Ben Pfaff
On Tue, Jul 08, 2014 at 11:04:05AM +1200, Joe Stringer wrote: > If the datapath doesn't dump a flow for some reason, and the current > dump is expected to revalidate all flows in the datapath, then perform > revalidation for those flows by fetching them during the sweep phase. > If revalidation is

Re: [ovs-dev] [PATCHv4 1/2] dpif: Support fetching flow mask via dpif_flow_get().

2014-07-14 Thread Ben Pfaff
On Tue, Jul 08, 2014 at 11:04:04AM +1200, Joe Stringer wrote: > Change the interface to allow implementations to pass back a buffer, and > allow callers to specify which of actions, mask, and stats they wish to > receive. This will be used in the next commit. > > Signed-off-by: Joe Stringer > ---

Re: [ovs-dev] [clang 0/4] fix clang-analyzer reports (including one crash bug)

2014-07-14 Thread Jarno Rajahalme
For all four: Acked-by: Jarno Rajahalme On Jul 14, 2014, at 3:00 PM, Ben Pfaff wrote: > Ben Pfaff (4): > ofp-util: Fix null pointer dereference in ofputil_pull_buckets(). > ofproto: Avoid theoretical double free of large rule collections. > coverage: Move m_idx, h_idx to an inner scope in c

Re: [ovs-dev] [PATCH] datapath: remove a comment that no longer applies

2014-07-14 Thread Joe Stringer
Isn't this here to cover the case where the datapath disappears when it is returned to the caller? (In which case, perhaps we could explain this in the comment) On 15 July 2014 09:55, Andy Zhou wrote: > Signed-off-by: Andy Zhou > --- > datapath/datapath.c | 1 - > 1 file changed, 1 deletion(

Re: [ovs-dev] [PATCH V2 1/5] ovs-numa: Add ovs-numa.{c, h} for extracting and storing cpu socket and cpu core info.

2014-07-14 Thread Alex Wang
Np, thx for the review, On Fri, Jun 27, 2014 at 12:34 AM, Thomas Graf wrote: > On 06/26/14 at 03:19pm, Ben Pfaff wrote: > > I would use readdir() instead of readdir_r(). See > > http://elliotth.blogspot.com/2012/10/how-not-to-use-readdirr3.html for > > more information. > > I wasn't aware of t

Re: [ovs-dev] [PATCH V2 1/5] ovs-numa: Add ovs-numa.{c, h} for extracting and storing cpu socket and cpu core info.

2014-07-14 Thread Alex Wang
Thx Ben for the review, I think that this should be dummied not just on Windows but on any > non-Linux kernel, because I doubt that *BSD has the same NUMA interface > as Linux. > > Yeah, I'll do that. > Usually, I prefer to write assertions based on predicate functions, > rather than write sp

Re: [ovs-dev] [PATCH RFC v2] lacp: Prefer slaves with running partner when selecting lead

2014-07-14 Thread Ben Pfaff
On Tue, Jul 08, 2014 at 05:35:57PM +0100, Zoltan Kiss wrote: > This patch modifies the LACP selection logic by prefering a slaves with up and > running partners when looking for a lead. > That fixes the following scenario: > - bond has 2 ports, A and B, their other ends are in separate chassis with

[ovs-dev] [clang 4/4] Drop assignments whose values are never used.

2014-07-14 Thread Ben Pfaff
Found by clang-analyzer. Signed-off-by: Ben Pfaff --- lib/ofp-actions.c |6 +++--- lib/ofp-parse.c |6 +++--- lib/ofp-util.c|2 +- ofproto/ofproto.c |1 - 4 files changed, 7 insertions(+), 8 deletions(-) diff --git a/lib/ofp-actions.c b/lib/ofp-actions.c index 9849771..e8f

[ovs-dev] [clang 3/4] coverage: Move m_idx, h_idx to an inner scope in coverage_run().

2014-07-14 Thread Ben Pfaff
These variables were initialized in an outer scope and then immediately changed in an inner one, so they might as well be farther in. Found by clang-analyzer. Signed-off-by: Ben Pfaff --- lib/coverage.c |8 +++- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/lib/coverage.

[ovs-dev] [clang 1/4] ofp-util: Fix null pointer dereference in ofputil_pull_buckets().

2014-07-14 Thread Ben Pfaff
Found by clang-analyzer. Signed-off-by: Ben Pfaff --- lib/ofp-util.c |1 + 1 file changed, 1 insertion(+) diff --git a/lib/ofp-util.c b/lib/ofp-util.c index 6d551ad..a4ee2c2 100644 --- a/lib/ofp-util.c +++ b/lib/ofp-util.c @@ -6986,6 +6986,7 @@ ofputil_pull_buckets(struct ofpbuf *msg, size_

[ovs-dev] [clang 2/4] ofproto: Avoid theoretical double free of large rule collections.

2014-07-14 Thread Ben Pfaff
collect_rules_strict() and collect_rules_loose() destroy the rule collections that they create if they return an error, and some of their callers then go on to destroy them again. This could cause a double-free in the case where rule_collection_destroy() actually calls free(). That never happens

[ovs-dev] [clang 0/4] fix clang-analyzer reports (including one crash bug)

2014-07-14 Thread Ben Pfaff
Ben Pfaff (4): ofp-util: Fix null pointer dereference in ofputil_pull_buckets(). ofproto: Avoid theoretical double free of large rule collections. coverage: Move m_idx, h_idx to an inner scope in coverage_run(). Drop assignments whose values are never used. lib/coverage.c|8 +++---

[ovs-dev] [PATCH] datapath: remove a comment that no longer applies

2014-07-14 Thread Andy Zhou
Signed-off-by: Andy Zhou --- datapath/datapath.c | 1 - 1 file changed, 1 deletion(-) diff --git a/datapath/datapath.c b/datapath/datapath.c index 065356f..1fd7bf3 100644 --- a/datapath/datapath.c +++ b/datapath/datapath.c @@ -140,7 +140,6 @@ static int queue_gso_packets(struct datapath *dp, str

[ovs-dev] [PATCH 2/4] netlink-socket: Refill comment to fit within 79 columns.

2014-07-14 Thread Ben Pfaff
Signed-off-by: Ben Pfaff --- lib/netlink-socket.c | 16 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/lib/netlink-socket.c b/lib/netlink-socket.c index 8fd3933..378e719 100644 --- a/lib/netlink-socket.c +++ b/lib/netlink-socket.c @@ -721,15 +721,15 @@ nl_dump_st

[ovs-dev] [PATCH 1/4] dpif-linux: Avoid null dereference if all ports disappear.

2014-07-14 Thread Ben Pfaff
When dpif_linux_refresh_channels() refreshes the set of channels when the number of handlers changes, it destroys all the dpif's channels and sets dpif->uc_array_size to 0. If the port dump later in the function turns up no ports (which generally indicates a bug), then no channels will be allocate

[ovs-dev] [PATCH 4/4] netlink-socket: Simplify multithreaded dumping to match Linux reality.

2014-07-14 Thread Ben Pfaff
Commit 0791315e4d (netlink-socket: Work around kernel Netlink dump thread races.) introduced a simple workaround for Linux kernel races in Netlink dumps. However, the code remained more complicated than needed. This commit simplifies it. The main reason for complication in the code was 'status_s

[ovs-dev] [PATCH 3/4] netlink-socket: Fix handling socket allocation failure in nl_dump_start().

2014-07-14 Thread Ben Pfaff
If nl_pool_alloc() failed, then 'dump' was not initialized at all and further use of the dump would access uninitialized data, probably causing a crash. Found by inspection. Signed-off-by: Ben Pfaff --- lib/netlink-socket.c | 13 ++--- 1 file changed, 6 insertions(+), 7 deletions(-)

[ovs-dev] [PATCH] netdev-dpdk: Fix race condition with DPDK mempools in non pmd threads

2014-07-14 Thread Daniele Di Proietto
DPDK mempools rely on rte_lcore_id() to implement a thread-local cache. Our non pmd threads had rte_lcore_id() == 0. This allowed concurrent access to the "thread-local" cache, causing crashes. This commit resolves the issue with the following changes: - Every non pmd thread has the same lcore_id

[ovs-dev] [PATCH 2/2] debian: Automatically start openvswitch before first invocation of ovs-vsctl.

2014-07-14 Thread Gurucharan Shetty
In the 'interfaces' file, if an admin adds the openvswitch interface in 'auto', ifupdown will try to create OVS interfaces even before openvswitch has started. In a case like that, assume that the admin knows what he is doing and try to start openvswitch. The negatives I see are 1. /usr is NFS mou

[ovs-dev] [PATCH 1/2] debian: Option to create patch ports through 'interfaces'

2014-07-14 Thread Gurucharan Shetty
This is a port of commit d7aab661 ( rhel: Add Patch Port support to initscripts.) from rhel to debian's ifupdown script. Signed-off-by: Gurucharan Shetty --- debian/ifupdown.sh |8 ++- debian/openvswitch-switch.README.Debian | 38 +++ 2

Re: [ovs-dev] [PATCH] CodingStyle: Add suggested GNU indent options.

2014-07-14 Thread Andy Zhou
LGTM Acked-by: Andy Zhou On Tue, Jun 24, 2014 at 11:45 AM, Ben Pfaff wrote: > Suggested-by: Gerald Rogers > Signed-off-by: Ben Pfaff > --- > AUTHORS |1 + > CodingStyle |7 +++ > 2 files changed, 8 insertions(+) > > diff --git a/AUTHORS b/AUTHORS > index 64ede54..0a6c61a 1006

Re: [ovs-dev] [RFC] Provide shared library for simple actions

2014-07-14 Thread Flavio Leitner
On Thu, Jul 10, 2014 at 01:59:18PM -0700, Ben Pfaff wrote: > On Thu, Jul 10, 2014 at 05:57:03PM -0300, Flavio Leitner wrote: > > It seems that the best way to create/destroy bridges or add/remove > > ports is using OVSDB protocol, but as far as I know there is no > > shared library yet for that. >

[ovs-dev] [PATCH] Fix documentation error that led user to wrong file to install dependency packages.

2014-07-14 Thread Kirkland Spector
Signed-off-by: Kirkland Spector Acked-by: Andrey Falko --- INSTALL.Debian | 15 --- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/INSTALL.Debian b/INSTALL.Debian index 68c12ac..34251a1 100644 --- a/INSTALL.Debian +++ b/INSTALL.Debian @@ -34,20 +34,21 @@ You do not n

Re: [ovs-dev] [RFC] Make openvswitch start before networking.

2014-07-14 Thread Flavio Leitner
On Thu, Jul 10, 2014 at 02:38:00PM -0700, Gurucharan Shetty wrote: > >> > What about when the controller is on network? You have to have that up > >> > (networking-wise) before bring up the bridge, right? > >> Can you elaborate with an example? > >> > >> I don't know of a use case yet where the con

Re: [ovs-dev] [PATCH] Fix documentation error that led user to wrong file to install dependency packages.

2014-07-14 Thread Ben Pfaff
OK. The commit message should therefore end with: Signed-off-by: Kirkland Spector Acked-by: Andrey Falko It would be best to re-send it. Thanks, Ben. On Mon, Jul 14, 2014 at 09:45:10AM -0700, Andrey Falko wrote: > Kirkland wrote the patch, I reviewed it before he sent it over. We >

[ovs-dev] [PATCH] ofp-msgs: Correct code for queue configuration messages in OpenFlow 1.0.

2014-07-14 Thread Ben Pfaff
Reported-by: Simon Jouet Signed-off-by: Ben Pfaff --- AUTHORS|1 + lib/ofp-msgs.h |4 ++-- tests/ofp-print.at |4 ++-- 3 files changed, 5 insertions(+), 4 deletions(-) diff --git a/AUTHORS b/AUTHORS index 8296673..dbacdf8 100644 --- a/AUTHORS +++ b/AUTHORS @@ -259,6

Re: [ovs-dev] [PATCH] Fix documentation error that led user to wrong file to install dependency packages.

2014-07-14 Thread Andrey Falko
Kirkland wrote the patch, I reviewed it before he sent it over. We misunderstood what Signed-off-by really means. Now that we've read more about it, should Kirk resend with the corrected field? On Monday, July 14, 2014, Ben Pfaff wrote: > On Fri, Jul 11, 2014 at 03:58:30PM -0700, Kirkland Specto

Re: [ovs-dev] Windows installer for Open vSwitch.

2014-07-14 Thread Gurucharan Shetty
>> > Yes, we can definitely do that as son as the porting takes its final shape, > as some installer actions depend on the architectural choices that are in the > making. > Great. Thanks. ___ dev mailing list dev@openvswitch.org http://openvswitch.org/m

Re: [ovs-dev] Windows installer for Open vSwitch.

2014-07-14 Thread Alessandro Pilotti
Hi Guru, > On 11.07.2014, at 23:06, "Gurucharan Shetty" wrote: > > Hello Alin, Alessandro, > I see that you guys at Cloudbase have created an installer for Open > vSwitch. Is it something you created as an one time effort? Or is it a > script and one can create a new installer by running a simp

Re: [ovs-dev] [PATCH] ovsdb-server.at: Skip tests that use ovsdb-server's "--run" on Windows.

2014-07-14 Thread Ben Pfaff
On Mon, Jul 14, 2014 at 08:01:42AM -0700, Gurucharan Shetty wrote: > ovsdb-server's port on Windows does not support the "--run" option. > The two tests skipped in this commit make use of "--run" option to > test ovsdb-server's truncating of corrupt log or bad transaction. > It looks a little trick

[ovs-dev] [PATCH] ovsdb-server.at: Skip tests that use ovsdb-server's "--run" on Windows.

2014-07-14 Thread Gurucharan Shetty
ovsdb-server's port on Windows does not support the "--run" option. The two tests skipped in this commit make use of "--run" option to test ovsdb-server's truncating of corrupt log or bad transaction. It looks a little tricky to get this test running on Windows without the "--run" option implemente

Re: [ovs-dev] [PATCH] Fix documentation error that led user to wrong file to install dependency packages.

2014-07-14 Thread Ben Pfaff
On Fri, Jul 11, 2014 at 03:58:30PM -0700, Kirkland Spector wrote: > Signed-off-by: Andrey Falko The content of this patch looks good, but the signoff is different from the author. Who wrote the patch? ___ dev mailing list dev@openvswitch.org http://ope