Merge Official Source

Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
This commit is contained in:
Tianling Shen 2024-02-27 17:33:26 +08:00
commit fd566ca982
No known key found for this signature in database
GPG Key ID: 6850B6345C862176
24 changed files with 208 additions and 80 deletions

View File

@ -165,6 +165,23 @@ part_magic_fat() {
[ "$magic" = "FAT" ] || [ "$magic_fat32" = "FAT32" ]
}
fitblk_get_bootdev() {
[ -e /sys/firmware/devicetree/base/chosen/rootdisk ] || return
local rootdisk="$(cat /sys/firmware/devicetree/base/chosen/rootdisk)"
local handle bootdev
for handle in /sys/class/block/*/of_node/phandle /sys/class/block/*/device/of_node/phandle; do
[ ! -e "$handle" ] && continue
if [ "$rootdisk" = "$(cat $handle)" ]; then
bootdev="${handle%/of_node/phandle}"
bootdev="${bootdev%/device}"
bootdev="${bootdev#/sys/class/block/}"
echo "$bootdev"
break
fi
done
}
export_bootdevice() {
local cmdline uuid blockdev uevent line class
local MAJOR MINOR DEVNAME DEVTYPE
@ -196,6 +213,7 @@ export_bootdevice() {
done
;;
/dev/*)
[ "$rootpart" = "/dev/fit0" ] && rootpart="$(fitblk_get_bootdev)"
uevent="/sys/class/block/${rootpart##*/}/../uevent"
;;
0x[a-f0-9][a-f0-9][a-f0-9] | 0x[a-f0-9][a-f0-9][a-f0-9][a-f0-9] | \

View File

@ -39,9 +39,9 @@ asus,rt-ax59u)
bananapi,bpi-r3|\
bananapi,bpi-r3-mini|\
bananapi,bpi-r4)
. /lib/upgrade/platform.sh
. /lib/upgrade/common.sh
bootdev="$(platform_get_bootdev)"
bootdev="$(fitblk_get_bootdev)"
case "$bootdev" in
ubi*)
ubootenv_add_ubi_default

View File

@ -35,8 +35,8 @@ linksys,e8450-ubi)
ubootenv_add_ubi_default
;;
bananapi,bpi-r64)
. /lib/upgrade/platform.sh
bootdev="$(platform_get_bootdev)"
. /lib/upgrade/common.sh
bootdev="$(fitblk_get_bootdev)"
case "$bootdev" in
mmc*)
ubootenv_add_mmc_default "${bootdev%p[0-9]*}"

View File

@ -13,8 +13,8 @@ board=$(board_name)
case "$board" in
bananapi,bpi-r2)
. /lib/upgrade/platform.sh
bootdev="$(platform_get_bootdev)"
. /lib/upgrade/common.sh
bootdev="$(fitblk_get_bootdev)"
ubootenv_add_uci_config "/dev/${bootdev%p[0-9]*}p1" "0xb0000" "0x10000" "0x10000" "1"
;;
unielec,u7623-02)

View File

