[ovs-dev] [port-renumbering 1/8] ofproto-dpif: Improve comment.

2013-12-11 Thread Ben Pfaff
Signed-off-by: Ben Pfaff --- ofproto/ofproto-dpif.c |2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ofproto/ofproto-dpif.c b/ofproto/ofproto-dpif.c index ff77903..bfa9a9a 100644 --- a/ofproto/ofproto-dpif.c +++ b/ofproto/ofproto-dpif.c @@ -436,7 +436,7 @@ struct dpif_backer

[ovs-dev] [port-renumbering 7/8] bridge: Reconfigure in single pass.

2013-12-11 Thread Ben Pfaff
This greatly simplifies the reconfiguration code, making it much easier to understand and modify. The old multi-pass configuration had the property that it didn't delay block packet processing as much, but that's not much of a worry anymore now that latency critical activities have been moved outs

[ovs-dev] [port-renumbering 3/8] ofproto: Make ofproto_enumerate_types() match its comment.

2013-12-11 Thread Ben Pfaff
The comment says that it clears the passed-in sset, but it didn't. The bug didn't actually affect any of the existing callers, which all passed in an empty sset. Signed-off-by: Ben Pfaff --- ofproto/ofproto.c |1 + 1 file changed, 1 insertion(+) diff --git a/ofproto/ofproto.c b/ofproto/ofp

[ovs-dev] [port-renumbering 2/8] ofproto-provider: Add comment on struct ofport.

2013-12-11 Thread Ben Pfaff
Signed-off-by: Ben Pfaff --- ofproto/ofproto-provider.h |2 ++ 1 file changed, 2 insertions(+) diff --git a/ofproto/ofproto-provider.h b/ofproto/ofproto-provider.h index 54d97f1..600b92b 100644 --- a/ofproto/ofproto-provider.h +++ b/ofproto/ofproto-provider.h @@ -162,6 +162,8 @@ struct ofpor

[ovs-dev] [port-renumbering 8/8] bridge: Support changing port numbers.

2013-12-11 Thread Ben Pfaff
Feature #21293. Requested-by: Anuprem Chalvadi Signed-off-by: Ben Pfaff --- NEWS |3 ++ vswitchd/bridge.c| 93 -- vswitchd/vswitch.xml | 21 +++- 3 files changed, 99 insertions(+), 18 deletions(-) diff --git a/N

[ovs-dev] [port-renumbering 5/8] netdev: Log a warning when netdev_set_config() fails.

2013-12-11 Thread Ben Pfaff
This allows its callers to avoid duplicating the code. Signed-off-by: Ben Pfaff --- lib/netdev.c | 10 -- utilities/ovs-dpctl.c |2 -- vswitchd/bridge.c |9 + 3 files changed, 9 insertions(+), 12 deletions(-) diff --git a/lib/netdev.c b/lib/netdev.c index

[ovs-dev] [port-renumbering 4/8] ofproto: Fix alphabetical order in list of structs.

2013-12-11 Thread Ben Pfaff
Signed-off-by: Ben Pfaff --- ofproto/ofproto.h |4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ofproto/ofproto.h b/ofproto/ofproto.h index d734eab..6197278 100644 --- a/ofproto/ofproto.h +++ b/ofproto/ofproto.h @@ -36,12 +36,12 @@ struct bfd_cfg; struct cfm_settings;

[ovs-dev] [port-renumbering 6/8] lacp: Make lacp negotiation test hard-code aggregation keys.

2013-12-11 Thread Ben Pfaff
The lacp implementation takes the aggregation key from the key or portid of the first slave to be added to the lacp object. When multiple slaves are added initially to a lacp object (the most common case), which is the "first" is arbitrary. Until now, it seems that the "first" was actually predic

Re: [ovs-dev] [RFC 1/4] compiler: Add OVS_CONSTRUCTOR to mark functions as init functions

2013-12-11 Thread Helmut Schaa
On Wed, Dec 11, 2013 at 12:10 AM, Gurucharan Shetty wrote: > On Tue, Dec 10, 2013 at 5:49 AM, Helmut Schaa > wrote: >> Functions marked with OVS_CONSTRUCTOR are called unconditionally >> before main. >> >> Signed-off-by: Helmut Schaa >> --- >> >> This works with gcc (tested), should work with cl

Re: [ovs-dev] [PATCH] util: Remove unused count_1bits_8

2013-12-11 Thread Jarno Rajahalme
On Dec 10, 2013, at 5:44 PM, Ben Pfaff wrote: > On Wed, Dec 11, 2013 at 10:42:02AM +0900, Simon Horman wrote: >> On Tue, Dec 10, 2013 at 05:40:00PM -0800, Ben Pfaff wrote: >>> On Wed, Dec 11, 2013 at 10:34:14AM +0900, Simon Horman wrote: On Tue, Dec 10, 2013 at 05:07:14PM -0800, Ben Pfaff w

[ovs-dev] [PATCHv4 3/4] ofproto-dpif: Only run bundles when lacp or bonds are enabled

2013-12-11 Thread Joe Stringer
When dealing with a large number of ports, bundle_run() and bundle_wait() add significant unnecessary processing to the main run loop, even when there are no bonds and lacp is not configured. This patch skips such execution if it is unneeded, reducing CPU usage from about 25% to about 20% in a test

