Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 05 Sep 2009 01:04:57 +0100
From:      Bruce Simpson <bms@incunabulum.net>
To:        Robert Watson <rwatson@FreeBSD.org>
Cc:        svn-src-head@freebsd.org, "George V. Neville-Neil" <gnn@FreeBSD.org>, svn-src-all@freebsd.org, src-committers@freebsd.org
Subject:   Re: svn commit: r196797 - in head: sys/net sys/netinet usr.bin/netstat
Message-ID:  <4AA1AB29.9030704@incunabulum.net>
In-Reply-To: <alpine.BSF.2.00.0909041832280.39164@fledge.watson.org>
References:  <200909032110.n83LAvUF044731@svn.freebsd.org> <4AA09B41.3040103@incunabulum.net> <alpine.BSF.2.00.0909041832280.39164@fledge.watson.org>

next in thread | previous in thread | raw e-mail | index | archive | help
Robert Watson wrote:
> For sysctls, explicit versioning doesn't help too much -- what I've 
> been pondering for another structure was including spares and having a 
> capabilities field in the structure where flags are set when fields 
> are known by the kernel.  That way userspace can tell if the kernel 
> knows about the field it cares about and therefore whether they're 
> worth looking at.

One thing that Thrift did was to explicitly all number fields in their 
implementation of RPC. This is useful, because if anything changes over 
time, implementations can be updated to keep track of that.

Whilst I agree that it's unlikely 'struct arpstat' would change, if it 
did, it would be great to have a length field, at a minimum, in front. 
sysctl can determine size at runtime, however, kmem interfaces cannot. 
That's the only real reason why I'd nudge about it. :-)

For igmpstat, at least, the SSM drop adds a LOT of state to the network 
stack which wasn't there before, so having an explicit version field is 
warranted for backwards compatibility (and this is something Robert 
chewed me out about many months ago). Much respect, big yo'self up yo...




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?4AA1AB29.9030704>