@ -6,9 +6,9 @@ PKG_RELEASE:=1
PKG_SOURCE_PROTO:=git
PKG_SOURCE_URL=$(PROJECT_GIT)/project/firmware/qca-wireless.git
PKG_SOURCE_DATE:=2024-02-23
PKG_SOURCE_VERSION:=9f9d9ba9cd77043744dcd5235497a15eea51c375
PKG_MIRROR_HASH:=38f6d15259a8e4d7d9d1f8043abe9981fc3ed03c57a909a8a484f59710f86815
PKG_SOURCE_DATE:=2024-02-25
PKG_SOURCE_VERSION:=fc30aeeb8ec5d069710a446f4eb5e30fc26145c1
PKG_MIRROR_HASH:=7fe83e3f36541444e0385a56fa8a048772d0531e16787cc10bce29775c7db235
PKG_FLAGS:=nonshared
@ -90,7 +90,7 @@ define ipq-wifi-install-one
$(call ipq-wifi-install-one-to,$(1),$(2),QCA99X0/hw2.0),\
$(if $(filter $(suffix $(1)),.IPQ6018 .ipq6018),\
$(call ipq-wifi-install-ath11-one-to,$(1),$(2),IPQ6018/hw1.0),\
$(if $(filter $(suffix $(1)),.IPQ8074 .ipq8074 .ipq8174),\
$(if $(filter $(suffix $(1)),.IPQ8074 .ipq8074),\
$(call ipq-wifi-install-ath11-one-to,$(1),$(2),IPQ8074/hw2.0),\
$(if $(filter $(suffix $(1)),.QCN9074 .qcn9074),\
$(call ipq-wifi-install-ath11-one-to,$(1),$(2),QCN9074/hw1.0),\

View File

@ -502,7 +502,7 @@ dhcp_boot_add() {
[ -n "$serveraddress" ] && [ ! -n "$servername" ] && return 0
xappend "--dhcp-boot=${networkid:+net:$networkid,}${filename}${servername:+,$servername}${serveraddress:+,$serveraddress}"
xappend "--dhcp-boot=${networkid:+tag:$networkid,}${filename}${servername:+,$servername}${serveraddress:+,$serveraddress}"
config_get_bool force "$cfg" force 0

View File

@ -34,7 +34,7 @@ define Package/e2fsprogs
SUBMENU:=Filesystem
TITLE:=Ext2/3/4 filesystem utilities
URL:=http://e2fsprogs.sourceforge.net/
DEPENDS:=+libuuid +libext2fs
DEPENDS:=+libuuid +libext2fs +libe2p
endef
define Package/e2fsprogs/description
@ -55,6 +55,20 @@ define Package/libext2fs/description
libext2fs is a library which can access ext2, ext3 and ext4 filesystems.
endef
define Package/libe2p
SECTION:=libs
CATEGORY:=Libraries
TITLE:=ext2fs userspace programs utility library
URL:=http://e2fsprogs.sourceforge.net/
DEPENDS:=+libuuid
ABI_VERSION:=2
endef
define Package/libe2p/description
This package contains libe2p, ext2fs userspace programs utility library
bundled with e2fsprogs.
endef
define Package/libss
SECTION:=libs
CATEGORY:=Libraries
@ -184,13 +198,17 @@ endef
define Build/InstallDev
$(INSTALL_DIR) $(1)/usr/lib/pkgconfig
$(CP) $(PKG_BUILD_DIR)/lib/ext2fs/ext2fs.pc $(1)/usr/lib/pkgconfig
$(CP) $(PKG_BUILD_DIR)/lib/et/com_err.pc $(1)/usr/lib/pkgconfig
$(CP) $(PKG_BUILD_DIR)/lib/e2p/e2p.pc $(1)/usr/lib/pkgconfig
$(CP) $(PKG_BUILD_DIR)/lib/ss/ss.pc $(1)/usr/lib/pkgconfig
$(INSTALL_DIR) $(1)/usr/lib
$(CP) $(PKG_BUILD_DIR)/lib/libext2fs.{so,a}* $(1)/usr/lib
$(CP) $(PKG_BUILD_DIR)/lib/libcom_err.{so,a}* $(1)/usr/lib
$(CP) $(PKG_BUILD_DIR)/lib/libss.{so,a}* $(1)/usr/lib
$(CP) $(PKG_BUILD_DIR)/lib/libe2p.{so,a}* $(1)/usr/lib
$(INSTALL_DIR) $(1)/usr/include/ext2fs
$(CP) $(PKG_BUILD_DIR)/lib/ext2fs/*.h $(1)/usr/include/ext2fs
@ -203,6 +221,8 @@ define Build/InstallDev
$(PKG_BUILD_DIR)/lib/ss/ss.h \
$(PKG_BUILD_DIR)/lib/ss/ss_err.h \
$(1)/usr/include/ss/
$(INSTALL_DIR) $(1)/usr/include/e2p
$(CP) $(PKG_BUILD_DIR)/lib/e2p/e2p.h $(1)/usr/include/e2p
endef
define Host/Compile
@ -237,13 +257,17 @@ define Package/e2fsprogs/install
$(LN) e2fsck $(1)/usr/sbin/fsck.ext3
$(LN) e2fsck $(1)/usr/sbin/fsck.ext4
$(INSTALL_DIR) $(1)/usr/lib
$(CP) $(PKG_INSTALL_DIR)/usr/lib/libe2p.so.* $(1)/usr/lib/
$(INSTALL_DIR) $(1)/etc/init.d
$(INSTALL_DIR) $(1)/lib/functions/fsck
$(INSTALL_DATA) ./files/e2fsck.sh $(1)/lib/functions/fsck/
$(INSTALL_DATA) ./files/e2fsck.conf $(1)/etc/e2fsck.conf
endef
define Package/libe2p/install
$(INSTALL_DIR) $(1)/usr/lib
$(CP) $(PKG_INSTALL_DIR)/usr/lib/libe2p.so.* $(1)/usr/lib/
endef
define Package/libcomerr/install
$(INSTALL_DIR) $(1)/usr/lib
$(CP) $(PKG_INSTALL_DIR)/usr/lib/libcom_err.so.* $(1)/usr/lib/
@ -318,6 +342,7 @@ endef
$(eval $(call BuildPackage,libcomerr))
$(eval $(call BuildPackage,libss))
$(eval $(call BuildPackage,libext2fs))
$(eval $(call BuildPackage,libe2p))
$(eval $(call BuildPackage,e2fsprogs))
$(eval $(call BuildPackage,tune2fs))
$(eval $(call BuildPackage,resize2fs))

View File

@ -157,7 +157,7 @@
clocks = <&scu EN7523_CLK_PCIE>;
clock-names = "sys_ck0";
bus-range = <0x00 0xff>;
ranges = <0x82000000 0 0x20000000 0x20000000 0 0x8000000>;
ranges = <0x82000000 0 0x20000000 0x20000000 0 0x2000000>;
status = "disabled";
#interrupt-cells = <1>;
@ -186,7 +186,7 @@
clocks = <&scu EN7523_CLK_PCIE>;
clock-names = "sys_ck1";
bus-range = <0x00 0xff>;
ranges = <0x82000000 0 0x28000000 0x28000000 0 0x8000000>;
ranges = <0x82000000 0 0x22000000 0x22000000 0 0x2000000>;
status = "disabled";
#interrupt-cells = <1>;

View File

@ -0,0 +1,31 @@
From 4a44a52f16ccd3d03e0cb5fb437a5eb31a5f9f05 Mon Sep 17 00:00:00 2001
From: David Bauer <mail@david-bauer.net>
Date: Mon, 26 Feb 2024 21:39:34 +0100
Subject: [PATCH] net l2tp: drop flow hash on forward
Drop the flow-hash of the skb when forwarding to the L2TP netdev.
This avoids the L2TP qdisc from using the flow-hash from the outer
packet, which is identical for every flow within the tunnel.
This does not affect every platform but is specific for the ethernet
driver. It depends on the platform including L4 information in the
flow-hash.
Signed-off-by: David Bauer <mail@david-bauer.net>
---
net/l2tp/l2tp_eth.c | 3 +++
1 file changed, 3 insertions(+)
--- a/net/l2tp/l2tp_eth.c
+++ b/net/l2tp/l2tp_eth.c
@@ -136,6 +136,9 @@ static void l2tp_eth_dev_recv(struct l2t
/* checksums verified by L2TP */
skb->ip_summed = CHECKSUM_NONE;
+ /* drop outer flow-hash */
+ skb_clear_hash(skb);
+
skb_dst_drop(skb);
nf_reset_ct(skb);

View File

@ -0,0 +1,30 @@
From 3f1a227cb071f65f6ecc4db9f399649869735a7c Mon Sep 17 00:00:00 2001
From: David Bauer <mail@david-bauer.net>
Date: Sat, 17 Feb 2024 22:34:59 +0100
Subject: [PATCH] net vxlan: don't learn non-unicast L2 destinations
This patch avoids learning non-unicast targets in the vxlan FDB.
They are non-unicast and thus should be sent to the broadcast-IPv6
instead of a unicast address.
Link: https://lore.kernel.org/netdev/15ee0cc7-9252-466b-8ce7-5225d605dde8@david-bauer.net/
Link: https://github.com/freifunk-gluon/gluon/issues/3191
Signed-off-by: David Bauer <mail@david-bauer.net>
---
drivers/net/vxlan.c | 4 ++++
1 file changed, 4 insertions(+)
--- a/drivers/net/vxlan/vxlan_core.c
+++ b/drivers/net/vxlan/vxlan_core.c
@@ -1493,6 +1493,10 @@ static bool vxlan_snoop(struct net_devic
struct vxlan_fdb *f;
u32 ifindex = 0;
+ /* Don't learn broadcast packets */
+ if (is_multicast_ether_addr(src_mac) || is_zero_ether_addr(src_mac))
+ return false;
+
#if IS_ENABLED(CONFIG_IPV6)
if (src_ip->sa.sa_family == AF_INET6 &&
(ipv6_addr_type(&src_ip->sin6.sin6_addr) & IPV6_ADDR_LINKLOCAL))

View File

@ -52,7 +52,7 @@ Signed-off-by: Daniel Golle <daniel@makrotopia.org>
+obj-$(CONFIG_MTD_UBI_NVMEM) += nvmem.o
--- /dev/null
+++ b/drivers/mtd/ubi/nvmem.c
@@ -0,0 +1,188 @@
@@ -0,0 +1,191 @@
+// SPDX-License-Identifier: GPL-2.0-or-later
+/*
+ * Copyright (c) 2023 Daniel Golle <daniel@makrotopia.org>
@ -78,14 +78,17 @@ Signed-off-by: Daniel Golle <daniel@makrotopia.org>
+static int ubi_nvmem_reg_read(void *priv, unsigned int from,
+ void *val, size_t bytes)
+{
+ int err = 0, lnum = from, offs, bytes_left = bytes, to_read;
+ uint32_t offs, to_read, bytes_left;
+ struct ubi_nvmem *unv = priv;
+ struct ubi_volume_desc *desc;
+ uint64_t lnum = from;
+ int err = 0;
+
+ desc = ubi_open_volume(unv->ubi_num, unv->vol_id, UBI_READONLY);
+ if (IS_ERR(desc))
+ return PTR_ERR(desc);
+
+ bytes_left = bytes;
+ offs = do_div(lnum, unv->usable_leb_size);
+ while (bytes_left) {
+ to_read = unv->usable_leb_size - offs;

View File

@ -0,0 +1,31 @@
From 4a44a52f16ccd3d03e0cb5fb437a5eb31a5f9f05 Mon Sep 17 00:00:00 2001
From: David Bauer <mail@david-bauer.net>
Date: Mon, 26 Feb 2024 21:39:34 +0100
Subject: [PATCH] net l2tp: drop flow hash on forward
Drop the flow-hash of the skb when forwarding to the L2TP netdev.
This avoids the L2TP qdisc from using the flow-hash from the outer
packet, which is identical for every flow within the tunnel.
This does not affect every platform but is specific for the ethernet
driver. It depends on the platform including L4 information in the
flow-hash.
Signed-off-by: David Bauer <mail@david-bauer.net>
---
net/l2tp/l2tp_eth.c | 3 +++
1 file changed, 3 insertions(+)
--- a/net/l2tp/l2tp_eth.c
+++ b/net/l2tp/l2tp_eth.c
@@ -136,6 +136,9 @@ static void l2tp_eth_dev_recv(struct l2t
/* checksums verified by L2TP */
skb->ip_summed = CHECKSUM_NONE;
+ /* drop outer flow-hash */
+ skb_clear_hash(skb);
+
skb_dst_drop(skb);
nf_reset_ct(skb);

View File

@ -0,0 +1,30 @@
From 3f1a227cb071f65f6ecc4db9f399649869735a7c Mon Sep 17 00:00:00 2001
From: David Bauer <mail@david-bauer.net>
Date: Sat, 17 Feb 2024 22:34:59 +0100
Subject: [PATCH] net vxlan: don't learn non-unicast L2 destinations
This patch avoids learning non-unicast targets in the vxlan FDB.
They are non-unicast and thus should be sent to the broadcast-IPv6
instead of a unicast address.
Link: https://lore.kernel.org/netdev/15ee0cc7-9252-466b-8ce7-5225d605dde8@david-bauer.net/
Link: https://github.com/freifunk-gluon/gluon/issues/3191
Signed-off-by: David Bauer <mail@david-bauer.net>
---
drivers/net/vxlan.c | 4 ++++
1 file changed, 4 insertions(+)
--- a/drivers/net/vxlan/vxlan_core.c
+++ b/drivers/net/vxlan/vxlan_core.c
@@ -1493,6 +1493,10 @@ static bool vxlan_snoop(struct net_devic
struct vxlan_fdb *f;
u32 ifindex = 0;
+ /* Don't learn broadcast packets */
+ if (is_multicast_ether_addr(src_mac) || is_zero_ether_addr(src_mac))
+ return false;
+
#if IS_ENABLED(CONFIG_IPV6)
if (src_ip->sa.sa_family == AF_INET6 &&
(ipv6_addr_type(&src_ip->sin6.sin6_addr) & IPV6_ADDR_LINKLOCAL))

View File

@ -36,7 +36,7 @@
wps {
label = "wps";
linux,code = <KEY_WPS_BUTTON>;
gpios = <&pio 0 GPIO_ACTIVE_HIGH>;
gpios = <&pio 0 GPIO_ACTIVE_LOW>;
};
};

View File

@ -60,21 +60,6 @@ xiaomi_initial_setup()
esac
}
platform_get_bootdev() {
local rootdisk="$(cat /sys/firmware/devicetree/base/chosen/rootdisk)"
local handle bootdev
for handle in /sys/class/block/*/of_node/phandle /sys/class/block/*/device/of_node/phandle; do
[ ! -e "$handle" ] && continue
if [ "$rootdisk" = "$(cat $handle)" ]; then
bootdev="${handle%/of_node/phandle}"
bootdev="${bootdev%/device}"
bootdev="${bootdev#/sys/class/block/}"
echo "$bootdev"
break
fi
done
}
platform_do_upgrade() {
local board=$(board_name)
@ -100,7 +85,7 @@ platform_do_upgrade() {
bananapi,bpi-r4)
[ -e /dev/fit0 ] && fitblk /dev/fit0
[ -e /dev/fitrw ] && fitblk /dev/fitrw
bootdev="$(platform_get_bootdev)"
bootdev="$(fitblk_get_bootdev)"
case "$bootdev" in
mmcblk*)
EMMC_KERN_DEV="/dev/$bootdev"
@ -221,7 +206,7 @@ platform_copy_config() {
bananapi,bpi-r3|\
bananapi,bpi-r3-mini|\
bananapi,bpi-r4)
case "$(platform_get_bootdev)" in
case "$(fitblk_get_bootdev)" in
mmcblk*)
emmc_copy_config
;;

View File

@ -2,7 +2,7 @@ ARCH:=aarch64
SUBTARGET:=filogic
BOARDNAME:=Filogic 8x0 (MT798x)
CPU_TYPE:=cortex-a53
DEFAULT_PACKAGES += kmod-phy-aquantia kmod-crypto-hw-safexcel kmod-mt7915e wpad-openssl uboot-envtools bridger
DEFAULT_PACKAGES += fitblk kmod-phy-aquantia kmod-crypto-hw-safexcel kmod-mt7915e wpad-openssl uboot-envtools bridger
KERNELNAME:=Image dtbs
define Target/Description

View File

@ -249,7 +249,7 @@ define Device/bananapi_bpi-r3
mt7986a-bananapi-bpi-r3-respeaker-2mics
DEVICE_DTS_DIR := $(DTS_DIR)/
DEVICE_DTS_LOADADDR := 0x43f00000
DEVICE_PACKAGES := fitblk kmod-hwmon-pwmfan kmod-i2c-gpio kmod-mt7986-firmware kmod-sfp kmod-usb3 \
DEVICE_PACKAGES := kmod-hwmon-pwmfan kmod-i2c-gpio kmod-mt7986-firmware kmod-sfp kmod-usb3 \
e2fsprogs f2fsck mkf2fs mt7986-wo-firmware automount
IMAGES := sysupgrade.itb
KERNEL_LOADADDR := 0x44000000
@ -302,7 +302,7 @@ define Device/bananapi_bpi-r3-mini
DEVICE_DTS_CONFIG := config-mt7986a-bananapi-bpi-r3-mini
DEVICE_DTS_DIR := ../dts
DEVICE_DTS_LOADADDR := 0x43f00000
DEVICE_PACKAGES := fitblk kmod-hwmon-pwmfan kmod-mt7986-firmware kmod-phy-airoha-en8811h \
DEVICE_PACKAGES := kmod-hwmon-pwmfan kmod-mt7986-firmware kmod-phy-airoha-en8811h \
kmod-usb3 e2fsprogs f2fsck mkf2fs mt7986-wo-firmware automount
KERNEL_LOADADDR := 0x44000000
KERNEL := kernel-bin | gzip
@ -351,7 +351,7 @@ define Device/bananapi_bpi-r4
DEVICE_DTS_LOADADDR := 0x45f00000
DEVICE_DTS_OVERLAY:= mt7988a-bananapi-bpi-r4-emmc mt7988a-bananapi-bpi-r4-rtc mt7988a-bananapi-bpi-r4-sd mt7988a-bananapi-bpi-r4-wifi-mt7996a
DEVICE_DTC_FLAGS := --pad 4096
DEVICE_PACKAGES := fitblk kmod-hwmon-pwmfan kmod-i2c-mux-pca954x kmod-eeprom-at24 kmod-mt7996-firmware \
DEVICE_PACKAGES := kmod-hwmon-pwmfan kmod-i2c-mux-pca954x kmod-eeprom-at24 kmod-mt7996-firmware \
kmod-rtc-pcf8563 kmod-sfp kmod-usb3 e2fsprogs f2fsck mkf2fs
IMAGES := sysupgrade.itb
KERNEL_LOADADDR := 0x46000000

View File

@ -90,7 +90,7 @@ define Device/bananapi_bpi-r64
DEVICE_MODEL := BPi-R64
DEVICE_DTS := mt7622-bananapi-bpi-r64
DEVICE_DTS_OVERLAY := mt7622-bananapi-bpi-r64-pcie1 mt7622-bananapi-bpi-r64-sata
DEVICE_PACKAGES := fitblk kmod-ata-ahci-mtk kmod-btmtkuart kmod-usb3 e2fsprogs mkf2fs f2fsck
DEVICE_PACKAGES := kmod-ata-ahci-mtk kmod-btmtkuart kmod-usb3 e2fsprogs mkf2fs f2fsck
DEVICE_DTC_FLAGS := --pad 4096
DEVICE_DTS_LOADADDR := 0x43f00000
ARTIFACTS := emmc-preloader.bin emmc-bl31-uboot.fip sdcard.img.gz snand-preloader.bin snand-bl31-uboot.fip
@ -256,7 +256,7 @@ define Device/linksys_e8450-ubi
DEVICE_ALT0_VARIANT := UBI
DEVICE_DTS := mt7622-linksys-e8450-ubi
DEVICE_DTS_DIR := ../dts
DEVICE_PACKAGES := fitblk kmod-mt7915-firmware kmod-usb3
DEVICE_PACKAGES := kmod-mt7915-firmware kmod-usb3
UBINIZE_OPTS := -E 5
BLOCKSIZE := 128k
PAGESIZE := 2048
@ -377,7 +377,7 @@ define Device/ubnt_unifi-6-lr-v1-ubootmod
DEVICE_VARIANT := v1 U-Boot mod
DEVICE_DTS := mt7622-ubnt-unifi-6-lr-v1-ubootmod
DEVICE_DTS_DIR := ../dts
DEVICE_PACKAGES := fitblk kmod-mt7915-firmware kmod-leds-ubnt-ledbar
DEVICE_PACKAGES := kmod-mt7915-firmware kmod-leds-ubnt-ledbar
KERNEL := kernel-bin | lzma
KERNEL_INITRAMFS_SUFFIX := -recovery.itb
KERNEL_INITRAMFS := kernel-bin | lzma | fit lzma $$(KDIR)/image-$$(firstword $$(DEVICE_DTS)).dtb with-initrd | pad-to 64k
@ -407,7 +407,7 @@ define Device/ubnt_unifi-6-lr-v2-ubootmod
DEVICE_VARIANT := v2 U-Boot mod
DEVICE_DTS := mt7622-ubnt-unifi-6-lr-v2-ubootmod
DEVICE_DTS_DIR := ../dts
DEVICE_PACKAGES := fitblk kmod-mt7915-firmware
DEVICE_PACKAGES := kmod-mt7915-firmware
KERNEL := kernel-bin | lzma
KERNEL_INITRAMFS_SUFFIX := -recovery.itb
KERNEL_INITRAMFS := kernel-bin | lzma | fit lzma $$(KDIR)/image-$$(firstword $$(DEVICE_DTS)).dtb with-initrd | pad-to 64k
@ -436,7 +436,7 @@ define Device/ubnt_unifi-6-lr-v3-ubootmod
DEVICE_VARIANT := v3 U-Boot mod
DEVICE_DTS := mt7622-ubnt-unifi-6-lr-v3-ubootmod
DEVICE_DTS_DIR := ../dts
DEVICE_PACKAGES := fitblk kmod-mt7915-firmware
DEVICE_PACKAGES := kmod-mt7915-firmware
KERNEL := kernel-bin | lzma
KERNEL_INITRAMFS_SUFFIX := -recovery.itb
KERNEL_INITRAMFS := kernel-bin | lzma | fit lzma $$(KDIR)/image-$$(firstword $$(DEVICE_DTS)).dtb with-initrd | pad-to 64k

View File

@ -1,21 +1,6 @@
REQUIRE_IMAGE_METADATA=1
RAMFS_COPY_BIN='fitblk'
platform_get_bootdev() {
local rootdisk="$(cat /sys/firmware/devicetree/base/chosen/rootdisk)"
local handle bootdev
for handle in /sys/class/block/*/of_node/phandle /sys/class/block/*/device/of_node/phandle; do
[ ! -e "$handle" ] && continue
if [ "$rootdisk" = "$(cat $handle)" ]; then
bootdev="${handle%/of_node/phandle}"
bootdev="${bootdev%/device}"
bootdev="${bootdev#/sys/class/block/}"
echo "$bootdev"
break
fi
done
}
platform_do_upgrade() {
local board=$(board_name)
local file_type=$(identify $1)
@ -28,7 +13,7 @@ platform_do_upgrade() {
ubnt,unifi-6-lr-v3-ubootmod)
[ -e /dev/fit0 ] && fitblk /dev/fit0
[ -e /dev/fitrw ] && fitblk /dev/fitrw
bootdev="$(platform_get_bootdev)"
bootdev="$(fitblk_get_bootdev)"
case "$bootdev" in
mmcblk*)
EMMC_KERN_DEV="/dev/$bootdev"
@ -119,7 +104,7 @@ platform_check_image() {
platform_copy_config() {
case "$(board_name)" in
bananapi,bpi-r64)
if platform_get_bootdev | grep -q mmc; then
if fitblk_get_bootdev | grep -q mmc; then
emmc_copy_config
fi
;;

View File

@ -2,7 +2,7 @@ ARCH:=aarch64
SUBTARGET:=mt7622
BOARDNAME:=MT7622
CPU_TYPE:=cortex-a53
DEFAULT_PACKAGES += kmod-mt7622-firmware wpad-openssl uboot-envtools bridger
DEFAULT_PACKAGES += fitblk kmod-mt7622-firmware wpad-openssl uboot-envtools bridger
KERNELNAME:=Image dtbs
define Target/Description

View File

@ -1,20 +1,5 @@
REQUIRE_IMAGE_METADATA=1
platform_get_bootdev() {
local rootdisk="$(cat /sys/firmware/devicetree/base/chosen/rootdisk)"
local handle bootdev
for handle in /sys/class/block/*/of_node/phandle /sys/class/block/*/device/of_node/phandle; do
[ ! -e "$handle" ] && continue
if [ "$rootdisk" = "$(cat $handle)" ]; then
bootdev="${handle%/of_node/phandle}"
bootdev="${bootdev%/device}"
bootdev="${bootdev#/sys/class/block/}"
echo "$bootdev"
break
fi
done
}
# Legacy full system upgrade including preloader for MediaTek SoCs on eMMC or SD
legacy_mtk_mmc_full_upgrade() {
local diskdev partdev diff oldrecovery
@ -100,7 +85,7 @@ platform_do_upgrade() {
unielec,u7623-02)
[ -e /dev/fit0 ] && fitblk /dev/fit0
[ -e /dev/fitrw ] && fitblk /dev/fitrw
bootdev="$(platform_get_bootdev)"
bootdev="$(fitblk_get_bootdev)"
EMMC_KERN_DEV="/dev/$bootdev"
emmc_do_upgrade "$1"
;;

View File

@ -9,7 +9,7 @@ CPU_TYPE:=cortex-a7
CPU_SUBTYPE:=neon-vfpv4
KERNELNAME:=Image dtbs zImage
FEATURES+=display usbgadget
DEFAULT_PACKAGES+=kmod-crypto-hw-safexcel uboot-envtools
DEFAULT_PACKAGES+=fitblk kmod-crypto-hw-safexcel uboot-envtools
define Target/Description
Build firmware images for MediaTek mt7623 ARM based boards.

View File

@ -104,7 +104,7 @@ define Device/cznic_turris-omnia
DEVICE_PACKAGES := \
mkf2fs e2fsprogs kmod-fs-vfat kmod-nls-cp437 kmod-nls-iso8859-1 \
wpad-basic-openssl kmod-ath9k kmod-ath10k-ct ath10k-firmware-qca988x-ct \
partx-utils kmod-i2c-mux-pca954x kmod-leds-turris-omnia
kmod-mt7915-firmware partx-utils kmod-i2c-mux-pca954x kmod-leds-turris-omnia
IMAGES := sysupgrade.img.gz
IMAGE/sysupgrade.img.gz := boot-scr | boot-img | sdcard-img | gzip | append-metadata
SUPPORTED_DEVICES += armada-385-turris-omnia

View File

@ -1,3 +1,6 @@
From: Felix Fietkau <nbd@nbd.name>
Subject: mvneta: tx queue workaround
The hardware queue scheduling is apparently configured with fixed
priorities, which creates a nasty fairness issue where traffic from one
CPU can starve traffic from all other CPUs.
@ -5,6 +8,8 @@ CPU can starve traffic from all other CPUs.
Work around this issue by forcing all tx packets to go through one CPU,
until this issue is fixed properly.
Ref: https://github.com/openwrt/openwrt/issues/5411
Signed-off-by: Felix Fietkau <nbd@nbd.name>
---
--- a/drivers/net/ethernet/marvell/mvneta.c