[ovs-dev] [PATCHv4 4/4] bridge: Only store instant_stats on device changes

2013-12-11 Thread Joe Stringer
Previously, we iterated through all interfaces in instant_stats_run(), grabbing up-to-date information about device status. After assembling all of this information for all interfaces, we would determine whether anything changed and only send an update to ovsdb-server if something changed. This pa

[ovs-dev] [PATCHv4 1/4] netdev: Globally track port status changes

2013-12-11 Thread Joe Stringer
Previously, we tracked status changes for ofports on a per-device basis. Each time in the main thread's loop, we would loop through all ofports and manually check whether the status has changed for corresponding devices. This patch shifts change_seq above the netdevice layer, with one atomic varia

[ovs-dev] [PATCHv4 0/4] Tunnel Scalability

2013-12-11 Thread Joe Stringer
Essentially the same patchset as previously posted, three minor changes:- * First patch merged ("bridge: Refresh STP statistics separately from status") * Fixed test failures in Patch #2 * Rebase against master A full description can be found in the previous posting: https://www.mail-archive.com/d

[ovs-dev] [PATCHv4 2/4] ofproto-dpif: Don't poll ports when nothing changes

2013-12-11 Thread Joe Stringer
Currently, as part of ofproto-dpif run() processing, we loop through all ports and poll corresponding devices for changes in carrier, cfm and bfd status. This allows us to determine how it may affect bundles. For the average case where devices are not going up or down constantly, this is a large am

Re: [ovs-dev] [PATCH RFC] netdev-linux: Read packet auxdata to obtain vlan_tid

2013-12-11 Thread Ben Pfaff
On Wed, Dec 11, 2013 at 11:24:14AM +0900, Simon Horman wrote: > If VLAN acceleration is used when the kernel receives a packet > then the outer-most VLAN tag will not be present in the packet > when it is received by netdev-linux. Rather, it will be present > in auxdata. > > This patch uses recvms

Re: [ovs-dev] [Windows thread 2]

2013-12-11 Thread Alin Serdean
Hey, After the include_next from string.h(wrapper) will be solved we will be faced with another scenario. Unfortunately on MSVC we don't have inline we have __inline(see http://msdn.microsoft.com/en-us/library/cx3b23a3.aspx for more information) so it is either autoconf magic again :-) or an i

[ovs-dev] [Windows thread 3]

2013-12-11 Thread Alin Serdean
Hey, The following is a quick patch for secure pseudorandom number generator on windows. I split the functionality with a brutal ifdef macro. Feedback on the code and suggestions for a nicer implementation is appreciated :). diff --git a/lib/entropy.c b/lib/entropy.c index 02f56e0..ec9d95c 100

Re: [ovs-dev] [Windows thread 3]

2013-12-11 Thread Ben Pfaff
On Wed, Dec 11, 2013 at 06:02:58PM +, Alin Serdean wrote: > The following is a quick patch for secure pseudorandom number > generator on windows. I split the functionality with a brutal ifdef > macro. Feedback on the code and suggestions for a nicer > implementation is appreciated :). I'm fine

Re: [ovs-dev] [port-renumbering 6/8] lacp: Make lacp negotiation test hard-code aggregation keys.

2013-12-11 Thread Jarno Rajahalme
I bumped to this yesterday and had the exact same patch ready to be sent, so: Acked-by: Jarno Rajahalme On Dec 10, 2013, at 11:20 PM, Ben Pfaff wrote: > The lacp implementation takes the aggregation key from the key or portid > of the first slave to be added to the lacp object. When multiple

Re: [ovs-dev] [PATCH] coverage: Fix build when linker sections not supported.

2013-12-11 Thread Gurucharan Shetty
On Sat, Dec 7, 2013 at 8:17 AM, Ben Pfaff wrote: > With this change, OVS builds and runs fine without linker section support. > > CC: Linda Sun > CC: Saurabh Shah > Signed-off-by: Ben Pfaff Looks good to me. > --- > lib/coverage.c |2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > >

Re: [ovs-dev] [port-renumbering 1/8] ofproto-dpif: Improve comment.

2013-12-11 Thread Jarno Rajahalme
Acked-by: Jarno Rajahalme On Dec 10, 2013, at 11:19 PM, Ben Pfaff wrote: > Signed-off-by: Ben Pfaff > --- > ofproto/ofproto-dpif.c |2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/ofproto/ofproto-dpif.c b/ofproto/ofproto-dpif.c > index ff77903..bfa9a9a 100644 > --- a

Re: [ovs-dev] [port-renumbering 2/8] ofproto-provider: Add comment on struct ofport.

2013-12-11 Thread Jarno Rajahalme
Acked-by: Jarno Rajahalme On Dec 10, 2013, at 11:19 PM, Ben Pfaff wrote: > Signed-off-by: Ben Pfaff > --- > ofproto/ofproto-provider.h |2 ++ > 1 file changed, 2 insertions(+) > > diff --git a/ofproto/ofproto-provider.h b/ofproto/ofproto-provider.h > index 54d97f1..600b92b 100644 > --- a/o

Re: [ovs-dev] [port-renumbering 3/8] ofproto: Make ofproto_enumerate_types() match its comment.

