From owner-freebsd-arm@FreeBSD.ORG Thu Feb 12 17:57:13 2015 Return-Path: Delivered-To: freebsd-arm@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id DA2D5207 for ; Thu, 12 Feb 2015 17:57:13 +0000 (UTC) Received: from anacreon.physics.berkeley.edu (anacreon.Physics.Berkeley.EDU [128.32.117.18]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "anacreon.physics.wisc.edu", Issuer "anacreon.physics.wisc.edu" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id B6C693DA for ; Thu, 12 Feb 2015 17:57:13 +0000 (UTC) Received: from anacreon.physics.berkeley.edu (localhost [127.0.0.1]) by anacreon.physics.berkeley.edu (8.14.9/8.14.9) with ESMTP id t1CHvCt1071755 for ; Thu, 12 Feb 2015 09:57:12 -0800 (PST) (envelope-from nwhitehorn@freebsd.org) Message-ID: <54DCE978.8030104@freebsd.org> Date: Thu, 12 Feb 2015 09:57:12 -0800 From: Nathan Whitehorn User-Agent: Mozilla/5.0 (X11; FreeBSD powerpc; rv:31.0) Gecko/20100101 Thunderbird/31.4.0 MIME-Version: 1.0 To: freebsd-arm@freebsd.org Subject: Re: FreeBSD/arm64 MACHINE/MACHINE_ARCH identification References: <607BF592-A09B-4DB4-9872-C9E63066AB57@bsdimp.com> <71E9C1B9-F819-420B-90A5-A36D58E71817@bsdimp.com> In-Reply-To: Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 8bit X-BeenThere: freebsd-arm@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: "Porting FreeBSD to ARM processors." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 12 Feb 2015 17:57:13 -0000 On 02/12/15 08:05, Ed Maste wrote: > On 12 February 2015 at 01:54, Warner Losh wrote: >> >> They moved the sources in the kernel from aarch64 to arm64. I’m sure. > > Oh - I don't care what directory Linux puts the kernel source in, only > what's reported by uname. As far as I can tell that has always been > aarch64 for uname -m. > >> config.guess uses uname -p: >> >> *:FreeBSD:*:*) >> UNAME_PROCESSOR=`/usr/bin/uname -p` >> echo ${UNAME_PROCESSOR}-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` >> exit ;; > > Ah, yes - it looks like this has changed repeatedly over time, and I > must have looked at a rather outdated config.guess. It's clear from > this snippet though that this is a special case for FreeBSD, and most > other cases rely on uname -m. I also found a few other configure-like > scripts that only use uname -m. > >> so uname -p must be ‘aarch64’ since that’s what is expected. > > Yes, I agree this is necessary. > >> uname -m must >> be arm64 unless we move our kernel implementation to sys/aarch64 from the >> sys/arm64 it is now. > > We might decide that "uname -m" has to be aarch64 to match > expectations of third-party software set by other operating systems. > If that in turn means we have to move the kernel source, so be it. I don't think we will (or should). We've had platforms where they don't match for years and years (I'm writing you this email on one such system now) and have had very little trouble with it. In the wild, close enough to all code does the right thing that we don't need to worry about it. In the few cases where it doesn't, ports already has the relevant patches. -Nathan