Review request: fix return value of socket(2) on no family found

2012-12-06 Thread Kevin Lo
Hi, Here's the patch mostly from NetBSD to make socket(2) return EAFNOSUPPORT rather than EPROTONOSUPPORT if the family cannot be found. http://people.freebsd.org/~kevlo/patch-socket The man page documents the behavior specified in POSIX.1-2008: http://pubs.opengroup.org/onlinepubs/9699919799/

ipfw(4) dynamic states/rules and its callout

2012-12-06 Thread Ermal Luçi
Hello, i was looking at ipfw dynamic code for dynamic states/rules and see that it unconditionally schedules a callout even if there is not work to do. Wouldn't it be best to reschedule it when there is something to do to avoid having a useless callout/event run every time on the system? Is ther

Re: Latency issues with buf_ring

2012-12-06 Thread Robert Watson
On Tue, 4 Dec 2012, John Baldwin wrote: Q2: Are there any case studies or benchmarks for buf_ring, or it is just blindly being used because someone claimed it was better and offered it for free? One of the points of locking is to avoid race conditions, so the fact that you have races in a su

Re: Latency issues with buf_ring

2012-12-06 Thread Robert Watson
On Tue, 4 Dec 2012, Andre Oppermann wrote: For most if not all ethernet drivers from 100Mbit/s the TX DMA rings are so large that buffering at the IFQ level doesn't make sense anymore and only adds latency. So it could simply directly put everything into the TX DMA and not even try to soft-qu

Re: ipfw(4) dynamic states/rules and its callout

2012-12-06 Thread Alexander V. Chernikov
On 06.12.2012 13:13, Ermal Luçi wrote: Hello, i was looking at ipfw dynamic code for dynamic states/rules and see that it unconditionally schedules a callout even if there is not work to do. Wouldn't it be best to reschedule it when there is something to do to avoid having a useless callout/eve

Re: Review request: fix return value of socket(2) on no family found

2012-12-06 Thread Gleb Smirnoff
Kevin, On Thu, Dec 06, 2012 at 02:39:11PM +0800, Kevin Lo wrote: K> Here's the patch mostly from NetBSD to make socket(2) return EAFNOSUPPORT K> rather than EPROTONOSUPPORT if the family cannot be found. K> K> http://people.freebsd.org/~kevlo/patch-socket K> K> The man page documents the behav

Re: Latency issues with buf_ring

2012-12-06 Thread Barney Cordoba
--- On Thu, 12/6/12, Robert Watson wrote: > From: Robert Watson > Subject: Re: Latency issues with buf_ring > To: "Andre Oppermann" > Cc: "Barney Cordoba" , "Adrian Chadd" > , "John Baldwin" , > freebsd-net@freebsd.org > Date: Thursday, December 6, 2012, 4:39 AM > On Tue, 4 Dec 2012, Andre

Re: Latency issues with buf_ring

2012-12-06 Thread Adrian Chadd
There've been plenty of discussions about "better" ways of doing this networking stuff. Barney, are you able to make it to any of the developer summits? adrian ___ freebsd-net@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-

Re: Review request: fix return value of socket(2) on no family found

2012-12-06 Thread Mike Karels
> On Thu, Dec 06, 2012 at 02:39:11PM +0800, Kevin Lo wrote: > K> Here's the patch mostly from NetBSD to make socket(2) return EAFNOSUPPORT > K> rather than EPROTONOSUPPORT if the family cannot be found. > K> > K> http://people.freebsd.org/~kevlo/patch-socket > K> > K> The man page documents the b