2013-12-11 Thread Jarno Rajahalme
Acked-by: Jarno Rajahalme On Dec 10, 2013, at 11:19 PM, Ben Pfaff wrote: > The comment says that it clears the passed-in sset, but it didn't. The bug > didn't actually affect any of the existing callers, which all passed in an > empty sset. > > Signed-off-by: Ben Pfaff > --- > ofproto/ofprot

Re: [ovs-dev] [port-renumbering 4/8] ofproto: Fix alphabetical order in list of structs.

2013-12-11 Thread Jarno Rajahalme
Acked-by: Jarno Rajahalme On Dec 10, 2013, at 11:20 PM, Ben Pfaff wrote: > Signed-off-by: Ben Pfaff > --- > ofproto/ofproto.h |4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) > > diff --git a/ofproto/ofproto.h b/ofproto/ofproto.h > index d734eab..6197278 100644 > --- a/ofproto/of

Re: [ovs-dev] [port-renumbering 5/8] netdev: Log a warning when netdev_set_config() fails.

2013-12-11 Thread Jarno Rajahalme
On Dec 10, 2013, at 11:20 PM, Ben Pfaff wrote: > This allows its callers to avoid duplicating the code. > > Signed-off-by: Ben Pfaff > --- > lib/netdev.c | 10 -- > utilities/ovs-dpctl.c |2 -- > vswitchd/bridge.c |9 + > 3 files changed, 9 insertions(+), 12

Re: [ovs-dev] [Windows thread 2]

2013-12-11 Thread Gurucharan Shetty
On Wed, Dec 11, 2013 at 9:43 AM, Alin Serdean wrote: > Hey, > > After the include_next from string.h(wrapper) will be solved we will be faced > with another scenario. > > Unfortunately on MSVC we don't have inline we have __inline(see > http://msdn.microsoft.com/en-us/library/cx3b23a3.aspx for m

Re: [ovs-dev] [PATCH v6 1/2] dpif-netdev: Properly create exact match masks.

2013-12-11 Thread Ben Pfaff
On Mon, Dec 09, 2013 at 06:35:57PM -0800, Jarno Rajahalme wrote: > Normally OVS userspace supplies a mask along with a flow key for each > new data path flow that should be created. OVS also provides an > option to disable the kernel wildcarding, in which case the flows are > created without a mas

Re: [ovs-dev] [PATCH v6 2/2] Classifier: Track address prefixes.

2013-12-11 Thread Ben Pfaff
On Mon, Dec 09, 2013 at 06:35:58PM -0800, Jarno Rajahalme wrote: > Add a prefix tree (trie) structure for tracking the used address > space, enabling skipping classifier tables containing longer masks > than necessary for an address field value in a packet header being > classified. This enables l

Re: [ovs-dev] [PATCH] coverage: Fix build when linker sections not supported.

2013-12-11 Thread Ben Pfaff
On Wed, Dec 11, 2013 at 10:17:40AM -0800, Gurucharan Shetty wrote: > On Sat, Dec 7, 2013 at 8:17 AM, Ben Pfaff wrote: > > With this change, OVS builds and runs fine without linker section support. > > > > CC: Linda Sun > > CC: Saurabh Shah > > Signed-off-by: Ben Pfaff > Looks good to me. Appli

Re: [ovs-dev] [PATCHv4 1/4] netdev: Globally track port status changes

2013-12-11 Thread Ethan Jackson
Couple of comments. Do we need a whole new module for the connectivity seq stuff? Couldn't we just do with an extern global struct seq *? That said, it's not exactly clear where we'd put it, so perhaps a separate module is the way to go. I don't feel strongly about it. Along those same lines, i

Re: [ovs-dev] [port-renumbering 5/8] netdev: Log a warning when netdev_set_config() fails.

2013-12-11 Thread Ben Pfaff
On Wed, Dec 11, 2013 at 10:24:50AM -0800, Jarno Rajahalme wrote: > > On Dec 10, 2013, at 11:20 PM, Ben Pfaff wrote: > > > This allows its callers to avoid duplicating the code. > > > > Signed-off-by: Ben Pfaff > > --- > > lib/netdev.c | 10 -- > > utilities/ovs-dpctl.c |2

[ovs-dev] [PATCH] datapath: Fix sparse warning.

2013-12-11 Thread Jarno Rajahalme
Make the new compat function skb_flow_get_ports() static to silence a sparse warning. Signed-off-by: Jarno Rajahalme --- datapath/linux/compat/flow_dissector.c |2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/datapath/linux/compat/flow_dissector.c b/datapath/linux/compat/f

[ovs-dev] [PATCH] lib/util: Only define count_1bits_8 when needed.

2013-12-11 Thread Jarno Rajahalme
util.h declares this when needed, make sure the definition is compiled in only in that case. Signed-off-by: Jarno Rajahalme --- lib/util.c |2 +- lib/util.h | 18 -- 2 files changed, 13 insertions(+), 7 deletions(-) diff --git a/lib/util.c b/lib/util.c index 13d41a7..00050

Re: [ovs-dev] [PATCH] datapath: Fix sparse warning.

2013-12-11 Thread Pravin Shelar
On Wed, Dec 11, 2013 at 10:51 AM, Jarno Rajahalme wrote: > Make the new compat function skb_flow_get_ports() static to silence a > sparse warning. > > Signed-off-by: Jarno Rajahalme > --- > datapath/linux/compat/flow_dissector.c |2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff

