mail archive of the barebox mailing list
 help / color / mirror / Atom feed
* [PATCH] arm: ensure the build doesn't fail when kwbimage lacks the binary blob
@ 2013-05-12 11:35 Thomas Petazzoni
  2013-05-12 11:41 ` Baruch Siach
  2013-05-13  8:20 ` Sascha Hauer
  0 siblings, 2 replies; 4+ messages in thread
From: Thomas Petazzoni @ 2013-05-12 11:35 UTC (permalink / raw)
  To: barebox

mach-mvebu images for Armada 370 and Armada XP SoC require a DDR3
training code which should be extracted from existing bootable images
for the relevant board. When such binary blob has not been extracted,
the build of the .kwb and .kwbuart images will fail. This is annoying
as it makes the build of all Armada 370/XP defconfig fail, which can
be a problem for automated builds.

This proposal makes the failure of kwbimage not a fatal failure for
the build process, and shows a warning. The user therefore sees:

====================================================================
  KWB     barebox.kwb
Didn't find the file 'plathome-openblocks-ax3-binary.0' in '/home/thomas/projets/barebox' which is mandatory to generate the image
This file generally contains the DDR3 training code, and should be extracted from an existing bootable
image for your board. See 'kwbimage -x' to extract it from an existing image.
Could not create image
WARNING: Couldn't create KWB image due to previous errors.
  KWBUART barebox.kwbuart
Didn't find the file 'plathome-openblocks-ax3-binary.0' in '/home/thomas/projets/barebox' which is mandatory to generate the image
This file generally contains the DDR3 training code, and should be extracted from an existing bootable
image for your board. See 'kwbimage -x' to extract it from an existing image.
Could not create image
WARNING Couldn't create KWB image due to previous errors.
====================================================================

The only drawback is that barebox-flash-image, which normally points
to barebox.kwb, becomes a state symbolic link.

Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
---
 arch/arm/Makefile |    6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/arch/arm/Makefile b/arch/arm/Makefile
index ce0921d..af8294d 100644
--- a/arch/arm/Makefile
+++ b/arch/arm/Makefile
@@ -270,10 +270,12 @@ KWBIMAGE_OPTS = \
 	-c -i $(srctree)/$(BOARD)/kwbimage.cfg -d $(TEXT_BASE) -e $(TEXT_BASE)
 
 quiet_cmd_kwbimage = KWB     $@
-      cmd_kwbimage = scripts/kwbimage -p $< $(KWBIMAGE_OPTS) -o $@
+      cmd_kwbimage = scripts/kwbimage -p $< $(KWBIMAGE_OPTS) -o $@ || \
+	echo "WARNING: Couldn't create KWB image due to previous errors."
 
 quiet_cmd_kwbimage_uart = KWBUART $@
-      cmd_kwbimage_uart = scripts/kwbimage -m uart -p $< $(KWBIMAGE_OPTS) -o $@
+      cmd_kwbimage_uart = scripts/kwbimage -m uart -p $< $(KWBIMAGE_OPTS) -o $@ || \
+	echo "WARNING Couldn't create KWB image due to previous errors."
 
 barebox.kwb: $(KBUILD_BINARY) FORCE
 	$(call if_changed,kwbimage)
-- 
1.7.9.5


_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH] arm: ensure the build doesn't fail when kwbimage lacks the binary blob
  2013-05-12 11:35 [PATCH] arm: ensure the build doesn't fail when kwbimage lacks the binary blob Thomas Petazzoni
@ 2013-05-12 11:41 ` Baruch Siach
  2013-05-12 11:52   ` Thomas Petazzoni
  2013-05-13  8:20 ` Sascha Hauer
  1 sibling, 1 reply; 4+ messages in thread
From: Baruch Siach @ 2013-05-12 11:41 UTC (permalink / raw)
  To: Thomas Petazzoni; +Cc: barebox

Hi Thomas,

On Sun, May 12, 2013 at 01:35:53PM +0200, Thomas Petazzoni wrote:
> mach-mvebu images for Armada 370 and Armada XP SoC require a DDR3
> training code which should be extracted from existing bootable images
> for the relevant board. When such binary blob has not been extracted,
> the build of the .kwb and .kwbuart images will fail. This is annoying
> as it makes the build of all Armada 370/XP defconfig fail, which can
> be a problem for automated builds.
> 
> This proposal makes the failure of kwbimage not a fatal failure for
> the build process, and shows a warning. The user therefore sees:
> 
> ====================================================================
>   KWB     barebox.kwb
> Didn't find the file 'plathome-openblocks-ax3-binary.0' in '/home/thomas/projets/barebox' which is mandatory to generate the image
> This file generally contains the DDR3 training code, and should be extracted from an existing bootable
> image for your board. See 'kwbimage -x' to extract it from an existing image.
> Could not create image
> WARNING: Couldn't create KWB image due to previous errors.
>   KWBUART barebox.kwbuart
> Didn't find the file 'plathome-openblocks-ax3-binary.0' in '/home/thomas/projets/barebox' which is mandatory to generate the image
> This file generally contains the DDR3 training code, and should be extracted from an existing bootable
> image for your board. See 'kwbimage -x' to extract it from an existing image.
> Could not create image
> WARNING Couldn't create KWB image due to previous errors.
> ====================================================================
> 
> The only drawback is that barebox-flash-image, which normally points
> to barebox.kwb, becomes a state symbolic link.

stale?

baruch

> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
> ---
>  arch/arm/Makefile |    6 ++++--
>  1 file changed, 4 insertions(+), 2 deletions(-)
> 
> diff --git a/arch/arm/Makefile b/arch/arm/Makefile
> index ce0921d..af8294d 100644
> --- a/arch/arm/Makefile
> +++ b/arch/arm/Makefile
> @@ -270,10 +270,12 @@ KWBIMAGE_OPTS = \
>  	-c -i $(srctree)/$(BOARD)/kwbimage.cfg -d $(TEXT_BASE) -e $(TEXT_BASE)
>  
>  quiet_cmd_kwbimage = KWB     $@
> -      cmd_kwbimage = scripts/kwbimage -p $< $(KWBIMAGE_OPTS) -o $@
> +      cmd_kwbimage = scripts/kwbimage -p $< $(KWBIMAGE_OPTS) -o $@ || \
> +	echo "WARNING: Couldn't create KWB image due to previous errors."
>  
>  quiet_cmd_kwbimage_uart = KWBUART $@
> -      cmd_kwbimage_uart = scripts/kwbimage -m uart -p $< $(KWBIMAGE_OPTS) -o $@
> +      cmd_kwbimage_uart = scripts/kwbimage -m uart -p $< $(KWBIMAGE_OPTS) -o $@ || \
> +	echo "WARNING Couldn't create KWB image due to previous errors."
>  
>  barebox.kwb: $(KBUILD_BINARY) FORCE
>  	$(call if_changed,kwbimage)
> -- 
> 1.7.9.5

-- 
     http://baruch.siach.name/blog/                  ~. .~   Tk Open Systems
=}------------------------------------------------ooO--U--Ooo------------{=
   - baruch@tkos.co.il - tel: +972.2.679.5364, http://www.tkos.co.il -

_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH] arm: ensure the build doesn't fail when kwbimage lacks the binary blob
  2013-05-12 11:41 ` Baruch Siach
