From 632a8435fadf907e45fff73b14ba005b4b3d17c5 Mon Sep 17 00:00:00 2001
From: guowenxue <guowenxue@gmail.com>
Date: Sun, 05 Jun 2022 17:30:04 +0800
Subject: [PATCH] Update u-boot patch

---
 bsp/bootloader/patch/uboot-imx-lf-5.10.52-2.1.0.patch |   53 ++++++++++++++++++++++++++---------------------------
 1 files changed, 26 insertions(+), 27 deletions(-)

diff --git a/bsp/bootloader/patch/uboot-imx-lf-5.10.52-2.1.0.patch b/bsp/bootloader/patch/uboot-imx-lf-5.10.52-2.1.0.patch
index 825f5dc..c033814 100644
--- a/bsp/bootloader/patch/uboot-imx-lf-5.10.52-2.1.0.patch
+++ b/bsp/bootloader/patch/uboot-imx-lf-5.10.52-2.1.0.patch
@@ -1,6 +1,6 @@
 diff -Nuar -x lingyun.bmp uboot-imx/arch/arm/dts/igkboard.dts uboot-imx-lf-5.10.52-2.1.0/arch/arm/dts/igkboard.dts
 --- uboot-imx/arch/arm/dts/igkboard.dts	1970-01-01 08:00:00.000000000 +0800
-+++ uboot-imx-lf-5.10.52-2.1.0/arch/arm/dts/igkboard.dts	2022-06-04 18:26:25.146238180 +0800
++++ uboot-imx-lf-5.10.52-2.1.0/arch/arm/dts/igkboard.dts	2022-06-04 18:39:14.483032318 +0800
 @@ -0,0 +1,19 @@
 +// SPDX-License-Identifier: (GPL-2.0 OR MIT)
 +//
@@ -23,7 +23,7 @@
 +};
 diff -Nuar -x lingyun.bmp uboot-imx/arch/arm/dts/imx6ul-14x14-evk.dtsi uboot-imx-lf-5.10.52-2.1.0/arch/arm/dts/imx6ul-14x14-evk.dtsi
 --- uboot-imx/arch/arm/dts/imx6ul-14x14-evk.dtsi	2021-09-06 16:48:23.000000000 +0800
-+++ uboot-imx-lf-5.10.52-2.1.0/arch/arm/dts/imx6ul-14x14-evk.dtsi	2022-06-04 18:26:25.146238180 +0800
++++ uboot-imx-lf-5.10.52-2.1.0/arch/arm/dts/imx6ul-14x14-evk.dtsi	2022-06-04 18:39:14.483032318 +0800
 @@ -21,7 +21,6 @@
  		regulator-name = "VSD_3V3";
  		regulator-min-microvolt = <3300000>;
@@ -140,7 +140,7 @@
  
 diff -Nuar -x lingyun.bmp uboot-imx/arch/arm/dts/Makefile uboot-imx-lf-5.10.52-2.1.0/arch/arm/dts/Makefile
 --- uboot-imx/arch/arm/dts/Makefile	2021-09-06 16:48:23.000000000 +0800
-+++ uboot-imx-lf-5.10.52-2.1.0/arch/arm/dts/Makefile	2022-06-04 18:26:25.146238180 +0800
++++ uboot-imx-lf-5.10.52-2.1.0/arch/arm/dts/Makefile	2022-06-04 18:39:14.483032318 +0800
 @@ -779,6 +779,7 @@
  	imx6ul-pico-pi.dtb
  
@@ -151,7 +151,7 @@
  	imx6ull-14x14-ddr3-val-emmc.dtb \
 diff -Nuar -x lingyun.bmp uboot-imx/arch/arm/mach-imx/mx6/Kconfig uboot-imx-lf-5.10.52-2.1.0/arch/arm/mach-imx/mx6/Kconfig
 --- uboot-imx/arch/arm/mach-imx/mx6/Kconfig	2021-09-06 16:48:23.000000000 +0800
-+++ uboot-imx-lf-5.10.52-2.1.0/arch/arm/mach-imx/mx6/Kconfig	2022-06-04 18:26:25.146238180 +0800
++++ uboot-imx-lf-5.10.52-2.1.0/arch/arm/mach-imx/mx6/Kconfig	2022-06-04 18:39:14.483032318 +0800
 @@ -158,6 +158,16 @@
  	prompt "MX6 board select"
  	optional
@@ -178,7 +178,7 @@
  endif
 diff -Nuar -x lingyun.bmp uboot-imx/board/lingyun/igkboard/igkboard.c uboot-imx-lf-5.10.52-2.1.0/board/lingyun/igkboard/igkboard.c
 --- uboot-imx/board/lingyun/igkboard/igkboard.c	1970-01-01 08:00:00.000000000 +0800
