summaryrefslogtreecommitdiff
path: root/recipes-bsp
diff options
context:
space:
mode:
authorStefan Agner <stefan.agner@toradex.com>2017-09-04 14:44:42 -0700
committerMax Krummenacher <max.krummenacher@toradex.com>2017-10-03 17:07:18 +0200
commit707cb8b83d327256abdbbf144ef99d83337a59a2 (patch)
tree6dc62ee84993c38eefb606ea7339a6d544b4edc5 /recipes-bsp
parent60197688509b5c27fd4e62d97b3c6d53fc670528 (diff)
u-boot-toradex-fsl-fw-utils: add colibri-imx7-emmc support
Add fw_env.config and make sure unlock eMMC gets installed. Signed-off-by: Stefan Agner <stefan.agner@toradex.com> Acked-by: Max Krummenacher <max.krummenacher@toradex.com>
Diffstat (limited to 'recipes-bsp')
-rw-r--r--recipes-bsp/u-boot/files/colibri-imx7-emmc/fw_env.config15
-rw-r--r--recipes-bsp/u-boot/u-boot-toradex-fsl-fw-utils_git.bb12
2 files changed, 25 insertions, 2 deletions
diff --git a/recipes-bsp/u-boot/files/colibri-imx7-emmc/fw_env.config b/recipes-bsp/u-boot/files/colibri-imx7-emmc/fw_env.config
new file mode 100644
index 0000000..00f21bf
--- /dev/null
+++ b/recipes-bsp/u-boot/files/colibri-imx7-emmc/fw_env.config
@@ -0,0 +1,15 @@
+# Configuration file for fw_(printenv/setenv) utility.
+# Up to two entries are valid, in this case the redundant
+# environment sector is assumed present.
+# Device offset must be prefixed with 0x to be parsed as a hexadecimal value.
+# On a block device a negative offset is treated as a backwards offset from the
+# end of the device/partition, rather than a forwards offset from the start.
+
+# Colibri iMX7 Dual 1GB (eMMC)
+# U-Boot environment is stored at the end of the first eMMC boot partition
+# hence use a negative value. The environment is just in front of the config
+# block which occupies the last sector (hence -0x200)
+
+# Block device name Device offset Env. size
+/dev/mmcblk0boot0 -0x2200 0x2000
+
diff --git a/recipes-bsp/u-boot/u-boot-toradex-fsl-fw-utils_git.bb b/recipes-bsp/u-boot/u-boot-toradex-fsl-fw-utils_git.bb
index 0861fa3..93a99e5 100644
--- a/recipes-bsp/u-boot/u-boot-toradex-fsl-fw-utils_git.bb
+++ b/recipes-bsp/u-boot/u-boot-toradex-fsl-fw-utils_git.bb
@@ -21,8 +21,8 @@ SRCBRANCH = "2016.11-toradex"
SRC_URI = " \
git://git.toradex.com/u-boot-toradex.git;protocol=git;branch=${SRCBRANCH} \
file://fw_env.config \
+ file://fw_unlock_mmc.sh \
"
-SRC_URI_append_mx6 = " file://fw_unlock_mmc.sh "
PV = "2016.11"
PR = "${TDX_VER_INT}-gitr${@d.getVar("SRCREV", False)[0:7]}"
@@ -48,9 +48,17 @@ do_install () {
install -m 644 ${WORKDIR}/fw_env.config ${D}${sysconfdir}/
}
-do_install_append_mx6() {
+install_unlock_emmc() {
install -d ${D}${sysconfdir}/profile.d/
install -m 0644 ${WORKDIR}/fw_unlock_mmc.sh ${D}${sysconfdir}/profile.d/fw_unlock_mmc.sh
}
+do_install_append_mx6() {
+ install_unlock_emmc
+}
+
+do_install_append_colibri-imx7-emmc() {
+ install_unlock_emmc
+}
+
PACKAGE_ARCH = "${MACHINE_ARCH}"