From owner-freebsd-current Wed Oct 9 8:18:58 2002 Delivered-To: freebsd-current@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id D5DFB37B401; Wed, 9 Oct 2002 08:18:55 -0700 (PDT) Received: from duke.cs.duke.edu (duke.cs.duke.edu [152.3.140.1]) by mx1.FreeBSD.org (Postfix) with ESMTP id 39E3343E65; Wed, 9 Oct 2002 08:18:51 -0700 (PDT) (envelope-from gallatin@cs.duke.edu) Received: from grasshopper.cs.duke.edu (grasshopper.cs.duke.edu [152.3.145.30]) by duke.cs.duke.edu (8.9.3/8.9.3) with ESMTP id LAA18317; Wed, 9 Oct 2002 11:18:50 -0400 (EDT) Received: (from gallatin@localhost) by grasshopper.cs.duke.edu (8.11.6/8.9.1) id g99FIKo54206; Wed, 9 Oct 2002 11:18:20 -0400 (EDT) (envelope-from gallatin@cs.duke.edu) From: Andrew Gallatin MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Message-ID: <15780.18620.457682.641298@grasshopper.cs.duke.edu> Date: Wed, 9 Oct 2002 11:18:20 -0400 (EDT) To: Jeff Roberson Cc: gibbs@freebsd.org, current@freebsd.org Subject: Re: alpha tinderbox failure In-Reply-To: <20021008235836.B44108-100000@mail.chesapeake.net> References: <200210082312.g98NCS5R025098@beast.freebsd.org> <20021008235836.B44108-100000@mail.chesapeake.net> X-Mailer: VM 6.75 under 21.1 (patch 12) "Channel Islands" XEmacs Lucid Sender: owner-freebsd-current@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Jeff Roberson writes: > > > On Tue, 8 Oct 2002, Dag-Erling Smorgrav wrote: > > "Makefile", line 4194: warning: duplicate script for target "geom_bsd.o" ignored > > cc1: warnings being treated as errors > > /h/des/src/sys/dev/advansys/adv_pci.c: In function `adv_pci_attach': > > /h/des/src/sys/dev/advansys/adv_pci.c:197: warning: overflow in implicit constant conversion > > *** Error code 1 > > Any progress on this? This particular message is caused by alpha's #define BUS_SPACE_UNRESTRICTED (~0UL) Clashing with int nsegments: /* XXX Should probably allow specification of alignment */ int bus_dma_tag_create(bus_dma_tag_t parent, bus_size_t alignemnt, bus_size_t boundary, bus_addr_t lowaddr, bus_addr_t highaddr, bus_dma_filter_t *filtfunc, void *filtfuncarg, bus_size_t maxsize, int nsegments, bus_size_t maxsegsz, int flags, bus_dma_tag_t *dmat); Sparc64 has the same problem. ia64 gets around it by just making BUS_SPACE_UNRESTRICTED an int: #define BUS_SPACE_UNRESTRICTED (~0) I'd like to do the same for alpha. I think this is valid, as BUS_SPACE_UNRESTRICTED seems to be used exlusively as an argument to bus_dma_tag_create(... nsegments = BUS_SPACE_UNRESTRICTED...) I'd also like to add a bus_space_subregion(). Please review the appended patch. I'm running it with no ill effects, and it makes alpha get a bit further on in LINT. (until it dies on printf format warnings). Its going to be a bear to get a clean lint with Werror. All those crusty old isa drivers casting pointers to integers make me feel a bit overwhelmed. It would be nice if des could remove LINT from the tinderbox builds until LINT has a chance of compiling. Right now people are ignoring the alpha tinderbox failure messages. Eventually, it will fail for a reason besides useless LINT garbage, and everybody will ignore it. Drew Index: include/bus.h =================================================================== RCS file: /home/ncvs/src/sys/alpha/include/bus.h,v retrieving revision 1.11 diff -u -r1.11 bus.h --- include/bus.h 4 Oct 2002 20:40:39 -0000 1.11 +++ include/bus.h 9 Oct 2002 00:06:39 -0000 @@ -88,7 +88,27 @@ /* The largest address space known so far is 40 bits */ #define BUS_SPACE_MAXADDR 0xFFFFFFFFFUL -#define BUS_SPACE_UNRESTRICTED (~0UL) +#define BUS_SPACE_UNRESTRICTED (~0) + +/* + * Get a new handle for a subregion of an already-mapped area of bus space. + */ + +static __inline int bus_space_subregion(bus_space_tag_t t, + bus_space_handle_t bsh, + bus_size_t offset, bus_size_t size, + bus_space_handle_t *nbshp); + +static __inline int +bus_space_subregion(bus_space_tag_t t __unused, bus_space_handle_t bsh, + bus_size_t offset, bus_size_t size __unused, + bus_space_handle_t *nbshp) +{ + + *nbshp = bsh + offset; + return (0); +} + struct alpha_busspace; To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message