-+++ uboot-imx-lf-5.10.52-2.1.0/board/lingyun/igkboard/igkboard.c	2022-06-04 18:26:25.146238180 +0800
++++ uboot-imx-lf-5.10.52-2.1.0/board/lingyun/igkboard/igkboard.c	2022-06-04 18:39:14.483032318 +0800
 @@ -0,0 +1,369 @@
 +// SPDX-License-Identifier: GPL-2.0+
 +/*
@@ -551,7 +551,7 @@
 +}
 diff -Nuar -x lingyun.bmp uboot-imx/board/lingyun/igkboard/imximage.cfg uboot-imx-lf-5.10.52-2.1.0/board/lingyun/igkboard/imximage.cfg
 --- uboot-imx/board/lingyun/igkboard/imximage.cfg	1970-01-01 08:00:00.000000000 +0800
-+++ uboot-imx-lf-5.10.52-2.1.0/board/lingyun/igkboard/imximage.cfg	2022-06-04 18:26:25.146238180 +0800
++++ uboot-imx-lf-5.10.52-2.1.0/board/lingyun/igkboard/imximage.cfg	2022-06-04 18:39:14.483032318 +0800
 @@ -0,0 +1,121 @@
 +/* SPDX-License-Identifier: GPL-2.0+ */
 +/*
@@ -676,7 +676,7 @@
 +#endif
 diff -Nuar -x lingyun.bmp uboot-imx/board/lingyun/igkboard/imximage_lpddr2.cfg uboot-imx-lf-5.10.52-2.1.0/board/lingyun/igkboard/imximage_lpddr2.cfg
 --- uboot-imx/board/lingyun/igkboard/imximage_lpddr2.cfg	1970-01-01 08:00:00.000000000 +0800
-+++ uboot-imx-lf-5.10.52-2.1.0/board/lingyun/igkboard/imximage_lpddr2.cfg	2022-06-04 18:26:25.146238180 +0800
++++ uboot-imx-lf-5.10.52-2.1.0/board/lingyun/igkboard/imximage_lpddr2.cfg	2022-06-04 18:39:14.483032318 +0800
 @@ -0,0 +1,126 @@
 +/*
 + * Copyright (C) 2016 Freescale Semiconductor, Inc.
@@ -806,7 +806,7 @@
 +#endif
 diff -Nuar -x lingyun.bmp uboot-imx/board/lingyun/igkboard/Kconfig uboot-imx-lf-5.10.52-2.1.0/board/lingyun/igkboard/Kconfig
 --- uboot-imx/board/lingyun/igkboard/Kconfig	1970-01-01 08:00:00.000000000 +0800
-+++ uboot-imx-lf-5.10.52-2.1.0/board/lingyun/igkboard/Kconfig	2022-06-04 18:26:25.146238180 +0800
++++ uboot-imx-lf-5.10.52-2.1.0/board/lingyun/igkboard/Kconfig	2022-06-04 18:39:14.483032318 +0800
 @@ -0,0 +1,14 @@
 +if TARGET_LINGYUN_IGKBOARD
 +
@@ -824,7 +824,7 @@
 +endif
 diff -Nuar -x lingyun.bmp uboot-imx/board/lingyun/igkboard/MAINTAINERS uboot-imx-lf-5.10.52-2.1.0/board/lingyun/igkboard/MAINTAINERS
 --- uboot-imx/board/lingyun/igkboard/MAINTAINERS	1970-01-01 08:00:00.000000000 +0800
-+++ uboot-imx-lf-5.10.52-2.1.0/board/lingyun/igkboard/MAINTAINERS	2022-06-04 18:26:25.146238180 +0800
++++ uboot-imx-lf-5.10.52-2.1.0/board/lingyun/igkboard/MAINTAINERS	2022-06-04 18:39:14.483032318 +0800
 @@ -0,0 +1,6 @@
 +LingYun IoT Gateway Board(IGKBoard)
 +M:	Guo Wenxue <guowenxue@gmail.com>
@@ -834,7 +834,7 @@
 +F:	configs/igkboard_defconfig
 diff -Nuar -x lingyun.bmp uboot-imx/board/lingyun/igkboard/Makefile uboot-imx-lf-5.10.52-2.1.0/board/lingyun/igkboard/Makefile
 --- uboot-imx/board/lingyun/igkboard/Makefile	1970-01-01 08:00:00.000000000 +0800
-+++ uboot-imx-lf-5.10.52-2.1.0/board/lingyun/igkboard/Makefile	2022-06-04 18:26:25.146238180 +0800
++++ uboot-imx-lf-5.10.52-2.1.0/board/lingyun/igkboard/Makefile	2022-06-04 18:39:14.483032318 +0800
 @@ -0,0 +1,5 @@
 +# SPDX-License-Identifier: GPL-2.0+
 +# (C) Copyright 2016 Freescale Semiconductor, Inc.
@@ -843,7 +843,7 @@
 +obj-y  += ../../freescale/common/mmc.o
 diff -Nuar -x lingyun.bmp uboot-imx/board/lingyun/igkboard/plugin.S uboot-imx-lf-5.10.52-2.1.0/board/lingyun/igkboard/plugin.S
 --- uboot-imx/board/lingyun/igkboard/plugin.S	1970-01-01 08:00:00.000000000 +0800
-+++ uboot-imx-lf-5.10.52-2.1.0/board/lingyun/igkboard/plugin.S	2022-06-04 18:26:25.146238180 +0800
++++ uboot-imx-lf-5.10.52-2.1.0/board/lingyun/igkboard/plugin.S	2022-06-04 18:39:14.483032318 +0800
 @@ -0,0 +1,263 @@
 +/* SPDX-License-Identifier: GPL-2.0+ */
 +/*
@@ -1110,7 +1110,7 @@
 +#include <asm/arch/mx6_plugin.S>
 diff -Nuar -x lingyun.bmp uboot-imx/configs/igkboard_defconfig uboot-imx-lf-5.10.52-2.1.0/configs/igkboard_defconfig
 --- uboot-imx/configs/igkboard_defconfig	1970-01-01 08:00:00.000000000 +0800
-+++ uboot-imx-lf-5.10.52-2.1.0/configs/igkboard_defconfig	2022-06-04 18:35:06.876141713 +0800
++++ uboot-imx-lf-5.10.52-2.1.0/configs/igkboard_defconfig	2022-06-05 17:28:51.237216727 +0800
 @@ -0,0 +1,97 @@
 +CONFIG_ARM=y
 +CONFIG_ARCH_MX6=y
@@ -1211,7 +1211,7 @@
 +CONFIG_OF_LIBFDT_OVERLAY=y
 diff -Nuar -x lingyun.bmp uboot-imx/drivers/fastboot/fb_fsl/fb_fsl_partitions.c uboot-imx-lf-5.10.52-2.1.0/drivers/fastboot/fb_fsl/fb_fsl_partitions.c
 --- uboot-imx/drivers/fastboot/fb_fsl/fb_fsl_partitions.c	2021-09-06 16:48:23.000000000 +0800
-+++ uboot-imx-lf-5.10.52-2.1.0/drivers/fastboot/fb_fsl/fb_fsl_partitions.c	2022-06-04 18:26:25.150238044 +0800
++++ uboot-imx-lf-5.10.52-2.1.0/drivers/fastboot/fb_fsl/fb_fsl_partitions.c	2022-06-04 18:39:14.483032318 +0800
 @@ -185,6 +185,12 @@
  			boot_partition = FASTBOOT_MMC_BOOT_PARTITION_ID;
  			user_partition = FASTBOOT_MMC_USER_PARTITION_ID;
@@ -1227,7 +1227,7 @@
  			fastboot_devinfo.type);
 diff -Nuar -x lingyun.bmp uboot-imx/drivers/net/phy/phy.c uboot-imx-lf-5.10.52-2.1.0/drivers/net/phy/phy.c
 --- uboot-imx/drivers/net/phy/phy.c	2021-09-06 16:48:23.000000000 +0800
-+++ uboot-imx-lf-5.10.52-2.1.0/drivers/net/phy/phy.c	2022-06-04 18:26:25.150238044 +0800
++++ uboot-imx-lf-5.10.52-2.1.0/drivers/net/phy/phy.c	2022-06-04 18:39:14.483032318 +0800
 @@ -182,6 +182,9 @@
  {
  	int result;
@@ -1240,7 +1240,7 @@
  
 diff -Nuar -x lingyun.bmp uboot-imx/include/configs/igkboard.h uboot-imx-lf-5.10.52-2.1.0/include/configs/igkboard.h
 --- uboot-imx/include/configs/igkboard.h	1970-01-01 08:00:00.000000000 +0800
-+++ uboot-imx-lf-5.10.52-2.1.0/include/configs/igkboard.h	2022-06-04 18:26:25.150238044 +0800
++++ uboot-imx-lf-5.10.52-2.1.0/include/configs/igkboard.h	2022-06-05 17:24:46.360263488 +0800
 @@ -0,0 +1,200 @@
 +/* SPDX-License-Identifier: GPL-2.0+ */
 +/*
@@ -1370,7 +1370,7 @@
 +        "run mmcargs; " \
 +        "bootz ${loadaddr} - ${fdt_addr}\0" \
 +    "upmode=fastboot 0\0" \
-+    "bbl=tftp ${loadaddr} u-boot-igkboard-emmc.imx && mmc dev ${mmcdev} 1 && mmc write ${loadaddr} 2 0x500\0" \
++    "bbl=tftp ${loadaddr} u-boot-igkboard.imx && mmc dev ${mmcdev} 1 && mmc write ${loadaddr} 2 0x500\0" \
 +	MMC_FDT_OVERLAY_SETTING \
 +	"bootcmd=run mmcbootdto\0"
 +#endif
@@ -1444,8 +1444,8 @@
 +#endif
 diff -Nuar -x lingyun.bmp uboot-imx/include/configs/igkboard_overlay.h uboot-imx-lf-5.10.52-2.1.0/include/configs/igkboard_overlay.h
 --- uboot-imx/include/configs/igkboard_overlay.h	1970-01-01 08:00:00.000000000 +0800
-+++ uboot-imx-lf-5.10.52-2.1.0/include/configs/igkboard_overlay.h	2022-06-04 18:26:25.150238044 +0800
-@@ -0,0 +1,79 @@
++++ uboot-imx-lf-5.10.52-2.1.0/include/configs/igkboard_overlay.h	2022-06-05 17:21:55.778465411 +0800
+@@ -0,0 +1,78 @@
 +/* SPDX-License-Identifier: GPL-2.0+ */
 +/*
 + * Copyright (C) 2022 LingYun IoT System Studio
@@ -1456,9 +1456,9 @@
 +#define  __IGKBOARD_OVERLAY_H
 +
 +#if 0
-+ enable_xxx is set in uEnv.txt, then load the corresponding dtbo file
++ dtoverlay_xxx is set in uEnv.txt, then load the corresponding dtbo file
 +
-+ if env exists enable_lcd && test ${enable_lcd} = 1 -o ${enable_lcd} = yes ; then
++ if env exists dtoverlay_lcd && test ${dtoverlay_lcd} = 1 -o ${dtoverlay_lcd} = yes ; then
 +	dtbo_file=lcd.dtbo;
 +    echo "Applying DT overlay: $dtbo_file";
 +	fatload mmc ${mmcdev}:${mmcpart} ${dtbo_addr} ${dtbo_dir}/${dtbo_file};
@@ -1468,8 +1468,8 @@
 + fi;
 +
 +
-+ if env exists enable_uart ; then
-+    for i in ${enable_uart};
++ if env exists dtoverlay_uart ; then
++    for i in ${dtoverlay_uart};
 +    do
 +    	dtbo_file=uart$i.dtbo;
 +        echo "Applying DT overlay: $dtbo_file";
@@ -1490,21 +1490,20 @@
 +	"fdt apply ${dtbo_addr}; "
 +
 +#define CHECK_APPLY_OVERLAY( name )     \
-+	"if env exists enable_" name " && test ${enable_" name "} = 1 -o ${enable_" name "} = yes ; then " \
++	"if env exists dtoverlay_" name " && test ${dtoverlay_" name "} = 1 -o ${dtoverlay_" name "} = yes ; then " \
 +		"setenv dtbo_file " name ".dtbo; " \
 +		FDT_APPLY_OVERLAY() \
 +	"fi; "
 +
 +#define CHECK_APPLY_OVERLAYS( name )     \
-+	"if env exists enable_" name "; then " \
-+    	"for i in ${enable_" name "}; do " \
++	"if env exists dtoverlay_" name "; then " \
++    	"for i in ${dtoverlay_" name "}; do " \
 +    		"setenv dtbo_file " name "$i.dtbo; " \
 +			FDT_APPLY_OVERLAY() \
 +		" done;" \
 +	"fi; "
 +
 +#define FDT_ENTRY_DEF_SETTINGS          \
-+				CHECK_APPLY_OVERLAY("gpios") \
 +				CHECK_APPLY_OVERLAY("lcd") \
 +				CHECK_APPLY_OVERLAY("i2c1") \
 +				CHECK_APPLY_OVERLAY("spi1") \
@@ -1527,7 +1526,7 @@
 +#endif
 diff -Nuar -x lingyun.bmp uboot-imx/Makefile uboot-imx-lf-5.10.52-2.1.0/Makefile
 --- uboot-imx/Makefile	2021-09-06 16:48:23.000000000 +0800
-+++ uboot-imx-lf-5.10.52-2.1.0/Makefile	2022-06-04 18:26:25.158237772 +0800
++++ uboot-imx-lf-5.10.52-2.1.0/Makefile	2022-06-05 17:24:50.628209364 +0800
 @@ -263,6 +263,9 @@
  CROSS_COMPILE ?=
  endif

--
Gitblit v1.9.1