Merge remote-tracking branch 'upstream/master' into owrt
This commit is contained in:
commit
30b43757dc
@ -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))
|
118
package/boot/uboot-tools/Makefile
Normal file
118
package/boot/uboot-tools/Makefile
Normal file
@ -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))
|
@ -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?= <rafal at milecki.pl>
|
||||
+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 <rafal at milecki.pl>
|
||||
+---
|
||||
+ 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 \
|
||||
|
@ -0,0 +1,84 @@
|
||||
From 1ceffec2523888b4701405b7cf1710489e17011a Mon Sep 17 00:00:00 2001
|
||||
From: Scott Mercer <TheRootEd24@gmail.com>
|
||||
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 <TheRootEd24@gmail.com>
|
||||
---
|
||||
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) > $@
|
||||
|
@ -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"
|
||||
|
||||
|
@ -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}")"
|
||||
|
||||
|
@ -0,0 +1,32 @@
|
||||
From 8cae5a0d91fea01d90ce7c1827e26934a22ca2fa Mon Sep 17 00:00:00 2001
|
||||
From: Rui Salvaterra <rsalvaterra@gmail.com>
|
||||
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 <rsalvaterra@gmail.com>
|
||||
---
|
||||
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;
|
Loading…
x
Reference in New Issue
Block a user