summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJohn Klug <john.klug@multitech.com>2019-04-04 17:28:38 -0500
committerJohn Klug <john.klug@multitech.com>2019-07-03 11:22:01 -0500
commitfc4ccc7d6563ee6ebfd159e074461b1a7396b21f (patch)
treee52c85f529b2b3fc07c1e716f1b7bd859d9f1f1e
parent43331f40e7e46b74167356533fa25d9cada611ab (diff)
downloadmeta-multitech-fc4ccc7d6563ee6ebfd159e074461b1a7396b21f.tar.gz
meta-multitech-fc4ccc7d6563ee6ebfd159e074461b1a7396b21f.tar.bz2
meta-multitech-fc4ccc7d6563ee6ebfd159e074461b1a7396b21f.zip
Disable USB, which otherwise will use pins PD18-PD20
-rw-r--r--recipes-bsp/u-boot/u-boot-2016.09.01/config.patch18
-rw-r--r--recipes-bsp/u-boot/u-boot.inc21
2 files changed, 33 insertions, 6 deletions
diff --git a/recipes-bsp/u-boot/u-boot-2016.09.01/config.patch b/recipes-bsp/u-boot/u-boot-2016.09.01/config.patch
index 3e9c0c2..658fdec 100644
--- a/recipes-bsp/u-boot/u-boot-2016.09.01/config.patch
+++ b/recipes-bsp/u-boot/u-boot-2016.09.01/config.patch
@@ -1,6 +1,6 @@
-diff -raNu old/configs/at91sam9x5ek_nandflash_defconfig new/configs/at91sam9x5ek_nandflash_defconfig
---- old/configs/at91sam9x5ek_nandflash_defconfig 2016-09-19 17:45:12.000000000 +0300
-+++ new/configs/at91sam9x5ek_nandflash_defconfig 2019-02-08 13:39:19.941473452 +0200
+diff -Naru old/configs/at91sam9x5ek_nandflash_defconfig new/configs/at91sam9x5ek_nandflash_defconfig
+--- old/configs/at91sam9x5ek_nandflash_defconfig 2019-04-09 18:00:13.342337484 -0500
++++ new/configs/at91sam9x5ek_nandflash_defconfig 2019-04-15 12:06:49.171618119 -0500
@@ -1,9 +1,9 @@
CONFIG_ARM=y
CONFIG_ARCH_AT91=y
@@ -13,7 +13,16 @@ diff -raNu old/configs/at91sam9x5ek_nandflash_defconfig new/configs/at91sam9x5ek
CONFIG_HUSH_PARSER=y
CONFIG_SYS_PROMPT="U-Boot> "
CONFIG_CMD_BOOTZ=y
-@@ -23,3 +23,18 @@
+@@ -12,7 +12,7 @@
+ # CONFIG_CMD_FLASH is not set
+ CONFIG_CMD_MMC=y
+ CONFIG_CMD_SF=y
+-CONFIG_CMD_USB=y
++CONFIG_CMD_USB=n
+ # CONFIG_CMD_FPGA is not set
+ # CONFIG_CMD_SETEXPR is not set
+ CONFIG_CMD_DHCP=y
+@@ -23,3 +23,17 @@
CONFIG_USB=y
CONFIG_USB_STORAGE=y
CONFIG_OF_LIBFDT=y
@@ -21,7 +30,6 @@ diff -raNu old/configs/at91sam9x5ek_nandflash_defconfig new/configs/at91sam9x5ek
+CONFIG_OF_CONTROL=n
+CONFIG_CMD_TFTPPUT=y
+CONFIG_CMD_FAT=y
-+CONFIG_CMD_USB=y
+CONFIG_CMD_NAND=y
+CONFIG_CMD_BOOTZ=y
+CONFIG_CMD_MII=y
diff --git a/recipes-bsp/u-boot/u-boot.inc b/recipes-bsp/u-boot/u-boot.inc
index a7d6828..56265ff 100644
--- a/recipes-bsp/u-boot/u-boot.inc
+++ b/recipes-bsp/u-boot/u-boot.inc
@@ -4,7 +4,7 @@ SECTION = "bootloaders"
PROVIDES = "virtual/bootloader"
# New U-Boot with suppressed version.
-PR="m1"
+PR="m2"
LICENSE = "GPLv2+"
LIC_FILES_CHKSUM = "file://Licenses/README;md5=a2c678cfd4a4d97135585cad908541c6"
@@ -69,6 +69,25 @@ UBOOT_ENV_IMAGE ?= "${UBOOT_ENV}-${MACHINE}-${PV}-${PR}.${UBOOT_ENV_SUFFIX}"
UBOOT_ENV_SYMLINK ?= "${UBOOT_ENV}-${MACHINE}.${UBOOT_ENV_SUFFIX}"
FILES_${PN}-dev += "${includedir}/u-boot/* ${includedir}/u-boot/configs/* ${includedir}/u-boot/asm/*"
+# Put the PR into the U-Boot image. u-boot allows a local
+# version in a file called localversion.*
+# For some reason, this must be written in python.
+do_patch_append () {
+ try:
+ S = d.getVar("S",True)
+ except TypeError:
+ bb.fatal("S is missing from recipe")
+
+ f = open(S + "/localversion.mt","w")
+
+ try:
+ PR = d.getVar("PR",True)
+ except TypeError:
+ bb.fatal("PR is missing from recipe")
+ f.write(PR + os.linesep)
+}
+
+
do_compile () {
if [ "${@bb.utils.contains('DISTRO_FEATURES', 'ld-is-gold', 'ld-is-gold', '', d)}" = "ld-is-gold" ] ; then
sed -i 's/$(CROSS_COMPILE)ld$/$(CROSS_COMPILE)ld.bfd/g' config.mk