All of lore.kernel.org
 help / color / mirror / Atom feed
From: Petr Kulhavy <brain@jikos.cz>
To: u-boot@lists.denx.de
Subject: [U-Boot] Building u-boot.imx and SPL simultaneously
Date: Fri, 2 Sep 2016 20:57:24 +0200	[thread overview]
Message-ID: <24f0546a-7a65-45ac-5128-667ff6fb87fa@jikos.cz> (raw)
In-Reply-To: <fb6b5a06-7ebd-c380-c4c8-cd4deede3e08@denx.de>

Hi,

you have already brought it to the point - it needs two defconfigs.
This means double the files in U-boot and second and more important, how 
does it integrate into a tool like Buildroot?
In other words I'm trying to do it with just one defconfig.

Alltogether I want to build 3 files:
* SPL which is started by the RBL
* u-boot.img which is loaded by the SPL from the flash after typing 'c' 
or similar on the terminal
* u-boot.imx for an initial load of the board via USB if there is no BL 
at all
All these images plus rootfs and kernel should be an outcome of one 
build in Buildroot.

Since the u-boot.imx is in fact u-boot.img with an extra header I don't 
see a reason why it shouldn't be possible to compile with the same make 
command.
And the interdependency of SPL and u-boot.imx, that only one can be 
built at a time, isn't obvious to me either. After all SPL is a 
completely different binary.

...or am I touching some skeleton in a cupboard?

Thanks
Petr

On 02/09/16 20:18, Stefano Babic wrote:
> Hi,
>
> On 02/09/2016 18:46, Petr Kulhavy wrote:
>> Hi,
>>
>> I'm facing a problem that the iMX Makefile does not allow to build
>> u-boot.imx and the SPL binary simultaneously.
> ...I am missing why you need to build them at the same time. Can you
> start with a detailed description of the problem ? Why is it not enough
> to build them in sequence ?
>
>> This would be useful for
>> generating images for flash and for a serial loading.
>> The reason is that each target needs a different config file, but there
>> is only one IMX_CONFIG variable.
> I do not get the point. Yes, you have two defconfig. And yes, you cannot
> built it at the same time. But you define the IMX_CONFIG in each of the
> two defconfig, making use of two different IMX_CONFIG, if this is what
> you want.
>
>> I have tried to create a dedicated IMX_CONFIG_SPL for the SPL, which
>> seems to work and I almost prepared a patch for submit.
>> Unfortunatelly there is some problem with the dependencies if both
>> u-boot.imx and SPL are put in ALL-y. The make with single job runs but
>> it fails in multi-job execution.
>>
>> Could you please help me and throw some light into the dependencies. I
>> think this patch could be useful also for others, see below.
>>
>>
> Best regards,
> Stefano Babic
>
>

  reply	other threads:[~2016-09-02 18:57 UTC|newest]

Thread overview: 20+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-09-02 16:46 [U-Boot] Building u-boot.imx and SPL simultaneously Petr Kulhavy
2016-09-02 18:18 ` Stefano Babic
2016-09-02 18:57   ` Petr Kulhavy [this message]
2016-09-02 20:03     ` Fabio Estevam
2016-09-02 20:53       ` Petr Kulhavy
2016-09-06 13:40         ` Tom Rini
2016-09-06 13:53           ` Otavio Salvador
2016-09-06 13:56             ` Tom Rini
2016-09-06 14:00           ` Eric Nelson
2016-09-06 14:12             ` Petr Kulhavy
2016-09-06 14:17               ` Tom Rini
2016-09-06 14:15             ` Tom Rini
2016-09-10 23:40               ` Eric Nelson
2016-09-18  6:50                 ` Peng Fan
2016-09-18  7:18                   ` Stefano Babic
2016-09-02 21:45     ` Stefano Babic
2016-09-02 23:15       ` Petr Kulhavy
2016-09-03  9:40         ` Stefano Babic
2016-09-03 20:27           ` Otavio Salvador
2016-09-04  8:53             ` Stefano Babic

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=24f0546a-7a65-45ac-5128-667ff6fb87fa@jikos.cz \
    --to=brain@jikos.cz \
    --cc=u-boot@lists.denx.de \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.