uboot-tools: update to v2025.07
Update to the latest version. Remove upstreamed patches: 010-image-fit-sig-skip-in-tools-build-if-key-is-missing.patch[1] 011-tools-fit_check_sign-make-key-optional.patch[2] 012-tools-fit_check_sign-no-libcrypto.patch[2] [1]40dcd5088b
[2]9c79c8fe70
Signed-off-by: Shiji Yang <yangshiji66@outlook.com> Link: https://github.com/openwrt/openwrt/pull/19342 Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
This commit is contained in:
parent
01654bc2ad
commit
9dc4128e03
7 changed files with 15 additions and 188 deletions
|
@ -1,8 +1,8 @@
|
|||
include $(TOPDIR)/rules.mk
|
||||
|
||||
PKG_DISTNAME:=u-boot
|
||||
PKG_VERSION:=2025.01
|
||||
PKG_RELEASE:=3
|
||||
PKG_VERSION:=2025.07
|
||||
PKG_RELEASE:=1
|
||||
|
||||
PKG_SOURCE:=$(PKG_DISTNAME)-$(PKG_VERSION).tar.bz2
|
||||
PKG_SOURCE_URL:= \
|
||||
|
@ -10,7 +10,7 @@ PKG_SOURCE_URL:= \
|
|||
https://mirror.cyberbits.eu/u-boot \
|
||||
ftp://ftp.denx.de/pub/u-boot
|
||||
PKG_URL:=http://www.denx.de/wiki/U-Boot
|
||||
PKG_HASH:=cdef7d507c93f1bbd9f015ea9bc21fa074268481405501945abc6f854d5b686f
|
||||
PKG_HASH:=0f933f6c5a426895bf306e93e6ac53c60870e4b54cda56d95211bec99e63bec7
|
||||
PKG_SOURCE_SUBDIR:=$(PKG_DISTNAME)-$(PKG_VERSION)
|
||||
PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_DISTNAME)-$(PKG_VERSION)
|
||||
|
||||
|
|
|
@ -46,7 +46,7 @@ Signed-off-by: Scott Mercer <TheRootEd24@gmail.com>
|
|||
# Enable all the config-independent tools
|
||||
ifneq ($(HOST_TOOLS_ALL),)
|
||||
CONFIG_ARCH_KIRKWOOD = y
|
||||
@@ -244,15 +264,10 @@ hostprogs-$(CONFIG_MIPS) += mips-relocs
|
||||
@@ -261,15 +281,10 @@ hostprogs-$(CONFIG_MIPS) += mips-relocs
|
||||
hostprogs-$(CONFIG_ASN1_COMPILER) += asn1_compiler
|
||||
HOSTCFLAGS_asn1_compiler.o = -idirafter $(srctree)/include
|
||||
|
||||
|
@ -66,7 +66,7 @@ Signed-off-by: Scott Mercer <TheRootEd24@gmail.com>
|
|||
|
||||
mkfwumdata-objs := mkfwumdata.o generated/lib/crc32.o
|
||||
HOSTLDLIBS_mkfwumdata += -luuid
|
||||
@@ -313,10 +328,9 @@ HOST_EXTRACFLAGS += -include $(srctree)/
|
||||
@@ -330,10 +345,9 @@ HOST_EXTRACFLAGS += -include $(srctree)/
|
||||
-I$(srctree)/scripts/dtc/libfdt \
|
||||
-I$(srctree)/tools \
|
||||
-DUSE_HOSTCC \
|
||||
|
|
|
@ -1,69 +0,0 @@
|
|||
From patchwork Sat Mar 29 03:12:50 2025
|
||||
Content-Type: text/plain; charset="utf-8"
|
||||
MIME-Version: 1.0
|
||||
Content-Transfer-Encoding: 7bit
|
||||
X-Patchwork-Submitter: Daniel Golle <daniel@makrotopia.org>
|
||||
X-Patchwork-Id: 2066664
|
||||
Return-Path: <u-boot-bounces@lists.denx.de>
|
||||
X-Original-To: incoming@patchwork.ozlabs.org
|
||||
Delivered-To: patchwork-incoming@legolas.ozlabs.org
|
||||
Date: Sat, 29 Mar 2025 03:12:50 +0000
|
||||
From: Daniel Golle <daniel@makrotopia.org>
|
||||
To: Tom Rini <trini@konsulko.com>, Simon Glass <sjg@chromium.org>,
|
||||
Chia-Wei Wang <chiawei_wang@aspeedtech.com>, u-boot@lists.denx.de
|
||||
Cc: Thomas =?iso-8859-1?q?H=FChn?= <thomas.huehn@hs-nordhausen.de>
|
||||
Subject: [PATCH 1/2] image-fit-sig: skip in tools build if key is missing
|
||||
Message-ID:
|
||||
<bf6a90e864b713db41bf788797554649eeaa0732.1743217745.git.daniel@makrotopia.org>
|
||||
MIME-Version: 1.0
|
||||
Content-Disposition: inline
|
||||
X-BeenThere: u-boot@lists.denx.de
|
||||
X-Mailman-Version: 2.1.39
|
||||
Precedence: list
|
||||
List-Id: U-Boot discussion <u-boot.lists.denx.de>
|
||||
List-Unsubscribe: <https://lists.denx.de/options/u-boot>,
|
||||
<mailto:u-boot-request@lists.denx.de?subject=unsubscribe>
|
||||
List-Archive: <https://lists.denx.de/pipermail/u-boot/>
|
||||
List-Post: <mailto:u-boot@lists.denx.de>
|
||||
List-Help: <mailto:u-boot-request@lists.denx.de?subject=help>
|
||||
List-Subscribe: <https://lists.denx.de/listinfo/u-boot>,
|
||||
<mailto:u-boot-request@lists.denx.de?subject=subscribe>
|
||||
Errors-To: u-boot-bounces@lists.denx.de
|
||||
Sender: "U-Boot" <u-boot-bounces@lists.denx.de>
|
||||
|
||||
Skip signature verification in case no public key was given in order to
|
||||
allow using fit_check_sign also to validate uImage.FIT images without
|
||||
signatures. Guarded by USE_HOSTCC macro the behavior on target is
|
||||
unchanged.
|
||||
|
||||
Signed-off-by: Daniel Golle <daniel@makrotopia.org>
|
||||
---
|
||||
boot/image-fit-sig.c | 10 ++++++++++
|
||||
1 file changed, 10 insertions(+)
|
||||
|
||||
--- a/boot/image-fit-sig.c
|
||||
+++ b/boot/image-fit-sig.c
|
||||
@@ -191,6 +191,11 @@ int fit_image_verify_required_sigs(const
|
||||
int noffset;
|
||||
int key_node;
|
||||
|
||||
+#ifdef USE_HOSTCC
|
||||
+ if (!key_blob)
|
||||
+ return 0;
|
||||
+#endif
|
||||
+
|
||||
/* Work out what we need to verify */
|
||||
*no_sigsp = 1;
|
||||
key_node = fdt_subnode_offset(key_blob, 0, FIT_SIG_NODENAME);
|
||||
@@ -477,6 +482,11 @@ static int fit_config_verify_required_ke
|
||||
bool reqd_policy_all = true;
|
||||
const char *reqd_mode;
|
||||
|
||||
+#ifdef USE_HOSTCC
|
||||
+ if (!key_blob)
|
||||
+ return 0;
|
||||
+#endif
|
||||
+
|
||||
/*
|
||||
* We don't support this since libfdt considers names with the
|
||||
* name root but different @ suffix to be equal
|
|
@ -1,92 +0,0 @@
|
|||
From patchwork Sat Mar 29 03:13:01 2025
|
||||
Content-Type: text/plain; charset="utf-8"
|
||||
MIME-Version: 1.0
|
||||
Content-Transfer-Encoding: 7bit
|
||||
X-Patchwork-Submitter: Daniel Golle <daniel@makrotopia.org>
|
||||
X-Patchwork-Id: 2066665
|
||||
Return-Path: <u-boot-bounces@lists.denx.de>
|
||||
X-Original-To: incoming@patchwork.ozlabs.org
|
||||
Delivered-To: patchwork-incoming@legolas.ozlabs.org
|
||||
Date: Sat, 29 Mar 2025 03:13:01 +0000
|
||||
From: Daniel Golle <daniel@makrotopia.org>
|
||||
To: Tom Rini <trini@konsulko.com>, Simon Glass <sjg@chromium.org>,
|
||||
Chia-Wei Wang <chiawei_wang@aspeedtech.com>,
|
||||
Daniel Golle <daniel@makrotopia.org>, u-boot@lists.denx.de
|
||||
Cc: Thomas =?iso-8859-1?q?H=FChn?= <thomas.huehn@hs-nordhausen.de>
|
||||
Subject: [PATCH 2/2] tools/fit_check_sign: make key optional
|
||||
Message-ID:
|
||||
<1f0c5a1f7e84f638f921278284ff6245d78e730d.1743217745.git.daniel@makrotopia.org>
|
||||
References:
|
||||
<bf6a90e864b713db41bf788797554649eeaa0732.1743217745.git.daniel@makrotopia.org>
|
||||
MIME-Version: 1.0
|
||||
Content-Disposition: inline
|
||||
In-Reply-To:
|
||||
<bf6a90e864b713db41bf788797554649eeaa0732.1743217745.git.daniel@makrotopia.org>
|
||||
X-BeenThere: u-boot@lists.denx.de
|
||||
X-Mailman-Version: 2.1.39
|
||||
Precedence: list
|
||||
List-Id: U-Boot discussion <u-boot.lists.denx.de>
|
||||
List-Unsubscribe: <https://lists.denx.de/options/u-boot>,
|
||||
<mailto:u-boot-request@lists.denx.de?subject=unsubscribe>
|
||||
List-Archive: <https://lists.denx.de/pipermail/u-boot/>
|
||||
List-Post: <mailto:u-boot@lists.denx.de>
|
||||
List-Help: <mailto:u-boot-request@lists.denx.de?subject=help>
|
||||
List-Subscribe: <https://lists.denx.de/listinfo/u-boot>,
|
||||
<mailto:u-boot-request@lists.denx.de?subject=subscribe>
|
||||
Errors-To: u-boot-bounces@lists.denx.de
|
||||
Sender: "U-Boot" <u-boot-bounces@lists.denx.de>
|
||||
|
||||
Allow invoking fit_check_sig without the key parameter, allowing to
|
||||
validate only checksums and hashes for unsigned images.
|
||||
|
||||
Signed-off-by: Daniel Golle <daniel@makrotopia.org>
|
||||
---
|
||||
tools/fit_check_sign.c | 15 ++++++---------
|
||||
1 file changed, 6 insertions(+), 9 deletions(-)
|
||||
|
||||
--- a/tools/fit_check_sign.c
|
||||
+++ b/tools/fit_check_sign.c
|
||||
@@ -45,7 +45,7 @@ int main(int argc, char **argv)
|
||||
char *config_name = NULL;
|
||||
char cmdname[256];
|
||||
int ret;
|
||||
- void *key_blob;
|
||||
+ void *key_blob = NULL;
|
||||
int c;
|
||||
|
||||
strncpy(cmdname, *argv, sizeof(cmdname) - 1);
|
||||
@@ -70,18 +70,15 @@ int main(int argc, char **argv)
|
||||
fprintf(stderr, "%s: Missing fdt file\n", *argv);
|
||||
usage(*argv);
|
||||
}
|
||||
- if (!keyfile) {
|
||||
- fprintf(stderr, "%s: Missing key file\n", *argv);
|
||||
- usage(*argv);
|
||||
- }
|
||||
|
||||
ffd = mmap_fdt(cmdname, fdtfile, 0, &fit_blob, &fsbuf, false, true);
|
||||
if (ffd < 0)
|
||||
return EXIT_FAILURE;
|
||||
- kfd = mmap_fdt(cmdname, keyfile, 0, &key_blob, &ksbuf, false, true);
|
||||
- if (kfd < 0)
|
||||
- return EXIT_FAILURE;
|
||||
-
|
||||
+ if (keyfile) {
|
||||
+ kfd = mmap_fdt(cmdname, keyfile, 0, &key_blob, &ksbuf, false, true);
|
||||
+ if (kfd < 0)
|
||||
+ return EXIT_FAILURE;
|
||||
+ }
|
||||
image_set_host_blob(key_blob);
|
||||
ret = fit_check_sign(fit_blob, key_blob, config_name);
|
||||
if (!ret) {
|
||||
@@ -93,7 +90,9 @@ int main(int argc, char **argv)
|
||||
}
|
||||
|
||||
(void) munmap((void *)fit_blob, fsbuf.st_size);
|
||||
- (void) munmap((void *)key_blob, ksbuf.st_size);
|
||||
+
|
||||
+ if (keyfile)
|
||||
+ (void) munmap((void *)key_blob, ksbuf.st_size);
|
||||
|
||||
close(ffd);
|
||||
close(kfd);
|
|
@ -1,13 +0,0 @@
|
|||
--- a/tools/Makefile
|
||||
+++ b/tools/Makefile
|
||||
@@ -83,8 +83,8 @@ HOSTCFLAGS_img2srec.o := -pedantic
|
||||
hostprogs-y += mkenvimage
|
||||
mkenvimage-objs := mkenvimage.o os_support.o generated/lib/crc32.o
|
||||
|
||||
-hostprogs-y += dumpimage mkimage
|
||||
-hostprogs-$(CONFIG_TOOLS_LIBCRYPTO) += fit_info fit_check_sign
|
||||
+hostprogs-y += dumpimage mkimage fit_check_sign
|
||||
+hostprogs-$(CONFIG_TOOLS_LIBCRYPTO) += fit_info
|
||||
hostprogs-$(CONFIG_TOOLS_LIBCRYPTO) += fdt_add_pubkey
|
||||
|
||||
ifneq ($(CONFIG_CMD_BOOTEFI_SELFTEST)$(CONFIG_FWU_MDATA_GPT_BLK),)
|
|
@ -1,6 +1,6 @@
|
|||
--- a/boot/bootm.c
|
||||
+++ b/boot/bootm.c
|
||||
@@ -1229,20 +1229,18 @@ static int bootm_host_load_image(const v
|
||||
@@ -1232,20 +1232,18 @@ static int bootm_host_load_image(const v
|
||||
|
||||
int bootm_host_load_images(const void *fit, int cfg_noffset)
|
||||
{
|
||||
|
@ -28,18 +28,19 @@
|
|||
/* Return the first error we found */
|
||||
--- a/boot/image-fit.c
|
||||
+++ b/boot/image-fit.c
|
||||
@@ -2072,7 +2072,9 @@ int fit_image_load(struct bootm_headers
|
||||
@@ -2079,8 +2079,10 @@ int fit_image_load(struct bootm_headers
|
||||
fit_uname_config = fit_uname_configp ? *fit_uname_configp : NULL;
|
||||
fit_base_uname_config = NULL;
|
||||
prop_name = fit_get_image_type_property(image_type);
|
||||
prop_name = fit_get_image_type_property(ph_type);
|
||||
+#ifndef USE_HOSTCC
|
||||
printf("## Loading %s from FIT Image at %08lx ...\n", prop_name, addr);
|
||||
printf("## Loading %s (%s) from FIT Image at %08lx ...\n",
|
||||
prop_name, genimg_get_phase_name(image_ph_phase(ph_type)), addr);
|
||||
+#endif
|
||||
|
||||
bootstage_mark(bootstage_id + BOOTSTAGE_SUB_FORMAT);
|
||||
ret = fit_check_format(fit, IMAGE_SIZE_INVAL);
|
||||
@@ -2108,7 +2110,9 @@ int fit_image_load(struct bootm_headers
|
||||
}
|
||||
@@ -2117,7 +2119,9 @@ int fit_image_load(struct bootm_headers
|
||||
cfg_noffset = ret;
|
||||
|
||||
fit_base_uname_config = fdt_get_name(fit, cfg_noffset, NULL);
|
||||
+#ifndef USE_HOSTCC
|
||||
|
@ -48,7 +49,7 @@
|
|||
/* Remember this config */
|
||||
if (image_type == IH_TYPE_KERNEL)
|
||||
images->fit_uname_cfg = fit_base_uname_config;
|
||||
@@ -2131,7 +2135,9 @@ int fit_image_load(struct bootm_headers
|
||||
@@ -2140,7 +2144,9 @@ int fit_image_load(struct bootm_headers
|
||||
fit_uname = fit_get_name(fit, noffset, NULL);
|
||||
}
|
||||
if (noffset < 0) {
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
--- a/boot/bootm.c
|
||||
+++ b/boot/bootm.c
|
||||
@@ -1188,10 +1188,6 @@ static int bootm_host_load_image(const v
|
||||
@@ -1191,10 +1191,6 @@ static int bootm_host_load_image(const v
|
||||
ulong data, len;
|
||||
struct bootm_headers images;
|
||||
int noffset;
|
||||
|
@ -11,7 +11,7 @@
|
|||
int ret;
|
||||
|
||||
fit_uname_config = fdt_get_name(fit, cfg_noffset, NULL);
|
||||
@@ -1203,26 +1199,6 @@ static int bootm_host_load_image(const v
|
||||
@@ -1206,26 +1202,6 @@ static int bootm_host_load_image(const v
|
||||
FIT_LOAD_IGNORED, &data, &len);
|
||||
if (noffset < 0)
|
||||
return noffset;
|
||||
|
|
Loading…
Reference in a new issue