Re: [ovs-dev] [PATCHv4 1/4] netdev: Globally track port status changes

2013-12-11 Thread Joe Stringer
On 11 December 2013 10:44, Ethan Jackson wrote: > Couple of comments. > > Do we need a whole new module for the connectivity seq stuff? > Couldn't we just do with an extern global struct seq *? That said, > it's not exactly clear where we'd put it, so perhaps a separate module > is the way to go.

Re: [ovs-dev] [PATCH v6 1/2] dpif-netdev: Properly create exact match masks.

2013-12-11 Thread Jarno Rajahalme
Pushed to master, Jarno On Dec 11, 2013, at 10:36 AM, Ben Pfaff wrote: > On Mon, Dec 09, 2013 at 06:35:57PM -0800, Jarno Rajahalme wrote: >> Normally OVS userspace supplies a mask along with a flow key for each >> new data path flow that should be created. OVS also provides an >> option to d

Re: [ovs-dev] [PATCH v6 2/2] Classifier: Track address prefixes.

2013-12-11 Thread Jarno Rajahalme
Thanks for the review Ben! Pushed to master with the changes proposed, Jarno On Dec 11, 2013, at 10:38 AM, Ben Pfaff wrote: > On Mon, Dec 09, 2013 at 06:35:58PM -0800, Jarno Rajahalme wrote: >> Add a prefix tree (trie) structure for tracking the used address >> space, enabling skipping class

[ovs-dev] [PATCH] lib/jhash.c: Fix comment.

