From owner-freebsd-arm@FreeBSD.ORG Fri Apr 18 04:10:39 2014 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 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id CD995830 for ; Fri, 18 Apr 2014 04:10:39 +0000 (UTC) Received: from mail-pb0-f54.google.com (mail-pb0-f54.google.com [209.85.160.54]) (using TLSv1 with cipher ECDHE-RSA-RC4-SHA (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 9B69C190D for ; Fri, 18 Apr 2014 04:10:39 +0000 (UTC) Received: by mail-pb0-f54.google.com with SMTP id ma3so1069433pbc.41 for ; Thu, 17 Apr 2014 21:10:33 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:content-type:mime-version:subject:from :in-reply-to:date:cc:content-transfer-encoding:message-id:references :to; bh=I+4FVT62K2fV42/xhYDfUcejr5ZykHRpSBltxJmXN8Q=; b=HG+e4lAkjY0YYxRcikZuSRApe2aWvVEcUoDmO1UhC7cBeNRJtOSkV8DzUqvWFaQuNz LP5fvzNDrecHdNIM2LvOGjD1PkppNh4J5dCM1j7wW1GR6irSNzvlxeNqsiebW+VOF954 F/5DbgtRqdn08lqUgbAXUZlWZPQxWz2Il+sY79ZKuBRjIkQ8QumlOrkSG+7ZpOwuaOmq Wz7RMNClPSoZAJ2jE5u8hDkAm9WbjLfTvp0hIy4c+5s0QUDybtFuMYWv1Z/Y29AKk3fq gnB5/q05qqVIwBbna7eEAxqG6ArEmBsC4XY5+ctdSMioUTXkcAbpMXLgO0sjRvxQN3ei VLRA== X-Gm-Message-State: ALoCoQkA/j6QGOCWM2iprQ5Frtyoylz7Hm/zUcFqoH5D2evOkNNUSKS9XNPudRSSYqdyOZUxbgaY X-Received: by 10.68.178.1 with SMTP id cu1mr19614410pbc.34.1397794233669; Thu, 17 Apr 2014 21:10:33 -0700 (PDT) Received: from [192.168.1.2] (c-50-156-22-189.hsd1.ca.comcast.net. [50.156.22.189]) by mx.google.com with ESMTPSA id ff4sm135351894pad.24.2014.04.17.21.10.32 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Thu, 17 Apr 2014 21:10:32 -0700 (PDT) Content-Type: text/plain; charset=windows-1251 Mime-Version: 1.0 (Mac OS X Mail 7.2 \(1874\)) Subject: Re: Building an ARM/RPI-B release (hacked) on CURRENT/AMD64. From: Tim Kientzle In-Reply-To: <54D788B2-BD68-4F75-86FF-0C4E71D9B75A@grondar.org> Date: Thu, 17 Apr 2014 21:10:29 -0700 Content-Transfer-Encoding: quoted-printable Message-Id: <1963F059-91A1-4D4C-84AE-7BC6C25044E1@kientzle.com> References: <9FDD6F0E-B2A9-48D9-A3E4-181868995FDA@grondar.org> <20140417103117.GE44138@cicely7.cicely.de> <1397738961.1124.157.camel@revolution.hippie.lan> <1397761628.1124.245.camel@revolution.hippie.lan> <7196A020-54E1-42FA-B8A0-25B145B0E412@bsdimp.com> <54D788B2-BD68-4F75-86FF-0C4E71D9B75A@grondar.org> To: Mark R V Murray X-Mailer: Apple Mail (2.1874) Cc: freebsd-arm , Ian Lepore , ticso@cicely.de X-BeenThere: freebsd-arm@freebsd.org X-Mailman-Version: 2.1.17 Precedence: list List-Id: "Porting FreeBSD to ARM processors." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 18 Apr 2014 04:10:40 -0000 On Apr 17, 2014, at 12:54 PM, Mark R V Murray wrote: >=20 > On 17 Apr 2014, at 20:14, Warner Losh wrote: >=20 >>=20 >> On Apr 17, 2014, at 1:07 PM, Ian Lepore wrote: >>>=20 >>> Hmmm. After a bit of poking around in the llvm code, it looks like = the >>> full extent of the support for -ffixed-r9 is that it doesn't = consider >>> that register available for use by the code generator; that's only = part >>> of what u-boot needs. =20 >>=20 >> what=92s the other part? Global register variables like this? >=20 > Yah. U-boot/Arm is heavily dependant on using R9 (previously R8) as a > global register variable. >=20 >>> Some online notes I found for clang 3.5 claim that global register >>> variables aren't supported, and aren't likely to be any time soon. >>=20 >> Is that a poke in the eye of uboot, or is it more of a contention = that >> uboot is moving away from that need? >=20 > It means that for now I guess we are stuck with using GCC to compile = u-boot. Unless you can find some other way to make the =91gd=92 symbol return = the value of r9. Hmmm=85. How good is clang=92s inline assembly? #define gd __asm(=85. return r9 =85 ) Or maybe: #define gd getr9() gd_t *getr9(void); > I=92d mind a lot less if this was done as a port. >=20 > > Hmm. A port to do what crochet does, without all the FreeBSD/ARM = (build|install)(world|kernel) stuff? >=20 > Something that makes an empty .img (with only the weird boot = bits in it) as its =93product=94 for later use by the release process = might be nice. /usr/ports/sysutils/u-boot-beaglebone-eabi is looking for an owner. ;-) This was my attempt to do essentially what you suggest, but I never got = it quite working. There are experimental bits in Crochet to exploit = this port if it=92s been =93installed=94 on the system. (=93Install=94 in this case installs the built U-Boot bits in = /usr/local/share and puts a shell script in /usr/local/bin that can copy = those bits to a specified target dir.) Tim