From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from list by lists.gnu.org with archive (Exim 4.71) id 1VxaOv-00064c-Se for mharc-grub-devel@gnu.org; Mon, 30 Dec 2013 05:48:49 -0500 Received: from eggs.gnu.org ([2001:4830:134:3::10]:52273) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VxaOm-00064V-V7 for grub-devel@gnu.org; Mon, 30 Dec 2013 05:48:48 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1VxaOf-0001q0-Jp for grub-devel@gnu.org; Mon, 30 Dec 2013 05:48:40 -0500 Received: from benson.vm.bytemark.co.uk ([212.110.190.137]:45279) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VxaOf-0001pw-EG for grub-devel@gnu.org; Mon, 30 Dec 2013 05:48:33 -0500 Received: from cpc22-cmbg14-2-0-cust482.5-4.cable.virginm.net ([86.6.25.227] helo=[192.168.1.7]) by benson.vm.bytemark.co.uk with esmtpsa (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.72) (envelope-from ) id 1VxaOd-0004qr-Pu; Mon, 30 Dec 2013 10:48:31 +0000 Message-ID: <1388400511.30225.11.camel@dagon.hellion.org.uk> Subject: Re: [PATCH 0/7] arm-uboot: support for different RAM bases From: Ian Campbell To: Vladimir =?UTF-8?Q?=27=CF=86-coder/phcoder=27?= Serbinenko Date: Mon, 30 Dec 2013 10:48:31 +0000 In-Reply-To: <52C0D294.6040103@gmail.com> References: <1388342839.32105.25.camel@hastur.hellion.org.uk> <52C0D294.6040103@gmail.com> Content-Type: text/plain; charset="UTF-8" X-Mailer: Evolution 3.4.4-4+b1 Mime-Version: 1.0 Content-Transfer-Encoding: quoted-printable X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic] X-Received-From: 212.110.190.137 Cc: grub-devel@gnu.org, Leif Lindholm X-BeenThere: grub-devel@gnu.org X-Mailman-Version: 2.1.14 Precedence: list Reply-To: The development of GNU GRUB List-Id: The development of GNU GRUB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 30 Dec 2013 10:48:48 -0000 On Mon, 2013-12-30 at 02:55 +0100, Vladimir '=CF=86-coder/phcoder' Serbinen= ko wrote: > Is there a way to make uboot to load GRUB at some appropriate address. I don't think there is with the uImage format which grub uses today. It contains a load address in the header which AFAIK is an absolute address with no scope for "u-boot chooses" or "offset from start of RAM" or anything like that. In theory we could drop the uImage header and just us a plain Linux zImage via u-boot's "bootz" command, which would then put things in the hands of the u-boot boot script and environment, but that is not all that widely available yet, whereas "bootm" is pretty much everywhere. > We can do relocations in the startup code if needed. The above notwithstanding I did wonder about this but it seems like potentially complex code to write in the early asm portion of things. I also vaguely played with -fpic/fpie but not with much success and I don't know if that solution would be workable in practice. Ian.