From owner-freebsd-arm@FreeBSD.ORG Wed Feb 20 09:31:26 2013 Return-Path: Delivered-To: arm@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 647D7267 for ; Wed, 20 Feb 2013 09:31:26 +0000 (UTC) (envelope-from andrew@fubar.geek.nz) Received: from smtp3.clear.net.nz (smtp3.clear.net.nz [203.97.33.64]) by mx1.freebsd.org (Postfix) with ESMTP id 3501AEC4 for ; Wed, 20 Feb 2013 09:31:26 +0000 (UTC) Received: from mxin1-orange.clear.net.nz (lb2-srcnat.clear.net.nz [203.97.32.237]) by smtp3.clear.net.nz (CLEAR Net Mail) with ESMTP id <0MII001FRIFIXR00@smtp3.clear.net.nz> for arm@freebsd.org; Wed, 20 Feb 2013 22:31:19 +1300 (NZDT) Received: from 202-0-48-19.paradise.net.nz (HELO bender) ([202.0.48.19]) by smtpin1.paradise.net.nz with ESMTP; Wed, 20 Feb 2013 22:31:10 +1300 Date: Wed, 20 Feb 2013 22:31:05 +1300 From: Andrew Turner Subject: Re: svn commit: r246926 - in head/sys: arm/arm arm/include vm In-reply-to: <5123BD37.7070709@rice.edu> To: Alan Cox Message-id: <20130220223105.4b71c62f@bender> MIME-version: 1.0 Content-type: text/plain; charset=US-ASCII Content-transfer-encoding: 7bit References: <201302180102.r1I12nMX049209@svn.freebsd.org> <20130219083455.176129d3@bender> <5123BD37.7070709@rice.edu> Cc: "arm@freebsd.org" X-BeenThere: freebsd-arm@freebsd.org X-Mailman-Version: 2.1.14 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, 20 Feb 2013 09:31:26 -0000 On Tue, 19 Feb 2013 11:58:15 -0600 Alan Cox wrote: > On 02/18/2013 13:34, Andrew Turner wrote: > > On Mon, 18 Feb 2013 01:02:49 +0000 (UTC) > > Alan Cox wrote: > > > >> Author: alc > >> Date: Mon Feb 18 01:02:48 2013 > >> New Revision: 246926 > >> URL: http://svnweb.freebsd.org/changeset/base/246926 > >> > >> Log: > >> On arm, like sparc64, the end of the kernel map varies from one > >> type of machine to another. Therefore, VM_MAX_KERNEL_ADDRESS can't > >> be a constant. Instead, #define it to be a variable, > >> vm_max_kernel_address, just like we do on sparc64. > > This looks to be broken on non-FDT ARM. There are still a number of > > copies of initarm for older ports without FDT that will need > > vm_max_kernel_address to be set. > > Thanks for pointing this out. I believe that the attached patch adds > the necessary initialization to all of the non-FDT platforms. Since I > had to edit most of the pmap_bootstrap() calls, I also eliminated the > redundant second argument. That patch looks correct and produces what appears to be a correct value on at91. Without the patch I get: # sysctl vm.max_kernel_address vm.max_kernel_address: 0 With the patch I get: # sysctl vm.max_kernel_address vm.max_kernel_address: 3623911424 I've checked this value for this board to be correct for the method at91 uses to calculate vm_max_kernel_address. Andrew