From owner-svn-src-all@FreeBSD.ORG Tue Jul 12 10:27:00 2011 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 6F2461065674; Tue, 12 Jul 2011 10:27:00 +0000 (UTC) (envelope-from brde@optusnet.com.au) Received: from mail05.syd.optusnet.com.au (mail05.syd.optusnet.com.au [211.29.132.186]) by mx1.freebsd.org (Postfix) with ESMTP id DCBA08FC18; Tue, 12 Jul 2011 10:26:59 +0000 (UTC) Received: from c122-106-165-191.carlnfd1.nsw.optusnet.com.au (c122-106-165-191.carlnfd1.nsw.optusnet.com.au [122.106.165.191]) by mail05.syd.optusnet.com.au (8.13.1/8.13.1) with ESMTP id p6CAQrpr014518 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Tue, 12 Jul 2011 20:26:56 +1000 Date: Tue, 12 Jul 2011 20:26:53 +1000 (EST) From: Bruce Evans X-X-Sender: bde@besplex.bde.org To: "Andrey V. Elsukov" In-Reply-To: <201107111002.p6BA2R7l085489@svn.freebsd.org> Message-ID: <20110712200015.N1311@besplex.bde.org> References: <201107111002.p6BA2R7l085489@svn.freebsd.org> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed Cc: svn-src-head@FreeBSD.org, svn-src-all@FreeBSD.org, src-committers@FreeBSD.org Subject: Re: svn commit: r223930 - head/sys/geom 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: Tue, 12 Jul 2011 10:27:00 -0000 On Mon, 11 Jul 2011, Andrey V. Elsukov wrote: > Log: > Remove include of sys/sbuf.h from geom/geom.h. > sbuf support is not always required for geom/geom.h users, and no need to > depend from it. > > PR: kern/158398 Thanks. It's not easy to recover from pollution. > Modified: head/sys/geom/geom.h > ============================================================================== > --- head/sys/geom/geom.h Mon Jul 11 08:42:09 2011 (r223929) > +++ head/sys/geom/geom.h Mon Jul 11 10:02:27 2011 (r223930) > @@ -44,7 +44,6 @@ > #include > #include > #include > -#include > #include > > struct g_class; > Any chance of fixing more pollution? -). 2 more polluting nested includes are visible in just the above (the last 2). 3 more are above . There are many more disk-related ones in . sys/disk.h still includes for reasons that are probably only historical (I think the reason for this include moved from there to here). has massive pollution. It even has an ifdef to avoid depending on but this was tuned into nonsense by including unconditionally. Many disk drivers started using mutexes without actually including soon after a polluting include of was added in one of the headers. I gave up trying to police pollution with this. This problem may have been reduced by centralizing things in geom and collateral churning of APIs. Most disk drivers now include only for general disk things, and the pollution there has been reduced to: - , and . Presumably needed for geom structs, but shouldn't be exported. Not too bad compared with all of and its prerequisites. The disk drivers would have to have been fixed to include if they want to actually use their mutexes. - and its polluting . Bruce