Date: Fri, 26 Nov 2010 15:26:32 +1100 (EST) From: Bruce Evans <brde@optusnet.com.au> To: Attilio Rao <attilio@FreeBSD.org> Cc: svn-src-head@FreeBSD.org, svn-src-all@FreeBSD.org, src-committers@FreeBSD.org Subject: Re: svn commit: r215821 - head/sys/sys Message-ID: <20101126144637.S1417@besplex.bde.org> In-Reply-To: <201011251556.oAPFu5Lg009989@svn.freebsd.org> References: <201011251556.oAPFu5Lg009989@svn.freebsd.org>
next in thread | previous in thread | raw e-mail | index | archive | help
On Thu, 25 Nov 2010, Attilio Rao wrote: > Log: > Add a missing CTL description from CVS revision 1.147. This compounds the bugs in rev.1.147. The description wasn't really missing, since the whole table (CTL_KERN_NAMES) is historical garbage that probably shouldn't exist and certainly shouldn't be added to. > Modified: head/sys/sys/sysctl.h > ============================================================================== > --- head/sys/sys/sysctl.h Thu Nov 25 15:42:33 2010 (r215820) > +++ head/sys/sys/sysctl.h Thu Nov 25 15:56:05 2010 (r215821) > @@ -452,6 +452,7 @@ TAILQ_HEAD(sysctl_ctx_list, sysctl_ctx_e > { "logsigexit", CTLTYPE_INT }, \ > { "iov_max", CTLTYPE_INT }, \ > { "hostuuid", CTLTYPE_STRING }, \ > + { "arc4rand", CTLTYPE_OPAQUE }, \ > } > > /* > The error in rev.1.147 was adding the corresponding sysctl number KERN_ARND 12 years after hard-allocation of sysctl numbers were deprecated and 10 years after they became obsolete. OID_AUTO should have been used in the sysctl declaration, and sysctl.h shouldn't have been touched. Fortunately, KERN_ARND is still not documented in either sysctl.8 or sysctl.3, so it is properly unusable. The sysctl by name "arc4rand" is also undocumented in these man pages. Documentation of the numbers and names in the above man pages seems to stop at logsigexit in sysctl.8 and before that in sysctl.3 (sysctl.8 is easier to use for this comparison but harder to use normally since its strings are mostly unsorted in the same historical order as the numbers). The previous mistakes "hostuid" and "iov_max" visible in the above list are also still not documented in either of these man pages. Some historical dates: 1995: OID_AUTO 1997: sysctlbyname() (before this, OID_AUTO sysctls were only easy to use via sysctl(8) 1998: KERN_LOGSIGEXIT 2007: KERN_ARND 2010: "arc4rand". Bruce
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20101126144637.S1417>