grub-devel.gnu.org archive mirror
 help / color / mirror / Atom feed
From: Ian Campbell <ijc@hellion.org.uk>
To: "Vladimir 'φ-coder/phcoder' Serbinenko" <phcoder@gmail.com>
Cc: grub-devel@gnu.org, Leif Lindholm <leif.lindholm@linaro.org>
Subject: Re: [PATCH 0/7] arm-uboot: support for different RAM bases
Date: Mon, 30 Dec 2013 10:48:31 +0000	[thread overview]
Message-ID: <1388400511.30225.11.camel@dagon.hellion.org.uk> (raw)
In-Reply-To: <52C0D294.6040103@gmail.com>

On Mon, 2013-12-30 at 02:55 +0100, Vladimir 'φ-coder/phcoder' Serbinenko
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.



      reply	other threads:[~2013-12-30 10:48 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-12-29 18:47 [PATCH 0/7] arm-uboot: support for different RAM bases Ian Campbell
2013-12-29 18:47 ` [PATCH 1/7] mkimage: Refactor IMAGE_EFI checks into a function grub_image_needs_reloc Ian Campbell
2013-12-29 18:47 ` [PATCH 2/7] mkimage: Replace hardcoded 0x400 in R_ARM_ABS32 relocation Ian Campbell
2013-12-29 18:47 ` [PATCH 3/7] mkimage: account for space for trampolines earlier Ian Campbell
2013-12-29 18:47 ` [PATCH 4/7] mkimage: make R_ARM_ABS32 debug output more consistent Ian Campbell
2013-12-29 18:47 ` [PATCH 5/7] mkimage: allow linking at address 0 Ian Campbell
2013-12-29 18:47 ` [PATCH 6/7] mkimage: support images which require full relocation at mkimage time Ian Campbell
2013-12-29 22:53   ` Leif Lindholm
2013-12-30  3:49     ` Vladimir 'φ-coder/phcoder' Serbinenko
2013-12-30 10:54     ` Ian Campbell
2013-12-30 15:46   ` Andrey Borzenkov
2013-12-31 14:19   ` Francesco Lavra
2013-12-31 16:44     ` Ian Campbell
2013-12-29 18:47 ` [PATCH 7/7] arm-uboot: support relocation at installation time Ian Campbell
2013-12-29 19:10 ` [PATCH 0/7] arm-uboot: support for different RAM bases Ian Campbell
2013-12-29 23:04 ` Leif Lindholm
2013-12-30  1:55 ` Vladimir 'φ-coder/phcoder' Serbinenko
2013-12-30 10:48   ` Ian Campbell [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1388400511.30225.11.camel@dagon.hellion.org.uk \
    --to=ijc@hellion.org.uk \
    --cc=grub-devel@gnu.org \
    --cc=leif.lindholm@linaro.org \
    --cc=phcoder@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).