Merge Official Source
Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
This commit is contained in:
commit
83590422a7
@ -1,8 +1,8 @@
|
||||
include $(TOPDIR)/rules.mk
|
||||
include $(INCLUDE_DIR)/kernel.mk
|
||||
|
||||
PKG_VERSION:=2021.04-rc3
|
||||
PKG_HASH:=7c418e07f6065c8761eb2df890bb524d7109864325d8850ddb0c93eb345734f9
|
||||
PKG_VERSION:=2021.04
|
||||
PKG_HASH:=0d438b1bb5cceb57a18ea2de4a0d51f7be5b05b98717df05938636e0aadfe11a
|
||||
PKG_BUILD_DEPENDS:=arm-trusted-firmware-tools/host
|
||||
|
||||
include $(INCLUDE_DIR)/u-boot.mk
|
||||
|
||||
@ -1,21 +0,0 @@
|
||||
From 04815ef5a49a9996acacfcb5e18924569f5e1bf5 Mon Sep 17 00:00:00 2001
|
||||
From: Matthias Brugger <mbrugger@suse.com>
|
||||
Date: Tue, 16 Feb 2021 20:54:08 +0100
|
||||
Subject: [PATCH 02/21] configs: RPi2: Disable EFI Grub workaround
|
||||
|
||||
The EFI Grub workaround isn't needed with Grub version 2.04 or higher.
|
||||
This version was published over a year ago, so disable the workaround
|
||||
to reduce boot time.
|
||||
|
||||
Signed-off-by: Matthias Brugger <mbrugger@suse.com>
|
||||
---
|
||||
configs/rpi_2_defconfig | 1 +
|
||||
1 file changed, 1 insertion(+)
|
||||
|
||||
--- a/configs/rpi_2_defconfig
|
||||
+++ b/configs/rpi_2_defconfig
|
||||
@@ -42,3 +42,4 @@ CONFIG_SYS_WHITE_ON_BLACK=y
|
||||
CONFIG_CONSOLE_SCROLL_LINES=10
|
||||
CONFIG_PHYS_TO_BUS=y
|
||||
CONFIG_OF_LIBFDT_OVERLAY=y
|
||||
+# CONFIG_EFI_GRUB_ARM32_WORKAROUND is not set
|
||||
@ -33,6 +33,6 @@ Signed-off-by: Weijie Gao <weijie.gao@mediatek.com>
|
||||
+ if (cfg->f_min < MIN_BUS_CLK)
|
||||
+ cfg->f_min = MIN_BUS_CLK;
|
||||
+
|
||||
cfg->f_max = host->src_clk_freq;
|
||||
if (cfg->f_max < cfg->f_min || cfg->f_max > host->src_clk_freq)
|
||||
cfg->f_max = host->src_clk_freq;
|
||||
|
||||
cfg->b_max = 1024;
|
||||
|
||||
@ -17,7 +17,7 @@ Signed-off-by: Weijie Gao <weijie.gao@mediatek.com>
|
||||
|
||||
--- a/Makefile
|
||||
+++ b/Makefile
|
||||
@@ -1728,6 +1728,9 @@ u-boot-elf.lds: arch/u-boot-elf.lds prep
|
||||
@@ -1666,6 +1666,9 @@ u-boot-elf.lds: arch/u-boot-elf.lds prep
|
||||
|
||||
ifeq ($(CONFIG_SPL),y)
|
||||
spl/u-boot-spl-mtk.bin: spl/u-boot-spl
|
||||
|
||||
@ -1,31 +0,0 @@
|
||||
From 4bdab0ea008113dda4e001ab8d6863945000c1b2 Mon Sep 17 00:00:00 2001
|
||||
From: Daniel Golle <daniel@makrotopia.org>
|
||||
Date: Thu, 11 Mar 2021 14:58:26 +0000
|
||||
Subject: [PATCH 21/21] mmc: mtk-sd: don't ignore max-frequency from device
|
||||
tree
|
||||
|
||||
commit e58e68d9 ("mmc: mtk-sd: assign plat->cfg.f_max with a correct value")
|
||||
wrongly assumed that plat->cfg.f_max is always unset at the time
|
||||
mscd_drv_probe() is run. This is not true in case max-frequency being
|
||||
defined in device tree, as it is then already set by mmc_of_parser()
|
||||
in msdc_of_to_plat().
|
||||
Only set plat->cfg.f_max to the default maximum value in case it is
|
||||
not already set to a sane value.
|
||||
|
||||
Signed-off-by: Daniel Golle <daniel@makrotopia.org>
|
||||
---
|
||||
drivers/mmc/mtk-sd.c | 3 ++-
|
||||
1 file changed, 2 insertions(+), 1 deletion(-)
|
||||
|
||||
--- a/drivers/mmc/mtk-sd.c
|
||||
+++ b/drivers/mmc/mtk-sd.c
|
||||
@@ -1644,7 +1644,8 @@ static int msdc_drv_probe(struct udevice
|
||||
if (cfg->f_min < MIN_BUS_CLK)
|
||||
cfg->f_min = MIN_BUS_CLK;
|
||||
|
||||
- cfg->f_max = host->src_clk_freq;
|
||||
+ if (cfg->f_max < cfg->f_min || cfg->f_max > host->src_clk_freq)
|
||||
+ cfg->f_max = host->src_clk_freq;
|
||||
|
||||
cfg->b_max = 1024;
|
||||
cfg->voltages = MMC_VDD_32_33 | MMC_VDD_33_34;
|
||||
@ -1,19 +0,0 @@
|
||||
From 7089c413216f1c0e374d71187030fe41ae4b3071 Mon Sep 17 00:00:00 2001
|
||||
From: Frank Wunderlich <frank-w@public-files.de>
|
||||
Date: Tue, 3 Nov 2020 19:45:30 +0100
|
||||
Subject: [PATCH] ahci: mediatek: fix missing dev_err definition
|
||||
|
||||
---
|
||||
drivers/ata/mtk_ahci.c | 1 +
|
||||
1 file changed, 1 insertion(+)
|
||||
|
||||
--- a/drivers/ata/mtk_ahci.c
|
||||
+++ b/drivers/ata/mtk_ahci.c
|
||||
@@ -21,6 +21,7 @@
|
||||
#include <sata.h>
|
||||
#include <scsi.h>
|
||||
#include <syscon.h>
|
||||
+#include <dm/device_compat.h>
|
||||
|
||||
#define SYS_CFG 0x14
|
||||
#define SYS_CFG_SATA_MSK GENMASK(31, 30)
|
||||
@ -1,6 +1,6 @@
|
||||
--- a/Makefile
|
||||
+++ b/Makefile
|
||||
@@ -1008,7 +1008,7 @@ quiet_cmd_pad_cat = CAT $@
|
||||
@@ -1004,7 +1004,7 @@ quiet_cmd_pad_cat = CAT $@
|
||||
cmd_pad_cat = $(cmd_objcopy) && $(append) || { rm -f $@; false; }
|
||||
|
||||
quiet_cmd_lzma = LZMA $@
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
--- a/cmd/Kconfig
|
||||
+++ b/cmd/Kconfig
|
||||
@@ -465,6 +465,12 @@ config CMD_ENV_EXISTS
|
||||
@@ -472,6 +472,12 @@ config CMD_ENV_EXISTS
|
||||
Check if a variable is defined in the environment for use in
|
||||
shell scripting.
|
||||
|
||||
|
||||
@ -334,7 +334,7 @@
|
||||
+};
|
||||
--- a/arch/arm/dts/Makefile
|
||||
+++ b/arch/arm/dts/Makefile
|
||||
@@ -996,6 +996,7 @@ dtb-$(CONFIG_ARCH_MEDIATEK) += \
|
||||
@@ -1007,6 +1007,7 @@ dtb-$(CONFIG_ARCH_MEDIATEK) += \
|
||||
mt7622-rfb.dtb \
|
||||
mt7623a-unielec-u7623-02-emmc.dtb \
|
||||
mt7622-bananapi-bpi-r64.dtb \
|
||||
|
||||
114
package/libs/libcap/Makefile
Normal file
114
package/libs/libcap/Makefile
Normal file
@ -0,0 +1,114 @@
|
||||
#
|
||||
# This is free software, licensed under the GNU General Public License v2.
|
||||
# See /LICENSE for more information.
|
||||
#
|
||||
|
||||
include $(TOPDIR)/rules.mk
|
||||
|
||||
PKG_NAME:=libcap
|
||||
PKG_VERSION:=2.48
|
||||
PKG_RELEASE:=1
|
||||
|
||||
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz
|
||||
PKG_SOURCE_URL:=@KERNEL/linux/libs/security/linux-privs/libcap2
|
||||
PKG_HASH:=4de9590ee09a87c282d558737ffb5b6175ccbfd26d580add10df44d0f047f6c2
|
||||
|
||||
PKG_MAINTAINER:=Paul Wassi <p.wassi@gmx.at>
|
||||
PKG_LICENSE:=GPL-2.0-only
|
||||
PKG_LICENSE_FILES:=License
|
||||
|
||||
PKG_INSTALL:=1
|
||||
PKG_BUILD_PARALLEL:=1
|
||||
|
||||
include $(INCLUDE_DIR)/package.mk
|
||||
include $(INCLUDE_DIR)/kernel.mk
|
||||
|
||||
define Package/libcap/Default
|
||||
TITLE:=Linux capabilities library
|
||||
SECTION:=libs
|
||||
CATEGORY:=Libraries
|
||||
URL:=https://www.kernel.org/pub/linux/libs/security/linux-privs/libcap2/
|
||||
endef
|
||||
|
||||
define Package/libcap/description/Default
|
||||
Linux capabilities
|
||||
endef
|
||||
|
||||
define Package/libcap
|
||||
$(call Package/libcap/Default)
|
||||
TITLE += library
|
||||
endef
|
||||
|
||||
define Package/libcap-bin
|
||||
$(call Package/libcap/Default)
|
||||
TITLE += binaries
|
||||
DEPENDS += libcap
|
||||
endef
|
||||
|
||||
define Package/libcap-bin/description
|
||||
$(call Package/libcap/description/Default)
|
||||
.
|
||||
This package contains the libcap utilities.
|
||||
endef
|
||||
|
||||
define Package/libcap-bin/config
|
||||
if PACKAGE_libcap-bin
|
||||
config PACKAGE_libcap-bin-capsh-shell
|
||||
string "capsh shell"
|
||||
help
|
||||
Set the capsh shell.
|
||||
default "/bin/sh"
|
||||
endif
|
||||
endef
|
||||
|
||||
MAKE_FLAGS += \
|
||||
BUILD_CC="$(CC)" \
|
||||
BUILD_CFLAGS="$(FPIC) -I$(PKG_BUILD_DIR)/libcap/include" \
|
||||
CFLAGS="$(TARGET_CFLAGS)" \
|
||||
LD="$(TARGET_CC) -Wl,-x -shared" \
|
||||
LDFLAGS="$(TARGET_LDFLAGS)" \
|
||||
INDENT="| true" \
|
||||
GOLANG="no" \
|
||||
PAM_CAP="no" \
|
||||
RAISE_SETFCAP="no" \
|
||||
DYNAMIC="yes" \
|
||||
lib="lib"
|
||||
|
||||
ifneq ($(CONFIG_PACKAGE_libcap-bin-capsh-shell),)
|
||||
TARGET_CFLAGS += -DSHELL='\"$(CONFIG_PACKAGE_libcap-bin-capsh-shell)\"'
|
||||
endif
|
||||
|
||||
TARGET_CFLAGS += $(if $(CONFIG_USE_MUSL),-Dpthread_yield=sched_yield)
|
||||
|
||||
define Build/InstallDev
|
||||
$(INSTALL_DIR) $(1)/usr/include/sys
|
||||
$(CP) $(PKG_INSTALL_DIR)/usr/include/sys/*.h $(1)/usr/include/sys/
|
||||
$(INSTALL_DIR) $(1)/usr/lib
|
||||
$(CP) $(PKG_INSTALL_DIR)/lib/libcap.{so*,a} $(1)/usr/lib/
|
||||
$(INSTALL_DATA) $(PKG_INSTALL_DIR)/lib/libpsx.a $(1)/usr/lib/
|
||||
$(INSTALL_DIR) $(1)/usr/lib/pkgconfig
|
||||
$(INSTALL_DATA) $(PKG_INSTALL_DIR)/lib/pkgconfig/libcap.pc $(1)/usr/lib/pkgconfig/
|
||||
$(SED) 's,exec_prefix=,exec_prefix=/usr,g' $(1)/usr/lib/pkgconfig/libcap.pc
|
||||
$(SED) 's,/lib,$$$${exec_prefix}/lib,g' $(1)/usr/lib/pkgconfig/libcap.pc
|
||||
$(SED) 's,/usr/include,$$$${prefix}/include,g' $(1)/usr/lib/pkgconfig/libcap.pc
|
||||
$(INSTALL_DATA) $(PKG_INSTALL_DIR)/lib/pkgconfig/libpsx.pc $(1)/usr/lib/pkgconfig/
|
||||
$(SED) 's,exec_prefix=,exec_prefix=/usr,g' $(1)/usr/lib/pkgconfig/libpsx.pc
|
||||
$(SED) 's,/lib,$$$${exec_prefix}/lib,g' $(1)/usr/lib/pkgconfig/libpsx.pc
|
||||
$(SED) 's,/usr/include,$$$${prefix}/include,g' $(1)/usr/lib/pkgconfig/libpsx.pc
|
||||
endef
|
||||
|
||||
define Package/libcap/install
|
||||
$(INSTALL_DIR) $(1)/usr/lib
|
||||
$(CP) $(PKG_INSTALL_DIR)/lib/libcap.so* $(1)/usr/lib/
|
||||
endef
|
||||
|
||||
define Package/libcap-bin/install
|
||||
$(INSTALL_DIR) $(1)/usr/sbin
|
||||
$(CP) $(PKG_INSTALL_DIR)/sbin/capsh $(1)/usr/sbin/
|
||||
$(CP) $(PKG_INSTALL_DIR)/sbin/getcap $(1)/usr/sbin/
|
||||
$(CP) $(PKG_INSTALL_DIR)/sbin/getpcaps $(1)/usr/sbin/
|
||||
$(CP) $(PKG_INSTALL_DIR)/sbin/setcap $(1)/usr/sbin/
|
||||
endef
|
||||
|
||||
$(eval $(call BuildPackage,libcap))
|
||||
$(eval $(call BuildPackage,libcap-bin))
|
||||
10
package/libs/libcap/patches/300-disable-tests.patch
Normal file
10
package/libs/libcap/patches/300-disable-tests.patch
Normal file
@ -0,0 +1,10 @@
|
||||
--- a/Makefile
|
||||
+++ b/Makefile
|
||||
@@ -17,7 +17,6 @@ ifeq ($(GOLANG),yes)
|
||||
$(MAKE) -C go $@
|
||||
rm -f cap/go.sum
|
||||
endif
|
||||
- $(MAKE) -C tests $@
|
||||
$(MAKE) -C progs $@
|
||||
$(MAKE) -C doc $@
|
||||
$(MAKE) -C kdebug $@
|
||||
@ -8,12 +8,12 @@
|
||||
include $(TOPDIR)/rules.mk
|
||||
|
||||
PKG_NAME:=lldpd
|
||||
PKG_VERSION:=1.0.7
|
||||
PKG_RELEASE:=1
|
||||
PKG_VERSION:=1.0.9
|
||||
PKG_RELEASE:=3
|
||||
|
||||
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
|
||||
PKG_SOURCE_URL:=https://media.luffy.cx/files/lldpd
|
||||
PKG_HASH:=1df79179d489c841b49265f2ab5ff05f284a647e95862d2f3c02b3fb079a87e1
|
||||
PKG_HASH:=6b64eb3125952b1e33472198b054e8aa0dee45f45d3d4be22789090a474949f5
|
||||
|
||||
PKG_MAINTAINER:=Stijn Tintel <stijn@linux-ipv6.be>
|
||||
PKG_LICENSE:=ISC
|
||||
@ -30,7 +30,7 @@ define Package/lldpd
|
||||
SUBMENU:=Routing and Redirection
|
||||
TITLE:=Link Layer Discovery Protocol daemon
|
||||
URL:=https://vincentbernat.github.io/lldpd/
|
||||
DEPENDS:=+libevent2 +USE_GLIBC:libbsd +LLDPD_WITH_JSON:libjson-c +LLDPD_WITH_SNMP:libnetsnmp
|
||||
DEPENDS:=+libcap +libevent2 +USE_GLIBC:libbsd +LLDPD_WITH_JSON:libjson-c +LLDPD_WITH_SNMP:libnetsnmp
|
||||
USERID:=lldp=121:lldp=129
|
||||
MENU:=1
|
||||
endef
|
||||
@ -110,4 +110,7 @@ CONFIGURE_ARGS += \
|
||||
$(if $(CONFIG_LLDPD_WITH_SNMP),--with-snmp,) \
|
||||
$(if $(CONFIG_USE_GLIBC),,--without-libbsd)
|
||||
|
||||
TARGET_CFLAGS += -flto
|
||||
TARGET_LDFLAGS += -flto -Wl,--gc-sections,--as-needed
|
||||
|
||||
$(eval $(call BuildPackage,lldpd))
|
||||
|
||||
@ -1,17 +0,0 @@
|
||||
--- a/configure.ac
|
||||
+++ b/configure.ac
|
||||
@@ -246,7 +246,13 @@ PKG_CHECK_MODULES([check], [check >= 0.9
|
||||
|
||||
# Third-party libraries
|
||||
lldp_CHECK_LIBEVENT
|
||||
-lldp_CHECK_LIBCAP
|
||||
+
|
||||
+#libcap is not a core package so disable this capability
|
||||
+#lldp_CHECK_LIBCAP
|
||||
+libcap_LIBS=
|
||||
+libcap_CFLAGS=
|
||||
+AC_SUBST([libcap_LIBS])
|
||||
+AC_SUBST([libcap_CFLAGS])
|
||||
|
||||
# Compatibility with pkg.m4 < 0.27
|
||||
m4_ifdef([PKG_INSTALLDIR], [PKG_INSTALLDIR],
|
||||
@ -1,61 +0,0 @@
|
||||
From 23509dc05b24a28fb46022800e0e271ae0118de2 Mon Sep 17 00:00:00 2001
|
||||
From: Jo-Philipp Wich <jo@mein.io>
|
||||
Date: Wed, 9 Dec 2020 12:04:04 +0100
|
||||
Subject: [PATCH] build: prevent conflict with official AX_LIB_READLINE macro
|
||||
|
||||
On systems where the official AX_LIB_READLINE (ax_lib_readline.m4) is
|
||||
present in a globally shared autoconf include directory, auto(re)conf
|
||||
will prefer including that offical version over the local variant due
|
||||
to the offical macro having a higher serial number.
|
||||
|
||||
As a consequence, @READLINE_LIBS@ will not be substituted in *.in files,
|
||||
eventually failing the compilation with errors similar to:
|
||||
|
||||
gcc: error: READLINE_LIBS@: No such file or directory
|
||||
|
||||
Avoid this problem by renaming the incompatible local macro to
|
||||
AX_LIB_READLINE_LLDPD which is sufficient to prevent any clashes.
|
||||
|
||||
We encountered this problem on OpenWrt which uses GNU autoconf-archive
|
||||
to provide commonly used M4 macros through a global include directory,
|
||||
which happens to ship AX_LIB_READLINE as well.
|
||||
|
||||
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
|
||||
---
|
||||
configure.ac | 2 +-
|
||||
m4/ax_lib_readline.m4 | 6 +++---
|
||||
2 files changed, 4 insertions(+), 4 deletions(-)
|
||||
|
||||
--- a/configure.ac
|
||||
+++ b/configure.ac
|
||||
@@ -273,7 +273,7 @@ AC_ARG_WITH([readline],
|
||||
[],
|
||||
[with_readline=auto])
|
||||
if test x"$with_readline" != x"no"; then
|
||||
- AX_LIB_READLINE
|
||||
+ AX_LIB_READLINE_LLDPD
|
||||
if test x"$with_readline" != x"check" -a x"$with_readline" != x"auto"; then
|
||||
if test x"$ax_cv_lib_readline" = x"no"; then
|
||||
AC_MSG_FAILURE([*** no readline support found])
|
||||
--- a/m4/ax_lib_readline.m4
|
||||
+++ b/m4/ax_lib_readline.m4
|
||||
@@ -4,7 +4,7 @@
|
||||
#
|
||||
# SYNOPSIS
|
||||
#
|
||||
-# AX_LIB_READLINE
|
||||
+# AX_LIB_READLINE_LLDPD
|
||||
#
|
||||
# DESCRIPTION
|
||||
#
|
||||
@@ -66,8 +66,8 @@
|
||||
|
||||
#serial 6
|
||||
|
||||
-AU_ALIAS([VL_LIB_READLINE], [AX_LIB_READLINE])
|
||||
-AC_DEFUN([AX_LIB_READLINE], [
|
||||
+AU_ALIAS([VL_LIB_READLINE], [AX_LIB_READLINE_LLDPD])
|
||||
+AC_DEFUN([AX_LIB_READLINE_LLDPD], [
|
||||
AC_CACHE_CHECK([for a readline compatible library],
|
||||
ax_cv_lib_readline, [
|
||||
_save_LIBS="$LIBS"
|
||||
@ -15,7 +15,7 @@ define Build/bcm4908img
|
||||
rm -fr $@-bootfs
|
||||
mkdir -p $@-bootfs
|
||||
cp -r $(DEVICE_NAME)/* $@-bootfs/
|
||||
touch $@-bootfs/1-dummy
|
||||
touch $@-bootfs/1-openwrt
|
||||
cp $(DTS_DIR)/$(firstword $(DEVICE_DTS)).dtb $@-bootfs/94908.dtb
|
||||
cp $(KDIR)/bcm63xx-cfe/$(subst _,$(comma),$(DEVICE_NAME))/cferam.000 $@-bootfs/
|
||||
cp $(IMAGE_KERNEL) $@-bootfs/vmlinux.lz
|
||||
|
||||
@ -12,8 +12,8 @@ PKG_RELEASE:=2
|
||||
|
||||
PKG_SOURCE_PROTO:=git
|
||||
PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION)
|
||||
PKG_SOURCE_VERSION:=db32fc27e7bdfb5468200a94e9152bcc1c971d25
|
||||
PKG_MIRROR_HASH:=e02f8b7df03d675db6279b99212c8a645aa50f1ae7789fafd7bc1987145a4c92
|
||||
PKG_SOURCE_VERSION:=e78ea9bd26199497b9f047e421f16284297629cf
|
||||
PKG_MIRROR_HASH:=1e08d10f04333cc6cd82c6cfc4c83a37db6b7ce1523b3f6e56673178379a9c2c
|
||||
PKG_SOURCE_URL:=https://sourceware.org/git/glibc.git
|
||||
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-$(PKG_SOURCE_VERSION).tar.xz
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user