2013-12-11 Thread Jarno Rajahalme
Signed-off-by: Jarno Rajahalme --- lib/jhash.c |2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/jhash.c b/lib/jhash.c index c08c368..c59b51b 100644 --- a/lib/jhash.c +++ b/lib/jhash.c @@ -91,7 +91,7 @@ jhash_words(const uint32_t *p, size_t n, uint32_t basis) /* Return

Re: [ovs-dev] [port-renumbering 6/8] lacp: Make lacp negotiation test hard-code aggregation keys.

2013-12-11 Thread Ben Pfaff
Great minds think alike, I guess. I applied patches 1 through 6 to master. On Wed, Dec 11, 2013 at 10:15:25AM -0800, Jarno Rajahalme wrote: > I bumped to this yesterday and had the exact same patch ready to be sent, so: > > Acked-by: Jarno Rajahalme > > > On Dec 10, 2013, at 11:20 PM, Ben Pfa

Re: [ovs-dev] [PATCH] lib/jhash.c: Fix comment.

2013-12-11 Thread Ben Pfaff
On Wed, Dec 11, 2013 at 11:14:06AM -0800, Jarno Rajahalme wrote: > Signed-off-by: Jarno Rajahalme Acked-by: Ben Pfaff ___ dev mailing list dev@openvswitch.org http://openvswitch.org/mailman/listinfo/dev

Re: [ovs-dev] [PATCH] lib/jhash.c: Fix comment.

2013-12-11 Thread Jarno Rajahalme
Pushed, Jarno On Dec 11, 2013, at 11:14 AM, Ben Pfaff wrote: > On Wed, Dec 11, 2013 at 11:14:06AM -0800, Jarno Rajahalme wrote: >> Signed-off-by: Jarno Rajahalme > > Acked-by: Ben Pfaff ___ dev mailing list dev@openvswitch.org http://openvswitc

Re: [ovs-dev] [PATCH] datapath: Fix sparse warning.

2013-12-11 Thread Jarno Rajahalme
Pushed to master, Jarno On Dec 11, 2013, at 10:53 AM, Pravin Shelar wrote: > On Wed, Dec 11, 2013 at 10:51 AM, Jarno Rajahalme > wrote: >> Make the new compat function skb_flow_get_ports() static to silence a >> sparse warning. >> >> Signed-off-by: Jarno Rajahalme >> --- >> datapath/linux

Re: [ovs-dev] [PATCH] lib/util: Only define count_1bits_8 when needed.

2013-12-11 Thread Ben Pfaff
On Wed, Dec 11, 2013 at 10:54:00AM -0800, Jarno Rajahalme wrote: > util.h declares this when needed, make sure the definition is compiled > in only in that case. > > Signed-off-by: Jarno Rajahalme With this, I still get: ../lib/util.c:921:15: warning: symbol 'count_1bits_8' was not decla

[ovs-dev] [PATCH] ofproto-dpif: Ignore non-packet field masks during flow revalidation

2013-12-11 Thread Andy Zhou
Commit bcd2633a5be(ofproto-dpif: Store relevant fields for wildcarding in facet) implements flow revalidation by comparing the newly looked up flow mask with that of the existing facet. The non-packet fields, such as register masks, are always cleared by xlate_actions in the masks stored within fa

Re: [ovs-dev] [PATCH] ofproto-dpif: Ignore non-packet field masks during flow revalidation

2013-12-11 Thread Justin Pettit
On Dec 11, 2013, at 11:37 AM, Andy Zhou wrote: > diff --git a/ofproto/ofproto-dpif.c b/ofproto/ofproto-dpif.c > index ff77903..8d9a9bd 100644 > --- a/ofproto/ofproto-dpif.c > +++ b/ofproto/ofproto-dpif.c > @@ -4219,6 +4219,9 @@ facet_revalidate(struct facet *facet) > xlate_in_init(&xin, ofpro

Re: [ovs-dev] [Windows thread 3]

2013-12-11 Thread Saurabh Shah
Hey, The following is a quick patch for secure pseudorandom number generator on windows. I split the functionality with a brutal ifdef macro. Feedback on the code and suggestions for a nicer implementation is appreciated :). diff --git a/lib/entropy.c b/lib/entropy.c index 02f56e0..ec9d95c 10

Re: [ovs-dev] [RFC 1/4] compiler: Add OVS_CONSTRUCTOR to mark functions as init functions

2013-12-11 Thread Ben Pfaff
On Tue, Dec 10, 2013 at 02:49:27PM +0100, Helmut Schaa wrote: > Functions marked with OVS_CONSTRUCTOR are called unconditionally > before main. > > Signed-off-by: Helmut Schaa > --- > > This works with gcc (tested), should work with clang (untested) > but does not work with MSVS. > > Could anyo

Re: [ovs-dev] [RFC 2/4] vlog: Use OVS_CONSTRUCTOR for vlog initialization

2013-12-11 Thread Ben Pfaff
On Tue, Dec 10, 2013 at 02:49:28PM +0100, Helmut Schaa wrote: > This allows to get rid of some special segment handling to allow > distributed registering of vlog modules. > > Instead use a global list and vlog module constructor functions to > build up the list. That means vlog modules reside wit

Re: [ovs-dev] [RFC 3/4] coverage: Use OVS_CONSTRUCTOR to initialize the coverage counter array

2013-12-11 Thread Ben Pfaff
On Tue, Dec 10, 2013 at 02:49:29PM +0100, Helmut Schaa wrote: > Use a global array that gets initialized by constructor functions > per coverage definition. > > Signed-off-by: Helmut Schaa > --- > > The realloc is not the nicest thing to do but looks reasonable as initial > approach. Using a lis

Re: [ovs-dev] [RFC 4/4] Remove unused USE_LINKER_SECTIONS

2013-12-11 Thread Ben Pfaff
On Tue, Dec 10, 2013 at 02:49:30PM +0100, Helmut Schaa wrote: > > Signed-off-by: Helmut Schaa You can also remove OVS_LINK2_IFELSE. Thanks, Ben. ___ dev mailing list dev@openvswitch.org http://openvswitch.org/mailman/listinfo/dev

Re: [ovs-dev] [RFC 1/4] compiler: Add OVS_CONSTRUCTOR to mark functions as init functions

2013-12-11 Thread Ben Pfaff
On Wed, Dec 11, 2013 at 12:58 PM, Ben Pfaff wrote: > On Tue, Dec 10, 2013 at 02:49:27PM +0100, Helmut Schaa wrote: > > Functions marked with OVS_CONSTRUCTOR are called unconditionally > > before main. > > > > Signed-off-by: Helmut Schaa > > --- > > > > This works with gcc (tested), should work w

Re: [ovs-dev] [port-renumbering 7/8] bridge: Reconfigure in single pass.

2013-12-11 Thread Jarno Rajahalme
On Dec 10, 2013, at 11:20 PM, Ben Pfaff wrote: > This greatly simplifies the reconfiguration code, making it much easier > to understand and modify. The old multi-pass configuration had the > property that it didn't delay block packet processing as much, but that's > not much of a worry anymore

Re: [ovs-dev] [PATCH 2/2] lib: Determine cpu core count with /proc/cpuinfo

2013-12-11 Thread Ed Maste
On 5 December 2013 18:42, Joe Stringer wrote: > On systems that provide /proc/cpuinfo similar to Linux on x86, this > should allow us to choose a better default value for the number of > upcall handler threads---in particular, it avoids counting hyper-thread > cores. If /proc/cpuinfo cannot be par

Re: [ovs-dev] [PATCH 2/2] lib: Determine cpu core count with /proc/cpuinfo

2013-12-11 Thread Joe Stringer
Hmm. Is it enough set a lower log level? /proc/cpuinfo parsing isn't strictly required. On 11 December 2013 13:26, Ed Maste wrote: > On 5 December 2013 18:42, Joe Stringer wrote: >> On systems that provide /proc/cpuinfo similar to Linux on x86, this >> should allow us to choose a better default

Re: [ovs-dev] [PATCH] ofproto-dpif: Ignore non-packet field masks during flow revalidation

2013-12-11 Thread Andy Zhou
Thanks for the review, pushed to master and branch-2.0 with fixes suggested. On Wed, Dec 11, 2013 at 11:48 AM, Justin Pettit wrote: > On Dec 11, 2013, at 11:37 AM, Andy Zhou wrote: > > > diff --git a/ofproto/ofproto-dpif.c b/ofproto/ofproto-dpif.c > > index ff77903..8d9a9bd 100644 > > --- a/of

[ovs-dev] [PATCH] ovs-thread: Reduce logging level for cpuinfo parsing

2013-12-11 Thread Joe Stringer
This was causing test failures on non-Linux platforms. Reported-by: Ed Maste Signed-off-by: Joe Stringer --- lib/ovs-thread.c |2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/ovs-thread.c b/lib/ovs-thread.c index 1a633cf..dcaf7ff 100644 --- a/lib/ovs-thread.c +++ b/lib

Re: [ovs-dev] [PATCH 2/2] lib: Determine cpu core count with /proc/cpuinfo

2013-12-11 Thread Joe Stringer
I'm pretty sure that we only care about this warning if we are specifically investigating how we calculate the number of threads to use. I've sent a patch below to reduce this to debug logging:- http://openvswitch.org/pipermail/dev/2013-December/034899.html

Re: [ovs-dev] [PATCH] ovs-thread: Reduce logging level for cpuinfo parsing

2013-12-11 Thread Ethan Jackson
Merged thanks. On Wed, Dec 11, 2013 at 1:46 PM, Joe Stringer wrote: > This was causing test failures on non-Linux platforms. > > Reported-by: Ed Maste > Signed-off-by: Joe Stringer > --- > lib/ovs-thread.c |2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/lib/ovs-thre

Re: [ovs-dev] [port-renumbering 6/8] lacp: Make lacp negotiation test hard-code aggregation keys.

2013-12-11 Thread Ethan Jackson
FWIW I'm fine with this as well. Ethan On Wed, Dec 11, 2013 at 11:13 AM, Ben Pfaff wrote: > Great minds think alike, I guess. > > I applied patches 1 through 6 to master. > > On Wed, Dec 11, 2013 at 10:15:25AM -0800, Jarno Rajahalme wrote: >> I bumped to this yesterday and had the exact same pat

Re: [ovs-dev] [port-renumbering 7/8] bridge: Reconfigure in single pass.

2013-12-11 Thread Jarno Rajahalme
Ben, I did some additional testing and accidentally found out a problem with this patch: While testing the code I accidentally requested a change in the interface type (to dummy), like this: # ovs-vsctl add-br br0 # ovs-vsctl add-port br0 p1 -- set Interface p1 type=internal # ovs-vsctl -- set

Re: [ovs-dev] [port-renumbering 8/8] bridge: Support changing port numbers.

2013-12-11 Thread Jarno Rajahalme
On Dec 10, 2013, at 11:20 PM, Ben Pfaff wrote: > Feature #21293. > Requested-by: Anuprem Chalvadi > Signed-off-by: Ben Pfaff > --- > NEWS |3 ++ > vswitchd/bridge.c| 93 -- > vswitchd/vswitch.xml | 21 +++- > 3 fi

Re: [ovs-dev] [PATCH] ofproto-dpif: Ignore non-packet field masks during flow revalidation

2013-12-11 Thread Justin Pettit
Did you determine whether it should be backported to branch-1.11? --Justin On Dec 11, 2013, at 1:34 PM, Andy Zhou wrote: > Thanks for the review, pushed to master and branch-2.0 with fixes suggested. > > > On Wed, Dec 11, 2013 at 11:48 AM, Justin Pettit wrote: > On Dec 11, 2013, at 11:37 AM

Re: [ovs-dev] [port-renumbering 7/8] bridge: Reconfigure in single pass.

2013-12-11 Thread Ethan Jackson
I'm happy with this once the segfault is fixed. Ethan On Tue, Dec 10, 2013 at 11:20 PM, Ben Pfaff wrote: > This greatly simplifies the reconfiguration code, making it much easier > to understand and modify. The old multi-pass configuration had the > property that it didn't delay block packet pr

Re: [ovs-dev] [PATCH] ofproto-dpif: Ignore non-packet field masks during flow revalidation

2013-12-11 Thread Andy Zhou
It looks to me this needs to be back ported. But I would like to make sure the same bug exists on branch-1.11 before applying. What do you think? On Wed, Dec 11, 2013 at 2:23 PM, Justin Pettit wrote: > Did you determine whether it should be backported to branch-1.11? > > --Justin > > > On Dec 1

Re: [ovs-dev] [PATCH] ofproto-dpif: Ignore non-packet field masks during flow revalidation

2013-12-11 Thread Justin Pettit
As we discussed off-line, I think you can reproduce this pretty easily with a fairly simple flow table. --Justin On Dec 11, 2013, at 2:43 PM, Andy Zhou wrote: > It looks to me this needs to be back ported. But I would like to make sure > the same bug exists on branch-1.11 before applying. Wh

[ovs-dev] [PATCH 2/2] string: Use workaround for #include_next when it is not available.

2013-12-11 Thread Ben Pfaff
Signed-off-by: Ben Pfaff --- configure.ac |3 +++ lib/automake.mk |2 +- lib/{string.h => string.h.in} |4 ++-- 3 files changed, 6 insertions(+), 3 deletions(-) rename lib/{string.h => string.h.in} (93%) diff --git a/configure.ac b/configure.ac index 1

[ovs-dev] [PATCH 1/2] configure: Add macros to check for #include_next and add a workaround.

2013-12-11 Thread Ben Pfaff
This will be used for the #include_next in string.h in the following commit. Signed-off-by: Ben Pfaff --- NOTICE|5 +- build-aux/.gitignore |2 + debian/copyright.in | 10 ++- m4/absolute-header.m4 | 102 ++ m4/include_next.m4| 223 +

Re: [ovs-dev] [PATCH] lib: Bypass include_next preprocessor directives on Windows platform

2013-12-11 Thread Ben Pfaff
On Mon, Dec 09, 2013 at 08:34:25PM +, Alin Serdean wrote: > I would leave it up too you. An easier solution would be to put in > the Vstudio includes first(in the case for cccl) because there is no > need for the string.h wrapper. I sent out a two-patch series, will you try it out? htt

Re: [ovs-dev] [port-renumbering 7/8] bridge: Reconfigure in single pass.

2013-12-11 Thread Ben Pfaff
On Wed, Dec 11, 2013 at 02:17:13PM -0800, Jarno Rajahalme wrote: > While testing the code I accidentally requested a change in the interface > type (to dummy), like this: > > # ovs-vsctl add-br br0 > # ovs-vsctl add-port br0 p1 -- set Interface p1 type=internal > # ovs-vsctl -- set Interface p1 t

Re: [ovs-dev] [PATCH] lib/util: Only define count_1bits_8 when needed.

2013-12-11 Thread Jarno Rajahalme
Ben, I like this, I’ll post a new patch ASAP, Jarno On Dec 11, 2013, at 11:33 AM, Ben Pfaff wrote: > On Wed, Dec 11, 2013 at 10:54:00AM -0800, Jarno Rajahalme wrote: >> util.h declares this when needed, make sure the definition is compiled >> in only in that case. >> >> Signed-off-by: Jarno

Re: [ovs-dev] [port-renumbering 7/8] bridge: Reconfigure in single pass.

2013-12-11 Thread Ben Pfaff
On Wed, Dec 11, 2013 at 01:27:25PM -0800, Jarno Rajahalme wrote: > > On Dec 10, 2013, at 11:20 PM, Ben Pfaff wrote: > > > This greatly simplifies the reconfiguration code, making it much easier > > to understand and modify. The old multi-pass configuration had the > > property that it didn't de

[ovs-dev] [PATCH] lib/util: More portable use of builtin popcnt.

2013-12-11 Thread Jarno Rajahalme
- Use the GCC predefined macro __POPCNT__ to detect the availability of fast __builtin_popcnt function. - Use portable preprocessor macros to detect 64-bit build. - Only define the 32-bit parts when needed and declare the count_1bits_8 at file scope to silence a warning. This time I have teste

Re: [ovs-dev] [PATCH 2/2] lib: Determine cpu core count with /proc/cpuinfo

2013-12-11 Thread Joe Stringer
Thanks Ed, it should be fixed on master now. On 11 December 2013 13:47, Joe Stringer wrote: > I'm pretty sure that we only care about this warning if we are > specifically investigating how we calculate the number of threads to > use. > > I've sent a patch below to reduce this to debug logging:-

Re: [ovs-dev] [port-renumbering 7/8] bridge: Reconfigure in single pass.

2013-12-11 Thread Jarno Rajahalme
On Dec 11, 2013, at 3:14 PM, Ben Pfaff wrote: > On Wed, Dec 11, 2013 at 02:17:13PM -0800, Jarno Rajahalme wrote: >> While testing the code I accidentally requested a change in the interface >> type (to dummy), like this: >> >> # ovs-vsctl add-br br0 >> # ovs-vsctl add-port br0 p1 -- set Interf

[ovs-dev] [PATCH] ovs-thread: Break recursion for coverage counters.

2013-12-11 Thread Gurucharan Shetty
For systems that do not use linker sections and also do not have either HAVE_THREAD_LOCAL or HAVE___THREAD (ex: windows using MSVC), a COVERAGE_INC() calls xmalloc which inturn calls COVERAGE_INC() creating a recursion that causes a stack overflow. This commit breaks the recursion by calling mallo

Re: [ovs-dev] [PATCH RFC] netdev-linux: Read packet auxdata to obtain vlan_tid

2013-12-11 Thread Simon Horman
On Wed, Dec 11, 2013 at 09:31:49AM -0800, Ben Pfaff wrote: > On Wed, Dec 11, 2013 at 11:24:14AM +0900, Simon Horman wrote: > > If VLAN acceleration is used when the kernel receives a packet > > then the outer-most VLAN tag will not be present in the packet > > when it is received by netdev-linux. R

[ovs-dev] [PATCH RFC] ofproto: Allow multiple array elements in PORT_DESC request body

2013-12-11 Thread Simon Horman
Signed-off-by: Simon Horman --- This change is also needed for several other stats request messages. I have posted this as an RFC before proceeding with updating the decoders for other stats request messages. --- lib/ofp-msgs.h| 4 ++-- lib/ofp-print.c | 23 +++ lib/o

[ovs-dev] [PATCH RFC] ofproto: Allow multiple array elements in PORT_DESC request body

2013-12-11 Thread Simon Horman
Signed-off-by: Simon Horman --- This change is also needed for several other stats request messages. I have posted this as an RFC before proceeding with updating the decoders for other stats request messages. --- lib/ofp-msgs.h| 4 ++-- lib/ofp-print.c | 23 +++ lib/o

Re: [ovs-dev] [PATCH RFC] ofproto: Allow multiple array elements in PORT_DESC request body

2013-12-11 Thread Ben Pfaff
On Thu, Dec 12, 2013 at 09:36:03AM +0900, Simon Horman wrote: > Signed-off-by: Simon Horman > > --- > > This change is also needed for several other stats request messages. > I have posted this as an RFC before proceeding with updating What's the rationale for the change? As far as I can tell,

Re: [ovs-dev] [port-renumbering 7/8] bridge: Reconfigure in single pass.

2013-12-11 Thread Ben Pfaff
On Wed, Dec 11, 2013 at 04:09:57PM -0800, Jarno Rajahalme wrote: > > On Dec 11, 2013, at 3:14 PM, Ben Pfaff wrote: > > > On Wed, Dec 11, 2013 at 02:17:13PM -0800, Jarno Rajahalme wrote: > >> While testing the code I accidentally requested a change in the interface > >> type (to dummy), like thi

Re: [ovs-dev] [PATCHv4 2/4] ofproto-dpif: Don't poll ports when nothing changes

2013-12-11 Thread Ethan Jackson
Acked-by: Ethan Jackson Could you fold my acked by into the commit message so when you resend rebased on the new version of the first patch, I know not to review it again? Thanks On Wed, Dec 11, 2013 at 9:10 AM, Joe Stringer wrote: > Currently, as part of ofproto-dpif run() processing, we loop

Re: [ovs-dev] [PATCHv4 3/4] ofproto-dpif: Only run bundles when lacp or bonds are enabled

2013-12-11 Thread Ethan Jackson
Acked-by: Ethan Jackson On Wed, Dec 11, 2013 at 9:10 AM, Joe Stringer wrote: > When dealing with a large number of ports, bundle_run() and > bundle_wait() add significant unnecessary processing to the main run > loop, even when there are no bonds and lacp is not configured. This > patch skips s

Re: [ovs-dev] [PATCHv4 4/4] bridge: Only store instant_stats on device changes

2013-12-11 Thread Ethan Jackson
Acked-by: Ethan Jackson The first line of the commit message needs a period. On Wed, Dec 11, 2013 at 9:10 AM, Joe Stringer wrote: > Previously, we iterated through all interfaces in instant_stats_run(), > grabbing up-to-date information about device status. After assembling > all of this inform

Re: [ovs-dev] [PATCHv4 1/4] netdev: Globally track port status changes

2013-12-11 Thread Ethan Jackson
I've reviewed this entire series except for the new version of the first patch. Ben, I'll be traveling all day tomorrow, so once Joe sends the new version of this patch, would you please merge the series for me? Thanks, Ethan On Wed, Dec 11, 2013 at 10:58 AM, Joe Stringer wrote: > On 11 Decembe

Re: [ovs-dev] [threaded-put 14/21] ofproto-dpif-xlate: Add a mechanism to skip wildcard calculation.

2013-12-11 Thread Ethan Jackson
Btw to whoever reviews this, this version of the patch fails to initialize skip_wildcards in xlate_in_init(). Ethan On Sun, Dec 8, 2013 at 6:45 PM, Ethan Jackson wrote: > As time goes on and the classifier becomes more complicated, calculate > the wildcard mask will get more and more expensive.

Re: [ovs-dev] [PATCH RFC] ofproto: Allow multiple array elements in PORT_DESC request body

2013-12-11 Thread Simon Horman
On Wed, Dec 11, 2013 at 05:34:28PM -0800, Ben Pfaff wrote: > On Thu, Dec 12, 2013 at 09:36:03AM +0900, Simon Horman wrote: > > Signed-off-by: Simon Horman > > > > --- > > > > This change is also needed for several other stats request messages. > > I have posted this as an RFC before proceeding w

Re: [ovs-dev] [PATCH] ovs-thread: Break recursion for coverage counters.

2013-12-11 Thread Saurabh Shah
Looks good to me. Thanks for fixing this! From: Gurucharan Shetty mailto:shet...@nicira.com>> Date: Wednesday, December 11, 2013 4:11 PM To: "dev@openvswitch.org" mailto:dev@openvswitch.org>> Subject: [ovs-dev] [PATCH] ovs-thread: Break recursion for coverage counters.

Re: [ovs-dev] [PATCH] lib/util: More portable use of builtin popcnt.

2013-12-11 Thread Simon Horman
On Wed, Dec 11, 2013 at 03:41:19PM -0800, Jarno Rajahalme wrote: > - Use the GCC predefined macro __POPCNT__ to detect the availability > of fast __builtin_popcnt function. > - Use portable preprocessor macros to detect 64-bit build. > - Only define the 32-bit parts when needed and declare the >

Re: [ovs-dev] [port-renumbering 7/8] bridge: Reconfigure in single pass.

2013-12-11 Thread Ben Pfaff
On Wed, Dec 11, 2013 at 05:55:35PM -0800, Ben Pfaff wrote: > On Wed, Dec 11, 2013 at 04:09:57PM -0800, Jarno Rajahalme wrote: > > > > On Dec 11, 2013, at 3:14 PM, Ben Pfaff wrote: > > > > > On Wed, Dec 11, 2013 at 02:17:13PM -0800, Jarno Rajahalme wrote: > > >> While testing the code I accidenta

Re: [ovs-dev] [port-renumbering 8/8] bridge: Support changing port numbers.

2013-12-11 Thread Ben Pfaff
On Wed, Dec 11, 2013 at 02:17:56PM -0800, Jarno Rajahalme wrote: > > On Dec 10, 2013, at 11:20 PM, Ben Pfaff wrote: > > > Feature #21293. > > Requested-by: Anuprem Chalvadi > > Signed-off-by: Ben Pfaff > > --- > > NEWS |3 ++ > > vswitchd/bridge.c| 93 > >