From owner-freebsd-arm@FreeBSD.ORG Sun Dec 2 13:13:38 2007 Return-Path: Delivered-To: freebsd-arm@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 9050716A41A for ; Sun, 2 Dec 2007 13:13:38 +0000 (UTC) (envelope-from mlfbsd@dong.ci0.org) Received: from dong.ci0.org (dong.ci0.org [IPv6:2001:7a8:2066:1::1]) by mx1.freebsd.org (Postfix) with ESMTP id B8C1A13C4E7 for ; Sun, 2 Dec 2007 13:13:37 +0000 (UTC) (envelope-from mlfbsd@dong.ci0.org) Received: from dong.ci0.org (localhost.ci0.org [127.0.0.1]) by dong.ci0.org (8.14.1/8.13.8) with ESMTP id lB2E9L5A040694; Sun, 2 Dec 2007 15:09:21 +0100 (CET) (envelope-from mlfbsd@dong.ci0.org) Received: (from mlfbsd@localhost) by dong.ci0.org (8.14.1/8.13.8/Submit) id lB2E9K2E040693; Sun, 2 Dec 2007 15:09:20 +0100 (CET) (envelope-from mlfbsd) Date: Sun, 2 Dec 2007 15:09:20 +0100 From: Olivier Houchard To: Rafal Jaworowski Message-ID: <20071202140920.GA40640@ci0.org> References: <474FF9BF.8090707@semihalf.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <474FF9BF.8090707@semihalf.com> User-Agent: Mutt/1.4.1i Cc: freebsd-arm@freebsd.org Subject: Re: ARM arch subdir cleanups X-BeenThere: freebsd-arm@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Porting FreeBSD to the StrongARM Processor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 02 Dec 2007 13:13:38 -0000 On Fri, Nov 30, 2007 at 12:53:35PM +0100, Rafal Jaworowski wrote: > Hi, > Attached are two patches with the following cleanups: > > 1. Convert nexus to standard device since it's mandatory anyway, remove stale > nexus_io_asm.S and nexus_io.c > > 2. Streamline sys/conf/files.arm (and hence the kernel image contents): move > asm routines to appropriate sys/arm//files. > > > It seems to me other items in the ARM arch subdirectory would benefit from > optimization/cleanups too, for example: > > - Shared OBIO routines. At least these are nearly identical and could be > compressed into one I guess: > > xscale/i80321/obio_space.c > xscale/i8134x/obio_space.c > xscale/pxa2x0/pxa2x0_space.c (in P4) > > - Shared bus space generic methods. A lot of BS methods like *_bs_map(), > _bs_subregion() etc. are copied in separate files for different ARM platforms, > but most of this could be placed in one file, just like we have a common > assembly routines in the arm/arm/bus_space_asm_generic.S. > > - Others like arm/arm/machdep.c and arm/arm/sys_machdep.c seem akin, could > they be merged into one file? > > I can work on cleaning those up, would such changes be welcome? > > Rafal Hi Rafal, I just committed your patches. Yes, this kind of work is very welcome. Thanks a lot ! Olivier From owner-freebsd-arm@FreeBSD.ORG Sun Dec 2 14:24:29 2007 Return-Path: Delivered-To: freebsd-arm@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id BDCE616A419 for ; Sun, 2 Dec 2007 14:24:29 +0000 (UTC) (envelope-from imp@bsdimp.com) Received: from harmony.bsdimp.com (bsdimp.com [199.45.160.85]) by mx1.freebsd.org (Postfix) with ESMTP id 7F04B13C447 for ; Sun, 2 Dec 2007 14:24:29 +0000 (UTC) (envelope-from imp@bsdimp.com) Received: from localhost (localhost [127.0.0.1]) by harmony.bsdimp.com (8.14.1/8.14.1) with ESMTP id lB2EIGkx069866; Sun, 2 Dec 2007 07:18:17 -0700 (MST) (envelope-from imp@bsdimp.com) Date: Sun, 02 Dec 2007 07:21:38 -0700 (MST) Message-Id: <20071202.072138.1723236577.imp@bsdimp.com> To: mlfbsd@ci0.org From: "M. Warner Losh" In-Reply-To: <20071202140920.GA40640@ci0.org> References: <474FF9BF.8090707@semihalf.com> <20071202140920.GA40640@ci0.org> X-Mailer: Mew version 5.2 on Emacs 21.3 / Mule 5.0 (SAKAKI) Mime-Version: 1.0 Content-Type: Text/Plain; charset=us-ascii Content-Transfer-Encoding: 7bit Cc: freebsd-arm@FreeBSD.org Subject: Re: ARM arch subdir cleanups X-BeenThere: freebsd-arm@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Porting FreeBSD to the StrongARM Processor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 02 Dec 2007 14:24:29 -0000 In message: <20071202140920.GA40640@ci0.org> Olivier Houchard writes: : On Fri, Nov 30, 2007 at 12:53:35PM +0100, Rafal Jaworowski wrote: : > Hi, : > Attached are two patches with the following cleanups: : > : > 1. Convert nexus to standard device since it's mandatory anyway, remove stale : > nexus_io_asm.S and nexus_io.c : > : > 2. Streamline sys/conf/files.arm (and hence the kernel image contents): move : > asm routines to appropriate sys/arm//files. : > : > : > It seems to me other items in the ARM arch subdirectory would benefit from : > optimization/cleanups too, for example: : > : > - Shared OBIO routines. At least these are nearly identical and could be : > compressed into one I guess: : > : > xscale/i80321/obio_space.c : > xscale/i8134x/obio_space.c : > xscale/pxa2x0/pxa2x0_space.c (in P4) : > : > - Shared bus space generic methods. A lot of BS methods like *_bs_map(), : > _bs_subregion() etc. are copied in separate files for different ARM platforms, : > but most of this could be placed in one file, just like we have a common : > assembly routines in the arm/arm/bus_space_asm_generic.S. : > : > - Others like arm/arm/machdep.c and arm/arm/sys_machdep.c seem akin, could : > they be merged into one file? : > : > I can work on cleaning those up, would such changes be welcome? : > : > Rafal : : : Hi Rafal, : : I just committed your patches. Yes, this kind of work is very welcome. Indeed. I've done some work trying to get obio abstracted out across all architectures. The other thing that I'd like to see is a better defined board/cpu initialization sequence. Or to make better use of the one that's defined now and document it better. I made some bad choices, in hindsight, for the at91rm9200 port that are only now becoming apparent. Warner From owner-freebsd-arm@FreeBSD.ORG Sun Dec 2 14:35:16 2007 Return-Path: Delivered-To: freebsd-arm@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id DE04716A419 for ; Sun, 2 Dec 2007 14:35:16 +0000 (UTC) (envelope-from raj@semihalf.com) Received: from mail.semihalf.com (mail.semihalf.com [83.15.139.206]) by mx1.freebsd.org (Postfix) with ESMTP id 918F613C458 for ; Sun, 2 Dec 2007 14:35:16 +0000 (UTC) (envelope-from raj@semihalf.com) Received: from localhost (unknown [127.0.0.1]) by mail.semihalf.com (Postfix) with ESMTP id EA0B41449C; Sun, 2 Dec 2007 15:37:32 +0100 (CET) Received: from mail.semihalf.com ([127.0.0.1]) by localhost (mail.semihalf.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 16034-09; Sun, 2 Dec 2007 15:37:31 +0100 (CET) Received: from [83.175.187.132] (pc187-132.ghnet.pl [83.175.187.132]) by mail.semihalf.com (Postfix) with ESMTP id 6741814429; Sun, 2 Dec 2007 15:37:31 +0100 (CET) Message-ID: <4752C2A0.9010604@semihalf.com> Date: Sun, 02 Dec 2007 15:35:12 +0100 From: Rafal Jaworowski MIME-Version: 1.0 To: "M. Warner Losh" References: <474FF9BF.8090707@semihalf.com> <20071202140920.GA40640@ci0.org> <20071202.072138.1723236577.imp@bsdimp.com> In-Reply-To: <20071202.072138.1723236577.imp@bsdimp.com> Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit X-Virus-Scanned: by amavisd-new at semihalf.com Cc: freebsd-arm@FreeBSD.org Subject: Re: ARM arch subdir cleanups X-BeenThere: freebsd-arm@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Porting FreeBSD to the StrongARM Processor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 02 Dec 2007 14:35:16 -0000 M. Warner Losh wrote: > : > : I just committed your patches. Yes, this kind of work is very welcome. > > Indeed. I've done some work trying to get obio abstracted out across > all architectures. > Are your OBIO cleanups available somewhere? Are you going to finish these (so as not to overlap the work...)? > The other thing that I'd like to see is a better defined board/cpu > initialization sequence. Or to make better use of the one that's > defined now and document it better. I made some bad choices, in > hindsight, for the at91rm9200 port that are only now becoming > apparent. > Yes, this is a valid point. As we already talked I keep this in mind while fleshing out the Orion port, but it'll make more sense for me to return to such refactoring in a second spin, after we have basic functionality in operation. Rafal From owner-freebsd-arm@FreeBSD.ORG Sun Dec 2 14:51:16 2007 Return-Path: Delivered-To: freebsd-arm@FreeBSD.ORG Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 26E8D16A417 for ; Sun, 2 Dec 2007 14:51:16 +0000 (UTC) (envelope-from imp@bsdimp.com) Received: from harmony.bsdimp.com (bsdimp.com [199.45.160.85]) by mx1.freebsd.org (Postfix) with ESMTP id DA9F913C45B for ; Sun, 2 Dec 2007 14:51:15 +0000 (UTC) (envelope-from imp@bsdimp.com) Received: from localhost (localhost [127.0.0.1]) by harmony.bsdimp.com (8.14.1/8.14.1) with ESMTP id lB2EifBS070170; Sun, 2 Dec 2007 07:44:41 -0700 (MST) (envelope-from imp@bsdimp.com) Date: Sun, 02 Dec 2007 07:48:03 -0700 (MST) Message-Id: <20071202.074803.-1625880187.imp@bsdimp.com> To: raj@semihalf.com From: "M. Warner Losh" In-Reply-To: <4752C2A0.9010604@semihalf.com> References: <20071202140920.GA40640@ci0.org> <20071202.072138.1723236577.imp@bsdimp.com> <4752C2A0.9010604@semihalf.com> X-Mailer: Mew version 5.2 on Emacs 21.3 / Mule 5.0 (SAKAKI) Mime-Version: 1.0 Content-Type: Text/Plain; charset=us-ascii Content-Transfer-Encoding: 7bit Cc: freebsd-arm@FreeBSD.ORG Subject: Re: ARM arch subdir cleanups X-BeenThere: freebsd-arm@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Porting FreeBSD to the StrongARM Processor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 02 Dec 2007 14:51:16 -0000 In message: <4752C2A0.9010604@semihalf.com> Rafal Jaworowski writes: : M. Warner Losh wrote: : > : : > : I just committed your patches. Yes, this kind of work is very welcome. : > : > Indeed. I've done some work trying to get obio abstracted out across : > all architectures. : > : : Are your OBIO cleanups available somewhere? Are you going to finish these (so : as not to overlap the work...)? What I've done to date is available in the p4 branch "arm-devel" and are in the form of a set of routines in subr_obio.c. They likely need to be enhanced and generalized a little (I just converted at91 to use them, nothing else). I had hoped to be able to come up with something that could also be merged into RELENG_7 as an optional feature to keep maintenance costs down for things MFC'd. : > The other thing that I'd like to see is a better defined board/cpu : > initialization sequence. Or to make better use of the one that's : > defined now and document it better. I made some bad choices, in : > hindsight, for the at91rm9200 port that are only now becoming : > apparent. : > : : Yes, this is a valid point. As we already talked I keep this in mind while : fleshing out the Orion port, but it'll make more sense for me to return to : such refactoring in a second spin, after we have basic functionality in operation. One thing that might help is better documentation in this area. Had my professional life not taken an unexpected turn recently, I had planned on getting some time to document the conventions and try to move all the arm subports into compliance with that vision. I was then hoping to use that experience to define a cleanup, etc. However, since I'm going to have a different focus professionally for a while, I'm afraid I'll have to leave at least some of the heavy lifting on this to others. My focus will be more MIPS and PowerPC based, but there's a lot of overlap here. Warner From owner-freebsd-arm@FreeBSD.ORG Sun Dec 2 16:33:47 2007 Return-Path: Delivered-To: freebsd-arm@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id DDA6616A420 for ; Sun, 2 Dec 2007 16:33:47 +0000 (UTC) (envelope-from hselasky@c2i.net) Received: from swip.net (mailfe03.swip.net [212.247.154.65]) by mx1.freebsd.org (Postfix) with ESMTP id 6DF5213C448 for ; Sun, 2 Dec 2007 16:33:47 +0000 (UTC) (envelope-from hselasky@c2i.net) X-Cloudmark-Score: 0.000000 [] Received: from [85.19.218.45] (account mc467741@c2i.net [85.19.218.45] verified) by mailfe03.swip.net (CommuniGate Pro SMTP 5.1.13) with ESMTPA id 718956787 for freebsd-arm@freebsd.org; Sun, 02 Dec 2007 16:33:44 +0100 From: Hans Petter Selasky To: freebsd-arm@freebsd.org Date: Sun, 2 Dec 2007 16:34:17 +0100 User-Agent: KMail/1.9.7 MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Content-Disposition: inline Message-Id: <200712021634.18193.hselasky@c2i.net> Subject: Setting up an AT91RM9200 based board with FreeBSD X-BeenThere: freebsd-arm@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Porting FreeBSD to the StrongARM Processor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 02 Dec 2007 16:33:47 -0000 Hi, I have an AT91RM9200 based board here which I want to load a FreeBSD/ARM kernel onto, based on the FreeBSD P4 USB project. I managed to get the kernel compiled, but I cannot compile all the other stuff I need, like bootloaders and programs ... I'm using the CVS version of FreeBSD-HEAD (probably 8-current) of today. For example I get these errors: ===> games/fortune/strfile (obj,depend,all,install) /usr/obj/arm/usr/7-current/src/tmp/usr/7-current/src/games/fortune/strfile creat ed for /usr/7-current/src/games/fortune/strfile rm -f .depend CC='/usr/cross/usr/bin/gcc' mkdep -f .depend -a -I/usr/obj/arm/usr/7-current/ src/tmp/legacy/usr/include /usr/7-current/src/games/fortune/strfile/strfile.c /usr/7-current/src/games/fortune/strfile/strfile.c:48:23: error: sys/cdefs.h: No such file or directory /usr/7-current/src/games/fortune/strfile/strfile.c:51:24: error: sys/param.h: No such file or directory /usr/7-current/src/games/fortune/strfile/strfile.c:52:25: error: sys/endian.h: N o such file or directory /usr/7-current/src/games/fortune/strfile/strfile.c:53:20: error: stdio.h: No suc h file or directory /usr/7-current/src/games/fortune/strfile/strfile.c:54:27: error: stdlib.h: No su ch file or directory /usr/7-current/src/games/fortune/strfile/strfile.c:55:20: error: ctype.h: No suc h file or directory /usr/7-current/src/games/fortune/strfile/strfile.c:56:27: error: string.h: No su ch file or directory /usr/7-current/src/games/fortune/strfile/strfile.c:57:25: error: time.h: No such file or directory /usr/7-current/src/games/fortune/strfile/strfile.c:58:27: error: locale.h: No su Any clues ? --HPS PS: I'm available on MSN/ICQ/AIM/JABBER/IRC/SIP . From owner-freebsd-arm@FreeBSD.ORG Sun Dec 2 16:38:21 2007 Return-Path: Delivered-To: freebsd-arm@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id B7ACA16A418 for ; Sun, 2 Dec 2007 16:38:21 +0000 (UTC) (envelope-from tinguely@casselton.net) Received: from casselton.net (casselton.net [63.165.140.2]) by mx1.freebsd.org (Postfix) with ESMTP id 6E8A213C43E for ; Sun, 2 Dec 2007 16:38:21 +0000 (UTC) (envelope-from tinguely@casselton.net) Received: from casselton.net (localhost [127.0.0.1]) by casselton.net (8.13.8/8.13.8) with ESMTP id lB2GcINX066306; Sun, 2 Dec 2007 10:38:18 -0600 (CST) (envelope-from tinguely@casselton.net) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=casselton.net; s=ccnMail; t=1196613498; bh=uR9ZMeL0+sdbW4T6Pz0Np4qQcwrgzFbYx0Ke2NH z0fc=; h=Date:From:Message-Id:To:Subject:Cc:In-Reply-To; b=UnmwOWvm vdwSE3Opu6glYmJHlk7kkI9DOo2KfDwANtkZ2pyvQb3Xv1DaJ0hqMmq4KdyNbPphaiG YwoWSlI+NbSACW3qBOasArPCshQrIu+wuP1wIPiNDgEbHO08f1SmzmwkThT4YoHsgFG r4YR/VIxtmEcrGFyBFfkot7uo29Jc= Received: (from tinguely@localhost) by casselton.net (8.13.8/8.13.8/Submit) id lB2GcICW066305; Sun, 2 Dec 2007 10:38:18 -0600 (CST) (envelope-from tinguely) Date: Sun, 2 Dec 2007 10:38:18 -0600 (CST) From: Mark Tinguely Message-Id: <200712021638.lB2GcICW066305@casselton.net> To: imp@bsdimp.com, raj@semihalf.com In-Reply-To: <20071202.074803.-1625880187.imp@bsdimp.com> Cc: freebsd-arm@freebsd.org Subject: Re: ARM arch subdir cleanups X-BeenThere: freebsd-arm@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Porting FreeBSD to the StrongARM Processor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 02 Dec 2007 16:38:21 -0000 > The other thing that I'd like to see is a better defined board/cpu > initialization sequence. Or to make better use of the one that's > defined now and document it better. I made some bad choices, in > hindsight, for the at91rm9200 port that are only now becoming > apparent. moving the pmap to a recursive page table (obviously the reuse of the L1 would have to be abandoned), would allow for major items to be removed such as the shadow of the page tables to find the level 2 entries; recusive page table should work with Sections, Small and Tiny pages. This could go a long ways to initialize every arm board the same. I can also see that the pv_array could be removed also because the pagetables are create earlier and the temporary page table created in locore.S is mapped with physical == virtual. the new pv_entry chunk code in i386 and amd64 hold about twice as many pv_entries/page. The downside, it is a big job. --Mark Tinguely From owner-freebsd-arm@FreeBSD.ORG Sun Dec 2 19:24:12 2007 Return-Path: Delivered-To: freebsd-arm@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id AD9D016A468 for ; Sun, 2 Dec 2007 19:24:12 +0000 (UTC) (envelope-from hselasky@c2i.net) Received: from swip.net (mailfe08.swip.net [212.247.154.225]) by mx1.freebsd.org (Postfix) with ESMTP id 39E1713C478 for ; Sun, 2 Dec 2007 19:24:12 +0000 (UTC) (envelope-from hselasky@c2i.net) X-Cloudmark-Score: 0.000000 [] Received: from [85.19.218.45] (account mc467741@c2i.net [85.19.218.45] verified) by mailfe08.swip.net (CommuniGate Pro SMTP 5.1.13) with ESMTPA id 709904639 for freebsd-arm@freebsd.org; Sun, 02 Dec 2007 20:24:04 +0100 From: Hans Petter Selasky To: freebsd-arm@freebsd.org Date: Sun, 2 Dec 2007 20:24:42 +0100 User-Agent: KMail/1.9.7 References: <200712021634.18193.hselasky@c2i.net> In-Reply-To: <200712021634.18193.hselasky@c2i.net> MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Content-Disposition: inline Message-Id: <200712022024.43708.hselasky@c2i.net> Subject: Re: Setting up an AT91RM9200 based board with FreeBSD X-BeenThere: freebsd-arm@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Porting FreeBSD to the StrongARM Processor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 02 Dec 2007 19:24:12 -0000 On Sunday 02 December 2007, Hans Petter Selasky wrote: > Hi, > > I have an AT91RM9200 based board here which I want to load a FreeBSD/ARM > kernel onto, based on the FreeBSD P4 USB project. I managed to get the > kernel compiled, but I cannot compile all the other stuff I need, like > bootloaders and programs ... > > I'm using the CVS version of FreeBSD-HEAD (probably 8-current) of today. > > For example I get these errors: > Hi again, My box was running FreeBSD-6.x . Seems like crossbuilding 7-current for ARM on a 6.x box did not work. I've now upgraded to 7-current and it is building fine so far. --HPS From owner-freebsd-arm@FreeBSD.ORG Sun Dec 2 20:59:08 2007 Return-Path: Delivered-To: arm@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 4B95116A41A; Sun, 2 Dec 2007 20:59:08 +0000 (UTC) (envelope-from tinderbox@freebsd.org) Received: from smarthost1.sentex.ca (smarthost1.sentex.ca [64.7.153.18]) by mx1.freebsd.org (Postfix) with ESMTP id 00A5D13C459; Sun, 2 Dec 2007 20:59:07 +0000 (UTC) (envelope-from tinderbox@freebsd.org) Received: from smtp1.sentex.ca (smtp1c.sentex.ca [64.7.153.10]) by smarthost1.sentex.ca (8.13.8/8.13.8) with ESMTP id lB2Kx7hO092820; Sun, 2 Dec 2007 15:59:07 -0500 (EST) (envelope-from tinderbox@freebsd.org) Received: from freebsd-current.sentex.ca (freebsd-current.sentex.ca [64.7.128.98]) by smtp1.sentex.ca (8.14.1/8.14.1) with ESMTP id lB2Kx7WW033369; Sun, 2 Dec 2007 15:59:07 -0500 (EST) (envelope-from tinderbox@freebsd.org) Received: by freebsd-current.sentex.ca (Postfix, from userid 666) id 63D2873039; Sun, 2 Dec 2007 15:59:07 -0500 (EST) Sender: FreeBSD Tinderbox From: FreeBSD Tinderbox To: FreeBSD Tinderbox , , Precedence: bulk Message-Id: <20071202205907.63D2873039@freebsd-current.sentex.ca> Date: Sun, 2 Dec 2007 15:59:07 -0500 (EST) X-Virus-Scanned: ClamAV 0.91.2/4641/Tue Oct 30 15:59:09 2007 clamav-milter version 0.91.2 on clamscanner5 X-Virus-Status: Clean Cc: Subject: [head tinderbox] failure on arm/arm X-BeenThere: freebsd-arm@freebsd.org X-Mailman-Version: 2.1.5 List-Id: Porting FreeBSD to the StrongARM Processor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 02 Dec 2007 20:59:08 -0000 TB --- 2007-12-02 20:35:00 - tinderbox 2.3 running on freebsd-current.sentex.ca TB --- 2007-12-02 20:35:00 - starting HEAD tinderbox run for arm/arm TB --- 2007-12-02 20:35:00 - cleaning the object tree TB --- 2007-12-02 20:35:22 - cvsupping the source tree TB --- 2007-12-02 20:35:22 - /usr/bin/csup -r 3 -g -L 1 -h localhost -s /tinderbox/HEAD/arm/arm/supfile TB --- 2007-12-02 20:35:42 - building world (CFLAGS=-O -pipe) TB --- 2007-12-02 20:35:42 - cd /src TB --- 2007-12-02 20:35:42 - /usr/bin/make -B buildworld >>> World build started on Sun Dec 2 20:35:44 UTC 2007 >>> Rebuilding the temporary build tree >>> stage 1.1: legacy release compatibility shims >>> stage 1.2: bootstrap tools >>> stage 2.1: cleaning up the object tree >>> stage 2.2: rebuilding the object tree >>> stage 2.3: build tools >>> stage 3: cross tools >>> stage 4.1: building includes >>> stage 4.2: building libraries [...] rm -f .depend mkdep -f .depend -a -DVERSION='"9.4.2"' -DHAVE_CONFIG_H -D_REENTRANT -D_THREAD_SAFE -DLIBINTERFACE=30 -DLIBREVISION=3 -DLIBAGE=0 -DWANT_IPV6 -DOPENSSL -DUSE_MD5 -DNS_LOCALSTATEDIR='"/var"' -DNS_SYSCONFDIR='"/etc/namedb"' -DNAMED_CONFFILE='"/etc/namedb/named.conf"' -DRNDC_CONFFILE='"/etc/namedb/rndc.conf"' -DRNDC_KEYFILE='"/etc/namedb/rndc.key"' -I/src/lib/bind/isccfg/.. -I/src/lib/bind/isccfg/../../../contrib/bind9/lib/bind9/include -I/src/lib/bind/isccfg/../../../contrib/bind9/lib/dns/include/dst -I/src/lib/bind/isccfg/../../../contrib/bind9/lib/dns/include -I/src/lib/bind/isccfg/../dns -I/src/lib/bind/isccfg/../../../contrib/bind9/lib/isccc/include -I/src/lib/bind/isccfg/../../../contrib/bind9/lib/isccfg/include -I/src/lib/bind/isccfg/../../../contrib/bind9/lib/isc/unix/include -I/src/lib/bind/isccfg/../../../contrib/bind9/lib/isc/pthreads/include -I/src/lib/bind/isccfg/../../../contrib/bind9/lib/isc/include -I/src/lib/bind/isccfg/../isc -I/src/lib/bind/isccfg/../../../c ontrib/bind9/lib/lwres/unix/include -I/src/lib/bind/isccfg/../../../contrib/bind9/lib/lwres/include -I/src/lib/bind/isccfg/../lwres -I/src/lib/bind/isccfg/../../../contrib/bind9/lib/isccfg/include -I/src/lib/bind/isccfg -I/src/lib/bind/isccfg/../../../contrib/bind9/lib/isc/arm/include /src/lib/bind/isccfg/../../../contrib/bind9/lib/isccfg/aclconf.c /src/lib/bind/isccfg/../../../contrib/bind9/lib/isccfg/log.c /src/lib/bind/isccfg/../../../contrib/bind9/lib/isccfg/namedconf.c /src/lib/bind/isccfg/../../../contrib/bind9/lib/isccfg/parser.c /src/lib/bind/isccfg/../../../contrib/bind9/lib/isccfg/version.c ===> lib/bind/lwres (depend) rm -f .depend mkdep -f .depend -a -DVERSION='"9.4.2"' -DHAVE_CONFIG_H -D_REENTRANT -D_THREAD_SAFE -DLIBINTERFACE=30 -DLIBREVISION=5 -DLIBAGE=0 -DWANT_IPV6 -DOPENSSL -DUSE_MD5 -DNS_LOCALSTATEDIR='"/var"' -DNS_SYSCONFDIR='"/etc/namedb"' -DNAMED_CONFFILE='"/etc/namedb/named.conf"' -DRNDC_CONFFILE='"/etc/namedb/rndc.conf"' -DRNDC_KEYFILE='"/etc/namedb/rndc.key"' -I/src/lib/bind/lwres/.. -I/src/lib/bind/lwres/../../../contrib/bind9/lib/lwres/unix/include -I/src/lib/bind/lwres/../../../contrib/bind9/lib/lwres/include -I/src/lib/bind/lwres -I/src/lib/bind/lwres/../../../contrib/bind9/lib/isc/arm/include -I/src/lib/bind/lwres/../../../contrib/bind9/lib/isc/include -I/src/lib/bind/lwres/../../../contrib/bind9/lib/isc/unix/include /src/lib/bind/lwres/../../../contrib/bind9/lib/lwres/context.c /src/lib/bind/lwres/../../../contrib/bind9/lib/lwres/gai_strerror.c /src/lib/bind/lwres/../../../contrib/bind9/lib/lwres/getaddrinfo.c /src/lib/bind/lwres/../../../contrib/bind9/lib/lwres/gethost.c /src/lib/ bind/lwres/../../../contrib/bind9/lib/lwres/getipnode.c /src/lib/bind/lwres/../../../contrib/bind9/lib/lwres/getnameinfo.c /src/lib/bind/lwres/../../../contrib/bind9/lib/lwres/getrrset.c /src/lib/bind/lwres/../../../contrib/bind9/lib/lwres/herror.c /src/lib/bind/lwres/../../../contrib/bind9/lib/lwres/lwbuffer.c /src/lib/bind/lwres/../../../contrib/bind9/lib/lwres/lwconfig.c /src/lib/bind/lwres/../../../contrib/bind9/lib/lwres/lwpacket.c /src/lib/bind/lwres/../../../contrib/bind9/lib/lwres/lwresutil.c /src/lib/bind/lwres/../../../contrib/bind9/lib/lwres/lwres_gabn.c /src/lib/bind/lwres/../../../contrib/bind9/lib/lwres/lwres_gnba.c /src/lib/bind/lwres/../../../contrib/bind9/lib/lwres/lwres_grbn.c /src/lib/bind/lwres/../../../contrib/bind9/lib/lwres/lwres_noop.c /src/lib/bind/lwres/../../../contrib/bind9/lib/lwres/lwinetaton.c /src/lib/bind/lwres/../../../contrib/bind9/lib/lwres/lwinetpton.c /src/lib/bind/lwres/../../../contrib/bind9/lib/lwres/lwinetntop.c /src/lib/bind/lwres/. ./../../contrib/bind9/lib/lwres/print.c In file included from /src/lib/bind/lwres/../../../contrib/bind9/lib/lwres/getaddrinfo.c:138: /src/lib/bind/lwres/../../../contrib/bind9/lib/isc/include/isc/string.h:28:26: error: isc/platform.h: No such file or directory mkdep: compile failed *** Error code 1 Stop in /src/lib/bind/lwres. *** Error code 1 Stop in /src/lib/bind. *** Error code 1 Stop in /src/lib. *** Error code 1 Stop in /src. *** Error code 1 Stop in /src. *** Error code 1 Stop in /src. *** Error code 1 Stop in /src. TB --- 2007-12-02 20:59:07 - WARNING: /usr/bin/make returned exit code 1 TB --- 2007-12-02 20:59:07 - ERROR: failed to build world TB --- 2007-12-02 20:59:07 - tinderbox aborted TB --- 1063.64 user 144.91 system 1446.48 real http://tinderbox.des.no/tinderbox-head-HEAD-arm-arm.full From owner-freebsd-arm@FreeBSD.ORG Sun Dec 2 22:38:30 2007 Return-Path: Delivered-To: arm@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 06E0416A419; Sun, 2 Dec 2007 22:38:30 +0000 (UTC) (envelope-from tinderbox@freebsd.org) Received: from smarthost1.sentex.ca (smarthost1.sentex.ca [64.7.153.18]) by mx1.freebsd.org (Postfix) with ESMTP id B2DBA13C43E; Sun, 2 Dec 2007 22:38:28 +0000 (UTC) (envelope-from tinderbox@freebsd.org) Received: from smtp2.sentex.ca (smtp2c.sentex.ca [64.7.153.30]) by smarthost1.sentex.ca (8.13.8/8.13.8) with ESMTP id lB2McROk097399; Sun, 2 Dec 2007 17:38:27 -0500 (EST) (envelope-from tinderbox@freebsd.org) Received: from freebsd-current.sentex.ca (freebsd-current.sentex.ca [64.7.128.98]) by smtp2.sentex.ca (8.14.1/8.14.1) with ESMTP id lB2McRmv011915; Sun, 2 Dec 2007 17:38:27 -0500 (EST) (envelope-from tinderbox@freebsd.org) Received: by freebsd-current.sentex.ca (Postfix, from userid 666) id 782DE73039; Sun, 2 Dec 2007 17:38:27 -0500 (EST) Sender: FreeBSD Tinderbox From: FreeBSD Tinderbox To: FreeBSD Tinderbox , , Precedence: bulk Message-Id: <20071202223827.782DE73039@freebsd-current.sentex.ca> Date: Sun, 2 Dec 2007 17:38:27 -0500 (EST) X-Virus-Scanned: ClamAV 0.90.2/3781/Fri Jul 27 07:24:10 2007 clamav-milter version 0.91.1 on clamscanner2 X-Virus-Status: Clean Cc: Subject: [head tinderbox] failure on arm/arm X-BeenThere: freebsd-arm@freebsd.org X-Mailman-Version: 2.1.5 List-Id: Porting FreeBSD to the StrongARM Processor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 02 Dec 2007 22:38:30 -0000 TB --- 2007-12-02 22:15:00 - tinderbox 2.3 running on freebsd-current.sentex.ca TB --- 2007-12-02 22:15:00 - starting HEAD tinderbox run for arm/arm TB --- 2007-12-02 22:15:00 - cleaning the object tree TB --- 2007-12-02 22:15:16 - cvsupping the source tree TB --- 2007-12-02 22:15:16 - /usr/bin/csup -r 3 -g -L 1 -h localhost -s /tinderbox/HEAD/arm/arm/supfile TB --- 2007-12-02 22:15:26 - building world (CFLAGS=-O -pipe) TB --- 2007-12-02 22:15:26 - cd /src TB --- 2007-12-02 22:15:26 - /usr/bin/make -B buildworld >>> World build started on Sun Dec 2 22:15:28 UTC 2007 >>> Rebuilding the temporary build tree >>> stage 1.1: legacy release compatibility shims >>> stage 1.2: bootstrap tools >>> stage 2.1: cleaning up the object tree >>> stage 2.2: rebuilding the object tree >>> stage 2.3: build tools >>> stage 3: cross tools >>> stage 4.1: building includes >>> stage 4.2: building libraries [...] rm -f .depend mkdep -f .depend -a -DVERSION='"9.4.2"' -DHAVE_CONFIG_H -D_REENTRANT -D_THREAD_SAFE -DLIBINTERFACE=30 -DLIBREVISION=3 -DLIBAGE=0 -DWANT_IPV6 -DOPENSSL -DUSE_MD5 -DNS_LOCALSTATEDIR='"/var"' -DNS_SYSCONFDIR='"/etc/namedb"' -DNAMED_CONFFILE='"/etc/namedb/named.conf"' -DRNDC_CONFFILE='"/etc/namedb/rndc.conf"' -DRNDC_KEYFILE='"/etc/namedb/rndc.key"' -I/src/lib/bind/isccfg/.. -I/src/lib/bind/isccfg/../../../contrib/bind9/lib/bind9/include -I/src/lib/bind/isccfg/../../../contrib/bind9/lib/dns/include/dst -I/src/lib/bind/isccfg/../../../contrib/bind9/lib/dns/include -I/src/lib/bind/isccfg/../dns -I/src/lib/bind/isccfg/../../../contrib/bind9/lib/isccc/include -I/src/lib/bind/isccfg/../../../contrib/bind9/lib/isccfg/include -I/src/lib/bind/isccfg/../../../contrib/bind9/lib/isc/unix/include -I/src/lib/bind/isccfg/../../../contrib/bind9/lib/isc/pthreads/include -I/src/lib/bind/isccfg/../../../contrib/bind9/lib/isc/include -I/src/lib/bind/isccfg/../isc -I/src/lib/bind/isccfg/../../../c ontrib/bind9/lib/lwres/unix/include -I/src/lib/bind/isccfg/../../../contrib/bind9/lib/lwres/include -I/src/lib/bind/isccfg/../lwres -I/src/lib/bind/isccfg/../../../contrib/bind9/lib/isccfg/include -I/src/lib/bind/isccfg -I/src/lib/bind/isccfg/../../../contrib/bind9/lib/isc/arm/include /src/lib/bind/isccfg/../../../contrib/bind9/lib/isccfg/aclconf.c /src/lib/bind/isccfg/../../../contrib/bind9/lib/isccfg/log.c /src/lib/bind/isccfg/../../../contrib/bind9/lib/isccfg/namedconf.c /src/lib/bind/isccfg/../../../contrib/bind9/lib/isccfg/parser.c /src/lib/bind/isccfg/../../../contrib/bind9/lib/isccfg/version.c ===> lib/bind/lwres (depend) rm -f .depend mkdep -f .depend -a -DVERSION='"9.4.2"' -DHAVE_CONFIG_H -D_REENTRANT -D_THREAD_SAFE -DLIBINTERFACE=30 -DLIBREVISION=5 -DLIBAGE=0 -DWANT_IPV6 -DOPENSSL -DUSE_MD5 -DNS_LOCALSTATEDIR='"/var"' -DNS_SYSCONFDIR='"/etc/namedb"' -DNAMED_CONFFILE='"/etc/namedb/named.conf"' -DRNDC_CONFFILE='"/etc/namedb/rndc.conf"' -DRNDC_KEYFILE='"/etc/namedb/rndc.key"' -I/src/lib/bind/lwres/.. -I/src/lib/bind/lwres/../../../contrib/bind9/lib/lwres/unix/include -I/src/lib/bind/lwres/../../../contrib/bind9/lib/lwres/include -I/src/lib/bind/lwres -I/src/lib/bind/lwres/../../../contrib/bind9/lib/isc/arm/include -I/src/lib/bind/lwres/../../../contrib/bind9/lib/isc/include -I/src/lib/bind/lwres/../../../contrib/bind9/lib/isc/unix/include /src/lib/bind/lwres/../../../contrib/bind9/lib/lwres/context.c /src/lib/bind/lwres/../../../contrib/bind9/lib/lwres/gai_strerror.c /src/lib/bind/lwres/../../../contrib/bind9/lib/lwres/getaddrinfo.c /src/lib/bind/lwres/../../../contrib/bind9/lib/lwres/gethost.c /src/lib/ bind/lwres/../../../contrib/bind9/lib/lwres/getipnode.c /src/lib/bind/lwres/../../../contrib/bind9/lib/lwres/getnameinfo.c /src/lib/bind/lwres/../../../contrib/bind9/lib/lwres/getrrset.c /src/lib/bind/lwres/../../../contrib/bind9/lib/lwres/herror.c /src/lib/bind/lwres/../../../contrib/bind9/lib/lwres/lwbuffer.c /src/lib/bind/lwres/../../../contrib/bind9/lib/lwres/lwconfig.c /src/lib/bind/lwres/../../../contrib/bind9/lib/lwres/lwpacket.c /src/lib/bind/lwres/../../../contrib/bind9/lib/lwres/lwresutil.c /src/lib/bind/lwres/../../../contrib/bind9/lib/lwres/lwres_gabn.c /src/lib/bind/lwres/../../../contrib/bind9/lib/lwres/lwres_gnba.c /src/lib/bind/lwres/../../../contrib/bind9/lib/lwres/lwres_grbn.c /src/lib/bind/lwres/../../../contrib/bind9/lib/lwres/lwres_noop.c /src/lib/bind/lwres/../../../contrib/bind9/lib/lwres/lwinetaton.c /src/lib/bind/lwres/../../../contrib/bind9/lib/lwres/lwinetpton.c /src/lib/bind/lwres/../../../contrib/bind9/lib/lwres/lwinetntop.c /src/lib/bind/lwres/. ./../../contrib/bind9/lib/lwres/print.c In file included from /src/lib/bind/lwres/../../../contrib/bind9/lib/lwres/getaddrinfo.c:138: /src/lib/bind/lwres/../../../contrib/bind9/lib/isc/include/isc/string.h:28:26: error: isc/platform.h: No such file or directory mkdep: compile failed *** Error code 1 Stop in /src/lib/bind/lwres. *** Error code 1 Stop in /src/lib/bind. *** Error code 1 Stop in /src/lib. *** Error code 1 Stop in /src. *** Error code 1 Stop in /src. *** Error code 1 Stop in /src. *** Error code 1 Stop in /src. TB --- 2007-12-02 22:38:27 - WARNING: /usr/bin/make returned exit code 1 TB --- 2007-12-02 22:38:27 - ERROR: failed to build world TB --- 2007-12-02 22:38:27 - tinderbox aborted TB --- 1060.16 user 146.72 system 1407.02 real http://tinderbox.des.no/tinderbox-head-HEAD-arm-arm.full From owner-freebsd-arm@FreeBSD.ORG Mon Dec 3 00:03:52 2007 Return-Path: Delivered-To: freebsd-arm@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 602FF16A41A for ; Mon, 3 Dec 2007 00:03:52 +0000 (UTC) (envelope-from hselasky@c2i.net) Received: from swip.net (mailfe02.swip.net [212.247.154.33]) by mx1.freebsd.org (Postfix) with ESMTP id E8C4013C459 for ; Mon, 3 Dec 2007 00:03:51 +0000 (UTC) (envelope-from hselasky@c2i.net) X-Cloudmark-Score: 0.000000 [] Received: from [85.19.218.45] (account mc467741@c2i.net [85.19.218.45] verified) by mailfe02.swip.net (CommuniGate Pro SMTP 5.1.13) with ESMTPA id 714431866 for freebsd-arm@freebsd.org; Mon, 03 Dec 2007 01:03:48 +0100 From: Hans Petter Selasky To: freebsd-arm@freebsd.org Date: Mon, 3 Dec 2007 01:04:21 +0100 User-Agent: KMail/1.9.7 References: <200712021634.18193.hselasky@c2i.net> <200712022024.43708.hselasky@c2i.net> In-Reply-To: <200712022024.43708.hselasky@c2i.net> MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Content-Disposition: inline Message-Id: <200712030104.21956.hselasky@c2i.net> Subject: Re: Setting up an AT91RM9200 based board (KB9202B) with FreeBSD X-BeenThere: freebsd-arm@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Porting FreeBSD to the StrongARM Processor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 03 Dec 2007 00:03:52 -0000 Hi, I have now successfully compiled the userland and the kernel for ARM. The next problem is to get the bootloaders installed. I've tried to search google about this, but no luck. Any hints? I have the KB9202B connected through a serial cable. I have tools like "minicom" and "kermit" installed. How to proceed ? --HPS From owner-freebsd-arm@FreeBSD.ORG Mon Dec 3 08:32:33 2007 Return-Path: Delivered-To: freebsd-arm@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 3929B16A420 for ; Mon, 3 Dec 2007 08:32:33 +0000 (UTC) (envelope-from xride@x12.dk) Received: from cicero2.cybercity.dk (cicero2.cybercity.dk [212.242.40.53]) by mx1.freebsd.org (Postfix) with ESMTP id 1754C13C448 for ; Mon, 3 Dec 2007 08:32:32 +0000 (UTC) (envelope-from xride@x12.dk) Received: from beacon.x12.dk (0x5550f21e.adsl.cybercity.dk [85.80.242.30]) by cicero2.cybercity.dk (Postfix) with ESMTP id 8C71719E286; Mon, 3 Dec 2007 09:32:31 +0100 (CET) Received: from localhost (localhost [127.0.0.1]) by beacon.x12.dk (Postfix) with ESMTP id C813428417; Mon, 3 Dec 2007 09:33:14 +0100 (CET) Date: Mon, 3 Dec 2007 09:32:25 +0100 From: Soeren Straarup To: Hans Petter Selasky Message-ID: <20071203093225.2804529a@x12.dk> In-Reply-To: <200712030104.21956.hselasky@c2i.net> References: <200712021634.18193.hselasky@c2i.net> <200712022024.43708.hselasky@c2i.net> <200712030104.21956.hselasky@c2i.net> X-Mailer: Claws Mail 3.0.2 (GTK+ 2.12.1; i386-portbld-freebsd8.0) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Cc: freebsd-arm@freebsd.org Subject: Re: Setting up an AT91RM9200 based board (KB9202B) with FreeBSD X-BeenThere: freebsd-arm@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Porting FreeBSD to the StrongARM Processor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 03 Dec 2007 08:32:33 -0000 On Mon, 3 Dec 2007 01:04:21 +0100 Hans Petter Selasky wrote: > Hi, > > I have now successfully compiled the userland and the kernel for ARM. > > The next problem is to get the bootloaders installed. I've tried to > search google about this, but no luck. > > Any hints? > > I have the KB9202B connected through a serial cable. > > I have tools like "minicom" and "kermit" installed. > > How to proceed ? > > --HPS unsubscribe, send any mail to "freebsd-arm-unsubscribe@freebsd.org" This is how it works for me: in src/sys/boot/arm/at91/Makefile.inc I set BOOT_FLAVOR to the board i'm working on. Then to setup the cross env i do the "Building the boot loader". http://people.freebsd.org/~xride/arm/ /Soeren -- Soeren Straarup | aka OZ2DAK aka Xride FreeBSD committer | FreeBSD since 2.2.6-R If a program is not working right, then send a patch From owner-freebsd-arm@FreeBSD.ORG Mon Dec 3 13:31:53 2007 Return-Path: Delivered-To: freebsd-arm@FreeBSD.ORG Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id AD4E216A421 for ; Mon, 3 Dec 2007 13:31:53 +0000 (UTC) (envelope-from raj@semihalf.com) Received: from mail.semihalf.com (mail.semihalf.com [83.15.139.206]) by mx1.freebsd.org (Postfix) with ESMTP id 0EE2F13C4CC for ; Mon, 3 Dec 2007 13:31:53 +0000 (UTC) (envelope-from raj@semihalf.com) Received: from localhost (unknown [127.0.0.1]) by mail.semihalf.com (Postfix) with ESMTP id 68CC21443D; Mon, 3 Dec 2007 14:34:15 +0100 (CET) Received: from mail.semihalf.com ([127.0.0.1]) by localhost (mail.semihalf.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 18946-02; Mon, 3 Dec 2007 14:34:13 +0100 (CET) Message-ID: <47540545.6020407@semihalf.com> Date: Mon, 03 Dec 2007 14:31:49 +0100 From: Rafal Jaworowski MIME-Version: 1.0 To: "M. Warner Losh" References: <20071202140920.GA40640@ci0.org> <20071202.072138.1723236577.imp@bsdimp.com> <4752C2A0.9010604@semihalf.com> <20071202.074803.-1625880187.imp@bsdimp.com> In-Reply-To: <20071202.074803.-1625880187.imp@bsdimp.com> Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit X-Virus-Scanned: by amavisd-new at semihalf.com Cc: freebsd-arm@FreeBSD.ORG Subject: Re: ARM arch subdir cleanups X-BeenThere: freebsd-arm@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Porting FreeBSD to the StrongARM Processor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 03 Dec 2007 13:31:53 -0000 M. Warner Losh wrote: > : Are your OBIO cleanups available somewhere? Are you going to finish these (so > : as not to overlap the work...)? > > What I've done to date is available in the p4 branch "arm-devel" and > are in the form of a set of routines in subr_obio.c. They likely need > to be enhanced and generalized a little (I just converted at91 to use > them, nothing else). I had hoped to be able to come up with something > that could also be merged into RELENG_7 as an optional feature to keep > maintenance costs down for things MFC'd. I'll have a look at your changes and try to come up with something generic for all OBIO incarnations; it's good you reworked the at91 as it seemed to me mostly divergent from what other OBIOs (Xscales mainly) look like. > : > The other thing that I'd like to see is a better defined board/cpu > : > initialization sequence. Or to make better use of the one that's > : > defined now and document it better. I made some bad choices, in > : > hindsight, for the at91rm9200 port that are only now becoming > : > apparent. > : > > : > : Yes, this is a valid point. As we already talked I keep this in mind while > : fleshing out the Orion port, but it'll make more sense for me to return to > : such refactoring in a second spin, after we have basic functionality in operation. > > One thing that might help is better documentation in this area. Had > my professional life not taken an unexpected turn recently, I had > planned on getting some time to document the conventions and try to > move all the arm subports into compliance with that vision. I was > then hoping to use that experience to define a cleanup, etc. However, Could you perhaps be able to share some notes on the most important items from that envisioned changes/refactoring? Rafal From owner-freebsd-arm@FreeBSD.ORG Mon Dec 3 22:33:55 2007 Return-Path: Delivered-To: freebsd-arm@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 0F2A716A469 for ; Mon, 3 Dec 2007 22:33:55 +0000 (UTC) (envelope-from hselasky@c2i.net) Received: from swip.net (mailfe11.swipnet.se [212.247.155.65]) by mx1.freebsd.org (Postfix) with ESMTP id B270C13C447 for ; Mon, 3 Dec 2007 22:33:54 +0000 (UTC) (envelope-from hselasky@c2i.net) X-Cloudmark-Score: 0.000000 [] Received: from [85.19.218.45] (account mc467741@c2i.net [85.19.218.45] verified) by mailfe11.swip.net (CommuniGate Pro SMTP 5.1.13) with ESMTPA id 544286975; Mon, 03 Dec 2007 22:33:50 +0100 From: Hans Petter Selasky To: Soeren Straarup Date: Mon, 3 Dec 2007 22:34:29 +0100 User-Agent: KMail/1.9.7 References: <200712021634.18193.hselasky@c2i.net> <200712030104.21956.hselasky@c2i.net> <20071203093225.2804529a@x12.dk> In-Reply-To: <20071203093225.2804529a@x12.dk> MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Content-Disposition: inline Message-Id: <200712032234.30584.hselasky@c2i.net> Cc: freebsd-arm@freebsd.org Subject: Re: Setting up an AT91RM9200 based board (KB9202B) with FreeBSD X-BeenThere: freebsd-arm@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Porting FreeBSD to the StrongARM Processor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 03 Dec 2007 22:33:55 -0000 Hi, Thanks for all the help. I got the kernel booting a last, but I didn't manage to get rid of the U-boot yet. I've updated the following page with some more info for newbies: http://wiki.freebsd.org/FreeBSDAtlmel --HPS From owner-freebsd-arm@FreeBSD.ORG Mon Dec 3 23:48:42 2007 Return-Path: Delivered-To: freebsd-arm@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id BACF016A417 for ; Mon, 3 Dec 2007 23:48:42 +0000 (UTC) (envelope-from imp@bsdimp.com) Received: from harmony.bsdimp.com (bsdimp.com [199.45.160.85]) by mx1.freebsd.org (Postfix) with ESMTP id 6556E13C442 for ; Mon, 3 Dec 2007 23:48:42 +0000 (UTC) (envelope-from imp@bsdimp.com) Received: from localhost (localhost [127.0.0.1]) by harmony.bsdimp.com (8.14.1/8.14.1) with ESMTP id lB3Nh49r094217; Mon, 3 Dec 2007 16:43:04 -0700 (MST) (envelope-from imp@bsdimp.com) Date: Mon, 03 Dec 2007 16:46:46 -0700 (MST) Message-Id: <20071203.164646.-432837869.imp@bsdimp.com> To: hselasky@c2i.net From: "M. Warner Losh" In-Reply-To: <200712032234.30584.hselasky@c2i.net> References: <200712030104.21956.hselasky@c2i.net> <20071203093225.2804529a@x12.dk> <200712032234.30584.hselasky@c2i.net> X-Mailer: Mew version 5.2 on Emacs 21.3 / Mule 5.0 (SAKAKI) Mime-Version: 1.0 Content-Type: Text/Plain; charset=us-ascii Content-Transfer-Encoding: 7bit Cc: freebsd-arm@freebsd.org Subject: Re: Setting up an AT91RM9200 based board (KB9202B) with FreeBSD X-BeenThere: freebsd-arm@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Porting FreeBSD to the StrongARM Processor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 03 Dec 2007 23:48:42 -0000 In message: <200712032234.30584.hselasky@c2i.net> Hans Petter Selasky writes: : Hi, : : Thanks for all the help. I got the kernel booting a last, but I didn't manage : to get rid of the U-boot yet. u-boot should be able to boot FreeBSD, but you may need to put the kernel into the flash on the board. : I've updated the following page with some more info for newbies: : : http://wiki.freebsd.org/FreeBSDAtlmel i'll take a look at this too. Warner From owner-freebsd-arm@FreeBSD.ORG Tue Dec 4 07:22:33 2007 Return-Path: Delivered-To: freebsd-arm@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 37A4B16A417 for ; Tue, 4 Dec 2007 07:22:33 +0000 (UTC) (envelope-from xride@x12.dk) Received: from cicero3.cybercity.dk (cicero3.cybercity.dk [212.242.43.248]) by mx1.freebsd.org (Postfix) with ESMTP id 04E9B13C474 for ; Tue, 4 Dec 2007 07:22:32 +0000 (UTC) (envelope-from xride@x12.dk) Received: from beacon.x12.dk (0x5550f21e.adsl.cybercity.dk [85.80.242.30]) by cicero3.cybercity.dk (Postfix) with ESMTP id 2495A2619A8; Tue, 4 Dec 2007 08:22:30 +0100 (CET) Received: from localhost (localhost [127.0.0.1]) by beacon.x12.dk (Postfix) with ESMTP id E648E28417; Tue, 4 Dec 2007 08:23:13 +0100 (CET) Date: Tue, 4 Dec 2007 08:22:22 +0100 From: Soeren Straarup To: "M. Warner Losh" Message-ID: <20071204082222.2ce47dee@x12.dk> In-Reply-To: <20071203.164646.-432837869.imp@bsdimp.com> References: <200712030104.21956.hselasky@c2i.net> <20071203093225.2804529a@x12.dk> <200712032234.30584.hselasky@c2i.net> <20071203.164646.-432837869.imp@bsdimp.com> X-Mailer: Claws Mail 3.0.2 (GTK+ 2.12.1; i386-portbld-freebsd8.0) Telephone: +4575581244 +13612371008 Mobil: +4520276244 X-Face: 7Y!o?/XT:H%BE>uVwW9m14t\pR.ZF]T!3s$d_`Gv6TVIknyh$"aMW=:t(r}QL:3W, Ico:Gec Ksmq@nVq-$Ks_33F0L>R[^qp'3-g4eV#nKv/8rl",TY4NTKO&DRL)e(x^6Tn^9".i; oJf-l69YL+>hY- }/$J[OE(pIER<2n`8E_}HLv`tXVvUr^O%#4 Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Cc: freebsd-arm@freebsd.org Subject: Re: Setting up an AT91RM9200 based board (KB9202B) with FreeBSD X-BeenThere: freebsd-arm@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Porting FreeBSD to the StrongARM Processor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 04 Dec 2007 07:22:33 -0000 On Mon, 03 Dec 2007 16:46:46 -0700 (MST) "M. Warner Losh" wrote: > In message: <200712032234.30584.hselasky@c2i.net> > Hans Petter Selasky writes: > : Hi, > : > : Thanks for all the help. I got the kernel booting a last, but I > didn't manage : to get rid of the U-boot yet. > > u-boot should be able to boot FreeBSD, but you may need to put the > kernel into the flash on the board. > Interreting.. It might be that i tftp'ed the kernel into ram and then tried to boot it that went wrong. [OT] what about yamon on mips? > : I've updated the following page with some more info for newbies: > : > : http://wiki.freebsd.org/FreeBSDAtlmel > > i'll take a look at this too. > > Warner /Soeren -- Soeren Straarup | aka OZ2DAK aka Xride FreeBSD committer | FreeBSD since 2.2.6-R If a program is not working right, then send a patch From owner-freebsd-arm@FreeBSD.ORG Tue Dec 4 12:07:02 2007 Return-Path: Delivered-To: freebsd-arm@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 5859B16A418 for ; Tue, 4 Dec 2007 12:07:02 +0000 (UTC) (envelope-from bkoenig@alpha-tierchen.de) Received: from mx01.qsc.de (mx01.qsc.de [213.148.129.14]) by mx1.freebsd.org (Postfix) with ESMTP id 1AFC013C45A for ; Tue, 4 Dec 2007 12:07:01 +0000 (UTC) (envelope-from bkoenig@alpha-tierchen.de) Received: from webmail.alpha-tierchen.de (port-212-202-40-215.dynamic.qsc.de [212.202.40.215]) by mx01.qsc.de (Postfix) with ESMTP id A0BB6C7E02; Tue, 4 Dec 2007 13:06:59 +0100 (CET) Received: from 212.202.40.215 (SquirrelMail authenticated user bkoenig) by webmail.alpha-tierchen.de with HTTP; Tue, 4 Dec 2007 13:06:47 +0100 (CET) Message-ID: <61569.212.202.40.215.1196770007.squirrel@webmail.alpha-tierchen.de> Date: Tue, 4 Dec 2007 13:06:47 +0100 (CET) From: =?iso-8859-1?Q?Bj=F6rn_K=F6nig?= To: "Soeren Straarup" User-Agent: SquirrelMail/1.4.11 MIME-Version: 1.0 Content-Type: text/plain;charset=iso-8859-1 Content-Transfer-Encoding: 8bit X-Priority: 3 (Normal) Importance: Normal Cc: freebsd-arm@freebsd.org Subject: Re: Setting up an AT91RM9200 based board (KB9202B) with FreeBSD X-BeenThere: freebsd-arm@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Porting FreeBSD to the StrongARM Processor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 04 Dec 2007 12:07:02 -0000 > On Mon, 03 Dec 2007 16:46:46 -0700 (MST) > "M. Warner Losh" wrote: > >> u-boot should be able to boot FreeBSD, but you may need to put the >> kernel into the flash on the board. >> > > Interreting.. > It might be that i tftp'ed the kernel into ram and then tried to > boot it that went wrong. For example you can do it this way: Build a kernel with 'make buildkernel', put the ELF binary into TFTP root, then run the following commands at u-boot prompt: tftpboot 20000000 /kernel erase 10040000 1043ffff cp.b 20000000 10040000 0x$(filesize) setenv freebsd cp.b 10040000 20000000 $(filesize)\; go 200000e0 saveenv Now you can boot the kernel from flash with run freebsd This doesn't even require that u-boot supports ELF. Björn From owner-freebsd-arm@FreeBSD.ORG Tue Dec 4 18:04:10 2007 Return-Path: Delivered-To: freebsd-arm@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 3C6D816A421 for ; Tue, 4 Dec 2007 18:04:10 +0000 (UTC) (envelope-from hselasky@c2i.net) Received: from swip.net (mailfe09.swipnet.se [212.247.155.1]) by mx1.freebsd.org (Postfix) with ESMTP id 4249013C46A for ; Tue, 4 Dec 2007 18:04:08 +0000 (UTC) (envelope-from hselasky@c2i.net) X-Cloudmark-Score: 0.000000 [] Received: from [85.19.218.45] (account mc467741@c2i.net [85.19.218.45] verified) by mailfe09.swip.net (CommuniGate Pro SMTP 5.1.13) with ESMTPA id 545591946; Tue, 04 Dec 2007 19:04:06 +0100 From: Hans Petter Selasky To: freebsd-arm@freebsd.org Date: Tue, 4 Dec 2007 19:04:36 +0100 User-Agent: KMail/1.9.7 References: <61569.212.202.40.215.1196770007.squirrel@webmail.alpha-tierchen.de> In-Reply-To: <61569.212.202.40.215.1196770007.squirrel@webmail.alpha-tierchen.de> MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Content-Disposition: inline Message-Id: <200712041904.37074.hselasky@c2i.net> Cc: =?iso-8859-1?q?Bj=F6rn_K=F6nig?= Subject: Re: Setting up an AT91RM9200 based board (KB9202B) with FreeBSD X-BeenThere: freebsd-arm@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Porting FreeBSD to the StrongARM Processor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 04 Dec 2007 18:04:10 -0000 On Tuesday 04 December 2007, Bj=F6rn K=F6nig wrote: > > On Mon, 03 Dec 2007 16:46:46 -0700 (MST) > > > > "M. Warner Losh" wrote: > >> u-boot should be able to boot FreeBSD, but you may need to put the > >> kernel into the flash on the board. > > > > Interreting.. > > It might be that i tftp'ed the kernel into ram and then tried to > > boot it that went wrong. > > For example you can do it this way: > > Build a kernel with 'make buildkernel', put the ELF binary into TFTP root, > then run the following commands at u-boot prompt: > tftpboot 20000000 /kernel > erase 10040000 1043ffff > cp.b 20000000 10040000 0x$(filesize) > setenv freebsd cp.b 10040000 20000000 $(filesize)\; go 200000e0 > saveenv > > Now you can boot the kernel from flash with > run freebsd > > This doesn't even require that u-boot supports ELF. > > Bj=F6rn Hi, I've updated the wiki accordingly. http://wiki.freebsd.org/FreeBSDAtmel Let me know if I got anything wrong. =2D-HPS From owner-freebsd-arm@FreeBSD.ORG Thu Dec 6 21:58:22 2007 Return-Path: Delivered-To: freebsd-arm@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 9710C16A421 for ; Thu, 6 Dec 2007 21:58:22 +0000 (UTC) (envelope-from tinguely@casselton.net) Received: from casselton.net (casselton.net [63.165.140.2]) by mx1.freebsd.org (Postfix) with ESMTP id 3491813C465 for ; Thu, 6 Dec 2007 21:58:22 +0000 (UTC) (envelope-from tinguely@casselton.net) Received: from casselton.net (localhost [127.0.0.1]) by casselton.net (8.13.8/8.13.8) with ESMTP id lB6LwLrN089100 for ; Thu, 6 Dec 2007 15:58:21 -0600 (CST) (envelope-from tinguely@casselton.net) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=casselton.net; s=ccnMail; t=1196978301; bh=T++/+HCadWAd70aA9tYMJdz0arHfOUbb6wV8Xk7 Pq/4=; h=Date:From:Message-Id:To:Subject; b=KiH8vHC9hyKLtNAZQn2wgaw Uns6RnmJHlSHxjZbK1EipB70t2Y1nI2vHI2JuCg0GPw0lrQ0j1ThLyvqELOUzv2fYYB rfUrIwEImRf4+bPZupzoOFYAxdOeHUQe2qWoUIvO0V2I23n5/uoO+B0TN7o32qynl4f yx62Fo+8VVQv4w= Received: (from tinguely@localhost) by casselton.net (8.13.8/8.13.8/Submit) id lB6LwL1D089098 for freebsd-arm@freebsd.org; Thu, 6 Dec 2007 15:58:21 -0600 (CST) (envelope-from tinguely) Date: Thu, 6 Dec 2007 15:58:21 -0600 (CST) From: Mark Tinguely Message-Id: <200712062158.lB6LwL1D089098@casselton.net> To: freebsd-arm@freebsd.org Subject: ARM pmap_enter_pv question X-BeenThere: freebsd-arm@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Porting FreeBSD to the StrongARM Processor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 06 Dec 2007 21:58:22 -0000 in pmap_enter_pv(), it seems to me there is an "else" missing: if (pm == pmap_kernel()) { if (flags & PVF_WRITE) pg->md.krw_mappings++; else pg->md.kro_mappings++; } <<<< is there a "else" missing? if (flags & PVF_WRITE) pg->md.urw_mappings++; else pg->md.uro_mappings++; I don't think it will effect any caching settings. --Mark Tinguely. From owner-freebsd-arm@FreeBSD.ORG Thu Dec 6 22:07:37 2007 Return-Path: Delivered-To: freebsd-arm@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id E3DF316A417 for ; Thu, 6 Dec 2007 22:07:37 +0000 (UTC) (envelope-from mlfbsd@dong.ci0.org) Received: from dong.ci0.org (dong.ci0.org [IPv6:2001:7a8:2066:1::1]) by mx1.freebsd.org (Postfix) with ESMTP id 3914F13C44B for ; Thu, 6 Dec 2007 22:07:36 +0000 (UTC) (envelope-from mlfbsd@dong.ci0.org) Received: from dong.ci0.org (localhost.ci0.org [127.0.0.1]) by dong.ci0.org (8.14.1/8.13.8) with ESMTP id lB6N4IPf007401; Fri, 7 Dec 2007 00:04:18 +0100 (CET) (envelope-from mlfbsd@dong.ci0.org) Received: (from mlfbsd@localhost) by dong.ci0.org (8.14.1/8.13.8/Submit) id lB6N4IoX007398; Fri, 7 Dec 2007 00:04:18 +0100 (CET) (envelope-from mlfbsd) Date: Fri, 7 Dec 2007 00:04:18 +0100 From: Olivier Houchard To: Mark Tinguely Message-ID: <20071206230417.GA7366@ci0.org> References: <200712062158.lB6LwL1D089098@casselton.net> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <200712062158.lB6LwL1D089098@casselton.net> User-Agent: Mutt/1.4.1i Cc: freebsd-arm@freebsd.org Subject: Re: ARM pmap_enter_pv question X-BeenThere: freebsd-arm@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Porting FreeBSD to the StrongARM Processor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 06 Dec 2007 22:07:38 -0000 On Thu, Dec 06, 2007 at 03:58:21PM -0600, Mark Tinguely wrote: > > in pmap_enter_pv(), it seems to me there is an "else" missing: > > if (pm == pmap_kernel()) { > if (flags & PVF_WRITE) > pg->md.krw_mappings++; > else > pg->md.kro_mappings++; > } <<<< is there a "else" missing? > if (flags & PVF_WRITE) > pg->md.urw_mappings++; > else > pg->md.uro_mappings++; > > I don't think it will effect any caching settings. > You're right, I wonder where this else went, it must have been there, because this code comes from NetBSD, and NetBSD has it. Thanks a lot ! Olivier From owner-freebsd-arm@FreeBSD.ORG Sat Dec 8 10:22:42 2007 Return-Path: Delivered-To: freebsd-arm@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 99D9816A46B for ; Sat, 8 Dec 2007 10:22:42 +0000 (UTC) (envelope-from raj@semihalf.com) Received: from mail.semihalf.com (mail.semihalf.com [83.15.139.206]) by mx1.freebsd.org (Postfix) with ESMTP id 1FAAF13C45A for ; Sat, 8 Dec 2007 10:22:42 +0000 (UTC) (envelope-from raj@semihalf.com) Received: from localhost (unknown [127.0.0.1]) by mail.semihalf.com (Postfix) with ESMTP id 8D9E11449A; Sat, 8 Dec 2007 11:25:31 +0100 (CET) Received: from mail.semihalf.com ([127.0.0.1]) by localhost (mail.semihalf.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 28005-03; Sat, 8 Dec 2007 11:25:29 +0100 (CET) Received: from [77.113.90.12] (apn-77-113-90-12.gprs.plus.pl [77.113.90.12]) by mail.semihalf.com (Postfix) with ESMTP id 88BD714474; Sat, 8 Dec 2007 11:25:25 +0100 (CET) Message-ID: <475A7061.7010001@semihalf.com> Date: Sat, 08 Dec 2007 11:22:25 +0100 From: Rafal Jaworowski MIME-Version: 1.0 To: freebsd-arm@freebsd.org Content-Type: text/plain; charset=ISO-8859-2 Content-Transfer-Encoding: 7bit X-Virus-Scanned: by amavisd-new at semihalf.com Cc: Subject: ARM pmap/UMA LOR in init(8) X-BeenThere: freebsd-arm@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Porting FreeBSD to the StrongARM Processor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 08 Dec 2007 10:22:42 -0000 Hi, We have identified the following lock order reversal that shows up early in the init(8); after closer look it seems harmless, so the description below is mostly for the record when it scares other people as well... [credits for the investigation and analysis go to Grzegorz] 1. It occurs only when *both* WITNESS and INVARIANTS are set in kernel config. lock order reversal: 1st 0xc195108c pmap (pmap) @ src/sys/arm/arm/pmap.c:971 2nd 0xc0f1b608 PV ENTRY (UMA zone) @ src/sys/vm/uma_core.c backtrace: witness_checkorder() at witness_checkorder+0x10 scp=0xc04abb48 rlv=0xc046bd88 (_mtx_lock_flags+0x60) rsp=0xc7882b0c rfp=0xc7882b34 r10=0xc0e6efd8 r9=0x00000001 r8=0x00000752 r7=0xc05b9d28 r6=0x00000000 r5=0xc0f1b608 r4=0xc0df8988 _mtx_lock_flags() at _mtx_lock_flags+0x10 scp=0xc046bd38 rlv=0xc05537fc (uma_zalloc_arg+0x94) rsp=0xc7882b38 rfp=0xc7882b78 r10=0x0141f55e r8=0xc0f1a580 r7=0xc0f1a5c8 r6=0x00000000 r5=0xc0f030b8 r4=0x0141f552 uma_zalloc_arg() at uma_zalloc_arg+0x10 scp=0xc0553778 rlv=0xc057b3a0 (pmap_release+0x112c) rsp=0xc7882b7c rfp=0xc7882be0 r10=0x0141f55e r9=0x00000001 r8=0x00000000 r7=0xc195108c r6=0x00000000 r5=0xc0f030b8 r4=0x0141f552 pmap_release() at pmap_release+0x2d4 scp=0xc057a548 rlv=0xc057b838 (pmap_enter+0x74) rsp=0xc7882be4 rfp=0xc7882c14 r10=0xc0f8baa8 r9=0xc0e655ac r8=0xbffff000 r7=0x00000000 r6=0xc195108c r5=0xc05be584 r4=0x00000007 pmap_enter() at pmap_enter+0x10 scp=0xc057b7d4 rlv=0xc0556d50 (vm_fault+0x1438) rsp=0xc7882c18 rfp=0xc7882d34 r10=0xc7882ddc r9=0xc7882ef8 r8=0x00000002 r7=0xc194a440 r6=0x00000000 r5=0x00000001 r4=0xc0f8baa8 vm_fault() at vm_fault+0x10 scp=0xc0555928 rlv=0xc058048c (data_abort_handler+0x1ec) rsp=0xc7882d38 rfp=0xc7882dd8 r10=0xc7882ddc r9=0xc7882ef8 r8=0x00000002 r7=0xc194a440 r6=0x00000000 r5=0xbffff000 r4=0xc194d090 data_abort_handler() at data_abort_handler+0x10 scp=0xc05802b0 rlv=0xc0573fa8 (address_exception_entry+0x50) rsp=0xc7882ddc rfp=0xc7882e7c r10=0x00000000 r9=0xc194d000 r8=0xc0df2a9c r7=0xc0df2aa6 r6=0xc044ac78 r5=0xe0000004 r4=0xbfffffff exec_shell_imgact() at exec_shell_imgact+0x614 scp=0xc044ac88 rlv=0xc045e5d0 (fork_exit+0x78) rsp=0xc7882e80 rfp=0xc7882ea8 r10=0x00000000 r9=0x00000001 r8=0xc7882eac r7=0xc194d000 r6=0xc044ac78 r5=0xc0e6efd8 r4=0xc194a440 fork_exit() at fork_exit+0x10 scp=0xc045e568 rlv=0xc057fb28 (fork_trampoline+0x14) rsp=0xc7882eac rfp=0x00000000 r10=0x00000000 r9=0x00000000 r8=0x00000000 r7=0xc0558268 r6=0xc785aeac r5=0x00000000 r4=0xc044ac78 2. From witness(4) perspective we have the follwing calls flow: witness_checkorder() <--- here pmap mutex is set as a child of 'UMA zone' mtx_lock_flags() <--- pmap mutex is taken pmap_extract() uma_dbg_getslab() uma_dbg_alloc() <--- it is called only with INVARIANTS uma_zalloc_arg() <--- here 'UMA zone' mutex is taken malloc() mtx_pool_create() mtx_pool_setup_dynamic() mi_startup() witness_checkorder() sets pmap mutex as a child of 'UMA zone' mutex since 'UMA zone' is already taken; so far all is considered correct by witness(4). 3. Here's an interesting part of ddb 'sh witness' trace (with pmap vs UMA zone order): 0 devfsmount 1 devfs interlock 5 vnode interlock 6 cdev 6 vnode_free_list 6 vnode_free_list 2 UMA zone 5 pmap 5 vnode interlock At this angle, pmap mutex is taken first and then we try to take UMA zone mutex, witness(4) considers this an order violation and screams. 4. The problem is witness(4) uses lock type to differentiate between locking objects. However, this field is hardly ever used when creating locking objects, so most often the name is used instead. In effect, all mutexes for pmap structures end up of the same 'pmap' type, similarly for UMA zone mutexes: whereas each zone has physically separate locking object, they all seem as one 'UMA zone' mutex... In summary this LOR doesn't concern the same mutexes that witness(4) thinks, but it's unable to discern this. Rafal