@ 2013-05-12 11:52   ` Thomas Petazzoni
  0 siblings, 0 replies; 4+ messages in thread
From: Thomas Petazzoni @ 2013-05-12 11:52 UTC (permalink / raw)
  To: Baruch Siach; +Cc: barebox

Dear Baruch Siach,

On Sun, 12 May 2013 14:41:16 +0300, Baruch Siach wrote:

> > The only drawback is that barebox-flash-image, which normally points
> > to barebox.kwb, becomes a state symbolic link.
> 
> stale?

Gaah, yes, thanks. I indeed wanted to say:

   The only drawback is that barebox-flash-image, which normally points
   to barebox.kwb, becomes a _stale_ symbolic link.

If the approach is approved, I'll resend a fixed up patch.

Sorry for the mess,

Thomas
-- 
Thomas Petazzoni, Free Electrons
Kernel, drivers, real-time and embedded Linux
development, consulting, training and support.
http://free-electrons.com

_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH] arm: ensure the build doesn't fail when kwbimage lacks the binary blob
  2013-05-12 11:35 [PATCH] arm: ensure the build doesn't fail when kwbimage lacks the binary blob Thomas Petazzoni
  2013-05-12 11:41 ` Baruch Siach
@ 2013-05-13  8:20 ` Sascha Hauer
  1 sibling, 0 replies; 4+ messages in thread
From: Sascha Hauer @ 2013-05-13  8:20 UTC (permalink / raw)
  To: Thomas Petazzoni; +Cc: barebox

On Sun, May 12, 2013 at 01:35:53PM +0200, Thomas Petazzoni wrote:
> mach-mvebu images for Armada 370 and Armada XP SoC require a DDR3
> training code which should be extracted from existing bootable images
> for the relevant board. When such binary blob has not been extracted,
> the build of the .kwb and .kwbuart images will fail. This is annoying
> as it makes the build of all Armada 370/XP defconfig fail, which can
> be a problem for automated builds.
> 
> This proposal makes the failure of kwbimage not a fatal failure for
> the build process, and shows a warning. The user therefore sees:
> 
> ====================================================================
>   KWB     barebox.kwb
> Didn't find the file 'plathome-openblocks-ax3-binary.0' in '/home/thomas/projets/barebox' which is mandatory to generate the image
> This file generally contains the DDR3 training code, and should be extracted from an existing bootable
> image for your board. See 'kwbimage -x' to extract it from an existing image.
> Could not create image
> WARNING: Couldn't create KWB image due to previous errors.
>   KWBUART barebox.kwbuart
> Didn't find the file 'plathome-openblocks-ax3-binary.0' in '/home/thomas/projets/barebox' which is mandatory to generate the image
> This file generally contains the DDR3 training code, and should be extracted from an existing bootable
> image for your board. See 'kwbimage -x' to extract it from an existing image.
> Could not create image
> WARNING Couldn't create KWB image due to previous errors.
> ====================================================================
> 
> The only drawback is that barebox-flash-image, which normally points
> to barebox.kwb, becomes a state symbolic link.
> 
> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>

Folded this into the original commit and fixed the typo along the way.

Sascha

-- 
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 |

_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2013-05-13  8:20 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-05-12 11:35 [PATCH] arm: ensure the build doesn't fail when kwbimage lacks the binary blob Thomas Petazzoni
2013-05-12 11:41 ` Baruch Siach
2013-05-12 11:52   ` Thomas Petazzoni
2013-05-13  8:20 ` Sascha Hauer

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox