Date: Mon, 31 Dec 2007 16:16:35 -0500 From: John Baldwin <jhb@freebsd.org> To: src-committers@freebsd.org Cc: cvs-src@freebsd.org, cvs-all@freebsd.org Subject: Re: cvs commit: src/sys/sys sysctl.h Message-ID: <200712311616.36232.jhb@freebsd.org> In-Reply-To: <200712312112.lBVLC5Yh063447@repoman.freebsd.org> References: <200712312112.lBVLC5Yh063447@repoman.freebsd.org>
next in thread | previous in thread | raw e-mail | index | archive | help
On Monday 31 December 2007 04:12:05 pm John Baldwin wrote: > jhb 2007-12-31 21:12:05 UTC > > FreeBSD src repository > > Modified files: > sys/sys sysctl.h > Log: > Add very basic support for the kernel to export a list of features. Each > feature is represented by a node in the new 'kern.features' sysctl node. > A feature is present if the corresponding node is present and evaluates to > true. > > A FEATURE() wrapper macro is added which takes the sysctl node name and > a description of the feature as the sole arguments and creates a read-only > sysctl node with a value of 1. > > Discussed on: arch Note that this is only the kernel side. I'm not sure what the userland interface will look like. It may be that each feature gains a new sysconf(3) constant rather than adding a new 'feature_present(const char *)' function. Also, I went ahead and put this into sys/sysctl.h rather than a new header because it was only 2 lines of code. -- John Baldwin
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200712311616.36232.jhb>