Re: [ovs-dev] [PATCH] stuck with 16-bit ifr_flags in FreeBSD

2015-04-03 Thread Ed Maste
On 3 April 2015 at 13:46, Ben Pfaff wrote: > >> > Also, the commit you name was in 2013, and we've had other >> > contributions from FreeBSD contributors since then >> > (namely Ed Maste ) and it seems like he >> > would have noticed if it were totally

Re: [ovs-dev] [PATCH] stuck with 16-bit ifr_flags in FreeBSD

2015-04-04 Thread Ed Maste
On 4 April 2015 at 12:56, Kevin Lo wrote: >> Kevin, what failure mode did you observe? > > On FreeBSD, multicast is enabled on the interface by default, the value of > ifr_flags could be negative if multicast is enabled. Right, but what actually happens in this case? The sign extension bug means

Re: [ovs-dev] [PATCH V2 09/10] dpif-netdev: Add DPDK netdev.

2014-03-26 Thread Ed Maste
On 21 March 2014 14:03, Pravin wrote: > Following patch adds DPDK netdev-class to userspace datapath. Now > OVS can use DPDK port for IO by just configuring DPDK port and then > adding dpdk type port to userspace datapath. Intel recently released DPDK also for FreeBSD, so it may be worth referrin

[ovs-dev] [PATCH] AUTHORS: use actual address for ema...@freebsd.org

2015-10-29 Thread Ed Maste
Signed-off-by: Ed Maste --- I don't recall how I ended up with this naive anti-spam obfuscation in AUTHORS. In any case there's no reason to have one inconsistent entry here. AUTHORS | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/AUTHORS b/AUTHORS index f4e1ca

[ovs-dev] [PATCH] netdev: Add NULL get_tunnel_config for BSD.

2013-01-16 Thread Ed Maste
Commit f431bf7d78f3212d32bb3d122f783c5c796a1576 added new method get_tunnel_config to netdev_class but did not update netdev-bsd. Signed-off-by: Ed Maste --- lib/netdev-bsd.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/lib/netdev-bsd.c b/lib/netdev-bsd.c index 9094d04..538f91a 100644

Re: [ovs-dev] [patch_ports (rebased) 3/4] ofproto-dpif: Implement patch ports in userspace.

2013-01-23 Thread Ed Maste
On 23 January 2013 15:51, Ethan Jackson wrote: > diff --git a/FAQ b/FAQ > index ab1c1cc..a466ca4 100644 > --- a/FAQ > +++ b/FAQ > @@ -172,17 +172,24 @@ A: The kernel module in upstream Linux 3.3 and later > does not include > vSwitch distribution instead of the upstream Linux kernel >

Re: [ovs-dev] [patch_ports (rebased) 3/4] ofproto-dpif: Implement patch ports in userspace.

2013-01-23 Thread Ed Maste
On 23 January 2013 18:40, Ben Pfaff wrote: > I think something got mixed up. Here's the change that I expected to > see here: > > -- > diff --git a/FAQ b/FAQ > index ab1c1cc..bd4d37e 100644 > --- a/FAQ > +++ b/FAQ > @@ -158,28 +1

Re: [ovs-dev] [tunnel 00/11] Flow based tunneling.

2013-01-28 Thread Ed Maste
On 27 January 2013 19:58, Ethan Jackson wrote: > This version of the series implements enough of the flow based > tunneling that we can begin testing. There are still some things > which need to be done (described in ofproto/tunnel.c) which we will > need to complete before making a release. As

Re: [ovs-dev] [tunnel 00/11] Flow based tunneling.

2013-01-28 Thread Ed Maste
On 28 January 2013 12:44, Ben Pfaff wrote: > On Mon, Jan 28, 2013 at 10:43:23AM -0500, Ed Maste wrote: >> On 27 January 2013 19:58, Ethan Jackson wrote: >> > This version of the series implements enough of the flow based >> > tunneling that we can begin testing.

Re: [ovs-dev] [tunnel 07/11] netdev: New function netdev_get_dpif_port().

2013-01-28 Thread Ed Maste
On 27 January 2013 19:58, Ethan Jackson wrote: > diff --git a/lib/netdev-linux.c b/lib/netdev-linux.c > index f0f1dc2..a06aef3 100644 > --- a/lib/netdev-linux.c > +++ b/lib/netdev-linux.c > @@ -2430,6 +2430,7 @@ netdev_linux_change_seq(const struct netdev *netdev) >

Re: [ovs-dev] [tunnel 00/11] Flow based tunneling.

2013-01-29 Thread Ed Maste
On 29 January 2013 00:12, Ben Pfaff wrote: > It looks like Ethan was able to fix the problems--he posted a new > version of patch 11 that says it fixes FreeBSD test failures. I didn't receive the new version of patch 11 (maybe Gmail decided it was a duplicate), but I grabbed it from the archive a

Re: [ovs-dev] [PATCH 01/18] fix an obvious mistake in a test of IFM_ETHER

