From owner-svn-src-head@FreeBSD.ORG Tue Jan 31 15:48:47 2012 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 6C5BC10657A7; Tue, 31 Jan 2012 15:48:47 +0000 (UTC) (envelope-from brde@optusnet.com.au) Received: from mail07.syd.optusnet.com.au (mail07.syd.optusnet.com.au [211.29.132.188]) by mx1.freebsd.org (Postfix) with ESMTP id 076358FC17; Tue, 31 Jan 2012 15:48:46 +0000 (UTC) Received: from c211-30-171-136.carlnfd1.nsw.optusnet.com.au (c211-30-171-136.carlnfd1.nsw.optusnet.com.au [211.30.171.136]) by mail07.syd.optusnet.com.au (8.13.1/8.13.1) with ESMTP id q0VFmiQY005074 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Wed, 1 Feb 2012 02:48:44 +1100 Date: Wed, 1 Feb 2012 02:48:44 +1100 (EST) From: Bruce Evans X-X-Sender: bde@besplex.bde.org To: Sergey Kandaurov In-Reply-To: <201201311300.q0VD0eWM036780@svn.freebsd.org> Message-ID: <20120201022150.N2889@besplex.bde.org> References: <201201311300.q0VD0eWM036780@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: r230808 - in head/sys: dev/ie sys X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 31 Jan 2012 15:48:47 -0000 On Tue, 31 Jan 2012, Sergey Kandaurov wrote: > Log: > Isolate v_caddr_t in the ie driver. > > Submitted by: Bruce Evans on net@ Thanks. > ... > Modified: head/sys/sys/types.h > ============================================================================== > --- head/sys/sys/types.h Tue Jan 31 12:57:21 2012 (r230807) > +++ head/sys/sys/types.h Tue Jan 31 13:00:40 2012 (r230808) > @@ -73,7 +73,6 @@ typedef quad_t * qaddr_t; > > typedef char * caddr_t; /* core address */ > typedef const char * c_caddr_t; /* core address, pointer to const */ > -typedef __volatile char *v_caddr_t; /* core address, pointer to volatile */ > > #ifndef _BLKSIZE_T_DECLARED > typedef __blksize_t blksize_t; c_caddr_t is a bit harder to fix or isolate. I removed it, then fixed the things that broke, but only the ones that were used in my normal kernel (or perhaps GENERIC). These are most mchain and its uses: - mbchain.9, mchain.9 (these also have a bogus include of uio.h) - nwfs_subr.c (remove the bogus casts to c_caddr_t and also many more to caddr_t, after fixing APIs). This is barely maintained, and might go away for other reasons (it needs Giant?). - subr_mchain.c, and headers: change APIs to use const void * instead of c_caddr_t, and void * instead of caddr_t; add casts to const char * or char * to access or do pointer arithmetic on these void *. - subr_mbuf.c: like subr_mchain.c, but only 1 place to unbreak. - ncp_rq.c: like nwfs_subr.c, but less to change. - smb_subr.c: change just 1 API to take const void * and void * instead of c_caddr_t etc., and add casts. The casts are now to const char ** and char **. That's 1 more star than before, so I don't see how this worked or works. - linker.h: the same bugs affect the "opaque" symbol linker_sym_t. We have to peer inside it to know that it is a pointer and modify it to make it a pointer to const. We use c_linker_sym_t for the latter, and since it is bogusly a caddr_t, we used c_caddr_t for the latter. I changed the latter to use const char *, but didn't try to fix the bogus opaqueness. - mchain.h: one of the headers affected. Also add a forward declaration of struct uio to it, so that uio.h isn't prerequisite, and fix the unsorting of the forward declarations. - types.h: remove c_caddr_t. Bruce