mailarchive of the ptxdist mailing list
 help / color / mirror / Atom feed
From: Michael Olbrich <m.olbrich@pengutronix.de>
To: ptxdist@pengutronix.de
Subject: Re: [ptxdist] [PATCH 1/2] kernel: pass loadaddr for building uImage
Date: Tue, 29 Nov 2016 10:12:18 +0100	[thread overview]
Message-ID: <20161129091217.aohonvq7bldqkpfo@pengutronix.de> (raw)
In-Reply-To: <54014cd5-74ef-3901-9459-953cb6b80d57@pengutronix.de>

On Tue, Nov 29, 2016 at 10:04:19AM +0100, Marc Kleine-Budde wrote:
> On 11/28/2016 05:46 PM, Michael Olbrich wrote:
> > On Mon, Nov 28, 2016 at 11:21:31AM +0100, Alexander Dahl wrote:
> >> On newer kernels (4.x ?) kernel build fails when building an uImage
> >> unless you provide LOADADDR as kernel make var, which is put in the
> >> resulting uImage header. You could append it to
> >> PTXCONF_KERNEL_EXTRA_MAKEVARS but this would be just a workaround. This
> >> patch extends the menu if uImage is selected so you can directly input
> >> the desired address.
> > 
> > I don't have a lot of experience with uImages. Marc, what do you think?
> 
> According to rmk uimages are considered obsolete. However there are
> probably some old bootloaders around that insist of that format.
> 
> >> Signed-off-by: Alexander Dahl <post@lespocky.de>
> >> ---
> >>  platforms/kernel.in | 7 +++++++
> >>  rules/kernel.make   | 5 +++++
> >>  2 files changed, 12 insertions(+)
> >>
> >> diff --git a/platforms/kernel.in b/platforms/kernel.in
> >> index fd1c492..2a00122 100644
> >> --- a/platforms/kernel.in
> >> +++ b/platforms/kernel.in
> >> @@ -213,6 +213,13 @@ config KERNEL_IMAGE
> >>  config KERNEL_DTC
> >>  	bool
> >>  
> >> +config KERNEL_LOADADDR
> >> +	hex
> >> +	prompt "uImage load address"
> >> +	depends on KERNEL_IMAGE_U
> >> +	help
> >> +	  Newer kernels want this passed if you build an uImage.
> >> +
> > 
> > This should be right after the image selection.
> > 
> > Michael
> > 
> >>  config KERNEL_XZ
> >>  	prompt "build xz-utils hosttool"
> >>  	bool
> >> diff --git a/rules/kernel.make b/rules/kernel.make
> >> index d02a69c..3270231 100644
> >> --- a/rules/kernel.make
> >> +++ b/rules/kernel.make
> >> @@ -71,6 +71,11 @@ KERNEL_MAKEVARS += \
> >>  	DEPMOD=$(PTXCONF_SYSROOT_HOST)/sbin/depmod
> >>  endif
> >>  
> >> +ifdef PTXCONF_KERNEL_IMAGE_U
> >> +KERNEL_MAKEVARS += \
> >> +	LOADADDR=$(PTXCONF_KERNEL_LOADADDR)
> >> +endif
> >> +
> 
> What happens if you build a older kernel and don't configure
> PTXCONF_KERNEL_LOADADDR via ptxdist? Does it break while it used to work
> with an older ptxdist?

We should add an 'empty' check. And the help text should include the kernel
version that introduced this requirement.

Michael


-- 
Pengutronix e.K.                           |                             |
Industrial Linux Solutions                 | http://www.pengutronix.de/  |
Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0    |
Amtsgericht Hildesheim, HRA 2686           | Fax:   +49-5121-206917-5555 |

_______________________________________________
ptxdist mailing list
ptxdist@pengutronix.de

  reply	other threads:[~2016-11-29  9:12 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-11-28 10:21 [ptxdist] [PATCH 0/2] kernel image generation extensions Alexander Dahl
2016-11-28 10:21 ` [ptxdist] [PATCH 1/2] kernel: pass loadaddr for building uImage Alexander Dahl
2016-11-28 16:46   ` Michael Olbrich
2016-11-29  9:04     ` Marc Kleine-Budde
2016-11-29  9:12       ` Michael Olbrich [this message]
2016-11-29  9:18       ` Uwe Kleine-König
2016-11-29  9:21       ` Alexander Stein
2016-11-29  9:23         ` Marc Kleine-Budde
2016-11-30 10:06       ` Alexander Dahl
2016-11-28 10:21 ` [ptxdist] [PATCH 2/2] image_kernel: new options for "appended DT" images Alexander Dahl

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=20161129091217.aohonvq7bldqkpfo@pengutronix.de \
    --to=m.olbrich@pengutronix.de \
    --cc=ptxdist@pengutronix.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox