diff --git a/config/sources/cubox.conf b/config/sources/cubox.conf index 0b56c9b9e3..4140082ca3 100644 --- a/config/sources/cubox.conf +++ b/config/sources/cubox.conf @@ -26,3 +26,11 @@ esac CPUMIN=396000 CPUMAX=996000 GOVERNOR=interactive + +UBOOT_FILES="SPL u-boot.img" + +write_uboot_platform() +{ + dd if=$1/SPL of=$2 bs=512 seek=2 status=noxfer > /dev/null 2>&1 + dd if=$1/u-boot.img of=$2 bs=1K seek=42 status=noxfer > /dev/null 2>&1 +} diff --git a/config/sources/marvell.conf b/config/sources/marvell.conf index dc444b287f..52c2e4dbe9 100644 --- a/config/sources/marvell.conf +++ b/config/sources/marvell.conf @@ -26,3 +26,10 @@ esac CPUMIN=800000 CPUMAX=1600000 GOVERNOR=ondemand + +UBOOT_FILES="u-boot.mmc" + +write_uboot_platform() +{ + dd if=$1/u-boot.mmc of=$2 bs=512 seek=1 status=noxfer > /dev/null 2>&1 +} diff --git a/config/sources/neo.conf b/config/sources/neo.conf index cb112734eb..0350fa5328 100644 --- a/config/sources/neo.conf +++ b/config/sources/neo.conf @@ -12,3 +12,11 @@ LINUXSOURCE="linux-udoo" CPUMIN=392000 CPUMAX=996000 GOVERNOR=interactive + +UBOOT_FILES="SPL u-boot.img" + +write_uboot_platform() +{ + dd if=$1/SPL of=$2 bs=1k seek=1 status=noxfer > /dev/null 2>&1 + dd if=$1/u-boot.img of=$2 bs=1k seek=69 conv=fsync > /dev/null 2>&1 +} diff --git a/config/sources/odroidc1.conf b/config/sources/odroidc1.conf index a75149830e..dc4ae1afa1 100644 --- a/config/sources/odroidc1.conf +++ b/config/sources/odroidc1.conf @@ -21,3 +21,13 @@ esac CPUMIN=504000 CPUMAX=1728000 GOVERNOR=interactive + +UBOOT_FILES="bl1.bin.hardkernel u-boot.bin" + +write_uboot_platform() +{ + dd if=$1/bl1.bin.hardkernel of=$2 bs=1 count=442 conv=fsync > /dev/null 2>&1 + dd if=$1/bl1.bin.hardkernel of=$2 bs=512 skip=1 seek=1 conv=fsync > /dev/null 2>&1 + dd if=$1/u-boot.bin of=$2 bs=512 seek=64 conv=fsync > /dev/null 2>&1 + dd if=/dev/zero of=$2 seek=1024 count=32 bs=512 conv=fsync > /dev/null 2>&1 +} diff --git a/config/sources/odroidc2.conf b/config/sources/odroidc2.conf index 91967b1635..86c916ef87 100644 --- a/config/sources/odroidc2.conf +++ b/config/sources/odroidc2.conf @@ -10,3 +10,13 @@ LINUXSOURCE='linux-odroidc2' CPUMIN=500000 CPUMAX=2016000 GOVERNOR=conservative + +UBOOT_FILES="bl1.bin.hardkernel u-boot.bin" + +write_uboot_platform() +{ + dd if=$1/bl1.bin.hardkernel of=$2 bs=1 count=442 conv=fsync > /dev/null 2>&1 + dd if=$1/bl1.bin.hardkernel of=$2 bs=512 skip=1 seek=1 conv=fsync > /dev/null 2>&1 + dd if=$1/u-boot.bin of=$2 bs=512 seek=97 conv=fsync > /dev/null 2>&1 + dd if=/dev/zero of=$2 seek=1249 count=799 bs=512 conv=fsync > /dev/null 2>&1 +} diff --git a/config/sources/odroidxu4.conf b/config/sources/odroidxu4.conf index f711763617..f346715a6f 100644 --- a/config/sources/odroidxu4.conf +++ b/config/sources/odroidxu4.conf @@ -20,3 +20,14 @@ esac CPUMIN=600000 CPUMAX=2000000 GOVERNOR=conservative + +UBOOT_FILES="bl1.bin.hardkernel bl2.bin.hardkernel u-boot.bin tzsw.bin.hardkernel" + +write_uboot_platform() +{ + dd if=$1/bl1.bin.hardkernel of=$2 seek=1 conv=fsync > /dev/null 2>&1 + dd if=$1/bl2.bin.hardkernel of=$2 seek=31 conv=fsync > /dev/null 2>&1 + dd if=$1/u-boot.bin of=$2 bs=512 seek=63 conv=fsync > /dev/null 2>&1 + dd if=$1/tzsw.bin.hardkernel of=$2 seek=719 conv=fsync > /dev/null 2>&1 + dd if=/dev/zero of=$2 seek=1231 count=32 bs=512 conv=fsync > /dev/null 2>&1 +} diff --git a/config/sources/s500.conf b/config/sources/s500.conf index 2ada27e9b9..9720cf043b 100644 --- a/config/sources/s500.conf +++ b/config/sources/s500.conf @@ -10,3 +10,11 @@ LINUXSOURCE='linux-s500' CPUMIN=408000 CPUMAX=1104000 GOVERNOR=interactive + +UBOOT_FILES="bootloader.bin u-boot-dtb.img" + +write_uboot_platform() +{ + dd if=$1/bootloader.bin of=$2 bs=512 seek=4097 conv=fsync > /dev/null 2>&1 + dd if=$1/u-boot-dtb.img of=$2 bs=512 seek=6144 conv=fsync > /dev/null 2>&1 +} diff --git a/config/sources/sunxi_common.inc b/config/sources/sunxi_common.inc index 2b702ad21e..b697e4f883 100644 --- a/config/sources/sunxi_common.inc +++ b/config/sources/sunxi_common.inc @@ -18,3 +18,11 @@ case $BRANCH in GOVERNOR=ondemand ;; esac + +UBOOT_FILES="u-boot-sunxi-with-spl.bin" + +write_uboot_platform() +{ + dd if=/dev/zero of=$2 bs=1k count=1023 seek=1 status=noxfer > /dev/null 2>&1 + dd if=$1/u-boot-sunxi-with-spl.bin of=$2 bs=1024 seek=8 status=noxfer > /dev/null 2>&1 +} diff --git a/config/sources/toradex.conf b/config/sources/toradex.conf index 65268e5b68..4b103daac1 100644 --- a/config/sources/toradex.conf +++ b/config/sources/toradex.conf @@ -10,3 +10,10 @@ LINUXSOURCE='linux-toradex' # CPUMIN= # CPUMAX= GOVERNOR=ondemand + +UBOOT_FILES="" + +write_uboot_platform() +{ + +} diff --git a/config/sources/udoo.conf b/config/sources/udoo.conf index 6903ea9755..01ffd3c3a1 100644 --- a/config/sources/udoo.conf +++ b/config/sources/udoo.conf @@ -20,3 +20,11 @@ esac CPUMIN=392000 CPUMAX=996000 GOVERNOR=interactive + +UBOOT_FILES="SPL u-boot.img" + +write_uboot_platform() +{ + dd if=$1/SPL of=$2 bs=1k seek=1 status=noxfer > /dev/null 2>&1 + dd if=$1/u-boot.img of=$2 bs=1k seek=69 conv=fsync > /dev/null 2>&1 +}