diff --git a/package/boot/uboot-envtools/Makefile b/package/boot/uboot-envtools/Makefile deleted file mode 100644 index 5b52c3b395..0000000000 --- a/package/boot/uboot-envtools/Makefile +++ /dev/null @@ -1,90 +0,0 @@ -# -# Copyright (C) 2006-2014 OpenWrt.org -# -# This is free software, licensed under the GNU General Public License v2. -# See /LICENSE for more information. -# - -include $(TOPDIR)/rules.mk - -PKG_NAME:=uboot-envtools -PKG_DISTNAME:=u-boot -PKG_VERSION:=2025.01 -PKG_RELEASE:=1 - -PKG_SOURCE:=$(PKG_DISTNAME)-$(PKG_VERSION).tar.bz2 -PKG_SOURCE_URL:= \ - https://ftp.denx.de/pub/u-boot \ - https://mirror.cyberbits.eu/u-boot \ - ftp://ftp.denx.de/pub/u-boot -PKG_HASH:=cdef7d507c93f1bbd9f015ea9bc21fa074268481405501945abc6f854d5b686f -PKG_SOURCE_SUBDIR:=$(PKG_DISTNAME)-$(PKG_VERSION) -PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_DISTNAME)-$(PKG_VERSION) - -PKG_BUILD_DEPENDS:=fstools - -PKG_LICENSE:=GPL-2.0 GPL-2.0+ -PKG_LICENSE_FILES:=Licenses/README - -PKG_FLAGS:=nonshared - -PKG_BUILD_PARALLEL:=1 - -include $(INCLUDE_DIR)/package.mk - -define Package/uboot-envtools - SECTION:=utils - CATEGORY:=Utilities - SUBMENU:=Boot Loaders - TITLE:=read/modify U-Boot bootloader environment - URL:=http://www.denx.de/wiki/U-Boot -endef - -define Package/uboot-envtools/description - This package includes tools to read and modify U-Boot bootloader environment. -endef - -define Build/Configure - $(call Build/Compile/Default,tools-only_defconfig) -endef - -define Build/Compile - $(call Build/Compile/Default,envtools) -endef - -# We need to override the ARCH passed by buildsystem as otherwise the defconfig -# for tools-only wont match and the includes for sandbox will be dropped -MAKE_FLAGS += \ - ARCH="sandbox" \ - TARGET_CFLAGS="$(TARGET_CFLAGS)" \ - TARGET_LDFLAGS="$(TARGET_LDFLAGS)" - -define Package/uboot-envtools/conffiles -/etc/config/ubootenv -/etc/fw_env.config -/etc/fw_sys.config -endef - -define Package/uboot-envtools/install - $(INSTALL_DIR) $(1)/usr/sbin - $(INSTALL_BIN) $(PKG_BUILD_DIR)/tools/env/fw_printenv $(1)/usr/sbin - $(LN) fw_printenv $(1)/usr/sbin/fw_setenv - $(INSTALL_BIN) ./files/fw_printsys $(1)/usr/sbin - $(INSTALL_BIN) ./files/fw_setsys $(1)/usr/sbin - $(INSTALL_BIN) ./files/fw_loadenv $(1)/usr/sbin - $(INSTALL_DIR) $(1)/etc/board.d - $(INSTALL_DATA) ./files/fw_defaults $(1)/etc/board.d/05_fw_defaults - $(INSTALL_DIR) $(1)/lib - $(INSTALL_DATA) ./files/uboot-envtools.sh $(1)/lib - $(INSTALL_DIR) $(1)/etc/uci-defaults - $(if $(wildcard ./files/$(BOARD)_$(SUBTARGET)), \ - $(INSTALL_DATA) ./files/$(BOARD)_$(SUBTARGET) \ - $(1)/etc/uci-defaults/30_uboot-envtools, \ - $(if $(wildcard ./files/$(BOARD)), \ - $(INSTALL_DATA) ./files/$(BOARD) \ - $(1)/etc/uci-defaults/30_uboot-envtools \ - ) \ - ) -endef - -$(eval $(call BuildPackage,uboot-envtools)) diff --git a/package/boot/uboot-tools/Makefile b/package/boot/uboot-tools/Makefile new file mode 100644 index 0000000000..dd47d84a59 --- /dev/null +++ b/package/boot/uboot-tools/Makefile @@ -0,0 +1,118 @@ +include $(TOPDIR)/rules.mk + +PKG_DISTNAME:=u-boot +PKG_VERSION:=2025.01 +PKG_RELEASE:=1 + +PKG_SOURCE:=$(PKG_DISTNAME)-$(PKG_VERSION).tar.bz2 +PKG_SOURCE_URL:= \ + https://ftp.denx.de/pub/u-boot \ + https://mirror.cyberbits.eu/u-boot \ + ftp://ftp.denx.de/pub/u-boot +PKG_HASH:=cdef7d507c93f1bbd9f015ea9bc21fa074268481405501945abc6f854d5b686f +PKG_SOURCE_SUBDIR:=$(PKG_DISTNAME)-$(PKG_VERSION) +PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_DISTNAME)-$(PKG_VERSION) + +PKG_BUILD_DEPENDS:=fstools + +PKG_LICENSE:=GPL-2.0 GPL-2.0+ +PKG_LICENSE_FILES:=Licenses/README + +PKG_BUILD_PARALLEL:=1 + +include $(INCLUDE_DIR)/package.mk + +define Package/uboot-tools + SECTION:=utils + CATEGORY:=Utilities + SUBMENU:=Boot Loaders + TITLE:=U-Boot bootloader Tools + URL:=http://www.denx.de/wiki/U-Boot +endef + +define Package/uboot-tools/description + U-Boot tools are a collection of utilities designed + to work with the U-Boot bootloader, +endef + +define Package/dumpimage + SECTION:=utils + CATEGORY:=Utilities + SUBMENU:=Boot Loaders + DEPENDS := +libopenssl + TITLE:=dumpimage lists and extracts data from U-Boot images. + URL:=http://www.denx.de/wiki/U-Boot +endef + +define Package/dumpimage/description + dumpimage lists and extracts data from U-Boot images. + If -l is specified, dumpimage lists the components in + image.Otherwise, dumpimage extracts the component at + position to outfile. +endef + +define Package/uboot-envtools + SECTION:=utils + CATEGORY:=Utilities + SUBMENU:=Boot Loaders + PKG_FLAGS+=nonshared + TITLE:=read/modify U-Boot bootloader environment + URL:=http://www.denx.de/wiki/U-Boot +endef + +define Package/uboot-envtools/description + This package includes tools to read and modify U-Boot + bootloader environment. +endef + +define Package/uboot-envtools/conffiles + /etc/config/ubootenv + /etc/fw_env.config + /etc/fw_sys.config +endef + +define Build/Configure + $(MAKE) -C $(PKG_BUILD_DIR) tools-only_defconfig + $(MAKE) -C $(PKG_BUILD_DIR) syncconfig + $(SED) 's/CONFIG_TOOLS_LIBCRYPTO=y/# CONFIG_TOOLS_LIBCRYPTO is not set/' $(PKG_BUILD_DIR)/.config +endef + +MAKE_FLAGS += \ + ARCH="sandbox" \ + TARGET_CFLAGS="$(TARGET_CFLAGS)" \ + TARGET_LDFLAGS="$(TARGET_LDFLAGS)" + +define Build/Compile + $(call Build/Compile/Default,envtools) + $(call Build/Compile/Default,cross_tools) +endef + +define Package/dumpimage/install + $(INSTALL_DIR) $(1)/usr/bin + $(INSTALL_BIN) $(PKG_BUILD_DIR)/tools/dumpimage $(1)/usr/bin +endef + +define Package/uboot-envtools/install + $(INSTALL_DIR) $(1)/usr/sbin + $(INSTALL_BIN) $(PKG_BUILD_DIR)/tools/env/fw_printenv $(1)/usr/sbin + $(LN) fw_printenv $(1)/usr/sbin/fw_setenv + $(INSTALL_BIN) ./uboot-envtools/files/fw_printsys $(1)/usr/sbin + $(INSTALL_BIN) ./uboot-envtools/files/fw_setsys $(1)/usr/sbin + $(INSTALL_BIN) ./uboot-envtools/files/fw_loadenv $(1)/usr/sbin + $(INSTALL_DIR) $(1)/etc/board.d + $(INSTALL_DATA) ./uboot-envtools/files/fw_defaults $(1)/etc/board.d/05_fw_defaults + $(INSTALL_DIR) $(1)/lib + $(INSTALL_DATA) ./uboot-envtools/files/uboot-envtools.sh $(1)/lib + $(INSTALL_DIR) $(1)/etc/uci-defaults + $(if $(wildcard ./uboot-envtools/files/$(BOARD)_$(SUBTARGET)), \ + $(INSTALL_DATA) ./uboot-envtools/files/$(BOARD)_$(SUBTARGET) \ + $(1)/etc/uci-defaults/30_uboot-envtools, \ + $(if $(wildcard ./uboot-envtools/files/$(BOARD)), \ + $(INSTALL_DATA) ./uboot-envtools/files/$(BOARD) \ + $(1)/etc/uci-defaults/30_uboot-envtools \ + ) \ + ) +endef + +$(eval $(call BuildPackage,dumpimage)) +$(eval $(call BuildPackage,uboot-envtools)) diff --git a/package/boot/uboot-tools/patches/0001-tools-dumpimage-disable-kwbimage.patch b/package/boot/uboot-tools/patches/0001-tools-dumpimage-disable-kwbimage.patch new file mode 100644 index 0000000000..4af6510c44 --- /dev/null +++ b/package/boot/uboot-tools/patches/0001-tools-dumpimage-disable-kwbimage.patch @@ -0,0 +1,32 @@ +diff --git a/package/boot/u-boot-tools/patches/0001-tools-disable-kwbimage.patch b/package/boot/u-boot-tools/patches/0001-tools-disable-kwbimage.patch +new file mode 100644 +index 0000000000..69a42ec383 +--- /dev/null ++++ b/package/boot/u-boot-tools/patches/0001-tools-disable-kwbimage.patch +@@ -0,0 +1,25 @@ ++From: =?UTF-8?q?Rafa=C5=82=20Mi=C5=82ecki?= ++Date: Tue, 30 Nov 2021 11:29:19 +0100 ++Subject: [PATCH] tools: disable kwbimage ++MIME-Version: 1.0 ++Content-Type: text/plain; charset=UTF-8 ++Content-Transfer-Encoding: 8bit ++ ++Without CONFIG_TOOLS_LIBCRYPTO kwbimage doesn't compile because of ++multiple "undefined reference"s to SSL functions. ++ ++Signed-off-by: Rafał Miłecki ++--- ++ tools/Makefile | 1 - ++ 1 file changed, 1 deletion(-) ++ ++--- a/tools/Makefile +++++ b/tools/Makefile ++@@ -117,7 +117,6 @@ dumpimage-mkimage-objs := aisimage.o \ ++ imximage.o \ ++ imx8image.o \ ++ imx8mimage.o \ ++- kwbimage.o \ ++ lib/md5.o \ ++ lpc32xximage.o \ ++ mxsimage.o \ + diff --git a/package/boot/uboot-tools/patches/0002-tools-dumpimage-fix-tools-compile.patch b/package/boot/uboot-tools/patches/0002-tools-dumpimage-fix-tools-compile.patch new file mode 100644 index 0000000000..ab2e817b57 --- /dev/null +++ b/package/boot/uboot-tools/patches/0002-tools-dumpimage-fix-tools-compile.patch @@ -0,0 +1,84 @@ +From 1ceffec2523888b4701405b7cf1710489e17011a Mon Sep 17 00:00:00 2001 +From: Scott Mercer +Date: Wed, 19 Mar 2025 06:31:44 -0400 +Subject: [PATCH] ipq50xx: packages: dumpimage: fix compile patch + +This patch is to fix compilation for uboot-tool V2025.01 in openwrt. + +* same "compile for enviroment patch" to makefile, that is used + in uboot-envtools. + +* remove mkeficapsule from build to avoid gnulib dependencies + +* disable bmp_logo from build to allow compilation + +Signed-off-by: Scott Mercer +--- + tools/Makefile | 38 ++++++++++++++++++++++++++------------ + 1 file changed, 26 insertions(+), 12 deletions(-) + +diff --git a/tools/Makefile b/tools/Makefile +index ee08a9675df8..a72b7909a066 100644 +--- a/tools/Makefile ++++ b/tools/Makefile +@@ -22,6 +22,26 @@ + # That's as long as the features of those tools aren't modified. + # + ++override HOSTCC = $(CC) ++ ++ifneq ($(TARGET_CFLAGS),) ++KBUILD_HOSTCFLAGS = $(TARGET_CFLAGS) ++endif ++ifneq ($(TARGET_LDFLAGS),) ++KBUILD_HOSTLDFLAGS = $(TARGET_LDFLAGS) ++endif ++ ++# Compile for a hosted environment on the target ++HOST_EXTRACFLAGS = -I$(srctree)/tools \ ++ $(patsubst -I%,-idirafter%, $(filter -I%, $(UBOOTINCLUDE))) \ ++ -idirafter $(srctree)/tools/env \ ++ -DUSE_HOSTCC \ ++ -DTEXT_BASE=$(TEXT_BASE) ++ ++ifeq ($(MTD_VERSION),old) ++HOST_EXTRACFLAGS += -DMTD_OLD ++endif ++ + # Enable all the config-independent tools + ifneq ($(HOST_TOOLS_ALL),) + CONFIG_ARCH_KIRKWOOD = y +@@ -244,15 +264,10 @@ hostprogs-$(CONFIG_MIPS) += mips-relocs + hostprogs-$(CONFIG_ASN1_COMPILER) += asn1_compiler + HOSTCFLAGS_asn1_compiler.o = -idirafter $(srctree)/include + +-HOSTCFLAGS_mkeficapsule.o += \ +- $(shell pkg-config --cflags gnutls 2> /dev/null || echo "") +-HOSTLDLIBS_mkeficapsule += \ +- $(shell pkg-config --libs gnutls 2> /dev/null || echo "-lgnutls") +-mkeficapsule-objs := generated/lib/uuid.o \ +- generated/lib/sha1.o \ +- $(LIBFDT_OBJS) \ +- mkeficapsule.o +-hostprogs-$(CONFIG_TOOLS_MKEFICAPSULE) += mkeficapsule ++HOSTCFLAGS_mkeficapsule.o += ++HOSTLDLIBS_mkeficapsule += ++mkeficapsule-objs := ++hostprogs-$(CONFIG_TOOLS_MKEFICAPSULE) += + + mkfwumdata-objs := mkfwumdata.o generated/lib/crc32.o + HOSTLDLIBS_mkfwumdata += -luuid +@@ -313,10 +328,9 @@ HOST_EXTRACFLAGS += -include $(srctree)/include/compiler.h \ + -I$(srctree)/scripts/dtc/libfdt \ + -I$(srctree)/tools \ + -DUSE_HOSTCC \ +- -D__KERNEL_STRICT_NAMES \ +- -D_GNU_SOURCE ++ -D__KERNEL_STRICT_NAMES + +-__build: $(LOGO-y) ++__build: $(LOGO-n) + + $(LOGO_H): $(obj)/bmp_logo $(LOGO_BMP) + $(obj)/bmp_logo --gen-info $(LOGO_BMP) > $@ + diff --git a/package/boot/uboot-envtools/patches/001-compile.patch b/package/boot/uboot-tools/patches/001-envtools-compile.patch similarity index 100% rename from package/boot/uboot-envtools/patches/001-compile.patch rename to package/boot/uboot-tools/patches/001-envtools-compile.patch diff --git a/package/boot/uboot-envtools/patches/002-Revert-tools-env-use-run-to-store-lockfile.patch b/package/boot/uboot-tools/patches/002-envtools-revert-tools-env-use-run-to-store-lockfile.patch similarity index 100% rename from package/boot/uboot-envtools/patches/002-Revert-tools-env-use-run-to-store-lockfile.patch rename to package/boot/uboot-tools/patches/002-envtools-revert-tools-env-use-run-to-store-lockfile.patch diff --git a/package/boot/uboot-envtools/files/apm821xx b/package/boot/uboot-tools/uboot-envtools/files/apm821xx similarity index 100% rename from package/boot/uboot-envtools/files/apm821xx rename to package/boot/uboot-tools/uboot-envtools/files/apm821xx diff --git a/package/boot/uboot-envtools/files/ath79 b/package/boot/uboot-tools/uboot-envtools/files/ath79 similarity index 100% rename from package/boot/uboot-envtools/files/ath79 rename to package/boot/uboot-tools/uboot-envtools/files/ath79 diff --git a/package/boot/uboot-envtools/files/cns3xxx b/package/boot/uboot-tools/uboot-envtools/files/cns3xxx similarity index 100% rename from package/boot/uboot-envtools/files/cns3xxx rename to package/boot/uboot-tools/uboot-envtools/files/cns3xxx diff --git a/package/boot/uboot-envtools/files/fw_defaults b/package/boot/uboot-tools/uboot-envtools/files/fw_defaults similarity index 100% rename from package/boot/uboot-envtools/files/fw_defaults rename to package/boot/uboot-tools/uboot-envtools/files/fw_defaults diff --git a/package/boot/uboot-envtools/files/fw_loadenv b/package/boot/uboot-tools/uboot-envtools/files/fw_loadenv similarity index 100% rename from package/boot/uboot-envtools/files/fw_loadenv rename to package/boot/uboot-tools/uboot-envtools/files/fw_loadenv diff --git a/package/boot/uboot-envtools/files/fw_printsys b/package/boot/uboot-tools/uboot-envtools/files/fw_printsys similarity index 100% rename from package/boot/uboot-envtools/files/fw_printsys rename to package/boot/uboot-tools/uboot-envtools/files/fw_printsys diff --git a/package/boot/uboot-envtools/files/fw_setsys b/package/boot/uboot-tools/uboot-envtools/files/fw_setsys similarity index 100% rename from package/boot/uboot-envtools/files/fw_setsys rename to package/boot/uboot-tools/uboot-envtools/files/fw_setsys diff --git a/package/boot/uboot-envtools/files/imx_cortexa7 b/package/boot/uboot-tools/uboot-envtools/files/imx_cortexa7 similarity index 100% rename from package/boot/uboot-envtools/files/imx_cortexa7 rename to package/boot/uboot-tools/uboot-envtools/files/imx_cortexa7 diff --git a/package/boot/uboot-envtools/files/imx_cortexa9 b/package/boot/uboot-tools/uboot-envtools/files/imx_cortexa9 similarity index 100% rename from package/boot/uboot-envtools/files/imx_cortexa9 rename to package/boot/uboot-tools/uboot-envtools/files/imx_cortexa9 diff --git a/package/boot/uboot-envtools/files/ipq40xx b/package/boot/uboot-tools/uboot-envtools/files/ipq40xx similarity index 100% rename from package/boot/uboot-envtools/files/ipq40xx rename to package/boot/uboot-tools/uboot-envtools/files/ipq40xx diff --git a/package/boot/uboot-envtools/files/ipq806x b/package/boot/uboot-tools/uboot-envtools/files/ipq806x similarity index 100% rename from package/boot/uboot-envtools/files/ipq806x rename to package/boot/uboot-tools/uboot-envtools/files/ipq806x diff --git a/package/boot/uboot-envtools/files/kirkwood b/package/boot/uboot-tools/uboot-envtools/files/kirkwood similarity index 100% rename from package/boot/uboot-envtools/files/kirkwood rename to package/boot/uboot-tools/uboot-envtools/files/kirkwood diff --git a/package/boot/uboot-envtools/files/lantiq b/package/boot/uboot-tools/uboot-envtools/files/lantiq similarity index 100% rename from package/boot/uboot-envtools/files/lantiq rename to package/boot/uboot-tools/uboot-envtools/files/lantiq diff --git a/package/boot/uboot-envtools/files/layerscape b/package/boot/uboot-tools/uboot-envtools/files/layerscape similarity index 100% rename from package/boot/uboot-envtools/files/layerscape rename to package/boot/uboot-tools/uboot-envtools/files/layerscape diff --git a/package/boot/uboot-envtools/files/mediatek_filogic b/package/boot/uboot-tools/uboot-envtools/files/mediatek_filogic similarity index 100% rename from package/boot/uboot-envtools/files/mediatek_filogic rename to package/boot/uboot-tools/uboot-envtools/files/mediatek_filogic diff --git a/package/boot/uboot-envtools/files/mediatek_mt7622 b/package/boot/uboot-tools/uboot-envtools/files/mediatek_mt7622 similarity index 100% rename from package/boot/uboot-envtools/files/mediatek_mt7622 rename to package/boot/uboot-tools/uboot-envtools/files/mediatek_mt7622 diff --git a/package/boot/uboot-envtools/files/mediatek_mt7623 b/package/boot/uboot-tools/uboot-envtools/files/mediatek_mt7623 similarity index 100% rename from package/boot/uboot-envtools/files/mediatek_mt7623 rename to package/boot/uboot-tools/uboot-envtools/files/mediatek_mt7623 diff --git a/package/boot/uboot-envtools/files/mediatek_mt7629 b/package/boot/uboot-tools/uboot-envtools/files/mediatek_mt7629 similarity index 100% rename from package/boot/uboot-envtools/files/mediatek_mt7629 rename to package/boot/uboot-tools/uboot-envtools/files/mediatek_mt7629 diff --git a/package/boot/uboot-envtools/files/mpc85xx b/package/boot/uboot-tools/uboot-envtools/files/mpc85xx similarity index 100% rename from package/boot/uboot-envtools/files/mpc85xx rename to package/boot/uboot-tools/uboot-envtools/files/mpc85xx diff --git a/package/boot/uboot-envtools/files/mvebu b/package/boot/uboot-tools/uboot-envtools/files/mvebu similarity index 100% rename from package/boot/uboot-envtools/files/mvebu rename to package/boot/uboot-tools/uboot-envtools/files/mvebu diff --git a/package/boot/uboot-envtools/files/mxs b/package/boot/uboot-tools/uboot-envtools/files/mxs similarity index 100% rename from package/boot/uboot-envtools/files/mxs rename to package/boot/uboot-tools/uboot-envtools/files/mxs diff --git a/package/boot/uboot-envtools/files/octeon b/package/boot/uboot-tools/uboot-envtools/files/octeon similarity index 100% rename from package/boot/uboot-envtools/files/octeon rename to package/boot/uboot-tools/uboot-envtools/files/octeon diff --git a/package/boot/uboot-envtools/files/oxnas b/package/boot/uboot-tools/uboot-envtools/files/oxnas similarity index 100% rename from package/boot/uboot-envtools/files/oxnas rename to package/boot/uboot-tools/uboot-envtools/files/oxnas diff --git a/package/boot/uboot-envtools/files/pistachio b/package/boot/uboot-tools/uboot-envtools/files/pistachio similarity index 100% rename from package/boot/uboot-envtools/files/pistachio rename to package/boot/uboot-tools/uboot-envtools/files/pistachio diff --git a/package/boot/uboot-envtools/files/qoriq b/package/boot/uboot-tools/uboot-envtools/files/qoriq similarity index 100% rename from package/boot/uboot-envtools/files/qoriq rename to package/boot/uboot-tools/uboot-envtools/files/qoriq diff --git a/package/boot/uboot-envtools/files/qualcommax_ipq50xx b/package/boot/uboot-tools/uboot-envtools/files/qualcommax_ipq50xx similarity index 100% rename from package/boot/uboot-envtools/files/qualcommax_ipq50xx rename to package/boot/uboot-tools/uboot-envtools/files/qualcommax_ipq50xx diff --git a/package/boot/uboot-envtools/files/qualcommax_ipq60xx b/package/boot/uboot-tools/uboot-envtools/files/qualcommax_ipq60xx similarity index 100% rename from package/boot/uboot-envtools/files/qualcommax_ipq60xx rename to package/boot/uboot-tools/uboot-envtools/files/qualcommax_ipq60xx diff --git a/package/boot/uboot-envtools/files/qualcommax_ipq807x b/package/boot/uboot-tools/uboot-envtools/files/qualcommax_ipq807x similarity index 100% rename from package/boot/uboot-envtools/files/qualcommax_ipq807x rename to package/boot/uboot-tools/uboot-envtools/files/qualcommax_ipq807x diff --git a/package/boot/uboot-envtools/files/ramips b/package/boot/uboot-tools/uboot-envtools/files/ramips similarity index 100% rename from package/boot/uboot-envtools/files/ramips rename to package/boot/uboot-tools/uboot-envtools/files/ramips diff --git a/package/boot/uboot-envtools/files/realtek b/package/boot/uboot-tools/uboot-envtools/files/realtek similarity index 100% rename from package/boot/uboot-envtools/files/realtek rename to package/boot/uboot-tools/uboot-envtools/files/realtek diff --git a/package/boot/uboot-envtools/files/rockchip_armv8 b/package/boot/uboot-tools/uboot-envtools/files/rockchip_armv8 similarity index 100% rename from package/boot/uboot-envtools/files/rockchip_armv8 rename to package/boot/uboot-tools/uboot-envtools/files/rockchip_armv8 diff --git a/package/boot/uboot-envtools/files/uboot-envtools.sh b/package/boot/uboot-tools/uboot-envtools/files/uboot-envtools.sh similarity index 100% rename from package/boot/uboot-envtools/files/uboot-envtools.sh rename to package/boot/uboot-tools/uboot-envtools/files/uboot-envtools.sh diff --git a/package/network/services/lldpd/files/lldpd.init b/package/network/services/lldpd/files/lldpd.init index 6c1c184bfa..e60cc82fd3 100644 --- a/package/network/services/lldpd/files/lldpd.init +++ b/package/network/services/lldpd/files/lldpd.init @@ -75,9 +75,9 @@ get_config_restart_hash() { export -n "$var=$_hash" } -get_config_cid_ifaces() { +get_interface_csv() { local _ifaces - config_get _ifaces 'config' "$2" + config_get _ifaces "$2" "$3" local _iface _ifnames="" # Set noglob to prevent '*' capturing diverse file names in the for ... in @@ -98,6 +98,21 @@ get_config_cid_ifaces() { export -n "${1}=$_ifnames" } +add_custom_tlv_callback() +{ + # syntax: configure [ports ethX[,…]] lldp custom-tlv [add|replace] oui XX,XX,XX subtype XX oui-info XX[,XX,...] + # ex: configure ports br-lan,eth0 lldp custom-tlv replace oui 33,44,55 subtype 254 oui-info 55,55,55,55,55 + # ex: configure lldp custom-tlv oui 33,44,44 subtype 232 + + local _ports + local _tlv + # CSV of device ports + get_interface_csv _ports "$1" 'ports' + config_get _tlv "$1" 'tlv' + + echo "configure ${_ports:+ports $_ports }lldp custom-tlv $_tlv" >> "$LLDPD_CONF" +} + write_lldpd_conf() { local lldp_description @@ -109,7 +124,7 @@ write_lldpd_conf() config_get lldp_hostname 'config' 'lldp_hostname' "$(cat /proc/sys/kernel/hostname)" local ifnames - get_config_cid_ifaces ifnames "interface" + get_interface_csv ifnames 'config' "interface" local lldp_mgmt_ip config_get lldp_mgmt_ip 'config' 'lldp_mgmt_ip' @@ -197,6 +212,9 @@ write_lldpd_conf() [ "$lldp_mgmt_addr_advertisements" -gt 0 ] && echo "configure lldp management-addresses-advertisements" >> "$LLDPD_CONF" ||\ echo "unconfigure lldp management-addresses-advertisements" >> "$LLDPD_CONF" + # Custom TLV handling + config_foreach add_custom_tlv_callback 'custom-tlv' + # Since lldpd's sysconfdir is /tmp, we'll symlink /etc/lldpd.d to /tmp/$LLDPD_CONFS_DIR [ -e "$LLDPD_CONFS_DIR" ] || ln -s /etc/lldpd.d "$LLDPD_CONFS_DIR" } @@ -335,7 +353,7 @@ start_service() { # ChassisID interfaces local ifnames - get_config_cid_ifaces ifnames "cid_interface" + get_interface_csv ifnames 'config' "cid_interface" [ -n "$ifnames" ] && procd_append_param command -C "$ifnames" diff --git a/package/system/ubox/files/log.init b/package/system/ubox/files/log.init index c6fdf44292..e02cc273da 100644 --- a/package/system/ubox/files/log.init +++ b/package/system/ubox/files/log.init @@ -52,8 +52,12 @@ start_service_file() } [ -z "${log_file}" ] && return + local mountpoint="$(procd_get_mountpoints "${log_file}")" + [ "$_BOOT" = "1" ] && - [ "$(procd_get_mountpoints "${log_file}")" ] && return 0 + [ "$mountpoint" ] && + ! grep -q ".* $mountpoint " /proc/mounts && + return 0 mkdir -p "$(dirname "${log_file}")" diff --git a/target/linux/generic/pending-6.6/792-igc-enable-HW-vlan-tag-insertion-stripping-by-defaul.patch b/target/linux/generic/pending-6.6/792-igc-enable-HW-vlan-tag-insertion-stripping-by-defaul.patch new file mode 100644 index 0000000000..0ca219457c --- /dev/null +++ b/target/linux/generic/pending-6.6/792-igc-enable-HW-vlan-tag-insertion-stripping-by-defaul.patch @@ -0,0 +1,32 @@ +From 8cae5a0d91fea01d90ce7c1827e26934a22ca2fa Mon Sep 17 00:00:00 2001 +From: Rui Salvaterra +Date: Wed, 5 Mar 2025 11:53:56 +0000 +Subject: [PATCH] igc: enable HW vlan tag insertion/stripping by default + +This is enabled by default in other Intel drivers I've checked (e1000, e1000e, +iavf, igb and ice). Fixes an out-of-the-box performance issue when running +OpenWrt on typical mini-PCs with igc-supported Ethernet controllers and 802.1Q +VLAN configurations, as ethtool isn't part of the default packages and sane +defaults are expected. + +In my specific case, with an Intel N100-based machine with four I226-V Ethernet +controllers, my upload performance increased from under 30 Mb/s to the expected +~1 Gb/s. + +Signed-off-by: Rui Salvaterra +--- + drivers/net/ethernet/intel/igc/igc_main.c | 3 +++ + 1 file changed, 3 insertions(+) + +--- a/drivers/net/ethernet/intel/igc/igc_main.c ++++ b/drivers/net/ethernet/intel/igc/igc_main.c +@@ -6850,6 +6850,9 @@ static int igc_probe(struct pci_dev *pde + netdev->xdp_features = NETDEV_XDP_ACT_BASIC | NETDEV_XDP_ACT_REDIRECT | + NETDEV_XDP_ACT_XSK_ZEROCOPY; + ++ /* enable HW vlan tag insertion/stripping by default */ ++ netdev->features |= NETIF_F_HW_VLAN_CTAG_TX | NETIF_F_HW_VLAN_CTAG_RX; ++ + /* MTU range: 68 - 9216 */ + netdev->min_mtu = ETH_MIN_MTU; + netdev->max_mtu = MAX_STD_JUMBO_FRAME_SIZE;