From owner-cvs-src@FreeBSD.ORG Wed Aug 30 09:37:29 2006 Return-Path: X-Original-To: cvs-src@FreeBSD.org Delivered-To: cvs-src@FreeBSD.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 3C5B516A4DA; Wed, 30 Aug 2006 09:37:29 +0000 (UTC) (envelope-from bde@zeta.org.au) Received: from mailout1.pacific.net.au (mailout1.pacific.net.au [61.8.0.84]) by mx1.FreeBSD.org (Postfix) with ESMTP id ABEA843D5E; Wed, 30 Aug 2006 09:37:27 +0000 (GMT) (envelope-from bde@zeta.org.au) Received: from mailproxy1.pacific.net.au (mailproxy1.pacific.net.au [61.8.2.162]) by mailout1.pacific.net.au (Postfix) with ESMTP id 54F565A7D94; Wed, 30 Aug 2006 19:37:26 +1000 (EST) Received: from katana.zip.com.au (katana.zip.com.au [61.8.7.246]) by mailproxy1.pacific.net.au (8.13.4/8.13.4/Debian-3sarge1) with ESMTP id k7U9bN04023496; Wed, 30 Aug 2006 19:37:25 +1000 Date: Wed, 30 Aug 2006 19:37:23 +1000 (EST) From: Bruce Evans X-X-Sender: bde@delplex.bde.org To: John Baldwin In-Reply-To: <200608292036.k7TKaXBp044347@repoman.freebsd.org> Message-ID: <20060830192747.B86395@delplex.bde.org> References: <200608292036.k7TKaXBp044347@repoman.freebsd.org> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed Cc: cvs-src@FreeBSD.org, src-committers@FreeBSD.org, cvs-all@FreeBSD.org Subject: Re: cvs commit: src/sys/sys sx.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: Wed, 30 Aug 2006 09:37:29 -0000 On Tue, 29 Aug 2006, John Baldwin wrote: > jhb 2006-08-29 20:36:33 UTC > > FreeBSD src repository > > Modified files: > sys/sys sx.h > Log: > The _sx_assert() prototype should exist if either of INVARIANTS or > INVARIANT_SUPPORT is defined so you can build a kernel with > INVARIANT_SUPPORT, but build a module with just INVARIANTS on. No it shouldn't. INVARIANT_SUPPORT is a documented prerequisite for INVARIANTS. So is the resulting requirements for using INVARIANTS to create non-modular "modules": From /sys/conf/NOTES: # The INVARIANT_SUPPORT option makes us compile in support for # verifying some of the internal structures. It is a prerequisite for ^^^^^^^^^^^^^^^^^^^^^^^^ # 'INVARIANTS', as enabling 'INVARIANTS' will make these functions be ^^^^^^^^^^^^ # called. The intent is that you can set 'INVARIANTS' for single # source files (by changing the source file or specifying it on the # command line) if you have 'INVARIANT_SUPPORT' enabled. Also, if you ^^^^^^^^^^^^ # wish to build a kernel module with 'INVARIANTS', then adding ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ # 'INVARIANT_SUPPORT' to your kernel will provide all the necessary ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ # infrastructure without the added overhead. ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ However, INVARIANTS is a fairly bogus option. Last time I looked (long ago) it only controlled a small amount of kernel bloat, and there are probably many other functions that are defined unconditionally else modules with INVARIANTS would be more broken. Bruce