From c7d1b1890880ee64786b92a1b95ba9ecb4694997 Mon Sep 17 00:00:00 2001 From: Christian Melki Date: Mon, 7 Jun 2021 11:21:15 +0200 Subject: [PATCH 01/10] disk/part_dos.c: Fix a variable typo in write_mbr_partitions() This function is passed *dev not *dev_desc, so pass the right name to part_init(). Fixes: f14c5ee5ab8b ("disk: part_dos: update partition table entries after write") Signed-off-by: Christian Melki --- disk/part_dos.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/disk/part_dos.c b/disk/part_dos.c index 60addc6e00..9e29aa6583 100644 --- a/disk/part_dos.c +++ b/disk/part_dos.c @@ -424,7 +424,7 @@ int write_mbr_partitions(struct blk_desc *dev, } /* Update the partition table entries*/ - part_init(dev_desc); + part_init(dev); return 0; } From 5a87df8380c3e20f44ee5f3f1fae15496456a361 Mon Sep 17 00:00:00 2001 From: Da Xue Date: Mon, 21 Jun 2021 22:39:19 -0400 Subject: [PATCH 02/10] autoboot: fix typos of CONFIG_AUTOBOOT_USE_MENUKEY Replace typo CONFIG_USE_AUTOBOOT_MENUKEY with CONFIG_AUTOBOOT_USE_MENUKEY as when they were introduced initially there was some mismatch in which name was used where. Fixes: 8fc31e23aa83 ("autoboot: Rename CONFIG_MENUKEY to CONFIG_AUTOBOOT_MENUKEY") Signed-off-by: Da Xue --- common/autoboot.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/common/autoboot.c b/common/autoboot.c index 0bb08e7a4c..c0b71af4d1 100644 --- a/common/autoboot.c +++ b/common/autoboot.c @@ -44,8 +44,8 @@ static int menukey; #define AUTOBOOT_STOP_STR_SHA256 "" #endif -#ifdef CONFIG_USE_AUTOBOOT_MENUKEY -#define AUTOBOOT_MENUKEY CONFIG_USE_AUTOBOOT_MENUKEY +#ifdef CONFIG_AUTOBOOT_USE_MENUKEY +#define AUTOBOOT_MENUKEY CONFIG_AUTOBOOT_USE_MENUKEY #else #define AUTOBOOT_MENUKEY 0 #endif @@ -282,7 +282,7 @@ static int abortboot_single_key(int bootdelay) abort = 1; /* don't auto boot */ bootdelay = 0; /* no more delay */ key = getchar();/* consume input */ - if (IS_ENABLED(CONFIG_USE_AUTOBOOT_MENUKEY)) + if (IS_ENABLED(CONFIG_AUTOBOOT_USE_MENUKEY)) menukey = key; break; } @@ -388,7 +388,7 @@ void autoboot_command(const char *s) disable_ctrlc(prev); /* restore Ctrl-C checking */ } - if (IS_ENABLED(CONFIG_USE_AUTOBOOT_MENUKEY) && + if (IS_ENABLED(CONFIG_AUTOBOOT_USE_MENUKEY) && menukey == AUTOBOOT_MENUKEY) { s = env_get("menucmd"); if (s) From 2600dd897ed247993670465a4c5acb23a57eab3e Mon Sep 17 00:00:00 2001 From: Jan Kiszka Date: Sun, 20 Jun 2021 22:29:13 +0200 Subject: [PATCH 03/10] Makefile: Adjust indention of GENENV quiet output The column width for a command name is 8. Signed-off-by: Jan Kiszka --- Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Makefile b/Makefile index a73481d18c..71cf6f72b0 100644 --- a/Makefile +++ b/Makefile @@ -2279,7 +2279,7 @@ endif $(build)=$(build-dir) $(@:.ko=.o) $(Q)$(MAKE) -f $(srctree)/scripts/Makefile.modpost -quiet_cmd_genenv = GENENV $@ +quiet_cmd_genenv = GENENV $@ cmd_genenv = $(OBJCOPY) --dump-section .rodata.default_environment=$@ env/common.o; \ sed --in-place -e 's/\x00/\x0A/g' $@ From 5ad9220bf7b54d958627dd8a0475a44c5a238f0a Mon Sep 17 00:00:00 2001 From: Heinrich Schuchardt Date: Sat, 29 May 2021 13:18:00 +0200 Subject: [PATCH 04/10] malloc: add SPDX license identifiers The original code is in the public domain. Licenses/README states that the general license for U-Boot is GPL 2.0+. So we can mark the malloc code as GPL 2.0+ too. Signed-off-by: Heinrich Schuchardt --- common/dlmalloc.c | 10 ++++++++++ include/malloc.h | 9 +++++---- 2 files changed, 15 insertions(+), 4 deletions(-) diff --git a/common/dlmalloc.c b/common/dlmalloc.c index cf0270a9c1..11729e8c85 100644 --- a/common/dlmalloc.c +++ b/common/dlmalloc.c @@ -1,3 +1,13 @@ +// SPDX-License-Identifier: GPL-2.0+ +/* + * This code is based on a version (aka dlmalloc) of malloc/free/realloc written + * by Doug Lea and released to the public domain, as explained at + * http://creativecommons.org/publicdomain/zero/1.0/- + * + * The original code is available at http://gee.cs.oswego.edu/pub/misc/ + * as file malloc-2.6.6.c. + */ + #include #include #include diff --git a/include/malloc.h b/include/malloc.h index 024b18be00..1fbaf3755c 100644 --- a/include/malloc.h +++ b/include/malloc.h @@ -1,12 +1,13 @@ +/* SPDX-License-Identifier: GPL-2.0+ */ /* - A version of malloc/free/realloc written by Doug Lea and released to the - public domain. Send questions/comments/complaints/performance data - to dl@cs.oswego.edu + This code is based on a version of malloc/free/realloc written by Doug Lea and + released to the public domain. Send questions/comments/complaints/performance + data to dl@cs.oswego.edu * VERSION 2.6.6 Sun Mar 5 19:10:03 2000 Doug Lea (dl at gee) Note: There may be an updated version of this malloc obtainable at - ftp://g.oswego.edu/pub/misc/malloc.c + http://g.oswego.edu/pub/misc/malloc.c Check before installing! * Why use this malloc? From 8b95deafc511b56a73b8565f411a49d98755c957 Mon Sep 17 00:00:00 2001 From: Tom Rini Date: Thu, 3 Jun 2021 09:38:59 -0400 Subject: [PATCH 05/10] powerpc: Don't use relative include for config.h in global_data.h As there is an arch/powerpc/include/asm/config.h file using "" to get config.h here can lead to using that rather than include/config.h. This in turn can lead to a mismatch in the size of gd. Cc: Matt Merhar Signed-off-by: Tom Rini Tested-by: Matt Merhar --- arch/powerpc/include/asm/global_data.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arch/powerpc/include/asm/global_data.h b/arch/powerpc/include/asm/global_data.h index 192a02d347..90bf5a2aea 100644 --- a/arch/powerpc/include/asm/global_data.h +++ b/arch/powerpc/include/asm/global_data.h @@ -8,7 +8,7 @@ #ifndef __ASM_GBL_DATA_H #define __ASM_GBL_DATA_H -#include "config.h" +#include #include "asm/types.h" /* Architecture-specific global data */ From 8f0f26eb59006846348b59e1e9eca98b24cea333 Mon Sep 17 00:00:00 2001 From: Tom Rini Date: Thu, 3 Jun 2021 09:39:00 -0400 Subject: [PATCH 06/10] Revert "powerpc: fix regression in arch_initr_trap()" With the changes in commit 588efcdd72fc ("powerpc: Don't use relative include for config.h in global_data.h") fixing the root of the problem, we no longer need this re-inclusion. This reverts commit f6c0d365d3e8ee8e4fd3ebe2ed957c2bca9d3328. Cc: Matt Merhar Signed-off-by: Tom Rini --- arch/powerpc/lib/traps.c | 1 - 1 file changed, 1 deletion(-) diff --git a/arch/powerpc/lib/traps.c b/arch/powerpc/lib/traps.c index ab8ca269a5..c7bce82a44 100644 --- a/arch/powerpc/lib/traps.c +++ b/arch/powerpc/lib/traps.c @@ -4,7 +4,6 @@ * Wolfgang Denk, DENX Software Engineering, wd@denx.de. */ -#include #include #include From 640e2cd6d4335bd1ec39d284cc913c3b90d608f0 Mon Sep 17 00:00:00 2001 From: Tom Rini Date: Thu, 3 Jun 2021 09:39:01 -0400 Subject: [PATCH 07/10] socfpga64: Do not define CONFIG_SYS_MEM_RESERVE_SECURE to 0 Based on the comment in socfpga_soc64_common.h, the intention is for CONFIG_SYS_MEM_RESERVE_SECURE to be unused. However, in the code we do: ... and that will evaluate to true. This leads to unwanted code being compiled. Further, as CONFIG_SYS_MEM_RESERVE_SECURE has not been migrated to Kconfig, this leads to a mismatch in the size of gd depending on if we have or have not also had also included yet. Remove the define as it's not needed. Cc: Siew Chin Lim Cc: Chee Hong Ang Cc: Dalon Westergreen Signed-off-by: Tom Rini --- include/configs/socfpga_soc64_common.h | 1 - 1 file changed, 1 deletion(-) diff --git a/include/configs/socfpga_soc64_common.h b/include/configs/socfpga_soc64_common.h index 5afdb10454..38fd775b5b 100644 --- a/include/configs/socfpga_soc64_common.h +++ b/include/configs/socfpga_soc64_common.h @@ -21,7 +21,6 @@ /* sysmgr.boot_scratch_cold4 & 5 (64bit) will be used for PSCI_CPU_ON call */ #define CPU_RELEASE_ADDR 0xFFD12210 #define CONFIG_SYS_CACHELINE_SIZE 64 -#define CONFIG_SYS_MEM_RESERVE_SECURE 0 /* using OCRAM, not DDR */ /* * U-Boot console configurations From 076c7bfb1f0f1b7c516391aeac6e46fac78fd7de Mon Sep 17 00:00:00 2001 From: Tom Rini Date: Thu, 3 Jun 2021 09:39:02 -0400 Subject: [PATCH 08/10] global_data: Ensure we have when symbols are not in Kconfig yet All symbols that are defined in Kconfig will always be defined (or not) prior to preprocessing due to the -include directive while building. However, symbols which are not yet migrated will only be defined (or not) once the board config.h is included, via . While the end goal must be to migrate all symbols, today we have cases where the size of gd will get mismatched within the build, based on include order. Mitigate this by making sure that any that uses symbols not in Kconfig does start with . Remove this when not needed. Cc: Alexey Brodkin Cc: Eugeniy Paltsev Cc: Huan Wang Cc: Angelo Dureghello Cc: Rick Chen Signed-off-by: Tom Rini --- arch/arc/include/asm/global_data.h | 2 -- arch/arm/include/asm/global_data.h | 2 ++ arch/m68k/include/asm/global_data.h | 2 ++ arch/nds32/include/asm/global_data.h | 2 ++ 4 files changed, 6 insertions(+), 2 deletions(-) diff --git a/arch/arc/include/asm/global_data.h b/arch/arc/include/asm/global_data.h index 8f9c83d3c2..e35a26f1eb 100644 --- a/arch/arc/include/asm/global_data.h +++ b/arch/arc/include/asm/global_data.h @@ -6,8 +6,6 @@ #ifndef __ASM_ARC_GLOBAL_DATA_H #define __ASM_ARC_GLOBAL_DATA_H -#include - #ifndef __ASSEMBLY__ /* Architecture-specific global data */ struct arch_global_data { diff --git a/arch/arm/include/asm/global_data.h b/arch/arm/include/asm/global_data.h index 2aff1c467c..79432f3bbd 100644 --- a/arch/arm/include/asm/global_data.h +++ b/arch/arm/include/asm/global_data.h @@ -9,6 +9,8 @@ #ifndef __ASSEMBLY__ +#include + #include #include diff --git a/arch/m68k/include/asm/global_data.h b/arch/m68k/include/asm/global_data.h index 188055e9d3..273e843c4a 100644 --- a/arch/m68k/include/asm/global_data.h +++ b/arch/m68k/include/asm/global_data.h @@ -7,6 +7,8 @@ #ifndef __ASM_GBL_DATA_H #define __ASM_GBL_DATA_H +#include + /* Architecture-specific global data */ struct arch_global_data { #ifdef CONFIG_SYS_I2C_FSL diff --git a/arch/nds32/include/asm/global_data.h b/arch/nds32/include/asm/global_data.h index be04a18857..297481beaa 100644 --- a/arch/nds32/include/asm/global_data.h +++ b/arch/nds32/include/asm/global_data.h @@ -17,6 +17,8 @@ #ifndef __ASM_GBL_DATA_H #define __ASM_GBL_DATA_H +#include + /* Architecture-specific global data */ struct arch_global_data { }; From af8e2d474662d2eaa518794da6ffdfc95d47859d Mon Sep 17 00:00:00 2001 From: Jaehoon Chung Date: Tue, 15 Jun 2021 07:16:36 +0900 Subject: [PATCH 09/10] MAINTAINER, git-mailrc: Update the mmc maintainer Update to me as co-maintainer with Peng. Additionally, update the mmc alias in git-mailrc. Signed-off-by: Jaehoon Chung Reviewed-by: Bin Meng Acked-by: Peng Fan --- MAINTAINERS | 1 + doc/git-mailrc | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/MAINTAINERS b/MAINTAINERS index 2accd1fb83..5ec1e366a1 100644 --- a/MAINTAINERS +++ b/MAINTAINERS @@ -882,6 +882,7 @@ F: arch/mips/dts/mrvl,cn73xx.dtsi MMC M: Peng Fan +M: Jaehoon Chung S: Maintained T: git https://source.denx.de/u-boot/custodians/u-boot-mmc.git F: drivers/mmc/ diff --git a/doc/git-mailrc b/doc/git-mailrc index 34f936f4d8..dc7b39b32f 100644 --- a/doc/git-mailrc +++ b/doc/git-mailrc @@ -119,7 +119,7 @@ alias kerneldoc uboot, marex alias fdt uboot, sjg alias i2c uboot, hs alias kconfig uboot, masahiro -alias mmc uboot, freenix +alias mmc uboot, freenix, jaehoon alias nand uboot alias net uboot, jhersh alias phy uboot, jhersh From b2710faf82998d7be9e4eef554063a5e27e88ec9 Mon Sep 17 00:00:00 2001 From: Andy Shevchenko Date: Thu, 10 Jun 2021 18:08:42 +0300 Subject: [PATCH 10/10] test: Include /sbin to the PATH when creating file system On some distributions the mkfs is under /sbin and /sbin is not set for mere users. Include /sbin to the PATH when creating file system, so that users won't get a scary traceback from Python. Signed-off-by: Andy Shevchenko --- test/py/tests/test_fs/conftest.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/test/py/tests/test_fs/conftest.py b/test/py/tests/test_fs/conftest.py index 410a675b97..7325486cdb 100644 --- a/test/py/tests/test_fs/conftest.py +++ b/test/py/tests/test_fs/conftest.py @@ -159,6 +159,10 @@ def mk_fs(config, fs_type, size, id): count = (size + 1048576 - 1) / 1048576 + # Some distributions do not add /sbin to the default PATH, where mkfs lives + if '/sbin' not in os.environ["PATH"].split(os.pathsep): + os.environ["PATH"] += os.pathsep + '/sbin' + try: check_call('rm -f %s' % fs_img, shell=True) check_call('dd if=/dev/zero of=%s bs=1M count=%d'