Received: from list by lists.gnu.org with archive (Exim 4.71) id 1VxLOk-0000oH-Lx for mharc-grub-devel@gnu.org; Sun, 29 Dec 2013 13:47:38 -0500 Received: from eggs.gnu.org ([2001:4830:134:3::10]:41533) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VxLOc-0000k4-EF for grub-devel@gnu.org; Sun, 29 Dec 2013 13:47:37 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1VxLOV-0008C3-3k for grub-devel@gnu.org; Sun, 29 Dec 2013 13:47:30 -0500 Received: from benson.vm.bytemark.co.uk ([212.110.190.137]:37715) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VxLOU-0008Bf-Tt for grub-devel@gnu.org; Sun, 29 Dec 2013 13:47:23 -0500 Received: from cpc22-cmbg14-2-0-cust482.5-4.cable.virginm.net ([86.6.25.227] helo=[192.168.1.164]) by benson.vm.bytemark.co.uk with esmtpsa (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.72) (envelope-from ) id 1VxLOS-0000Jo-KP; Sun, 29 Dec 2013 18:47:20 +0000 Message-ID: <1388342839.32105.25.camel@hastur.hellion.org.uk> Subject: [PATCH 0/7] arm-uboot: support for different RAM bases From: Ian Campbell To: grub-devel@gnu.org Date: Sun, 29 Dec 2013 18:47:19 +0000 Content-Type: text/plain; charset="UTF-8" X-Mailer: Evolution 3.4.4-4+b1 Mime-Version: 1.0 Content-Transfer-Encoding: 7bit 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: Vladimir Serbinenko , Leif Lindholm , "ijc@hellion.org.uk" 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: Sun, 29 Dec 2013 18:47:37 -0000 The current arm-uboot image type is hardcoded to run at address 0x08000000 which means that it cannot be used on ARM systems which do not have RAM starting from address 0 (which is many of them). This is a bit of a problem for distros. The following series attempts to address this by only performing a partial link of the arm-uboot kernel.img at build time and enhancing grub-mkimage to finalise the link to a specific address while building the core.img. I have test this on a Midway system, which has RAM at address 0, linking to a variety of addresses (0x{0,1,4}8000000) and on a cubieboard2 which has RAM at 0x40000000-0x80000000 linked at 0x48000000. (there is an unrelated issue on cubieboard2 relating to the scan for the uboot API signature, which I'm still investigating, but I hacked around it here and things worked fine otherwise). I have done build only tests of arm64-efi, i386-pc and x86_64-efi. After running grub-mkimage under faketime the resulting binaries are bit for bit identical in every case (faketime due to the timestamp in the PE header). I haven't yet integrated this into grub-install, I need to think a bit more about how to automagically determine the correct link address for a given platform. If no target address is given then the existing hardcoded address (0x08000000) is used as the default. Please CC on any replies since I'm not subscribed. Ian.