From 564a073b01046e3d4d8163c4f6519d11763382fc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fran=C3=A7ois=20Revol?= Date: Sat, 1 Nov 2014 19:48:06 +0100 Subject: [PATCH] ARM: move uEnv.txt content to BoardSetup file That's really where it belongs. Not all boards will need it, but for now it's always created. --- build/jam/board/beagle/BoardSetup | 9 +++++++++ src/system/boot/platform/u-boot/Jamfile | 6 +----- 2 files changed, 10 insertions(+), 5 deletions(-) diff --git a/build/jam/board/beagle/BoardSetup b/build/jam/board/beagle/BoardSetup index a0020dd778..2c22fe223f 100644 --- a/build/jam/board/beagle/BoardSetup +++ b/build/jam/board/beagle/BoardSetup @@ -52,6 +52,15 @@ mloFile = [ DownloadFile $(HAIKU_BOARD_MLO_IMAGE) ubootFile = [ DownloadFile $(HAIKU_BOARD_UBOOT_IMAGE) : $(HAIKU_BOARD_UBOOT_IMAGE_URL) ] ; +# U-Boot environment +# We load the uImage 2MB above its final destination, bootm will decode +# it to the proper location. Our image is smaller than 2MB so this works. +#HAIKU_BOARD_SDIMAGE_UBOOT_UENV_NAME = uEnv.txt ; +HAIKU_BOARD_SDIMAGE_UBOOT_UENV = "uenvcmd=run loadImage; run mmcboot; \ + loadImage=fatload mmc0 0 $(HAIKU_BOARD_LOADER_UIBASE) haiku_loader_nbsd.ub \ + mmcboot=bootm $(HAIKU_BOARD_LOADER_UIBASE)" ; + + HAIKU_BOARD_SDIMAGE_FILES = $(mloFile) $(ubootFile) diff --git a/src/system/boot/platform/u-boot/Jamfile b/src/system/boot/platform/u-boot/Jamfile index cf7a27327f..a7bddfcb8f 100644 --- a/src/system/boot/platform/u-boot/Jamfile +++ b/src/system/boot/platform/u-boot/Jamfile @@ -187,11 +187,7 @@ actions BuildUBootSDImage1 MTOOLSRC=$(1).mtools mformat -L 32 -v "Haiku" i: # generate u-boot environment variables - # We load the uImage 2MB above its final destination, bootm will decode - # it to the proper location. Our image is smaller than 2MB so this works. - echo 'uenvcmd=run loadImage; run mmcboot; - loadImage=fatload mmc0 0 $(HAIKU_BOARD_LOADER_UIBASE) haiku_loader_nbsd.ub - mmcboot=bootm $(HAIKU_BOARD_LOADER_UIBASE)' > uEnv.txt + echo '$(HAIKU_BOARD_SDIMAGE_UBOOT_UENV)' > uEnv.txt # populate MTOOLSRC=$(1).mtools mcopy $(2[1-]) i: MTOOLSRC=$(1).mtools mcopy uEnv.txt i: