From owner-freebsd-arm@FreeBSD.ORG Wed May 31 17:17:08 2006 Return-Path: X-Original-To: freebsd-arm@freebsd.org Delivered-To: freebsd-arm@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 507B816A5E2 for ; Wed, 31 May 2006 17:17:08 +0000 (UTC) (envelope-from mlfbsd@dong.ci0.org) Received: from dong.ci0.org (cognet.ci0.org [80.65.224.102]) by mx1.FreeBSD.org (Postfix) with ESMTP id 5BFF043D4C for ; Wed, 31 May 2006 17:17:06 +0000 (GMT) (envelope-from mlfbsd@dong.ci0.org) Received: from dong.ci0.org (localhost.ci0.org [127.0.0.1]) by dong.ci0.org (8.13.6/8.13.4) with ESMTP id k4VHoQnP097365; Wed, 31 May 2006 19:50:26 +0200 (CEST) (envelope-from mlfbsd@dong.ci0.org) Received: (from mlfbsd@localhost) by dong.ci0.org (8.13.6/8.13.4/Submit) id k4VHoPhL097364; Wed, 31 May 2006 19:50:25 +0200 (CEST) (envelope-from mlfbsd) Date: Wed, 31 May 2006 19:50:25 +0200 From: Olivier Houchard To: "Max N. Boyarov" Message-ID: <20060531175025.GA97299@ci0.org> References: <7hodxe4132.fsf@bsd.by> <20060531170631.GA96970@ci0.org> <7hk6823yzj.fsf@bsd.by> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <7hk6823yzj.fsf@bsd.by> User-Agent: Mutt/1.4.1i Cc: freebsd-arm@freebsd.org Subject: Re: i80321reg.h 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: Wed, 31 May 2006 17:17:09 -0000 On Wed, May 31, 2006 at 08:06:40PM +0300, Max N. Boyarov wrote: > > >>>>> "OH" == Olivier Houchard writes: > > OH> On Wed, May 31, 2006 at 07:21:21PM +0300, Max N. Boyarov wrote: > >> > >> Hi! > >> > >> What document should I read in order to understand > >> how to calculate the defines that are used in i80321reg.h ? > >> > > OH> Hi Max, > Hi Olivier, > OH> I'm not sure I understand the question. However, those most of those values > OH> come from the Intel 80321 I/O Processor developer's manual, available here : > OH> http://www.intel.com/design/iio/manuals/273517.htm > > Sorry for my english :). I meant, I do not know how freebsd works with virtual > memory, i.e. what address range is used for user applications, where kernel resides. > What would you recommend to read about that? Just for education purposes :) My concern > is 80321 xcale port only (not generic). > No worries, my english isn't better :) Unfortunately I'm not sure there's something explaining this beside the code itself, so I'm gonna try to answer. Most of this is the same for every arm port, including the 80321. The interesting #define are mostly in sys/arm/include/vmparam.h * The line between user space and kernel space * Mappings >= KERNEL_BASE are constant across all processes */ #define KERNBASE 0xc0000000 So generally speaking, whatever is >= 0xc0000000 is kernelland, whatever is < is userland. In arm/xscale/iq31244_machdep.c (which should be usable for every i80321 port, and thus has an unaccurate name), we map 0xfe800000 (IQ80321_OBIO_BASE), physical == virtual, to be able to use the UART early, then we use the virtual address 0xfe400000 (IQ80321_IOW_VBASE) to map the ATU stuff and the CPU registers. I'm still not sure I properly answer to your question:) Feel free to ask for more. Olivier