From owner-svn-src-all@FreeBSD.ORG Mon Aug 2 07:17:00 2010 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 9D1F5106568A; Mon, 2 Aug 2010 07:17:00 +0000 (UTC) (envelope-from brde@optusnet.com.au) Received: from mail06.syd.optusnet.com.au (mail06.syd.optusnet.com.au [211.29.132.187]) by mx1.freebsd.org (Postfix) with ESMTP id 3420D8FC18; Mon, 2 Aug 2010 07:16:59 +0000 (UTC) Received: from besplex.bde.org (c122-106-147-41.carlnfd1.nsw.optusnet.com.au [122.106.147.41]) by mail06.syd.optusnet.com.au (8.13.1/8.13.1) with ESMTP id o727Gsu4030897 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Mon, 2 Aug 2010 17:16:55 +1000 Date: Mon, 2 Aug 2010 17:16:54 +1000 (EST) From: Bruce Evans X-X-Sender: bde@besplex.bde.org To: Rick Macklem In-Reply-To: <201008012358.o71NwQFL052445@svn.freebsd.org> Message-ID: <20100802163746.L800@besplex.bde.org> References: <201008012358.o71NwQFL052445@svn.freebsd.org> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed Cc: svn-src-stable@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org, svn-src-stable-8@freebsd.org Subject: Re: svn commit: r210740 - in stable/8/sys/fs: nfs nfsclient X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 02 Aug 2010 07:17:00 -0000 On Sun, 1 Aug 2010, Rick Macklem wrote: > Log: > MFC: r210201 > Change the nfscl_mustflush() function in the experimental NFSv4 > client to return a boolean_t in order to make it more compatible > with style(9). Er, this makes it less compatible. style(9) doesn't mention any of boolean_t, TRUE or FALSE, and it doesn't dream of the C99 or its true, false, bool, _Bool or __bool_true_and_false_are_defined. I believe the former are Mach style, which is foreign to BSD style and was used mainly in the Mach-derived in BSD, especially before I moved the typedef for boolean_t from a vm header to in 1995. In Lite2 kern/*.c, there is a whole 1 use of TRUE and that is for a vm call; there are 3 uses of FALSE, all for vm calls; there are no uses of boolean_t although this was wrong for non-prototyped functions since some vm functions take or return a boolean_t. E.g., kmem_malloc() was passed an uncast plain int where a boolean_t is required, so the behaviour was undefined unless boolean_t was int (which it was and still is in the kernel) or there was a prototype in scope (which there should have been by 1993, but the system pretended to support K&R compilers). In Lite2 vm/*.c, there are 64 uses of TRUE, 80 of FALSE and 85 of boolean_t (49 more boolean_t's in *.h). Now the counts are 10% smaller despite vm being 2.2 times larger. I guess this is due to stronger adherence to style rules in Mach. In Lite2 nfs/*.c, there are 27 uses of TRUE, 41 of FALSE and none of boolean_t. So booleans in nfs are nfs(rmacklem) style except for the newfangled boolean_t (which is now > 10 years out of date with standard type) but not BSD style :-). Bruce