From owner-cvs-src@FreeBSD.ORG Mon Dec 31 21:38:44 2007 Return-Path: Delivered-To: cvs-src@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id EC56116A420; Mon, 31 Dec 2007 21:38:44 +0000 (UTC) (envelope-from jhb@freebsd.org) Received: from speedfactory.net (mail6.speedfactory.net [66.23.216.219]) by mx1.freebsd.org (Postfix) with ESMTP id 6E56C13C467; Mon, 31 Dec 2007 21:38:44 +0000 (UTC) (envelope-from jhb@freebsd.org) Received: from server.baldwin.cx (unverified [66.23.211.162]) by speedfactory.net (SurgeMail 3.8q) with ESMTP id 226843196-1834499 for multiple; Mon, 31 Dec 2007 16:41:06 -0500 Received: from localhost.corp.yahoo.com (john@localhost [127.0.0.1]) (authenticated bits=0) by server.baldwin.cx (8.13.8/8.13.8) with ESMTP id lBVLcQhJ099591; Mon, 31 Dec 2007 16:38:34 -0500 (EST) (envelope-from jhb@freebsd.org) From: John Baldwin To: src-committers@freebsd.org Date: Mon, 31 Dec 2007 16:16:35 -0500 User-Agent: KMail/1.9.6 References: <200712312112.lBVLC5Yh063447@repoman.freebsd.org> In-Reply-To: <200712312112.lBVLC5Yh063447@repoman.freebsd.org> MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-15" Content-Transfer-Encoding: 7bit Content-Disposition: inline Message-Id: <200712311616.36232.jhb@freebsd.org> X-Greylist: Sender succeeded SMTP AUTH authentication, not delayed by milter-greylist-2.0.2 (server.baldwin.cx [127.0.0.1]); Mon, 31 Dec 2007 16:38:35 -0500 (EST) X-Virus-Scanned: ClamAV 0.91.2/5311/Mon Dec 31 12:05:08 2007 on server.baldwin.cx X-Virus-Status: Clean X-Spam-Status: No, score=-4.4 required=4.2 tests=ALL_TRUSTED,AWL,BAYES_00 autolearn=ham version=3.1.3 X-Spam-Checker-Version: SpamAssassin 3.1.3 (2006-06-01) on server.baldwin.cx Cc: cvs-src@freebsd.org, cvs-all@freebsd.org Subject: Re: cvs commit: src/sys/sys sysctl.h X-BeenThere: cvs-src@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: CVS commit messages for the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 31 Dec 2007 21:38:45 -0000 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