2013-01-31 Thread Ed Maste
On 31 January 2013 05:49, YAMAMOTO Takashi wrote: > From: YAMAMOTO Takashi > > -if (!IFM_TYPE(ifmr.ifm_current) & IFM_ETHER) { > +if (!(IFM_TYPE(ifmr.ifm_current) & IFM_ETHER)) { > VLOG_DBG_RL(&rl, "%s: doesn't appear to be ethernet", > netdev_get_name(netdev

Re: [ovs-dev] [PATCH 04/18] use ax_check_openssl.m4 instead of a direct use of pkg-config.

2013-01-31 Thread Ed Maste
On 31 January 2013 05:49, YAMAMOTO Takashi wrote: > From: YAMAMOTO Takashi > > on some platforms, including NetBSD-6, openssl is available but > its pkg-config files (*.pc) are not. FreeBSD as well (this is a common issue in the FreeBSD ports tree). Thanks. _

Re: [ovs-dev] [PATCH] ofpbuf: Remove OFPBUF_STACK_BUFFER.

2013-03-08 Thread Ed Maste
On 27 February 2013 20:03, Ben Pfaff wrote: > Its alleged convenience just doesn't outweigh the syntactical ugliness, and > so it didn't have any users. Not entirely true: there's a consumer in lib/netdev-bsd.c. I don't have any time right now to look at it, but will try if nobody gets to it fir

Re: [ovs-dev] [PATCH] ofpbuf: Remove OFPBUF_STACK_BUFFER.

2013-03-08 Thread Ed Maste
On 8 March 2013 16:06, Ed Maste wrote: > On 27 February 2013 20:03, Ben Pfaff wrote: >> Its alleged convenience just doesn't outweigh the syntactical ugliness, and >> so it didn't have any users. > > Not entirely true: there's a consumer in lib/netdev-bsd.c.

Re: [ovs-dev] [PATCH] INSTALL: Admit that only GNU make works.

2013-04-15 Thread Ed Maste
On 15 March 2013 17:30, Ben Pfaff wrote: > I promised some time ago to take a look at fixing the behavior of the > Makefiles with non-GNU make, but it doesn't realistically seem that I will. > Thanks. Even if we addressed the current issues I wouldn't be surprised to find new failures appearing

Re: [ovs-dev] [PATCH 04/22] use ax_check_openssl.m4 instead of a direct use of pkg-config.

2013-04-23 Thread Ed Maste
On 22 April 2013 09:20, YAMAMOTO Takashi wrote: > on some platforms, including NetBSD-6, openssl is available but > its pkg-config files (*.pc) are not. according to Ed Maste, > this is the case for FreeBSD as well. That's correct. This should be a nice convenience for anyo

Re: [ovs-dev] [PATCH 15/22] add minimal NetBSD support

2013-04-23 Thread Ed Maste
> Ed, do you want to look over any of these changes? They affect code > for which you are a primary author, so if you would prefer to see > anything done a different way, etc., for maintainability purposes then > it would be valuable to get that in review. Yep - I'm looking at them now. I've rev

Re: [ovs-dev] [PATCH 17/22] netdev-bsd: NetBSD: keep a AF_LINK socket open

2013-04-23 Thread Ed Maste
On 22 April 2013 09:20, YAMAMOTO Takashi wrote: > this will be used for get_stats and set_etheraddr > > Signed-off-by: YAMAMOTO Takashi > --- > lib/netdev-bsd.c | 15 ++- > 1 file changed, 14 insertions(+), 1 deletion(-) > > diff --git a/lib/netdev-bsd.c b/lib/netdev-bsd.c > index ba

Re: [ovs-dev] [PATCH 20/22] some NetBSD related documentation changes

2013-04-23 Thread Ed Maste
On 22 April 2013 09:20, YAMAMOTO Takashi wrote: > > Signed-off-by: YAMAMOTO Takashi Acked-by: Ed Maste ___ dev mailing list dev@openvswitch.org http://openvswitch.org/mailman/listinfo/dev

Re: [ovs-dev] [PATCH 22/22] acinclude.m4: update a comment for NetBSD support

2013-04-23 Thread Ed Maste
On 22 April 2013 09:20, YAMAMOTO Takashi wrote: > > Signed-off-by: YAMAMOTO Takashi Acked-by: Ed Maste ___ dev mailing list dev@openvswitch.org http://openvswitch.org/mailman/listinfo/dev

Re: [ovs-dev] [PATCH 15/22] add minimal NetBSD support

2013-04-24 Thread Ed Maste
Yamamoto-san, Thanks for this work. I'm happy that it will result in BSD systems as a group getting more OVS test coverage. The patch set builds and passes unit tests for me on FreeBSD, with the exception of the missing #if defined() guard described in a previous email. I have only one overall

Re: [ovs-dev] [PATCH 16/22] keep "kernel name" for each netdev

2013-04-24 Thread Ed Maste
On 22 April 2013 09:20, YAMAMOTO Takashi wrote: > where interface renaming is not supported (NetBSD), remember both of > our netdev name and the correspoinding kernel name separately. > the latter is necessary to talk with kernel using interface names. > eg. ifioctls, bpf Acked-

Re: [ovs-dev] [PATCH 19/22] implement get_stats for NetBSD

2013-04-24 Thread Ed Maste
On 22 April 2013 09:20, YAMAMOTO Takashi wrote: > > Signed-off-by: YAMAMOTO Takashi > --- > lib/netdev-bsd.c | 47 +++ > 1 file changed, 43 insertions(+), 4 deletions(-) > ... > +#elif defined(__NetBSD__) > +struct netdev_dev_bsd *netdev_dev = > +

Re: [ovs-dev] [PATCH 18/22] implement set_etheraddr for NetBSD

2013-04-24 Thread Ed Maste
On 22 April 2013 09:20, YAMAMOTO Takashi wrote: > > Signed-off-by: YAMAMOTO Takashi > --- > lib/netdev-bsd.c | 60 > +--- > 1 file changed, 53 insertions(+), 7 deletions(-)

Re: [ovs-dev] [PATCH 19/22] implement get_stats for NetBSD

2013-04-24 Thread Ed Maste
On 24 April 2013 11:56, Ben Pfaff wrote: > On Wed, Apr 24, 2013 at 11:28:45AM -0400, Ed Maste wrote: >> On 22 April 2013 09:20, YAMAMOTO Takashi wrote: >> > +/* >> > + * note: UINT64_MAX means unsupported >> > + */ >> >> Is this checked

Re: [ovs-dev] [PATCH 21/22] implement get_next_hop for NetBSD

2013-04-24 Thread Ed Maste
> +static int > +netdev_bsd_get_next_hop(const struct in_addr *host, struct in_addr *next_hop, > +char **netdev_name) > +{ > +#if defined(__NetBSD__) Acked-by: Ed Maste This is close to being usable on FreeBSD as well, with the exception that we don't

[ovs-dev] [PATCH] socket-util: restore building on FreeBSD.

2013-05-03 Thread Ed Maste
FreeBSD does not have EAI_ADDRFAMILY or EAI_NODATA and thus failed to build after commit 3cbb5dc7e89df2b40bb6f715873cf2b6b25a7054 "socket-util: Use getaddrinfo() instead of gethostbyname() for thread safety." Signed-off-by: Ed Maste --- lib/socket-util.c | 4 1 file changed, 4

[ovs-dev] [PATCH] netdev-bsd: Use UINT64_MAX for unsupported stats.

2013-05-03 Thread Ed Maste
As documented in netdev-provider.h for the get_stats method. Signed-off-by: Ed Maste --- lib/netdev-bsd.c | 26 +- 1 file changed, 13 insertions(+), 13 deletions(-) diff --git a/lib/netdev-bsd.c b/lib/netdev-bsd.c index e3461b8..7ab9d3e 100644 --- a/lib/netdev-bsd.c

Re: [ovs-dev] [PATCH] Allow master to build on Fedora with the recent threading changes

2013-05-06 Thread Ed Maste
#x27;ve also tested this on Ubuntu and it builds fine there. > > Signed-off-by: Kyle Mestery Acked-by: Ed Maste Builds fine for me on FreeBSD with this change. ___ dev mailing list dev@openvswitch.org http://openvswitch.org/mailman/listinfo/dev

Re: [ovs-dev] [netdev v3 1/4] netdev: Factor restoring flags into new "struct netdev_saved_flags".

2013-05-10 Thread Ed Maste
On 9 May 2013 18:35, Ben Pfaff wrote: > This gets rid of the only per-instance data in "struct netdev", which > will make it possible to merge "struct netdev_dev" into "struct netdev" in > a later commit. The four patches generally look good to me, and when I apply the whole set they pass the uni

Re: [ovs-dev] [netdev v3 1/4] netdev: Factor restoring flags into new "struct netdev_saved_flags".

2013-05-10 Thread Ed Maste
On 10 May 2013 11:55, Ben Pfaff wrote: > Thanks, I found the problem with valgrind, and here is an incremental > fix: > > diff --git a/lib/netdev.c b/lib/netdev.c > index 9590f83..415cdb4 100644 > --- a/lib/netdev.c > +++ b/lib/netdev.c > @@ -322,8 +322,10 @@ void > netdev_close(struct netdev *ne

Re: [ovs-dev] [netdev v3 1/4] netdev: Factor restoring flags into new "struct netdev_saved_flags".

2013-05-10 Thread Ed Maste
On 10 May 2013 13:12, Ed Maste wrote: > Ahh, of course. This fixes the segfaulting tests for me, but the unit > tests now get stuck in "tunnel - input." Oh, and of course the reason ovs-vsctl is stuck is that ovs-vswitchd segfaulted. #0 0x00080164b560 in strncpy () from /

[ovs-dev] [PATCH] netdev: Incremental BSD fix for netdev refactoriong

2013-05-10 Thread Ed Maste
This is an incremental to patch v3 of netdev: Factor restoring flags into new "struct netdev_saved_flags", implementing the equivalent change for netdev-bsd. Signed-off-by: Ed Maste --- With this, the first patch now passes unit tests for me on FreeBSD. lib/netdev-

Re: [ovs-dev] [PATCH] netdev: Incremental BSD fix for netdev refactoriong

2013-05-10 Thread Ed Maste
On 10 May 2013 14:38, Ben Pfaff wrote: > On Fri, May 10, 2013 at 02:15:50PM -0400, Ed Maste wrote: >> This is an incremental to patch v3 of >> netdev: Factor restoring flags into new "struct netdev_saved_flags", >> implementing the equivalent change for netdev-bsd

[ovs-dev] [PATCH] netdev-bsd: Adjust argument line wrapping

2013-05-10 Thread Ed Maste
This file presumably started out life as a copy of netdev-linux.c, and some indentation was not updated after s/linux/bsd/. Signed-off-by: Ed Maste --- There are still a few cases that seem not to match style; I adjusted these because Ethan noticed them in commit 4b60911. lib/netdev-bsd.c | 18

Re: [ovs-dev] [PATCH] netdev-dummy: Remove FreeBSD dependency.

2013-05-17 Thread Ed Maste
stering them from netdev_dummy_register() and making that function > idempotent, so that calling it twice under Linux has no additional effect. > This commit implements that solution. > > CC: Ed Maste > Signed-off-by: Ben Pfaff Acked-by: Ed Maste Looks good to me, and unit t

Re: [ovs-dev] [PATCH 02/13] add minimal NetBSD support

2013-05-21 Thread Ed Maste
On 21 May 2013 10:59, Ben Pfaff wrote: > On Tue, May 21, 2013 at 05:49:54PM +0900, y...@mwd.biglobe.ne.jp wrote: >> From: YAMAMOTO Takashi >> >> mostly ride on the existing FreeBSD support. >> >> Signed-off-by: YAMAMOTO Takashi > > I'd like to refine this patch a little in the following way (whi

[ovs-dev] [PATCH] configure: Add if_mib.h prerequisites.

2013-05-23 Thread Ed Maste
Signed-off-by: Ed Maste --- configure.ac | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/configure.ac b/configure.ac index 1e23289..91f3835 100644 --- a/configure.ac +++ b/configure.ac @@ -63,8 +63,9 @@ AC_CHECK_MEMBERS([struct stat.st_mtim.tv_nsec, struct

[ovs-dev] [PATCH] netdev-bsd: Correct pointer use after refactoring.

2013-05-23 Thread Ed Maste
Introduced in commit 666afb55e84e9118812de81a75655ec9567b7a5b. Signed-off-by: Ed Maste --- lib/netdev-bsd.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/netdev-bsd.c b/lib/netdev-bsd.c index 1301aad..87ac79f 100644 --- a/lib/netdev-bsd.c +++ b/lib/netdev-bsd.c

Re: [ovs-dev] [PATCH 00/13] NetBSD support

2013-05-23 Thread Ed Maste
On 23 May 2013 00:05, Ben Pfaff wrote: > I have all of these patches ready to apply, after Ed reviewed my changes > to patch 2. Apparently I didn't review them well enough; sorry for letting some minor nits slip through. ___ dev mailing list dev@openvsw

[ovs-dev] [PATCH] netdev-bsd: Silence warnings on unimplemented platform.

2013-05-24 Thread Ed Maste
netdev_bsd_get_next_hop currently lacks an implementation on FreeBSD, so its arguments are unused; mark them so. Signed-off-by: Ed Maste --- lib/netdev-bsd.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/lib/netdev-bsd.c b/lib/netdev-bsd.c index 87ac79f..0fb0057

Re: [ovs-dev] Possible Regression in 'netdev: Add new "struct netdev_rx" for capturing packets from a netdev.'

2013-06-12 Thread Ed Maste
On 12 June 2013 07:04, Murphy McCauley wrote: > (Sorry this isn't an actual reply and is missing context -- I wasn't on the > list when it was originally posted.) > > Simon and I have been in touch about this, and I thought I'd share my > findings for what they're worth. > > The problem is from

Re: [ovs-dev] [threads 00/11] basic thread support library

2013-06-19 Thread Ed Maste
On 19 June 2013 16:17, Ben Pfaff wrote: > This series has two purposes: > > * Add a basic thread support library to the tree. > > * Get rid of all calls to C library functions that POSIX describes > as inherently unsafe in a multithreaded program, and then add a > make-time che

Re: [ovs-dev] [threads 06/11] New function ovs_strerror() as a thread-safe replacement for strerror().

2013-06-19 Thread Ed Maste
On 19 June 2013 16:17, Ben Pfaff wrote: > +#if STRERROR_R_CHAR_P > +/* GNU style strerror_r() might return an immutable static string, or it > + * might write and return 'buffer', but in either case we can pass the > + * returned string directly to the caller. */ > +s = strerror_r(

Re: [ovs-dev] [threads 00/11] basic thread support library

2013-06-19 Thread Ed Maste
On 19 June 2013 17:22, Ben Pfaff wrote: > On Wed, Jun 19, 2013 at 05:20:11PM -0400, Ed Maste wrote: >> On 19 June 2013 16:17, Ben Pfaff wrote: >> > This series has two purposes: >> > >> > * Add a basic thread support library to the tree. >> >

Re: [ovs-dev] [threads 00/11] basic thread support library

2013-06-19 Thread Ed Maste
On 19 June 2013 17:54, Ben Pfaff wrote: > Oh, that's odd. C11 appears to say that the parentheses are optional > with _Atomic in this case (you can use _Atomic(...) as a type > specifier or _Atomic by itself as a type qualifier) but I'll change it > since that fixes the problem. Ahh, it looks li

Re: [ovs-dev] [threads 06/11] New function ovs_strerror() as a thread-safe replacement for strerror().

2013-06-19 Thread Ed Maste
On 19 June 2013 18:48, Ben Pfaff wrote: > I pushed a fix for this issue (just s/ptb.bufsize/BUFSIZE/) and the > ovs-atomic-c11.h issue you also mentioned to the "threads" branch at > https://github.com/blp/ovs-reviews/commits/threads Thanks Ben, with those two changes your threads branch passes u

Re: [ovs-dev] [threads 02/11] ovs-thread: Add per-thread data support.

2013-06-20 Thread Ed Maste
X API, where they are available. This commit adds a >> macro-based wrapper, DEFINE_PER_THREAD_DATA, that takes advantage of the >> GCC extension where it is available and falls back to the POSIX API >> otherwise. (I'm not aware of any compilers that implement the C11 feature, >

Re: [ovs-dev] [threads 02/11] ovs-thread: Add per-thread data support.

2013-06-21 Thread Ed Maste
On 20 June 2013 20:10, Ben Pfaff wrote: > Can you confirm that the autoconf test needs #include but > the actual program doesn't? It looks funny. Yes. It looks like it should be added in the actual program; right wow we end up with the definition leaking from another header. __

[ovs-dev] autoconf test OVS_ENABLE_OPTION fails to detect options unsupported by clang

2013-06-21 Thread Ed Maste
In clang's attempt to be GCC compatible it ignores, but does not fail on, unknown -W options. Configure then ends up added the option to WARNING_FLAGS, and the warning is then emitted for every file compiled. >From config.log: configure:7388: checking whether clang accepts -Wno-override-init con

Re: [ovs-dev] autoconf test OVS_ENABLE_OPTION fails to detect options unsupported by clang

2013-06-21 Thread Ed Maste
ation with -Werror, clang does fail on unknown -W options. This > commit adds -Werror during configure's warning tests, which should cause > the not-understood warnings to be detected that way. > > Reported-by: Ed Maste > Signed-off-by: Ben Pfaff Than

Re: [ovs-dev] [threads 28/28] vlog: Make thread-safe.

2013-07-11 Thread Ed Maste
On 10 July 2013 19:04, Ben Pfaff wrote: > static void format_log_message(const struct vlog_module *, enum vlog_level, > - enum vlog_facility, unsigned int msg_num, > + enum vlog_facility, > const char *mes

Re: [ovs-dev] [threads 05/28] timeval: Always block SIGALRM in time_poll().

2013-07-11 Thread Ed Maste
On 10 July 2013 19:03, Ben Pfaff wrote: > (The usual reason for ppoll() is to ensure atomicity of changing the signal > mask and blocking, but time_poll() does not need atomicity. Therefore, > even a userspace emulated ppoll() would work here in a race-free manner, if > the kernel does not suppor

Re: [ovs-dev] [threads 01/28] fatal-signal: Remove write-only variable fatal_signal_set.

2013-07-11 Thread Ed Maste
On 10 July 2013 19:03, Ben Pfaff wrote: > Signed-off-by: Ben Pfaff > --- > lib/fatal-signal.c |5 - Acked-by: Ed Maste X-CudaMail-Whitelist-To: dev@openvswitch.org ___ dev mailing list dev@openvswitch.org http://openvswitch.or

Re: [ovs-dev] [threads 24/28] vlog: Make vlog_should_drop() thread-safe.

2013-07-11 Thread Ed Maste
On 10 July 2013 19:04, Ben Pfaff wrote: > Signed-off-by: Ben Pfaff Acked-by: Ed Maste X-CudaMail-Whitelist-To: dev@openvswitch.org ___ dev mailing list dev@openvswitch.org http://openvswitch.org/mailman/listinfo/dev

Re: [ovs-dev] [threads 13/28] poll-loop: Fix typo in comment.

2013-07-11 Thread Ed Maste
On 10 July 2013 19:03, Ben Pfaff wrote: > Signed-off-by: Ben Pfaff Acked-by: Ed Maste X-CudaMail-Whitelist-To: dev@openvswitch.org ___ dev mailing list dev@openvswitch.org http://openvswitch.org/mailman/listinfo/dev

Re: [ovs-dev] [threads 08/28] timeval: Remove backtrace feature.

2013-07-11 Thread Ed Maste
t; multithreaded process. In a single-threaded process, it can just block > the signal handler, but in a multithreaded process this does not prevent > signal delivery to threads other than the one running format_backtrace(). > > Signed-off-by: Ben Pfaff Acked

Re: [ovs-dev] [threads 23/28] util: Make subprogram_name thread-specific.

2013-07-11 Thread Ed Maste
np (FreeBSD)? The thread names will then appear in gdb or lldb, and in top(1) (on FreeBSD at least). Acked-by: Ed Maste X-CudaMail-Whitelist-To: dev@openvswitch.org ___ dev mailing list dev@openvswitch.org http://openvswitch.org/mailman/listinfo/dev

Re: [ovs-dev] [threads 06/28] timeval: New function xclock_gettime().

2013-07-11 Thread Ed Maste
On 10 July 2013 19:03, Ben Pfaff wrote: > Signed-off-by: Ben Pfaff Acked-by: Ed Maste X-CudaMail-Whitelist-To: dev@openvswitch.org ___ dev mailing list dev@openvswitch.org http://openvswitch.org/mailman/listinfo/dev

Re: [ovs-dev] [threads 09/28] timeval: Fix typo in comment.

2013-07-11 Thread Ed Maste
On 10 July 2013 19:03, Ben Pfaff wrote: > Signed-off-by: Ben Pfaff Acked-by: Ed Maste X-CudaMail-Whitelist-To: dev@openvswitch.org ___ dev mailing list dev@openvswitch.org http://openvswitch.org/mailman/listinfo/dev

Re: [ovs-dev] [threads 27/28] vlog: Remove unused function vlog_exit().

2013-07-11 Thread Ed Maste
On 10 July 2013 19:04, Ben Pfaff wrote: > This is harder to implement once threads are introduced. > > Signed-off-by: Ben Pfaff Acked-by: Ed Maste X-CudaMail-Whitelist-To: dev@openvswitch.org ___ dev mailing list dev@openvswitch

Re: [ovs-dev] [threads 14/28] vlog: Remove support for worker process.

2013-07-11 Thread Ed Maste
On 10 July 2013 19:03, Ben Pfaff wrote: > The worker process implementation isn't thread-safe and, once OVS > itself is threaded, it doesn't make much sense to have a worker > process anyway. > > Signed-off-by: Ben Pfaff Acked-by: Ed Maste X-CudaMail-Whitelis

Re: [ovs-dev] [threads 26/28] vlog: Remove unused function vlog_get_log_file().

2013-07-11 Thread Ed Maste
On 10 July 2013 19:04, Ben Pfaff wrote: > Signed-off-by: Ben Pfaff Acked-by: Ed Maste X-CudaMail-Whitelist-To: dev@openvswitch.org ___ dev mailing list dev@openvswitch.org http://openvswitch.org/mailman/listinfo/dev

Re: [ovs-dev] [threads 07/28] timeval: Make reading the current time thread-safe.

2013-07-12 Thread Ed Maste
On 10 July 2013 19:03, Ben Pfaff wrote: > Signed-off-by: Ben Pfaff Acked-by: Ed Maste (I rebased on master and had a trivial conflict to resolve.) X-CudaMail-Whitelist-To: dev@openvswitch.org ___ dev mailing list dev@openvswitch.org h

Re: [ovs-dev] [threads 10/28] timeval: Make CPU usage and wakeup tracking per-thread.

2013-07-12 Thread Ed Maste
On 10 July 2013 19:03, Ben Pfaff wrote: > This should make the "timeval" module thread-safe, except for its > calls into vlog (because vlog is not yet thread-safe). > > Signed-off-by: Ben Pfaff Acked-by: Ed Maste X-CudaMail-Whitelist-T

Re: [ovs-dev] [threads v2 06/13] latch: New module for a thread-safe, signal-safe, pollable doorbell.

2013-07-15 Thread Ed Maste
On 12 July 2013 17:54, Ben Pfaff wrote: > Signed-off-by: Ben Pfaff > Acked-by: Ed Maste with one comment, diff --git a/lib/latch.c b/lib/latch.c > +void > +(latch_wait)(const struct latch *latch, const char *where) > ... > diff --git a/lib/latch.h b/lib/latch.h > +#de

Re: [ovs-dev] [PATCH] Avoid C preprocessor trick where macro has the same name as a function.

2013-07-29 Thread Ed Maste
int f(int x, const char *file, int line); > > ... > > f(1);/* Expands to a call like f(1, __FILE__, __LINE__); */ > > However it's somewhat confusing, so this commit stops using that trick. > > Reported-by: Ed Maste > Signed-off-by: Ben Pfaff Acked-by:

Re: [ovs-dev] [PATCH v4 1/4] lib: Add CRC32C Implementation

2013-08-12 Thread Ed Maste
On 30 July 2013 20:31, Joe Stringer wrote: > This implementation was derived from FreeBSD: > http://code.google.com/p/freebsd-head/source/browse/sys/libkern/crc32.c The canonical FreeBSD web repo location for this file would be: http://svnweb.freebsd.org/base/head/sys/libkern/crc32.c (It doesn't

[ovs-dev] [PATCH] bfd: Include prerequisite header for FreeBSD

2013-08-16 Thread Ed Maste
Signed-off-by: Ed Maste --- lib/bfd.c | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/bfd.c b/lib/bfd.c index 74b27c4..6f86f26 100644 --- a/lib/bfd.c +++ b/lib/bfd.c @@ -15,6 +15,7 @@ #include #include "bfd.h" +#include #include #include #include -

[ovs-dev] [PATCH] tests: Fix build on FreeBSD

2013-08-17 Thread Ed Maste
Avoid relying on a non-portable implementation detail for atomic_flag tests. Per the standard, the only way to obtain the value of the flag is via the return value from atomic_flag_test_and_set. Signed-off-by: Ed Maste --- tests/test-atomic.c | 4 ++-- 1 file changed, 2 insertions(+), 2

[ovs-dev] Clang compile failure with C11 atomics

2013-08-19 Thread Ed Maste
Commit 1514b275 introduces the use of atomic_read_explicit for once-only initializers. When using C11 atomics this becomes atomic_load_explicit, and the first argument needs to be non-const -- with FreeBSD HEAD's in-tree clang 3.3 the build fails for me with: In file included from lib/bfd.c:34: ./

Re: [ovs-dev] [clang-atomics 4/4] ovs-thread: Work around apparent Clang bug.

2013-08-20 Thread Ed Maste
On 20 August 2013 14:10, Ben Pfaff wrote: > Without this patch, I get Clang warnings that I don't understand for each > of the non-static functions in dirs.c: > > warning: control reaches end of non-void function This is a clang bug; in your example the call to bar() is omitted by clang, and

Re: [ovs-dev] [clang-atomics 2/4] ovs-atomic: atomic_load() must take a non-const argument.

2013-08-20 Thread Ed Maste
On 20 August 2013 14:10, Ben Pfaff wrote: > C11 says that atomic_load() requires a non-const argument, and Clang > enforces that. This fixes warnings with FreeBSD that uses > the Clang extensions. Acked-by: Ed Maste ___ dev mailing

Re: [ovs-dev] [clang-atomics 1/4] ovs-atomic: Fix typo in comment.

2013-08-21 Thread Ed Maste
On 20 August 2013 14:10, Ben Pfaff wrote: > Signed-off-by: Ben Pfaff Acked-by: Ed Maste ___ dev mailing list dev@openvswitch.org http://openvswitch.org/mailman/listinfo/dev

[ovs-dev] [PATCH] util.c: Include pthread_np.h on FreeBSD

2013-08-30 Thread Ed Maste
Signed-off-by: Ed Maste --- On FreeBSD pthread_set_name_np's prototype is provided by pthread_np.h. As I believe it is the only platform to provide the "set_name" (with an underscore) variant I hope it's fine to use the existing autoconf macro HAVE_PTHREAD_SET_NAME_NP. l

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] timeval: On 64-bit systems refresh time whenever it is requested.

2012-08-07 Thread Ed Maste
> > +/* On Linux IA64 systems, glibc avoids using syscalls for clock_gettime(). > I assume you mean x86-64 or one of the equivalent names here, not IA64. > +#ifndef __LP64__ > +#define CACHE_TIME 1 > +#endif > This will disable the syscall mitigation for 64-bit FreeBSD as well, which is not (ye

[ovs-dev] Threaded userspace datapath

2012-08-07 Thread Ed Maste
The original developer of the BSD port (Gaetano Catalli) also implemented a threaded version of the userspace datapath to increase performance. As with the original port, the threading work was done against Open vSwitch 1.1.0pre2. Giuseppe Lettieri and I have ported it forward, and it's functiona

[ovs-dev] [PATCH] lib: Correct "old-style function definition" warning.

2012-08-08 Thread Ed Maste
Signed-off-by: Ed Maste --- lib/route-table-bsd.c |4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/route-table-bsd.c b/lib/route-table-bsd.c index 1c29071..eb4a168 100644 --- a/lib/route-table-bsd.c +++ b/lib/route-table-bsd.c @@ -104,7 +104,7

[ovs-dev] [PATCH] lib: Add header #include for writev

2012-08-08 Thread Ed Maste
This fixes a warning on FreeBSD. Signed-off-by: Ed Maste --- lib/socket-util.c |1 + 1 file changed, 1 insertion(+) diff --git a/lib/socket-util.c b/lib/socket-util.c index 314761d..7c40ab8 100644 --- a/lib/socket-util.c +++ b/lib/socket-util.c @@ -30,6 +30,7 @@ #include #include

[ovs-dev] [PATCH] netdev-bsd: Initialize variable to silence a compiler warning.

2012-08-08 Thread Ed Maste
FreeBSD's system compiler is a somewhat old version of GCC that produced a spurious warning about a potential unitialized variable use. Signed-off-by: Ed Maste --- lib/netdev-bsd.c |2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/netdev-bsd.c b/lib/netdev-bsd.c

Re: [ovs-dev] Threaded userspace datapath

2012-08-09 Thread Ed Maste
On 9 August 2012 11:56, Ben Pfaff wrote: > I'm curious about the performance improvement. You mentioned a 10x > performance improvement. How much did CPU usage increase as part of > that? We already have users who complain when CPU usage spikes to 100%; > I'm not sure that users will be happy

Re: [ovs-dev] Threaded userspace datapath

2012-08-10 Thread Ed Maste
> We've had good improvements in a similar issue in dpif-linux by > switching to use "epoll". Can kqueue under FreeBSD do something > similar? Yes, epoll and kqueue basically provide the same functionality. What do you think about incorporating something like libevent to abstract that? -Ed

Re: [ovs-dev] Threaded userspace datapath

2012-08-14 Thread Ed Maste
> There may be some confusion about numbering. OpenFlow says that the > port number of the "local port" is 65534 (OFPP_LOCAL). The datapaths, > on the other hand, use port number 0 for the "local port". There is > supposed to be translation going on at the interface between the > datapath and th

Re: [ovs-dev] Threaded userspace datapath

2012-08-15 Thread Ed Maste
On 14 August 2012 21:21, Ed Maste wrote: >> There may be some confusion about numbering. OpenFlow says that the >> port number of the "local port" is 65534 (OFPP_LOCAL). The datapaths, >> on the other hand, use port number 0 for the "local port". There is

Re: [ovs-dev] Threaded userspace datapath

2012-08-15 Thread Ed Maste
>>> There may be some confusion about numbering. OpenFlow says that the >>> port number of the "local port" is 65534 (OFPP_LOCAL). The datapaths, >>> on the other hand, use port number 0 for the "local port". There is >>> supposed to be translation going on at the interface between the >>> datap

[ovs-dev] [PATCH] netdev: Map to OpenFlow port for flow lookup

2012-08-15 Thread Ed Maste
In the flow hash special ports are stored using OpenFlow constants. For example the "local port" is stored as 0xfffe (OFPP_LOCAL). Signed-off-by: Ed Maste --- lib/dpif-netdev.c |2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/dpif-netdev.c b/lib/dpif-netd

Re: [ovs-dev] [PATCH 1/2] dpif-netdev: Fix memory leak.

2012-08-16 Thread Ed Maste
On 15 August 2012 19:12, Ben Pfaff wrote: > upcall->packet is allocated with malloc(), via ofpbuf_new(), but nothing > ever frees it. > > Found by valgrind. > > CC: Ed Maste > Signed-off-by: Ben Pfaff > --- > lib/dpif-netdev.c |1 + > 1 files chan

Re: [ovs-dev] [PATCH 2/2] dpif-netdev: Eliminate two malloc() calls per packet sent to "userspace".

2012-08-16 Thread Ed Maste
On 15 August 2012 19:12, Ben Pfaff wrote: > This is easy enough, so it seems worthwhile now that FreeBSD is starting > to make more use of the "userspace switch". > > CC: Ed Maste > Signed-off-by: Ben Pfaff > --- > lib/dpif-netdev.c | 33 +++--

Re: [ovs-dev] [PATCH 1/2] dpif-netdev: Fix memory leak.

2012-08-16 Thread Ed Maste
t. > > Found by valgrind. > > CC: Ed Maste > Signed-off-by: Ben Pfaff > --- > lib/dpif-netdev.c |2 ++ > 1 files changed, 2 insertions(+), 0 deletions(-) > > diff --git a/lib/dpif-netdev.c b/lib/dpif-netdev.c > index 7fa2720..63b59a3 100644 > --- a/li

Re: [ovs-dev] [PATCH 2/2] dpif-netdev: Eliminate two malloc() calls per packet sent to "userspace".

2012-08-16 Thread Ed Maste
On 16 August 2012 11:42, Ben Pfaff wrote: > On Thu, Aug 16, 2012 at 10:22:21AM -0400, Ed Maste wrote: >> On 15 August 2012 19:12, Ben Pfaff wrote: >> > This is easy enough, so it seems worthwhile now that FreeBSD is starting >> > to make more use of the "userspace

Re: [ovs-dev] [PATCH] netdev: Map to OpenFlow port for flow lookup

2012-08-16 Thread Ed Maste
On 15 August 2012 19:09, Ben Pfaff wrote: > On Wed, Aug 15, 2012 at 10:00:34PM +0000, Ed Maste wrote: >> In the flow hash special ports are stored using OpenFlow constants. >> For example the "local port" is stored as 0xfffe (OFPP_LOCAL). >> >> Signed-off-by:

Re: [ovs-dev] Threaded userspace datapath

2012-08-20 Thread Ed Maste
I've updated the snapshot of the threaded userspace datapath path with improvements Giuseppe and I have done over the last couple of weeks. The current patch is available here: http://people.freebsd.org/~emaste/openvswitch/threaded-20120820.diff This patch contains a number of minor improvements

[ovs-dev] [PATCH] lib: Add xpipe_nonblocking helper

2012-09-28 Thread Ed Maste
Signed-off-by: Ed Maste --- As suggested by Ben Pfaff in the 'Threaded userspace datapath' thread. This looks like a useful utility function refactoring, independent of any outcome of that discussion. lib/fatal-signal.c | 4 +--- lib/process.c | 4 +--- lib/signals.c | 4

[ovs-dev] [PATCH] tests: Also enable FreeBSD libc debugging

2012-10-01 Thread Ed Maste
Signed-off-by: Ed Maste --- There should probably be an OS check to set only the appropriate environment variables. I'm not sure if there's a generic autotest way to do that while building atlocal from atlocal.in though (vs. a switch on $(uname) in the generated file). Perhaps

Re: [ovs-dev] [PATCH] tests: Also enable FreeBSD libc debugging

2012-10-01 Thread Ed Maste
On 1 October 2012 17:19, Ben Pfaff wrote: > On Mon, Oct 01, 2012 at 09:11:31PM +0000, Ed Maste wrote: >> Signed-off-by: Ed Maste > > Applied, thanks. > >> There should probably be an OS check to set only the appropriate environment >> variables. I'm not sure i

[ovs-dev] [PATCH] tests: jemalloc debug config for FreeBSD 9 and 10.

2012-10-02 Thread Ed Maste
Signed-off-by: Ed Maste --- tests/atlocal.in | 28 +++- 1 file changed, 19 insertions(+), 9 deletions(-) diff --git a/tests/atlocal.in b/tests/atlocal.in index c23f8e9..c736df4 100644 --- a/tests/atlocal.in +++ b/tests/atlocal.in @@ -33,12 +33,22 @@ if test $HAVE_PYTHON

[ovs-dev] Changing proc title on FreeBSD

2012-10-09 Thread Ed Maste
On 9 October 2012 17:18, Ben Pfaff wrote: > On Tue, Oct 09, 2012 at 01:54:28PM -0700, Ethan Jackson wrote: >> > Does the 'argv' code in command-line.c actually malfunction on ESX? >> > It'd be nice to just leave it in, if not. It's not really tied to >> > having the Linux datapath, it's orthogona

Re: [ovs-dev] Changing proc title on FreeBSD

2012-10-10 Thread Ed Maste
On 9 October 2012 18:07, Ben Pfaff wrote: > On Tue, Oct 09, 2012 at 06:03:32PM -0400, Ed Maste wrote: >>... >> >> Interesting - I didn't notice this code before. >> >> On FreeBSD we have setproctitle(const char *fmt, ...) for this >> functionality, w

  1   2   >