clearfog: Upgrade U-Boot

Updating U-Boot is not something that we do every day; in fact, I wanted
to *never ever* do that after the initial deployment. However, now it
seems to be a good time because all of the devices are being upgraded
with new EDFA modules and especially the updated electronics, so let's
see if sticking with an U-Boot that's more than two years newer improves
the experience with USB flash drives (it does). Also, I'm really hoping
that this will reduce the number of nasty surprises when we update the
compiler and the dtc next time.

"Unfortunately", it's right after the 2021.01 release, which means that
there are hundreds of commits in master since that tag already. When
we're updating, be sure to update the hell of the system, so let's bump
it all the way to 11. Hopefully, we can catch something like 2021.04
when it gets released.

The watchdog timer was a bit tricky. Apparently, it's an unsigned 32bit
counter ticking at 25 MHz, giving us about 171s of breathing time until
the watchdog shoots us into the head. In the past I was bitten by too
short timeouts (most recently earlier today), so let's use this long
default. The time can be made shorter later on in Linux, if needed (not
sure if it's possible via a U-Boot command).

Change-Id: I8730956f43731e777376f34e795a15e30cbfbf09
diff --git a/board/czechlight/clearfog/patches/u-boot/0001-Remove-redundant-YYLOC-global-declaration.patch b/board/czechlight/clearfog/patches/u-boot/0001-Remove-redundant-YYLOC-global-declaration.patch
deleted file mode 100644
index 7520514..0000000
--- a/board/czechlight/clearfog/patches/u-boot/0001-Remove-redundant-YYLOC-global-declaration.patch
+++ /dev/null
@@ -1,27 +0,0 @@
-From ed9bbf870fad6be3ad1fb3f01fd3d2b08da915b1 Mon Sep 17 00:00:00 2001
-From: Peter Robinson <pbrobinson@gmail.com>
-Date: Thu, 30 Jan 2020 09:37:15 +0000
-Subject: [PATCH 1/3] Remove redundant YYLOC global declaration
-
-Same as the upstream fix for building dtc with gcc 10.
-
-Signed-off-by: Peter Robinson <pbrobinson@gmail.com>
----
- scripts/dtc/dtc-lexer.l | 1 -
- 1 file changed, 1 deletion(-)
-
-diff --git a/scripts/dtc/dtc-lexer.l b/scripts/dtc/dtc-lexer.l
-index fd825ebba6..24af549977 100644
---- a/scripts/dtc/dtc-lexer.l
-+++ b/scripts/dtc/dtc-lexer.l
-@@ -38,7 +38,6 @@ LINECOMMENT	"//".*\n
- #include "srcpos.h"
- #include "dtc-parser.tab.h"
- 
--YYLTYPE yylloc;
- extern bool treesource_error;
- 
- /* CAUTION: this will stop working if we ever use yyless() or yyunput() */
--- 
-2.28.0
-
diff --git a/board/czechlight/clearfog/patches/u-boot/0002-Kbuild-fix-escaping-in-.cmd-files-for-future-Make.patch b/board/czechlight/clearfog/patches/u-boot/0002-Kbuild-fix-escaping-in-.cmd-files-for-future-Make.patch
deleted file mode 100644
index c126f2a..0000000
--- a/board/czechlight/clearfog/patches/u-boot/0002-Kbuild-fix-escaping-in-.cmd-files-for-future-Make.patch
+++ /dev/null
@@ -1,80 +0,0 @@
-From 0307515dad49ee108b10053757e43187debe0642 Mon Sep 17 00:00:00 2001
-From: Rasmus Villemoes <linux@rasmusvillemoes.dk>
-Date: Wed, 19 Sep 2018 11:35:56 +0900
-Subject: [PATCH 2/3] Kbuild: fix # escaping in .cmd files for future Make
-MIME-Version: 1.0
-Content-Type: text/plain; charset=UTF-8
-Content-Transfer-Encoding: 8bit
-
-[ commit 9564a8cf422d7b58f6e857e3546d346fa970191e in Linux ]
-
-I tried building using a freshly built Make (4.2.1-69-g8a731d1), but
-already the objtool build broke with
-
-orc_dump.c: In function ‘orc_dump’:
-orc_dump.c:106:2: error: ‘elf_getshnum’ is deprecated [-Werror=deprecated-declarations]
-  if (elf_getshdrnum(elf, &nr_sections)) {
-
-Turns out that with that new Make, the backslash was not removed, so cpp
-didn't see a #include directive, grep found nothing, and
--DLIBELF_USE_DEPRECATED was wrongly put in CFLAGS.
-
-Now, that new Make behaviour is documented in their NEWS file:
-
-  * WARNING: Backward-incompatibility!
-    Number signs (#) appearing inside a macro reference or function invocation
-    no longer introduce comments and should not be escaped with backslashes:
-    thus a call such as:
-      foo := $(shell echo '#')
-    is legal.  Previously the number sign needed to be escaped, for example:
-      foo := $(shell echo '\#')
-    Now this latter will resolve to "\#".  If you want to write makefiles
-    portable to both versions, assign the number sign to a variable:
-      C := \#
-      foo := $(shell echo '$C')
-    This was claimed to be fixed in 3.81, but wasn't, for some reason.
-    To detect this change search for 'nocomment' in the .FEATURES variable.
-
-This also fixes up the two make-cmd instances to replace # with $(pound)
-rather than with \#. There might very well be other places that need
-similar fixup in preparation for whatever future Make release contains
-the above change, but at least this builds an x86_64 defconfig with the
-new make.
-
-Link: https://bugzilla.kernel.org/show_bug.cgi?id=197847
-Cc: Randy Dunlap <rdunlap@infradead.org>
-Signed-off-by: Rasmus Villemoes <linux@rasmusvillemoes.dk>
-Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
----
- scripts/Kbuild.include | 5 +++--
- 1 file changed, 3 insertions(+), 2 deletions(-)
-
-diff --git a/scripts/Kbuild.include b/scripts/Kbuild.include
-index 2c7918ad37..13ebddda65 100644
---- a/scripts/Kbuild.include
-+++ b/scripts/Kbuild.include
-@@ -7,6 +7,7 @@ quote   := "
- squote  := '
- empty   :=
- space   := $(empty) $(empty)
-+pound := \#
- 
- ###
- # Name of target with a '.' as filename prefix. foo/bar.o => foo/.bar.o
-@@ -242,11 +243,11 @@ endif
- 
- # Replace >$< with >$$< to preserve $ when reloading the .cmd file
- # (needed for make)
--# Replace >#< with >\#< to avoid starting a comment in the .cmd file
-+# Replace >#< with >$(pound)< to avoid starting a comment in the .cmd file
- # (needed for make)
- # Replace >'< with >'\''< to be able to enclose the whole string in '...'
- # (needed for the shell)
--make-cmd = $(call escsq,$(subst \#,\\\#,$(subst $$,$$$$,$(cmd_$(1)))))
-+make-cmd = $(call escsq,$(subst $(pound),$$(pound),$(subst $$,$$$$,$(cmd_$(1)))))
- 
- # Find any prerequisites that is newer than target or that does not exist.
- # PHONY targets skipped in both cases.
--- 
-2.28.0
-
diff --git a/board/czechlight/clearfog/patches/u-boot/0003-kbuild-fix-escaping-in-appending-U-Boot-own-DT.patch b/board/czechlight/clearfog/patches/u-boot/0003-kbuild-fix-escaping-in-appending-U-Boot-own-DT.patch
deleted file mode 100644
index e8b3dda..0000000
--- a/board/czechlight/clearfog/patches/u-boot/0003-kbuild-fix-escaping-in-appending-U-Boot-own-DT.patch
+++ /dev/null
@@ -1,31 +0,0 @@
-From 1ac1000adde5805b1aa385382f759d1186284d46 Mon Sep 17 00:00:00 2001
-From: Masahiro Yamada <yamada.masahiro@socionext.com>
-Date: Wed, 19 Sep 2018 11:35:57 +0900
-Subject: [PATCH 3/3] kbuild: fix # escaping in appending U-Boot own DT
-
-The escape sequence '\#' does not work for the latest GNU Make from
-the git tree.
-
-Replace it with $(pound) as Linux did.
-
-Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
----
- scripts/Makefile.lib | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/scripts/Makefile.lib b/scripts/Makefile.lib
-index f8c3fff1d1..4dceb6d1b3 100644
---- a/scripts/Makefile.lib
-+++ b/scripts/Makefile.lib
-@@ -299,7 +299,7 @@ quiet_cmd_dtc = DTC     $@
- # Modified for U-Boot
- # Bring in any U-Boot-specific include at the end of the file
- cmd_dtc = mkdir -p $(dir ${dtc-tmp}) ; \
--	(cat $<; $(if $(u_boot_dtsi),echo '\#include "$(u_boot_dtsi)"')) > $(pre-tmp); \
-+	(cat $<; $(if $(u_boot_dtsi),echo '$(pound)include "$(u_boot_dtsi)"')) > $(pre-tmp); \
- 	$(CPP) $(dtc_cpp_flags) -x assembler-with-cpp -o $(dtc-tmp) $(pre-tmp) ; \
- 	$(DTC) -O dtb -o $@ -b 0 \
- 		-i $(dir $<) $(DTC_FLAGS) \
--- 
-2.28.0
-
diff --git a/board/czechlight/clearfog/patches/u-boot/0004-examples-make-examples-optional.patch b/board/czechlight/clearfog/patches/u-boot/0004-examples-make-examples-optional.patch
deleted file mode 100644
index 3dbad3f..0000000
--- a/board/czechlight/clearfog/patches/u-boot/0004-examples-make-examples-optional.patch
+++ /dev/null
@@ -1,57 +0,0 @@
-From 25591463ae3bfbb359c42edde15158a714437c65 Mon Sep 17 00:00:00 2001
-From: Heinrich Schuchardt <xypron.glpk@gmx.de>
-Date: Wed, 23 Sep 2020 19:09:51 +0200
-Subject: [PATCH] examples: make examples/ optional
-
-Most users don't need the standalone API examples. Distributions like SUSE
-do not supply libgcc for cross-compiling and we cannot do without on ARMv8
-for building examples/.
-
-Make examples selectable via symbol CONFIG_EXAMPLES. It defaults to
-yes on ARCH_QEMU to ensure that we compile the API as part of our
-continuous integration.
-
-Cc: Matthias Brugger <mbrugger@suse.com>
-Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
-Reviewed-by: Tom Rini <trini@konsulko.com>
-Reviewed-by: Simon Glass <sjg@chromium.org>
-Reviewed-by: Matthias Brugger <mbrugger@suse.com>
----
- Kconfig           | 8 ++++++++
- examples/Makefile | 2 +-
- 2 files changed, 9 insertions(+), 1 deletion(-)
-
-diff --git a/Kconfig b/Kconfig
-index d96e3373c1..b272def247 100644
---- a/Kconfig
-+++ b/Kconfig
-@@ -221,6 +221,14 @@ config BUILD_ROM
- 	  which are not shipped in the U-Boot source tree.
- 	  Please, see doc/README.x86 for details.
- 
-+config EXAMPLES
-+	bool "Compile API examples"
-+	depends on !SANDBOX
-+	default y if ARCH_QEMU
-+	help
-+	  U-Boot provides an API for standalone applications. Examples are
-+	  provided in directory examples/.
-+
- endmenu		# General setup
- 
- menu "Boot images"
-diff --git a/examples/Makefile b/examples/Makefile
-index d440bc5655..bf518bd221 100644
---- a/examples/Makefile
-+++ b/examples/Makefile
-@@ -1,6 +1,6 @@
- # SPDX-License-Identifier: GPL-2.0+
- 
--ifndef CONFIG_SANDBOX
-+ifdef CONFIG_EXAMPLES
- 
- ifdef FTRACE
- subdir-ccflags-y += -finstrument-functions -DFTRACE
--- 
-2.29.0
-
diff --git a/board/czechlight/clearfog/patches/u-boot/boot.patch b/board/czechlight/clearfog/patches/u-boot/boot.patch
deleted file mode 100644
index d1b6b80..0000000
--- a/board/czechlight/clearfog/patches/u-boot/boot.patch
+++ /dev/null
@@ -1,238 +0,0 @@
-diff --git a/board/solidrun/clearfog/clearfog.c b/board/solidrun/clearfog/clearfog.c
-index 4e1386c8a2..be54ae0b78 100644
---- a/board/solidrun/clearfog/clearfog.c
-+++ b/board/solidrun/clearfog/clearfog.c
-@@ -10,10 +10,15 @@
- #include <asm/io.h>
- #include <asm/arch/cpu.h>
- #include <asm/arch/soc.h>
-+#include <dm/uclass.h>
- 
- #include "../drivers/ddr/marvell/a38x/ddr3_init.h"
- #include <../serdes/a38x/high_speed_env_spec.h>
- 
-+#ifdef CONFIG_WDT_ORION
-+# include <wdt.h>
-+#endif
-+
- DECLARE_GLOBAL_DATA_PTR;
- 
- #define ETH_PHY_CTRL_REG		0
-@@ -108,11 +113,95 @@ int board_early_init_f(void)
- 	return 0;
- }
- 
-+#if !defined(CONFIG_SPL_BUILD) && defined(CONFIG_WDT_ORION)
-+static struct udevice *watchdog_dev = NULL;
-+#endif
-+
-+#define TLC59XXX_REG_MODE1 0x00
-+#define TLC59XXX_REG_MODE2 0x01
-+#define TLC59XXX_REG_PWM(LED) (LED + 0x02)
-+#define TLC59XXX_REG_GRPPWM 0x12
-+#define TLC59XXX_REG_GRPFREQ 0x13
-+#define TLC59XXX_REG_LEDOUT0 0x14
-+#define TLC59XXX_REG_LEDOUT1 0x15
-+#define TLC59XXX_REG_LEDOUT2 0x16
-+#define TLC59XXX_REG_LEDOUT3 0x17
-+#define TLC59XXX_CHIP_RESET_ADDR 0x6b
-+#define TLC59XXX_RESET_BYTE_0 0xa5
-+#define TLC59XXX_RESET_BYTE_1 0x5a
-+#define CLA_LED_CHIP_ADDR 0x60
-+#define CLA_LED_STATUS_RED 8
-+#define CLA_LED_STATUS_GREEN 9
-+#define CLA_LED_STATUS_BLUE 10
-+
-+struct cla_led_config {
-+	u8 reg;
-+	u8 val;
-+};
-+
-+static struct cla_led_config led_reset_config[] = {
-+	{ TLC59XXX_RESET_BYTE_0, TLC59XXX_RESET_BYTE_1 },
-+};
-+
-+static struct cla_led_config led_config[] = {
-+	{ TLC59XXX_REG_MODE1, 0x01 }, /* enable oscillator */
-+	{ TLC59XXX_REG_MODE2, 0x20 }, /* DMBLINK */
-+	{ TLC59XXX_REG_GRPPWM, 0x40 }, /* 25% duty cycle */
-+	{ TLC59XXX_REG_GRPFREQ, 0x03 }, /* very fast blinking */
-+	{ TLC59XXX_REG_PWM(CLA_LED_STATUS_RED), 0x80 }, /* 50% brightness */
-+	{ TLC59XXX_REG_PWM(CLA_LED_STATUS_GREEN), 0x80 }, /* 50% brightness */
-+	{ TLC59XXX_REG_PWM(CLA_LED_STATUS_BLUE), 0x80 }, /* 50% brightness */
-+	{ TLC59XXX_REG_LEDOUT2, 0x3f }, /* LEDs #8, 9, 10: mode 0b11 -> group blinking */
-+};
-+
-+int cla_setup_leds(void)
-+{
-+	struct udevice *bus, *dev;
-+
-+	if (uclass_get_device_by_seq(UCLASS_I2C, 1, &bus)) {
-+		puts("Cannot find I2C bus for LEDs\n");
-+		return 1;
-+	}
-+
-+	if (i2c_get_chip(bus, TLC59XXX_CHIP_RESET_ADDR, 1, &dev)) {
-+		puts("Cannot request I2C chip for SWRST\n");
-+		return 1;
-+	}
-+	if (dm_i2c_write(dev, led_reset_config[0].reg, &led_reset_config[0].val, 1)) {
-+		puts("LED reset failed\n");
-+		return 1;
-+	}
-+
-+	if (i2c_get_chip(bus, CLA_LED_CHIP_ADDR, 1, &dev)) {
-+		puts("Cannot request I2C chip for LEDs\n");
-+		return 1;
-+	}
-+	for (int i = 0; i < ARRAY_SIZE(led_config); i++) {
-+		if (dm_i2c_write(dev, led_config[i].reg, &led_config[i].val, 1)) {
-+			printf("LED config operation #%d failed\n", i);
-+			return 1;
-+		}
-+	}
-+	return 0;
-+}
-+
- int board_init(void)
- {
- 	/* Address of boot parameters */
- 	gd->bd->bi_boot_params = mvebu_sdram_bar(0) + 0x100;
- 
-+#ifndef CONFIG_SPL_BUILD
-+# ifdef CONFIG_WDT_ORION
-+        if (uclass_get_device(UCLASS_WDT, 0, &watchdog_dev)) {
-+                puts("Cannot find Armada 385 watchdog!\n");
-+        } else {
-+                puts("Enabling Armada 385 watchdog.\n");
-+		/* one minute */
-+                wdt_start(watchdog_dev, (u32) 25000000 * 60, 0);
-+        }
-+# endif
-+#endif
-+
- 	/* Toggle GPIO41 to reset onboard switch and phy */
- 	clrbits_le32(MVEBU_GPIO1_BASE + 0x0, BIT(9));
- 	clrbits_le32(MVEBU_GPIO1_BASE + 0x4, BIT(9));
-@@ -124,9 +213,33 @@ int board_init(void)
- 	setbits_le32(MVEBU_GPIO0_BASE + 0x0, BIT(19));
- 	mdelay(10);
- 
-+	cla_setup_leds();
-+
- 	return 0;
- }
- 
-+#ifdef CONFIG_WATCHDOG
-+/* Called by macro WATCHDOG_RESET */
-+void watchdog_reset(void)
-+{
-+# if !defined(CONFIG_SPL_BUILD) && defined(CONFIG_WDT_ORION)
-+        static ulong next_reset = 0;
-+        ulong now;
-+
-+        if (!watchdog_dev)
-+                return;
-+
-+        now = timer_get_us();
-+
-+        /* Do not reset the watchdog too often */
-+        if (now > next_reset) {
-+                wdt_reset(watchdog_dev);
-+                next_reset = now + 1000;
-+        }
-+# endif
-+}
-+#endif
-+
- int checkboard(void)
- {
- 	puts("Board: SolidRun ClearFog\n");
-diff --git a/configs/clearfog_defconfig b/configs/clearfog_defconfig
-index 9167a9450d..faf06cb216 100644
---- a/configs/clearfog_defconfig
-+++ b/configs/clearfog_defconfig
-@@ -63,3 +63,5 @@ CONFIG_USB=y
- CONFIG_DM_USB=y
- CONFIG_USB_XHCI_HCD=y
- CONFIG_USB_STORAGE=y
-+CONFIG_WDT=y
-+CONFIG_WDT_ORION=y
-diff --git a/include/configs/clearfog.h b/include/configs/clearfog.h
-index 7d56dfd86e..c7697ad0f4 100644
---- a/include/configs/clearfog.h
-+++ b/include/configs/clearfog.h
-@@ -21,6 +21,14 @@
-  * Commands configuration
-  */
- 
-+/* Watchdog */
-+#if !defined(CONFIG_SPL_BUILD) && defined(CONFIG_WDT_ORION)
-+# define CONFIG_WATCHDOG
-+#endif
-+
-+/* CzechLight: we have a 128kB EEPROM */
-+#define CONFIG_SYS_EEPROM_SIZE		(128 * 1024)
-+
- /* SPI NOR flash default params, used by sf commands */
- #define CONFIG_SF_DEFAULT_BUS		1
- 
-@@ -47,6 +55,9 @@
- #define CONFIG_ENV_OFFSET		0xf0000
- #define CONFIG_ENV_ADDR			CONFIG_ENV_OFFSET
- 
-+#define CONFIG_ENV_OFFSET_REDUND	0xe0000
-+#define CONFIG_SYS_REDUNDAND_ENVIRONMENT
-+
- #define PHY_ANEG_TIMEOUT	8000	/* PHY needs a longer aneg time */
- 
- /* PCIe support */
-@@ -139,14 +150,44 @@
- 	"scriptaddr=" SCRIPT_ADDR_R "\0" \
- 	"pxefile_addr_r=" PXEFILE_ADDR_R "\0"
- 
--#include <config_distro_bootcmd.h>
--
- #define CONFIG_EXTRA_ENV_SETTINGS \
- 	RELOCATION_LIMITS_ENV_SETTINGS \
- 	LOAD_ADDRESS_ENV_SETTINGS \
--	"fdtfile=" CONFIG_DEFAULT_DEVICE_TREE ".dtb\0" \
- 	"console=ttyS0,115200\0" \
--	BOOTENV
-+	"usbboot=usb start; fatload usb 0:1 ${scriptaddr} boot.scr; source ${scriptaddr}\0" \
-+	"bootcmd=test -n \"${BOOT_A_LEFT}\" || setenv BOOT_A_LEFT 3;" \
-+	"test -n \"${BOOT_B_LEFT}\" || setenv BOOT_B_LEFT 3;" \
-+	"test -n \"${BOOT_ORDER}\" || setenv BOOT_ORDER \"A B\";" \
-+	"for BOOT_SLOT in \"${BOOT_ORDER}\"; do" \
-+	"  if test \"x${rauc_part}\" != \"x\"; then" \
-+	"    ;" \
-+	"  elif test \"x${BOOT_SLOT}\" = \"xA\"; then" \
-+	"    if test ${BOOT_A_LEFT} -gt 0; then" \
-+	"      setexpr BOOT_A_LEFT ${BOOT_A_LEFT} - 1;" \
-+	"      echo \"Found valid slot A, ${BOOT_A_LEFT} attempts remaining\";" \
-+	"      rauc_part=1;" \
-+	"      rauc_slot=A;" \
-+	"    fi;" \
-+	"  elif test \"x${BOOT_SLOT}\" = \"xB\"; then" \
-+	"    if test ${BOOT_B_LEFT} -gt 0; then" \
-+	"      setexpr BOOT_B_LEFT ${BOOT_B_LEFT} - 1;" \
-+	"      echo \"Found valid slot B, ${BOOT_B_LEFT} attempts remaining\";" \
-+	"      rauc_part=3;" \
-+	"      rauc_slot=B;" \
-+	"    fi;" \
-+	"  fi;" \
-+	"done;" \
-+	"if test -n \"${rauc_part}\"; then" \
-+	"  saveenv ;" \
-+	"else" \
-+	"  echo \"No valid slot found, resetting tries to 3\";" \
-+	"  setenv BOOT_A_LEFT 3;" \
-+	"  setenv BOOT_B_LEFT 3;" \
-+	"  saveenv;" \
-+	"  reset;" \
-+	"fi;" \
-+	"load mmc 0:${rauc_part} ${scriptaddr} /boot/boot.scr || reset;" \
-+	"source ${scriptaddr} || reset\0"
- 
- #endif /* CONFIG_SPL_BUILD */
- 
diff --git a/board/czechlight/clearfog/uboot.fragment b/board/czechlight/clearfog/uboot.fragment
index 40082ef..659e470 100644
--- a/board/czechlight/clearfog/uboot.fragment
+++ b/board/czechlight/clearfog/uboot.fragment
@@ -1,2 +1,10 @@
-CONFIG_CMD_SETEXPR=y
+CONFIG_TARGET_CLEARFOG_BASE=y
+CONFIG_MMC_BROKEN_CD=y
 CONFIG_EXAMPLES=n
+CONFIG_CMD_SETEXPR=y
+CONFIG_CMD_WDT=y
+CONFIG_USB_STORAGE=y
+CONFIG_WATCHDOG=y
+CONFIG_WATCHDOG_TIMEOUT_MSECS=120000
+CONFIG_WDT=y
+CONFIG_WDT_ORION=y
diff --git a/configs/czechlight_clearfog_defconfig b/configs/czechlight_clearfog_defconfig
index 842e556..75a9bed 100644
--- a/configs/czechlight_clearfog_defconfig
+++ b/configs/czechlight_clearfog_defconfig
@@ -84,8 +84,7 @@
 BR2_TARGET_UBOOT_BUILD_SYSTEM_KCONFIG=y
 BR2_TARGET_UBOOT_CUSTOM_GIT=y
 BR2_TARGET_UBOOT_CUSTOM_REPO_URL="https://gerrit.cesnet.cz/github/trini/u-boot"
-BR2_TARGET_UBOOT_CUSTOM_REPO_VERSION="v2018.09"
-BR2_TARGET_UBOOT_PATCH="$(BR2_EXTERNAL_CZECHLIGHT_PATH)/board/czechlight/clearfog/patches/u-boot/boot.patch $(BR2_EXTERNAL_CZECHLIGHT_PATH)/board/czechlight/clearfog/patches/u-boot/0001-Remove-redundant-YYLOC-global-declaration.patch $(BR2_EXTERNAL_CZECHLIGHT_PATH)/board/czechlight/clearfog/patches/u-boot/0002-Kbuild-fix-escaping-in-.cmd-files-for-future-Make.patch $(BR2_EXTERNAL_CZECHLIGHT_PATH)/board/czechlight/clearfog/patches/u-boot/0003-kbuild-fix-escaping-in-appending-U-Boot-own-DT.patch $(BR2_EXTERNAL_CZECHLIGHT_PATH)/board/czechlight/clearfog/patches/u-boot/0004-examples-make-examples-optional.patch"
+BR2_TARGET_UBOOT_CUSTOM_REPO_VERSION="cesnet/2021-01-29"
 BR2_TARGET_UBOOT_BOARD_DEFCONFIG="clearfog"
 BR2_TARGET_UBOOT_CONFIG_FRAGMENT_FILES="$(BR2_EXTERNAL_CZECHLIGHT_PATH)/board/czechlight/clearfog/uboot.fragment"
 BR2_TARGET_UBOOT_NEEDS_DTC=y