diff --git a/backports/0001-build-build-kernel-image-before-building-modules-pac.patch b/backports/0001-build-build-kernel-image-before-building-modules-pac.patch index cf11e3af7..ffe455d14 100644 --- a/backports/0001-build-build-kernel-image-before-building-modules-pac.patch +++ b/backports/0001-build-build-kernel-image-before-building-modules-pac.patch @@ -1,7 +1,7 @@ -From 08be0915e06fb6f2b62c022099e82bb4d849a8c6 Mon Sep 17 00:00:00 2001 +From c51ac602aff1a9b0093687fe39164a3b895fd4a2 Mon Sep 17 00:00:00 2001 From: Felix Fietkau Date: Thu, 22 Oct 2020 10:29:34 +0200 -Subject: [PATCH 1/9] build: build kernel image before building +Subject: [PATCH 01/27] build: build kernel image before building modules/packages This is needed for linux 5.10, where modules.builtin is generated from @@ -13,10 +13,10 @@ Signed-off-by: Felix Fietkau 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/include/kernel-defaults.mk b/include/kernel-defaults.mk -index e5a0ba367b..b069c1e671 100644 +index 3aa1baa761..c02e0d34ca 100644 --- a/include/kernel-defaults.mk +++ b/include/kernel-defaults.mk -@@ -113,7 +113,7 @@ endef +@@ -115,7 +115,7 @@ endef define Kernel/CompileModules/Default rm -f $(LINUX_DIR)/vmlinux $(LINUX_DIR)/System.map @@ -25,7 +25,7 @@ index e5a0ba367b..b069c1e671 100644 endef OBJCOPY_STRIP = -R .reginfo -R .notes -R .note -R .comment -R .mdebug -R .note.gnu.build-id -@@ -137,7 +137,7 @@ endef +@@ -139,7 +139,7 @@ endef define Kernel/CompileImage/Default rm -f $(TARGET_DIR)/init @@ -34,7 +34,7 @@ index e5a0ba367b..b069c1e671 100644 $(call Kernel/CopyImage) endef -@@ -147,7 +147,7 @@ define Kernel/CompileImage/Initramfs +@@ -149,7 +149,7 @@ define Kernel/CompileImage/Initramfs $(CP) $(GENERIC_PLATFORM_DIR)/other-files/init $(TARGET_DIR)/init $(if $(SOURCE_DATE_EPOCH),touch -hcd "@$(SOURCE_DATE_EPOCH)" $(TARGET_DIR)/init) rm -rf $(KERNEL_BUILD_DIR)/linux-$(LINUX_VERSION)/usr/initramfs_data.cpio* diff --git a/backports/0002-build-fix-build-with-CONFIG_STRIP_KERNEL_EXPORTS.patch b/backports/0002-build-fix-build-with-CONFIG_STRIP_KERNEL_EXPORTS.patch index cec74bb0f..39398eee8 100644 --- a/backports/0002-build-fix-build-with-CONFIG_STRIP_KERNEL_EXPORTS.patch +++ b/backports/0002-build-fix-build-with-CONFIG_STRIP_KERNEL_EXPORTS.patch @@ -1,7 +1,7 @@ -From 6d2e2ff2778ca6360af9bf1e712d7ff276afa54b Mon Sep 17 00:00:00 2001 +From 6c50e27b166b30c0b3f7b730717ab4b7f446e4d0 Mon Sep 17 00:00:00 2001 From: Felix Fietkau Date: Wed, 17 Feb 2021 13:49:14 +0100 -Subject: [PATCH 2/9] build: fix build with CONFIG_STRIP_KERNEL_EXPORTS +Subject: [PATCH 02/27] build: fix build with CONFIG_STRIP_KERNEL_EXPORTS Only use symtab.h on the final kernel link @@ -11,7 +11,7 @@ Signed-off-by: Felix Fietkau 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/include/kernel-defaults.mk b/include/kernel-defaults.mk -index b069c1e671..93eed54ae1 100644 +index c02e0d34ca..f9316fc3f9 100644 --- a/include/kernel-defaults.mk +++ b/include/kernel-defaults.mk @@ -3,7 +3,7 @@ @@ -23,7 +23,7 @@ index b069c1e671..93eed54ae1 100644 EXTRA_LDSFLAGS="-I$(KERNEL_BUILD_DIR) -include symtab.h" endif -@@ -137,7 +137,7 @@ endef +@@ -139,7 +139,7 @@ endef define Kernel/CompileImage/Default rm -f $(TARGET_DIR)/init @@ -32,7 +32,7 @@ index b069c1e671..93eed54ae1 100644 $(call Kernel/CopyImage) endef -@@ -147,7 +147,7 @@ define Kernel/CompileImage/Initramfs +@@ -149,7 +149,7 @@ define Kernel/CompileImage/Initramfs $(CP) $(GENERIC_PLATFORM_DIR)/other-files/init $(TARGET_DIR)/init $(if $(SOURCE_DATE_EPOCH),touch -hcd "@$(SOURCE_DATE_EPOCH)" $(TARGET_DIR)/init) rm -rf $(KERNEL_BUILD_DIR)/linux-$(LINUX_VERSION)/usr/initramfs_data.cpio* diff --git a/backports/0003-kernel-add-linux-5.10-support.patch b/backports/0003-kernel-add-linux-5.10-support.patch index d764e2f6d..2221290cc 100644 --- a/backports/0003-kernel-add-linux-5.10-support.patch +++ b/backports/0003-kernel-add-linux-5.10-support.patch @@ -1,7 +1,7 @@ -From 0f37bb5919d96aaca7b0d06b56d37dabba87b190 Mon Sep 17 00:00:00 2001 +From 369794a62050fadc47b617acb29e19d6f536fe3f Mon Sep 17 00:00:00 2001 From: Felix Fietkau Date: Sat, 24 Oct 2020 21:14:16 +0200 -Subject: [PATCH 01/45] kernel: add linux 5.10 support +Subject: [PATCH 03/27] kernel: add linux 5.10 support Signed-off-by: Felix Fietkau --- @@ -422,7 +422,7 @@ Signed-off-by: Felix Fietkau create mode 100644 target/linux/generic/pending-5.10/920-mangle_bootargs.patch diff --git a/include/image-commands.mk b/include/image-commands.mk -index 51e745958e..bddbed6052 100644 +index 4d54a14ba4..2c917d613e 100644 --- a/include/image-commands.mk +++ b/include/image-commands.mk @@ -200,11 +200,12 @@ define Build/fit @@ -744,7 +744,7 @@ index b46fcebc08..e2bb1d0681 100644 AUTOLOAD:=$(call AutoProbe,$(notdir $(NFT_CORE-m))) KCONFIG:= \ diff --git a/package/kernel/linux/modules/usb.mk b/package/kernel/linux/modules/usb.mk -index d050165df3..3dd20a0696 100644 +index 93f99f7cbe..4191590ba7 100644 --- a/package/kernel/linux/modules/usb.mk +++ b/package/kernel/linux/modules/usb.mk @@ -1387,7 +1387,7 @@ define KernelPackage/usb-net-cdc-ncm @@ -12418,10 +12418,10 @@ index 0000000000..4eb5607f17 +# CONFIG_ZSMALLOC is not set +# CONFIG_ZX_TDM is not set diff --git a/target/linux/generic/config-5.4 b/target/linux/generic/config-5.4 -index 91dc0b0f49..d3e9325f71 100644 +index 50e627297e..da0e2e2186 100644 --- a/target/linux/generic/config-5.4 +++ b/target/linux/generic/config-5.4 -@@ -3273,6 +3273,7 @@ CONFIG_MTD_ROOTFS_ROOT_DEV=y +@@ -3287,6 +3287,7 @@ CONFIG_MTD_ROOTFS_ROOT_DEV=y CONFIG_MTD_SPI_NOR_USE_4K_SECTORS_LIMIT=4096 CONFIG_MTD_SPLIT=y # CONFIG_MTD_SPLIT_BCM_WFI_FW is not set diff --git a/backports/0004-mediatek-update-to-latest-trunk-version.patch b/backports/0004-mediatek-update-to-latest-trunk-version.patch index 3ba2f9552..903261b10 100644 --- a/backports/0004-mediatek-update-to-latest-trunk-version.patch +++ b/backports/0004-mediatek-update-to-latest-trunk-version.patch @@ -1,7 +1,7 @@ -From 583b54e2f10ee14b5756d7035e641f7a1bb3095c Mon Sep 17 00:00:00 2001 +From 29f60bb65745d63e7d8cce273bd3f773fda251ff Mon Sep 17 00:00:00 2001 From: Felix Fietkau Date: Thu, 9 Apr 2020 09:53:24 +0200 -Subject: [PATCH 01/43] mediatek: update to latest trunk version +Subject: [PATCH 04/27] mediatek: update to latest trunk version Signed-off-by: Felix Fietkau --- @@ -101957,7 +101957,7 @@ diff --git a/target/linux/mediatek/mt7622/config-5.4 b/target/linux/mediatek/mt7 similarity index 67% rename from target/linux/mediatek/mt7622/config-5.4 rename to target/linux/mediatek/mt7622/config-5.10 -index b873bdc40c..2d7f82ce23 100644 +index 282cd0bab5..e6696bd50a 100644 --- a/target/linux/mediatek/mt7622/config-5.4 +++ b/target/linux/mediatek/mt7622/config-5.10 @@ -1,59 +1,6 @@ @@ -102116,7 +102116,7 @@ index b873bdc40c..2d7f82ce23 100644 # CONFIG_FUJITSU_ERRATUM_010001 is not set CONFIG_FW_LOADER_PAGED_BUF=y CONFIG_GENERIC_ALLOCATOR=y -@@ -267,102 +201,19 @@ CONFIG_GLOB=y +@@ -267,103 +201,20 @@ CONFIG_GLOB=y CONFIG_GPIOLIB=y CONFIG_GRO_CELLS=y CONFIG_HANDLE_DOMAIN_IRQ=y @@ -102184,6 +102184,7 @@ index b873bdc40c..2d7f82ce23 100644 -CONFIG_HAVE_UID16=y -CONFIG_HAVE_VIRT_CPU_ACCOUNTING_GEN=y CONFIG_HOLES_IN_ZONE=y + # CONFIG_HW_RANDOM_MTK is not set CONFIG_HZ=250 CONFIG_HZ_250=y -CONFIG_I2C=y @@ -102219,7 +102220,7 @@ index b873bdc40c..2d7f82ce23 100644 CONFIG_IO_URING=y CONFIG_IRQCHIP=y CONFIG_IRQ_DOMAIN=y -@@ -370,9 +221,10 @@ CONFIG_IRQ_DOMAIN_HIERARCHY=y +@@ -371,9 +222,10 @@ CONFIG_IRQ_DOMAIN_HIERARCHY=y CONFIG_IRQ_FORCED_THREADING=y CONFIG_IRQ_TIME_ACCOUNTING=y CONFIG_IRQ_WORK=y @@ -102231,7 +102232,7 @@ index b873bdc40c..2d7f82ce23 100644 CONFIG_LOCK_DEBUGGING_SUPPORT=y CONFIG_LOCK_SPIN_ON_OWNER=y CONFIG_LZO_COMPRESS=y -@@ -380,21 +232,25 @@ CONFIG_LZO_DECOMPRESS=y +@@ -381,21 +233,25 @@ CONFIG_LZO_DECOMPRESS=y CONFIG_MAGIC_SYSRQ=y CONFIG_MDIO_BUS=y CONFIG_MDIO_DEVICE=y @@ -102259,7 +102260,7 @@ index b873bdc40c..2d7f82ce23 100644 CONFIG_MTD_RAW_NAND=y CONFIG_MTD_SPI_NAND=y CONFIG_MTD_SPI_NOR=y -@@ -422,7 +278,6 @@ CONFIG_NET_DSA=y +@@ -423,7 +279,6 @@ CONFIG_NET_DSA=y CONFIG_NET_DSA_MT7530=y CONFIG_NET_DSA_TAG_MTK=y CONFIG_NET_FLOW_LIMIT=y @@ -102267,7 +102268,7 @@ index b873bdc40c..2d7f82ce23 100644 CONFIG_NET_MEDIATEK_SOC=y CONFIG_NET_SWITCHDEV=y CONFIG_NET_VENDOR_MEDIATEK=y -@@ -447,7 +302,6 @@ CONFIG_PARTITION_PERCPU=y +@@ -448,7 +303,6 @@ CONFIG_PARTITION_PERCPU=y CONFIG_PCI=y CONFIG_PCIEAER=y CONFIG_PCIEASPM=y @@ -102275,7 +102276,7 @@ index b873bdc40c..2d7f82ce23 100644 # CONFIG_PCIEASPM_DEFAULT is not set CONFIG_PCIEASPM_PERFORMANCE=y # CONFIG_PCIEASPM_POWERSAVE is not set -@@ -460,6 +314,7 @@ CONFIG_PCI_DOMAINS=y +@@ -461,6 +315,7 @@ CONFIG_PCI_DOMAINS=y CONFIG_PCI_DOMAINS_GENERIC=y CONFIG_PCI_MSI=y CONFIG_PCI_MSI_IRQ_DOMAIN=y @@ -102283,7 +102284,7 @@ index b873bdc40c..2d7f82ce23 100644 CONFIG_PGTABLE_LEVELS=3 CONFIG_PHYLIB=y CONFIG_PHYLINK=y -@@ -477,7 +332,7 @@ CONFIG_PINCTRL_MT7622=y +@@ -478,7 +333,7 @@ CONFIG_PINCTRL_MT7622=y CONFIG_PINCTRL_MT8516=y CONFIG_PINCTRL_MTK=y CONFIG_PINCTRL_MTK_MOORE=y @@ -102292,7 +102293,7 @@ index b873bdc40c..2d7f82ce23 100644 CONFIG_PM=y CONFIG_PM_CLK=y CONFIG_PM_GENERIC_DOMAINS=y -@@ -487,6 +342,20 @@ CONFIG_POWER_RESET=y +@@ -488,6 +343,20 @@ CONFIG_POWER_RESET=y CONFIG_POWER_RESET_SYSCON=y CONFIG_POWER_SUPPLY=y CONFIG_PRINTK_TIME=y @@ -102313,7 +102314,7 @@ index b873bdc40c..2d7f82ce23 100644 CONFIG_PWM=y CONFIG_PWM_MEDIATEK=y # CONFIG_PWM_MTK_DISP is not set -@@ -499,7 +368,9 @@ CONFIG_RATIONAL=y +@@ -500,7 +369,9 @@ CONFIG_RATIONAL=y CONFIG_RCU_NEED_SEGCBLIST=y CONFIG_RCU_STALL_COMMON=y CONFIG_REALTEK_PHY=y @@ -102324,7 +102325,7 @@ index b873bdc40c..2d7f82ce23 100644 CONFIG_REGMAP=y CONFIG_REGMAP_MMIO=y CONFIG_REGULATOR=y -@@ -552,7 +423,6 @@ CONFIG_THERMAL_EMERGENCY_POWEROFF_DELAY_MS=0 +@@ -555,7 +426,6 @@ CONFIG_THERMAL_EMERGENCY_POWEROFF_DELAY_MS=0 CONFIG_THERMAL_EMULATION=y CONFIG_THERMAL_GOV_BANG_BANG=y CONFIG_THERMAL_GOV_FAIR_SHARE=y @@ -102332,7 +102333,7 @@ index b873bdc40c..2d7f82ce23 100644 CONFIG_THERMAL_GOV_STEP_WISE=y CONFIG_THERMAL_GOV_USER_SPACE=y CONFIG_THERMAL_OF=y -@@ -584,6 +454,9 @@ CONFIG_WATCHDOG_PRETIMEOUT_GOV_PANIC=y +@@ -587,6 +457,9 @@ CONFIG_WATCHDOG_PRETIMEOUT_GOV_PANIC=y CONFIG_WATCHDOG_PRETIMEOUT_GOV_SEL=m CONFIG_WATCHDOG_SYSFS=y CONFIG_XPS=y diff --git a/backports/0005-sysupgrade-nand-allow-limiting-rootfs_data-by-settin.patch b/backports/0005-sysupgrade-nand-allow-limiting-rootfs_data-by-settin.patch index aa55f8c21..0bdfc3078 100644 --- a/backports/0005-sysupgrade-nand-allow-limiting-rootfs_data-by-settin.patch +++ b/backports/0005-sysupgrade-nand-allow-limiting-rootfs_data-by-settin.patch @@ -1,7 +1,7 @@ -From 0a0953b5c81a2b5b366a3f0f543db71ffc81f713 Mon Sep 17 00:00:00 2001 +From 7ed003d57f1c5273fecddabcdc7bd6845c3854a0 Mon Sep 17 00:00:00 2001 From: John Crispin Date: Sat, 20 Feb 2021 08:36:43 +0100 -Subject: [PATCH 5/9] sysupgrade-nand: allow limiting rootfs_data by setting +Subject: [PATCH 05/27] sysupgrade-nand: allow limiting rootfs_data by setting env variable Check if firmware environment variable 'rootfs_data_max' exists and is diff --git a/backports/0006-uboot-mediatek-add-support-for-linksys-e8450.patch b/backports/0006-uboot-mediatek-add-support-for-linksys-e8450.patch index f717cae77..30a694799 100644 --- a/backports/0006-uboot-mediatek-add-support-for-linksys-e8450.patch +++ b/backports/0006-uboot-mediatek-add-support-for-linksys-e8450.patch @@ -1,7 +1,7 @@ -From eed2e31cb32b565a3ebcc3bc2e9d7dc7a9550b4b Mon Sep 17 00:00:00 2001 +From 3c6515c9db444da27192c1182fa1e9ab8ba6e2f6 Mon Sep 17 00:00:00 2001 From: Daniel Golle Date: Sat, 30 Jan 2021 13:58:16 +0000 -Subject: [PATCH 01/36] uboot-mediatek: add support for linksys e8450 +Subject: [PATCH 06/27] uboot-mediatek: add support for linksys e8450 Build U-Boot for the Linksys E8450 in order to have support for UBI. The loader has a default environment with scripts handling the reset diff --git a/backports/0007-uboot-envtools-add-defaults-for-linksys-e8450-ubi.patch b/backports/0007-uboot-envtools-add-defaults-for-linksys-e8450-ubi.patch index 55f81b79b..462d6890e 100644 --- a/backports/0007-uboot-envtools-add-defaults-for-linksys-e8450-ubi.patch +++ b/backports/0007-uboot-envtools-add-defaults-for-linksys-e8450-ubi.patch @@ -1,7 +1,7 @@ -From 256daf33ec9c8cc8b094d7612ba7384db18d0a6b Mon Sep 17 00:00:00 2001 +From 1a9921bab861dd2c89337c3e4833c716a0474653 Mon Sep 17 00:00:00 2001 From: Daniel Golle Date: Fri, 12 Feb 2021 03:09:39 +0000 -Subject: [PATCH 04/64] uboot-envtools: add defaults for linksys-e8450-ubi +Subject: [PATCH 07/27] uboot-envtools: add defaults for linksys-e8450-ubi Add U-Boot environment configuration for the Linksys E8450 (UBI) to allow access to the bootloader environment from OpenWrt via diff --git a/backports/0008-realtek-update-to-latest-owrt-HEAD.patch b/backports/0008-realtek-update-to-latest-owrt-HEAD.patch index 138fb1532..b995a42c2 100644 --- a/backports/0008-realtek-update-to-latest-owrt-HEAD.patch +++ b/backports/0008-realtek-update-to-latest-owrt-HEAD.patch @@ -1,24 +1,31 @@ -From bbaaab1515cc5abbe0ebcbbc05ff6e29f98867a0 Mon Sep 17 00:00:00 2001 +From 0b769e318e332d3bf8c7ab68b492cdc90dcb8e18 Mon Sep 17 00:00:00 2001 From: John Crispin -Date: Tue, 16 Mar 2021 10:46:51 +0100 -Subject: [PATCH 01/59] realtek: update to latest owrt HEAD +Date: Sat, 4 Sep 2021 05:42:30 +0200 +Subject: [PATCH 08/27] realtek: update to latest owrt HEAD Signed-off-by: John Crispin --- - package/boot/uboot-envtools/files/realtek | 7 + .../realtek/base-files/etc/board.d/01_leds | 1 - .../realtek/base-files/etc/board.d/02_network | 12 +- - target/linux/realtek/config-5.4 | 33 +- - .../realtek/dts/rtl8380_zyxel_gs1900-10hp.dts | 20 +- - .../dts/rtl8392_edgecore_ecs4100-12ph.dts | 297 ++ + .../lib/preinit/05_set_preinit_iface_realtek | 13 - + .../lib/preinit/98_remove_preinit_realtek | 6 - + target/linux/realtek/config-5.4 | 30 +- + .../realtek/dts/rtl8380_netgear_gigabit.dtsi | 11 +- + .../realtek/dts/rtl8380_zyxel_gs1900-10hp.dts | 4 +- + .../realtek/dts/rtl8380_zyxel_gs1900-8.dts | 12 - + .../realtek/dts/rtl8380_zyxel_gs1900.dtsi | 1 + + .../dts/rtl8382_allnet_all-sg8208m.dts | 1 + + .../dts/rtl8382_d-link_dgs-1210-10p.dts | 1 + + .../realtek/dts/rtl8382_d-link_dgs-1210.dtsi | 1 + + .../dts/rtl8392_edgecore_ecs4100-12ph.dts | 301 ++ target/linux/realtek/dts/rtl839x.dtsi | 197 ++ .../include/asm/mach-rtl838x/mach-rtl83xx.h | 30 +- .../files-5.4/drivers/gpio/gpio-rtl838x.c | 119 +- .../files-5.4/drivers/net/dsa/rtl83xx/Kconfig | 2 +- .../drivers/net/dsa/rtl83xx/Makefile | 2 +- - .../drivers/net/dsa/rtl83xx/common.c | 1076 +++++- + .../drivers/net/dsa/rtl83xx/common.c | 1065 +++++- .../drivers/net/dsa/rtl83xx/debugfs.c | 392 ++- - .../files-5.4/drivers/net/dsa/rtl83xx/dsa.c | 1397 ++++++-- + .../files-5.4/drivers/net/dsa/rtl83xx/dsa.c | 1363 +++++-- .../drivers/net/dsa/rtl83xx/rtl838x.c | 1749 ++++++++- .../drivers/net/dsa/rtl83xx/rtl838x.h | 472 --- .../drivers/net/dsa/rtl83xx/rtl839x.c | 1617 ++++++++- @@ -26,15 +33,14 @@ Signed-off-by: John Crispin .../drivers/net/dsa/rtl83xx/rtl930x.c | 2065 ++++++++++- .../drivers/net/dsa/rtl83xx/rtl931x.c | 191 +- .../files-5.4/drivers/net/dsa/rtl83xx/tc.c | 406 +++ - .../drivers/net/ethernet/rtl838x_eth.c | 380 +- + .../drivers/net/ethernet/rtl838x_eth.c | 352 +- .../drivers/net/ethernet/rtl838x_eth.h | 3 +- .../files-5.4/drivers/net/phy/rtl83xx-phy.c | 1078 ++++-- .../realtek/files-5.4/include/linux/rtl838x.h | 1072 ++++++ .../realtek/files-5.4/net/dsa/tag_rtl83xx.c | 119 + - target/linux/realtek/image/Makefile | 9 + + target/linux/realtek/image/Makefile | 44 +- .../realtek/patches-5.4/100-dsa-lag.patch | 3123 +++++++++++++++++ .../realtek/patches-5.4/101-brflood-api.patch | 817 +++++ - .../300-mips-add-rtl838x-platform.patch | 2 +- ...0-gpio-Add-Realtek-Otto-GPIO-support.patch | 405 +++ ...nclude-linux-add-phy-ops-for-rtl838x.patch | 2 +- ...04-include-linux-add-phy-hsgmii-mode.patch | 19 + @@ -45,7 +51,10 @@ Signed-off-by: John Crispin .../realtek/patches-5.4/710-adt7470.patch | 20 + .../realtek/patches-5.4/711-ec4100.patch | 150 + .../linux/realtek/patches-5.4/712-fixes.patch | 23 + - 40 files changed, 16304 insertions(+), 1597 deletions(-) + 46 files changed, 16262 insertions(+), 1623 deletions(-) + delete mode 100644 target/linux/realtek/base-files/lib/preinit/05_set_preinit_iface_realtek + delete mode 100644 target/linux/realtek/base-files/lib/preinit/98_remove_preinit_realtek + delete mode 100644 target/linux/realtek/dts/rtl8380_zyxel_gs1900-8.dts create mode 100644 target/linux/realtek/dts/rtl8392_edgecore_ecs4100-12ph.dts create mode 100644 target/linux/realtek/dts/rtl839x.dtsi delete mode 100644 target/linux/realtek/files-5.4/drivers/net/dsa/rtl83xx/rtl838x.h @@ -64,29 +73,6 @@ Signed-off-by: John Crispin create mode 100644 target/linux/realtek/patches-5.4/711-ec4100.patch create mode 100644 target/linux/realtek/patches-5.4/712-fixes.patch -diff --git a/package/boot/uboot-envtools/files/realtek b/package/boot/uboot-envtools/files/realtek -index cce0628ffc..a4b7089d62 100644 ---- a/package/boot/uboot-envtools/files/realtek -+++ b/package/boot/uboot-envtools/files/realtek -@@ -11,11 +11,18 @@ case "$board" in - d-link,dgs-1210-16|\ - d-link,dgs-1210-28|\ - d-link,dgs-1210-10p|\ -+zyxel,gs1900-8hp-v1|\ -+zyxel,gs1900-8hp-v2|\ - zyxel,gs1900-10hp) - idx="$(find_mtd_index u-boot-env)" - [ -n "$idx" ] && \ - ubootenv_add_uci_config "/dev/mtd$idx" "0x0" "0x400" "0x10000" - ;; -+edgecore,ecs4100-12ph) -+ idx="$(find_mtd_index u-boot-env)" -+ [ -n "$idx" ] && \ -+ ubootenv_add_uci_config "/dev/mtd$idx" "0x0" "0x20000" "0x10000" -+ ;; - *) - idx="$(find_mtd_index u-boot-env)" - [ -n "$idx" ] && \ diff --git a/target/linux/realtek/base-files/etc/board.d/01_leds b/target/linux/realtek/base-files/etc/board.d/01_leds index 699ab817dd..36ca01a696 100755 --- a/target/linux/realtek/base-files/etc/board.d/01_leds @@ -98,7 +84,7 @@ index 699ab817dd..36ca01a696 100755 board=$(board_name) diff --git a/target/linux/realtek/base-files/etc/board.d/02_network b/target/linux/realtek/base-files/etc/board.d/02_network -index 2568fd2e0e..7a53e2ca9e 100755 +index 45ab84ee9e..7a53e2ca9e 100755 --- a/target/linux/realtek/base-files/etc/board.d/02_network +++ b/target/linux/realtek/base-files/etc/board.d/02_network @@ -19,12 +19,11 @@ board=$(board_name) @@ -112,7 +98,7 @@ index 2568fd2e0e..7a53e2ca9e 100755 done ucidef_set_bridge_device switch ucidef_set_interface_wan "$lan_list" --ucidef_set_interface "lan" ifname "lan1:t" protocol "static" vlan 100 +-ucidef_set_interface "lan" device "lan1:t" protocol "static" vlan 100 lan_mac="" wan_mac="" @@ -141,8 +127,39 @@ index 2568fd2e0e..7a53e2ca9e 100755 netgear,gs110tpp-v1) ucidef_set_poe 130 "$lan_list" ;; +diff --git a/target/linux/realtek/base-files/lib/preinit/05_set_preinit_iface_realtek b/target/linux/realtek/base-files/lib/preinit/05_set_preinit_iface_realtek +deleted file mode 100644 +index e2a7cf5a69..0000000000 +--- a/target/linux/realtek/base-files/lib/preinit/05_set_preinit_iface_realtek ++++ /dev/null +@@ -1,13 +0,0 @@ +-set_preinit_iface() { +- +- # Create a switch on lan1 to configure the VLAN 1. +- # Without configuring VLAN ID 1 RTL8380 - RTL9300 will not +- # forward packets. +- ip link add name switch type bridge vlan_filtering 1 +- ip link set dev lan1 master switch +- ip link set lan1 up +- +- pi_ifname=switch +-} +- +-boot_hook_add preinit_main set_preinit_iface +diff --git a/target/linux/realtek/base-files/lib/preinit/98_remove_preinit_realtek b/target/linux/realtek/base-files/lib/preinit/98_remove_preinit_realtek +deleted file mode 100644 +index dc5fdb059b..0000000000 +--- a/target/linux/realtek/base-files/lib/preinit/98_remove_preinit_realtek ++++ /dev/null +@@ -1,6 +0,0 @@ +-remove_switch() { +- # delete switch created in 05_set_preinit_iface_realtek again +- ip link del name switch +-} +- +-boot_hook_add preinit_main remove_switch diff --git a/target/linux/realtek/config-5.4 b/target/linux/realtek/config-5.4 -index 2fbd904376..ced5d5f7ae 100644 +index 51025d5d89..ced5d5f7ae 100644 --- a/target/linux/realtek/config-5.4 +++ b/target/linux/realtek/config-5.4 @@ -2,17 +2,18 @@ CONFIG_ARCH_32BIT_OFF_T=y @@ -193,14 +210,7 @@ index 2fbd904376..ced5d5f7ae 100644 CONFIG_GRO_CELLS=y CONFIG_HANDLE_DOMAIN_IRQ=y CONFIG_HARDWARE_WATCHPOINTS=y -@@ -82,12 +81,14 @@ CONFIG_HAS_DMA=y - CONFIG_HAS_IOMEM=y - CONFIG_HAS_IOPORT_MAP=y - # CONFIG_HIGH_RES_TIMERS is not set -+CONFIG_HWMON=y - CONFIG_HZ=250 - CONFIG_HZ_250=y - CONFIG_HZ_PERIODIC=y +@@ -89,6 +88,7 @@ CONFIG_HZ_PERIODIC=y CONFIG_I2C=y CONFIG_I2C_ALGOBIT=y CONFIG_I2C_BOARDINFO=y @@ -208,12 +218,7 @@ index 2fbd904376..ced5d5f7ae 100644 CONFIG_I2C_GPIO=y CONFIG_INITRAMFS_SOURCE="" CONFIG_IRQCHIP=y -@@ -101,10 +102,13 @@ CONFIG_LEGACY_PTYS=y - CONFIG_LEGACY_PTY_COUNT=256 - CONFIG_LIBFDT=y - CONFIG_LOCK_DEBUGGING_SUPPORT=y -+CONFIG_MARVELL_PHY=y - CONFIG_MDIO_BUS=y +@@ -107,6 +107,8 @@ CONFIG_MDIO_BUS=y CONFIG_MDIO_DEVICE=y CONFIG_MDIO_I2C=y CONFIG_MEMFD_CREATE=y @@ -222,7 +227,7 @@ index 2fbd904376..ced5d5f7ae 100644 CONFIG_MFD_SYSCON=y CONFIG_MIGRATION=y CONFIG_MIPS=y -@@ -136,7 +140,7 @@ CONFIG_NEED_PER_CPU_KM=y +@@ -138,7 +140,7 @@ CONFIG_NEED_PER_CPU_KM=y CONFIG_NET_DEVLINK=y CONFIG_NET_DSA=y CONFIG_NET_DSA_RTL83XX=y @@ -231,12 +236,12 @@ index 2fbd904376..ced5d5f7ae 100644 CONFIG_NET_RTL838X=y CONFIG_NET_SWITCHDEV=y CONFIG_NO_GENERIC_PCI_IOPORT_MAP=y -@@ -159,11 +163,17 @@ CONFIG_PINCTRL=y +@@ -161,12 +163,17 @@ CONFIG_PINCTRL=y CONFIG_POWER_RESET=y CONFIG_POWER_RESET_SYSCON=y CONFIG_PSB6970_PHY=y +CONFIG_RATIONAL=y -+CONFIG_REALTEK_PHY=y + CONFIG_REALTEK_PHY=y +CONFIG_REALTEK_SOC_PHY=y CONFIG_REGMAP=y +CONFIG_REGMAP_I2C=y @@ -249,7 +254,7 @@ index 2fbd904376..ced5d5f7ae 100644 CONFIG_SERIAL_MCTRL_GPIO=y CONFIG_SERIAL_OF_PLATFORM=y CONFIG_SFP=y -@@ -172,7 +182,7 @@ CONFIG_SPI_MASTER=y +@@ -175,7 +182,7 @@ CONFIG_SPI_MASTER=y CONFIG_SPI_MEM=y CONFIG_SPI_RTL838X=y CONFIG_SRCU=y @@ -258,7 +263,7 @@ index 2fbd904376..ced5d5f7ae 100644 CONFIG_SWPHY=y CONFIG_SYSCTL_EXCEPTION_TRACE=y CONFIG_SYS_HAS_CPU_MIPS32_R1=y -@@ -184,8 +194,11 @@ CONFIG_SYS_SUPPORTS_BIG_ENDIAN=y +@@ -187,8 +194,11 @@ CONFIG_SYS_SUPPORTS_BIG_ENDIAN=y CONFIG_SYS_SUPPORTS_MIPS16=y CONFIG_TARGET_ISA_REV=2 CONFIG_TICK_CPU_ACCOUNTING=y @@ -270,50 +275,141 @@ index 2fbd904376..ced5d5f7ae 100644 +CONFIG_WATCHDOG_CORE=y CONFIG_ZLIB_DEFLATE=y CONFIG_ZLIB_INFLATE=y +diff --git a/target/linux/realtek/dts/rtl8380_netgear_gigabit.dtsi b/target/linux/realtek/dts/rtl8380_netgear_gigabit.dtsi +index 0d34ca5dc2..2cda3c15a3 100644 +--- a/target/linux/realtek/dts/rtl8380_netgear_gigabit.dtsi ++++ b/target/linux/realtek/dts/rtl8380_netgear_gigabit.dtsi +@@ -47,30 +47,31 @@ + #size-cells = <1>; + + partition@0 { +- label = "u-boot"; ++ label = "loader"; + reg = <0x0000000 0x00e0000>; + read-only; + }; + + partition@e0000 { +- label = "u-boot-env"; ++ label = "bdinfo"; + reg = <0x00e0000 0x0010000>; + read-only; + }; + + partition@f0000 { +- label = "u-boot-env2"; ++ label = "sysinfo"; + reg = <0x00f0000 0x0010000>; ++ read-only; + }; + + partition@100000 { +- label = "jffs"; ++ label = "jffs2_cfg"; + reg = <0x0100000 0x0100000>; + read-only; + }; + + partition@200000 { +- label = "jffs2"; ++ label = "jffs2_log"; + reg = <0x0200000 0x0100000>; + read-only; + }; diff --git a/target/linux/realtek/dts/rtl8380_zyxel_gs1900-10hp.dts b/target/linux/realtek/dts/rtl8380_zyxel_gs1900-10hp.dts -index 92d0e25fc4..a590450055 100644 +index c16028788e..a590450055 100644 --- a/target/linux/realtek/dts/rtl8380_zyxel_gs1900-10hp.dts +++ b/target/linux/realtek/dts/rtl8380_zyxel_gs1900-10hp.dts -@@ -55,29 +55,17 @@ - port@24 { - reg = <24>; - label = "lan9"; -- phy-mode = "rgmii-id"; -- phy-handle = <&phy24>; -+ phy-mode = "1000base-x"; -+ managed = "in-band-status"; - sfp = <&sfp0>; -- -- fixed-link { -- speed = <1000>; -- full-duplex; -- pause; -- }; - }; - - port@26 { - reg = <26>; - label = "lan10"; -- phy-mode = "rgmii-id"; -- phy-handle = <&phy26>; -+ phy-mode = "1000base-x"; -+ managed = "in-band-status"; - sfp = <&sfp1>; -- -- fixed-link { -- speed = <1000>; -- full-duplex; -- pause; -- }; - }; +@@ -17,7 +17,7 @@ }; - }; + + sfp0: sfp-p9 { +- compatible = "sff,sfp"; ++ compatible = "_sff,sfp"; + i2c-bus = <&i2c0>; + los-gpio = <&gpio1 27 GPIO_ACTIVE_HIGH>; + tx-fault-gpio = <&gpio1 22 GPIO_ACTIVE_HIGH>; +@@ -36,7 +36,7 @@ + }; + + sfp1: sfp-p10 { +- compatible = "sff,sfp"; ++ compatible = "_sff,sfp"; + i2c-bus = <&i2c1>; + los-gpio = <&gpio1 33 GPIO_ACTIVE_HIGH>; + tx-fault-gpio = <&gpio1 28 GPIO_ACTIVE_HIGH>; +diff --git a/target/linux/realtek/dts/rtl8380_zyxel_gs1900-8.dts b/target/linux/realtek/dts/rtl8380_zyxel_gs1900-8.dts +deleted file mode 100644 +index e9c5efe603..0000000000 +--- a/target/linux/realtek/dts/rtl8380_zyxel_gs1900-8.dts ++++ /dev/null +@@ -1,12 +0,0 @@ +-// SPDX-License-Identifier: GPL-2.0-or-later +- +-#include "rtl8380_zyxel_gs1900.dtsi" +- +-/ { +- compatible = "zyxel,gs1900-8", "realtek,rtl838x-soc"; +- model = "ZyXEL GS1900-8 Switch"; +-}; +- +-&gpio1 { +- /delete-node/ poe_enable; +-}; +diff --git a/target/linux/realtek/dts/rtl8380_zyxel_gs1900.dtsi b/target/linux/realtek/dts/rtl8380_zyxel_gs1900.dtsi +index d61ac3b2b8..c4441ec30e 100644 +--- a/target/linux/realtek/dts/rtl8380_zyxel_gs1900.dtsi ++++ b/target/linux/realtek/dts/rtl8380_zyxel_gs1900.dtsi +@@ -79,6 +79,7 @@ + partition@50000 { + label = "u-boot-env2"; + reg = <0x50000 0x10000>; ++ read-only; + }; + partition@60000 { + label = "jffs"; +diff --git a/target/linux/realtek/dts/rtl8382_allnet_all-sg8208m.dts b/target/linux/realtek/dts/rtl8382_allnet_all-sg8208m.dts +index fdcc01fdac..681d699e8a 100644 +--- a/target/linux/realtek/dts/rtl8382_allnet_all-sg8208m.dts ++++ b/target/linux/realtek/dts/rtl8382_allnet_all-sg8208m.dts +@@ -79,6 +79,7 @@ + partition@90000 { + label = "u-boot-env2"; + reg = <0x90000 0x10000>; ++ read-only; + }; + + partition@a0000 { +diff --git a/target/linux/realtek/dts/rtl8382_d-link_dgs-1210-10p.dts b/target/linux/realtek/dts/rtl8382_d-link_dgs-1210-10p.dts +index e2f5e7a4c0..a2ebdad11b 100644 +--- a/target/linux/realtek/dts/rtl8382_d-link_dgs-1210-10p.dts ++++ b/target/linux/realtek/dts/rtl8382_d-link_dgs-1210-10p.dts +@@ -77,6 +77,7 @@ + partition@c0000 { + label = "u-boot-env2"; + reg = <0x000c0000 0x40000>; ++ read-only; + }; + partition@280000 { + label = "firmware"; +diff --git a/target/linux/realtek/dts/rtl8382_d-link_dgs-1210.dtsi b/target/linux/realtek/dts/rtl8382_d-link_dgs-1210.dtsi +index a14738c8a9..e41c6f9f22 100644 +--- a/target/linux/realtek/dts/rtl8382_d-link_dgs-1210.dtsi ++++ b/target/linux/realtek/dts/rtl8382_d-link_dgs-1210.dtsi +@@ -61,6 +61,7 @@ + partition@c0000 { + label = "u-boot-env2"; + reg = <0x000c0000 0x40000>; ++ read-only; + }; + partition@280000 { + label = "firmware"; diff --git a/target/linux/realtek/dts/rtl8392_edgecore_ecs4100-12ph.dts b/target/linux/realtek/dts/rtl8392_edgecore_ecs4100-12ph.dts new file mode 100644 -index 0000000000..7b7b39f417 +index 0000000000..7de5c5f053 --- /dev/null +++ b/target/linux/realtek/dts/rtl8392_edgecore_ecs4100-12ph.dts -@@ -0,0 +1,297 @@ +@@ -0,0 +1,301 @@ +// SPDX-License-Identifier: GPL-2.0-or-later + +#include "rtl839x.dtsi" @@ -492,11 +588,15 @@ index 0000000000..7b7b39f417 + reg = <0x100000 0x100000>; + read-only; + }; -+ partition@b260000 { ++ partition@200000 { + label = "firmware"; -+ reg = <0x200000 0xe00000>; ++ reg = <0x200000 0xdf0000>; + compatible = "openwrt,uimage", "denx,uimage"; + }; ++ partition@ff0000 { ++ label = "certificates"; ++ reg = <0xff0000 0x10000>; ++ }; + }; + }; +}; @@ -1086,7 +1186,7 @@ index 016184c3d9..8752c79700 100644 - rtl838x.o rtl839x.o rtl930x.o rtl931x.o debugfs.o qos.o + rtl838x.o rtl839x.o rtl930x.o rtl931x.o debugfs.o qos.o tc.o diff --git a/target/linux/realtek/files-5.4/drivers/net/dsa/rtl83xx/common.c b/target/linux/realtek/files-5.4/drivers/net/dsa/rtl83xx/common.c -index 698f2892ea..f16bdb998e 100644 +index 6940afa7f2..f16bdb998e 100644 --- a/target/linux/realtek/files-5.4/drivers/net/dsa/rtl83xx/common.c +++ b/target/linux/realtek/files-5.4/drivers/net/dsa/rtl83xx/common.c @@ -2,6 +2,11 @@ @@ -1205,15 +1305,11 @@ index 698f2892ea..f16bdb998e 100644 } /* Disable MAC polling the PHY so that we can start configuration */ -@@ -368,29 +349,22 @@ static int __init rtl83xx_mdio_probe(struct rtl838x_switch_priv *priv) - - /* Enable PHY control via SoC */ +@@ -370,27 +351,20 @@ static int __init rtl83xx_mdio_probe(struct rtl838x_switch_priv *priv) if (priv->family_id == RTL8380_FAMILY_ID) { -- /* Enable PHY control via SoC */ -- sw_w32_mask(0, BIT(15), RTL838X_SMI_GLB_CTRL); + /* Enable SerDes NWAY and PHY control via SoC */ + sw_w32_mask(BIT(7), BIT(15), RTL838X_SMI_GLB_CTRL); - } else { -+ /* Enable SerDes NWAY and PHY control via SoC */ -+ sw_w32_mask(BIT(7), BIT(15), RTL838X_SMI_GLB_CTRL); + } else if (priv->family_id == RTL8390_FAMILY_ID) { /* Disable PHY polling via SoC */ sw_w32_mask(BIT(7), 0, RTL839X_SMI_GLB_CTRL); @@ -1507,7 +1603,7 @@ index 698f2892ea..f16bdb998e 100644 break; } -@@ -550,12 +707,712 @@ static int rtl83xx_netdevice_event(struct notifier_block *this, +@@ -550,6 +707,707 @@ static int rtl83xx_netdevice_event(struct notifier_block *this, return NOTIFY_DONE; } @@ -2215,13 +2311,7 @@ index 698f2892ea..f16bdb998e 100644 static int __init rtl83xx_sw_probe(struct platform_device *pdev) { int err = 0, i; - struct rtl838x_switch_priv *priv; - struct device *dev = &pdev->dev; -- u64 irq_mask; - u64 bpdu_mask; - - pr_debug("Probing RTL838X switch device\n"); -@@ -571,19 +1428,24 @@ static int __init rtl83xx_sw_probe(struct platform_device *pdev) +@@ -570,19 +1428,24 @@ static int __init rtl83xx_sw_probe(struct platform_device *pdev) if (!priv) return -ENOMEM; @@ -2248,7 +2338,7 @@ index 698f2892ea..f16bdb998e 100644 priv->ds->ops = &rtl83xx_switch_ops; priv->cpu_port = RTL838X_CPU_PORT; priv->port_mask = 0x1f; -@@ -592,10 +1454,14 @@ static int __init rtl83xx_sw_probe(struct platform_device *pdev) +@@ -591,10 +1454,14 @@ static int __init rtl83xx_sw_probe(struct platform_device *pdev) priv->r = &rtl838x_reg; priv->ds->num_ports = 29; priv->fib_entries = 8192; @@ -2264,7 +2354,7 @@ index 698f2892ea..f16bdb998e 100644 priv->ds->ops = &rtl83xx_switch_ops; priv->cpu_port = RTL839X_CPU_PORT; priv->port_mask = 0x3f; -@@ -604,10 +1470,14 @@ static int __init rtl83xx_sw_probe(struct platform_device *pdev) +@@ -603,10 +1470,14 @@ static int __init rtl83xx_sw_probe(struct platform_device *pdev) priv->r = &rtl839x_reg; priv->ds->num_ports = 53; priv->fib_entries = 16384; @@ -2280,7 +2370,7 @@ index 698f2892ea..f16bdb998e 100644 priv->ds->ops = &rtl930x_switch_ops; priv->cpu_port = RTL930X_CPU_PORT; priv->port_mask = 0x1f; -@@ -616,11 +1486,15 @@ static int __init rtl83xx_sw_probe(struct platform_device *pdev) +@@ -615,11 +1486,15 @@ static int __init rtl83xx_sw_probe(struct platform_device *pdev) priv->r = &rtl930x_reg; priv->ds->num_ports = 29; priv->fib_entries = 16384; @@ -2297,7 +2387,7 @@ index 698f2892ea..f16bdb998e 100644 priv->ds->ops = &rtl930x_switch_ops; priv->cpu_port = RTL931X_CPU_PORT; priv->port_mask = 0x3f; -@@ -629,16 +1503,24 @@ static int __init rtl83xx_sw_probe(struct platform_device *pdev) +@@ -628,16 +1503,24 @@ static int __init rtl83xx_sw_probe(struct platform_device *pdev) priv->r = &rtl931x_reg; priv->ds->num_ports = 57; priv->fib_entries = 16384; @@ -2324,7 +2414,7 @@ index 698f2892ea..f16bdb998e 100644 */ return err; } -@@ -648,11 +1530,14 @@ static int __init rtl83xx_sw_probe(struct platform_device *pdev) +@@ -647,6 +1530,9 @@ static int __init rtl83xx_sw_probe(struct platform_device *pdev) return err; } @@ -2333,16 +2423,8 @@ index 698f2892ea..f16bdb998e 100644 + /* Enable link and media change interrupts. Are the SERDES masks needed? */ sw_w32_mask(0, 3, priv->r->isr_glb_src); -- -- priv->r->set_port_reg_le(irq_mask, priv->r->isr_port_link_sts_chg); -- priv->r->set_port_reg_le(irq_mask, priv->r->imr_port_link_sts_chg); -+ -+ priv->r->set_port_reg_le(priv->irq_mask, priv->r->isr_port_link_sts_chg); -+ priv->r->set_port_reg_le(priv->irq_mask, priv->r->imr_port_link_sts_chg); - priv->link_state_irq = platform_get_irq(pdev, 0); - pr_info("LINK state irq: %d\n", priv->link_state_irq); -@@ -687,16 +1572,50 @@ static int __init rtl83xx_sw_probe(struct platform_device *pdev) +@@ -686,16 +1572,50 @@ static int __init rtl83xx_sw_probe(struct platform_device *pdev) rtl83xx_setup_qos(priv); @@ -2363,8 +2445,8 @@ index 698f2892ea..f16bdb998e 100644 + priv->nb.notifier_call = NULL; + dev_err(dev, "Failed to register LAG netdev notifier\n"); + goto err_register_nb; - } - ++ } ++ + // Initialize hash table for L3 routing + rhltable_init(&priv->routes, &route_ht_params); + @@ -2377,8 +2459,8 @@ index 698f2892ea..f16bdb998e 100644 + priv->ne_nb.notifier_call = NULL; + dev_err(dev, "Failed to register netevent notifier\n"); + goto err_register_ne_nb; -+ } -+ + } + + priv->fib_nb.notifier_call = rtl83xx_fib_event; + + /* @@ -2396,7 +2478,7 @@ index 698f2892ea..f16bdb998e 100644 // Flood BPDUs to all ports including cpu-port if (soc_info.family != RTL9300_FAMILY_ID) { // TODO: Port this functionality bpdu_mask = soc_info.family == RTL8380_FAMILY_ID ? 0x1FFFFFFF : 0x1FFFFFFFFFFFFF; -@@ -706,8 +1625,17 @@ static int __init rtl83xx_sw_probe(struct platform_device *pdev) +@@ -705,8 +1625,17 @@ static int __init rtl83xx_sw_probe(struct platform_device *pdev) sw_w32(7, priv->r->spcl_trap_eapol_ctrl); rtl838x_dbgfs_init(priv); @@ -2898,7 +2980,7 @@ index 4f81408453..0425bae4ab 100644 + debugfs_create_file("drop_counters", 0400, dbg_dir, priv, &drop_counter_fops); +} diff --git a/target/linux/realtek/files-5.4/drivers/net/dsa/rtl83xx/dsa.c b/target/linux/realtek/files-5.4/drivers/net/dsa/rtl83xx/dsa.c -index e0832c42b8..a17208b72b 100644 +index 987b47dc8f..a17208b72b 100644 --- a/target/linux/realtek/files-5.4/drivers/net/dsa/rtl83xx/dsa.c +++ b/target/linux/realtek/files-5.4/drivers/net/dsa/rtl83xx/dsa.c @@ -1,4 +1,3 @@ @@ -3092,7 +3174,7 @@ index e0832c42b8..a17208b72b 100644 return 0; } -@@ -242,9 +252,10 @@ static void rtl83xx_phylink_validate(struct dsa_switch *ds, int port, +@@ -242,7 +252,7 @@ static void rtl83xx_phylink_validate(struct dsa_switch *ds, int port, struct rtl838x_switch_priv *priv = ds->priv; __ETHTOOL_DECLARE_LINK_MODE_MASK(mask) = { 0, }; @@ -3100,11 +3182,8 @@ index e0832c42b8..a17208b72b 100644 + pr_debug("In %s port %d, state is %d", __func__, port, state->interface); if (!phy_interface_mode_is_rgmii(state->interface) && -+ state->interface != PHY_INTERFACE_MODE_NA && - state->interface != PHY_INTERFACE_MODE_1000BASEX && - state->interface != PHY_INTERFACE_MODE_MII && - state->interface != PHY_INTERFACE_MODE_REVMII && -@@ -278,6 +289,68 @@ static void rtl83xx_phylink_validate(struct dsa_switch *ds, int port, + state->interface != PHY_INTERFACE_MODE_NA && +@@ -279,6 +289,68 @@ static void rtl83xx_phylink_validate(struct dsa_switch *ds, int port, if (port >= 24 && port <= 27 && priv->family_id == RTL8380_FAMILY_ID) phylink_set(mask, 1000baseX_Full); @@ -3173,51 +3252,40 @@ index e0832c42b8..a17208b72b 100644 phylink_set(mask, 10baseT_Half); phylink_set(mask, 10baseT_Full); phylink_set(mask, 100baseT_Half); -@@ -296,6 +369,54 @@ static int rtl83xx_phylink_mac_link_state(struct dsa_switch *ds, int port, - u64 speed; - u64 link; +@@ -300,18 +372,11 @@ static int rtl83xx_phylink_mac_link_state(struct dsa_switch *ds, int port, + if (port < 0 || port > priv->cpu_port) + return -EINVAL; -+ if (port < 0 || port > priv->cpu_port) -+ return -EINVAL; -+ -+ state->link = 0; -+ link = priv->r->get_port_reg_le(priv->r->mac_link_sts); -+ if (link & BIT_ULL(port)) -+ state->link = 1; +- /* +- * On the RTL9300 for at least the RTL8226B PHY, the MAC-side link +- * state needs to be read twice in order to read a correct result. +- * This would not be necessary for ports connected e.g. to RTL8218D +- * PHYs. +- */ + state->link = 0; + link = priv->r->get_port_reg_le(priv->r->mac_link_sts); +- link = priv->r->get_port_reg_le(priv->r->mac_link_sts); + if (link & BIT_ULL(port)) + state->link = 1; +- pr_debug("%s: link state: %llx\n", __func__, link & BIT_ULL(port)); + pr_debug("%s: link state port %d: %llx\n", __func__, port, link & BIT_ULL(port)); -+ -+ state->duplex = 0; -+ if (priv->r->get_port_reg_le(priv->r->mac_link_dup_sts) & BIT_ULL(port)) -+ state->duplex = 1; -+ -+ speed = priv->r->get_port_reg_le(priv->r->mac_link_spd_sts(port)); -+ speed >>= (port % 16) << 1; -+ switch (speed & 0x3) { -+ case 0: -+ state->speed = SPEED_10; -+ break; -+ case 1: -+ state->speed = SPEED_100; -+ break; -+ case 2: -+ state->speed = SPEED_1000; -+ break; -+ case 3: + + state->duplex = 0; + if (priv->r->get_port_reg_le(priv->r->mac_link_dup_sts) & BIT_ULL(port)) +@@ -330,7 +395,8 @@ static int rtl83xx_phylink_mac_link_state(struct dsa_switch *ds, int port, + state->speed = SPEED_1000; + break; + case 3: +- if (port == 24 || port == 26) /* Internal serdes */ + if (priv->family_id == RTL9300_FAMILY_ID + && (port == 24 || port == 26)) /* Internal serdes */ -+ state->speed = SPEED_2500; -+ else -+ state->speed = SPEED_100; /* Is in fact 500Mbit */ -+ } -+ -+ state->pause &= (MLO_PAUSE_RX | MLO_PAUSE_TX); -+ if (priv->r->get_port_reg_le(priv->r->mac_rx_pause_sts) & BIT_ULL(port)) -+ state->pause |= MLO_PAUSE_RX; -+ if (priv->r->get_port_reg_le(priv->r->mac_tx_pause_sts) & BIT_ULL(port)) -+ state->pause |= MLO_PAUSE_TX; -+ return 1; -+} -+ + state->speed = SPEED_2500; + else + state->speed = SPEED_100; /* Is in fact 500Mbit */ +@@ -344,6 +410,69 @@ static int rtl83xx_phylink_mac_link_state(struct dsa_switch *ds, int port, + return 1; + } + +static int rtl93xx_phylink_mac_link_state(struct dsa_switch *ds, int port, + struct phylink_link_state *state) +{ @@ -3225,41 +3293,40 @@ index e0832c42b8..a17208b72b 100644 + u64 speed; + u64 link; + - if (port < 0 || port > priv->cpu_port) - return -EINVAL; - -@@ -310,15 +431,16 @@ static int rtl83xx_phylink_mac_link_state(struct dsa_switch *ds, int port, - link = priv->r->get_port_reg_le(priv->r->mac_link_sts); - if (link & BIT_ULL(port)) - state->link = 1; -- pr_info("%s: link state: %llx\n", __func__, link & BIT_ULL(port)); ++ if (port < 0 || port > priv->cpu_port) ++ return -EINVAL; ++ ++ /* ++ * On the RTL9300 for at least the RTL8226B PHY, the MAC-side link ++ * state needs to be read twice in order to read a correct result. ++ * This would not be necessary for ports connected e.g. to RTL8218D ++ * PHYs. ++ */ ++ state->link = 0; ++ link = priv->r->get_port_reg_le(priv->r->mac_link_sts); ++ link = priv->r->get_port_reg_le(priv->r->mac_link_sts); ++ if (link & BIT_ULL(port)) ++ state->link = 1; + pr_info("%s: link state port %d: %llx, media %08x\n", __func__, port, + link & BIT_ULL(port), sw_r32(RTL930X_MAC_LINK_MEDIA_STS)); - - state->duplex = 0; - if (priv->r->get_port_reg_le(priv->r->mac_link_dup_sts) & BIT_ULL(port)) - state->duplex = 1; - - speed = priv->r->get_port_reg_le(priv->r->mac_link_spd_sts(port)); -- speed >>= (port % 16) << 1; -- switch (speed & 0x3) { ++ ++ state->duplex = 0; ++ if (priv->r->get_port_reg_le(priv->r->mac_link_dup_sts) & BIT_ULL(port)) ++ state->duplex = 1; ++ ++ speed = priv->r->get_port_reg_le(priv->r->mac_link_spd_sts(port)); + speed >>= (port % 8) << 2; + switch (speed & 0xf) { - case 0: - state->speed = SPEED_10; - break; -@@ -326,15 +448,24 @@ static int rtl83xx_phylink_mac_link_state(struct dsa_switch *ds, int port, - state->speed = SPEED_100; - break; - case 2: ++ case 0: ++ state->speed = SPEED_10; ++ break; ++ case 1: ++ state->speed = SPEED_100; ++ break; ++ case 2: + case 7: - state->speed = SPEED_1000; - break; -- case 3: -- if (port == 24 || port == 26) /* Internal serdes */ -- state->speed = SPEED_2500; -- else -- state->speed = SPEED_100; /* Is in fact 500Mbit */ ++ state->speed = SPEED_1000; ++ break; + case 4: + state->speed = SPEED_10000; + break; @@ -3272,57 +3339,20 @@ index e0832c42b8..a17208b72b 100644 + break; + default: + pr_err("%s: unknown speed: %d\n", __func__, (u32)speed & 0xf); - } - ++ } ++ + pr_info("%s: speed is: %d %d\n", __func__, (u32)speed & 0xf, state->speed); - state->pause &= (MLO_PAUSE_RX | MLO_PAUSE_TX); - if (priv->r->get_port_reg_le(priv->r->mac_rx_pause_sts) & BIT_ULL(port)) - state->pause |= MLO_PAUSE_RX; -@@ -343,6 +474,43 @@ static int rtl83xx_phylink_mac_link_state(struct dsa_switch *ds, int port, - return 1; - } - -+static void rtl83xx_config_interface(int port, phy_interface_t interface) -+{ -+ u32 old, int_shift, sds_shift; -+ -+ switch (port) { -+ case 24: -+ int_shift = 0; -+ sds_shift = 5; -+ break; -+ case 26: -+ int_shift = 3; -+ sds_shift = 0; -+ break; -+ default: -+ return; -+ } -+ -+ old = sw_r32(RTL838X_SDS_MODE_SEL); -+ switch (interface) { -+ case PHY_INTERFACE_MODE_1000BASEX: -+ if ((old >> sds_shift & 0x1f) == 4) -+ return; -+ sw_w32_mask(0x7 << int_shift, 1 << int_shift, RTL838X_INT_MODE_CTRL); -+ sw_w32_mask(0x1f << sds_shift, 4 << sds_shift, RTL838X_SDS_MODE_SEL); -+ break; -+ case PHY_INTERFACE_MODE_SGMII: -+ if ((old >> sds_shift & 0x1f) == 2) -+ return; -+ sw_w32_mask(0x7 << int_shift, 2 << int_shift, RTL838X_INT_MODE_CTRL); -+ sw_w32_mask(0x1f << sds_shift, 2 << sds_shift, RTL838X_SDS_MODE_SEL); -+ break; -+ default: -+ return; -+ } -+ pr_debug("configured port %d for interface %s\n", port, phy_modes(interface)); ++ state->pause &= (MLO_PAUSE_RX | MLO_PAUSE_TX); ++ if (priv->r->get_port_reg_le(priv->r->mac_rx_pause_sts) & BIT_ULL(port)) ++ state->pause |= MLO_PAUSE_RX; ++ if (priv->r->get_port_reg_le(priv->r->mac_tx_pause_sts) & BIT_ULL(port)) ++ state->pause |= MLO_PAUSE_TX; ++ return 1; +} -+ - static void rtl83xx_phylink_mac_config(struct dsa_switch *ds, int port, - unsigned int mode, - const struct phylink_link_state *state) -@@ -350,12 +518,10 @@ static void rtl83xx_phylink_mac_config(struct dsa_switch *ds, int port, + + static void rtl83xx_config_interface(int port, phy_interface_t interface) + { +@@ -389,12 +518,10 @@ static void rtl83xx_phylink_mac_config(struct dsa_switch *ds, int port, struct rtl838x_switch_priv *priv = ds->priv; u32 reg; int speed_bit = priv->family_id == RTL8380_FAMILY_ID ? 4 : 3; @@ -3338,21 +3368,16 @@ index e0832c42b8..a17208b72b 100644 if (port == priv->cpu_port) { /* Set Speed, duplex, flow control -@@ -376,10 +542,11 @@ static void rtl83xx_phylink_mac_config(struct dsa_switch *ds, int port, - reg = sw_r32(priv->r->mac_force_mode_ctrl(port)); - /* Auto-Negotiation does not work for MAC in RTL8390 */ +@@ -417,7 +544,7 @@ static void rtl83xx_phylink_mac_config(struct dsa_switch *ds, int port, if (priv->family_id == RTL8380_FAMILY_ID) { -- if (mode == MLO_AN_PHY) { -+ if (mode == MLO_AN_PHY || phylink_autoneg_inband(mode)) { + if (mode == MLO_AN_PHY || phylink_autoneg_inband(mode)) { pr_debug("PHY autonegotiates\n"); - reg |= BIT(2); + reg |= RTL830X_NWAY_EN; sw_w32(reg, priv->r->mac_force_mode_ctrl(port)); -+ rtl83xx_config_interface(port, state->interface); + rtl83xx_config_interface(port, state->interface); return; - } - } -@@ -387,20 +554,46 @@ static void rtl83xx_phylink_mac_config(struct dsa_switch *ds, int port, +@@ -427,20 +554,46 @@ static void rtl83xx_phylink_mac_config(struct dsa_switch *ds, int port, if (mode != MLO_AN_FIXED) pr_debug("Fixed state.\n"); @@ -3369,11 +3394,13 @@ index e0832c42b8..a17208b72b 100644 + { + case RTL8380_FAMILY_ID: + reg &= ~(RTL830X_RX_PAUSE_EN | RTL830X_TX_PAUSE_EN); -+ if (state->pause & MLO_PAUSE_TXRX_MASK) { -+ if (state->pause & MLO_PAUSE_TX) + if (state->pause & MLO_PAUSE_TXRX_MASK) { + if (state->pause & MLO_PAUSE_TX) +- reg |= TX_PAUSE_EN; +- reg |= RX_PAUSE_EN; + reg |= RTL830X_TX_PAUSE_EN; + reg |= RTL830X_RX_PAUSE_EN; -+ } + } + break; + case RTL8390_FAMILY_ID: + reg &= ~(RTL839X_RX_PAUSE_EN | RTL839X_TX_PAUSE_EN); @@ -3393,13 +3420,11 @@ index e0832c42b8..a17208b72b 100644 + break; + case RTL9310_FAMILY_ID: + reg &= ~(RTL931X_RX_PAUSE_EN | RTL931X_TX_PAUSE_EN); - if (state->pause & MLO_PAUSE_TXRX_MASK) { - if (state->pause & MLO_PAUSE_TX) -- reg |= TX_PAUSE_EN; -- reg |= RX_PAUSE_EN; ++ if (state->pause & MLO_PAUSE_TXRX_MASK) { ++ if (state->pause & MLO_PAUSE_TX) + reg |= RTL931X_TX_PAUSE_EN; + reg |= RTL931X_RX_PAUSE_EN; - } ++ } + break; } - @@ -3408,7 +3433,7 @@ index e0832c42b8..a17208b72b 100644 switch (state->speed) { case SPEED_1000: reg |= 2 << speed_bit; -@@ -408,29 +601,191 @@ static void rtl83xx_phylink_mac_config(struct dsa_switch *ds, int port, +@@ -448,29 +601,191 @@ static void rtl83xx_phylink_mac_config(struct dsa_switch *ds, int port, case SPEED_100: reg |= 1 << speed_bit; break; @@ -3474,17 +3499,17 @@ index e0832c42b8..a17208b72b 100644 + reg |= RTL839X_DUPLEX_MODE; + break; + case RTL9300_FAMILY_ID: - if (state->link) -- reg |= FORCE_LINK_EN; ++ if (state->link) + reg |= RTL930X_FORCE_LINK_EN; - if (state->duplex == DUPLEX_FULL) -- reg |= DUPLX_MODE; ++ if (state->duplex == DUPLEX_FULL) + reg |= RTL930X_DUPLEX_MODE; + break; + case RTL9310_FAMILY_ID: -+ if (state->link) + if (state->link) +- reg |= FORCE_LINK_EN; + reg |= RTL931X_FORCE_LINK_EN; -+ if (state->duplex == DUPLEX_FULL) + if (state->duplex == DUPLEX_FULL) +- reg |= DUPLX_MODE; + reg |= RTL931X_DUPLEX_MODE; + break; } @@ -3606,7 +3631,7 @@ index e0832c42b8..a17208b72b 100644 } static void rtl83xx_phylink_mac_link_up(struct dsa_switch *ds, int port, -@@ -439,6 +794,18 @@ static void rtl83xx_phylink_mac_link_up(struct dsa_switch *ds, int port, +@@ -479,6 +794,18 @@ static void rtl83xx_phylink_mac_link_up(struct dsa_switch *ds, int port, struct phy_device *phydev) { struct rtl838x_switch_priv *priv = ds->priv; @@ -3625,15 +3650,18 @@ index e0832c42b8..a17208b72b 100644 /* Restart TX/RX to port */ sw_w32_mask(0, 0x3, priv->r->mac_port_ctrl(port)); } -@@ -483,6 +850,31 @@ static int rtl83xx_get_sset_count(struct dsa_switch *ds, int port, int sset) +@@ -523,13 +850,40 @@ static int rtl83xx_get_sset_count(struct dsa_switch *ds, int port, int sset) return ARRAY_SIZE(rtl83xx_mib); } +-static int rtl83xx_port_enable(struct dsa_switch *ds, int port, +- struct phy_device *phydev) +static u64 rtl83xx_mc_group_del_port(struct rtl838x_switch_priv *priv, int mc_group, int port); +static u64 rtl83xx_mc_group_add_port(struct rtl838x_switch_priv *priv, int mc_group, int port); + +static void store_mcgroups(struct rtl838x_switch_priv *priv, int port) -+{ + { +- struct rtl838x_switch_priv *priv = ds->priv; + int mc_group; + for (mc_group = 0; mc_group < MAX_MC_GROUPS; mc_group++) { + u64 portmask = priv->r->read_mcast_pmask(mc_group); @@ -3654,10 +3682,10 @@ index e0832c42b8..a17208b72b 100644 + } +} + - static int rtl83xx_port_enable(struct dsa_switch *ds, int port, - struct phy_device *phydev) - { -@@ -490,6 +882,8 @@ static int rtl83xx_port_enable(struct dsa_switch *ds, int port, ++static int rtl83xx_port_enable(struct dsa_switch *ds, int port, ++ struct phy_device *phydev) ++{ ++ struct rtl838x_switch_priv *priv = ds->priv; u64 v; pr_debug("%s: %x %d", __func__, (u32) priv, port); @@ -3666,7 +3694,7 @@ index e0832c42b8..a17208b72b 100644 priv->ports[port].enable = true; /* enable inner tagging on egress, do not keep any tags */ -@@ -501,20 +895,31 @@ static int rtl83xx_port_enable(struct dsa_switch *ds, int port, +@@ -541,20 +895,31 @@ static int rtl83xx_port_enable(struct dsa_switch *ds, int port, if (dsa_is_cpu_port(ds, port)) return 0; @@ -3701,7 +3729,7 @@ index e0832c42b8..a17208b72b 100644 static void rtl83xx_port_disable(struct dsa_switch *ds, int port) { struct rtl838x_switch_priv *priv = ds->priv; -@@ -528,6 +933,7 @@ static void rtl83xx_port_disable(struct dsa_switch *ds, int port) +@@ -568,6 +933,7 @@ static void rtl83xx_port_disable(struct dsa_switch *ds, int port) // BUG: This does not work on RTL931X /* remove port from switch mask of CPU_PORT */ priv->r->traffic_disable(priv->cpu_port, port); @@ -3709,7 +3737,7 @@ index e0832c42b8..a17208b72b 100644 /* remove all other ports in the same bridge from switch mask of port */ v = priv->r->traffic_get(port); -@@ -537,58 +943,57 @@ static void rtl83xx_port_disable(struct dsa_switch *ds, int port) +@@ -577,58 +943,57 @@ static void rtl83xx_port_disable(struct dsa_switch *ds, int port) priv->ports[port].enable = false; } @@ -3800,7 +3828,7 @@ index e0832c42b8..a17208b72b 100644 return 0; } -@@ -618,26 +1023,32 @@ static int rtl83xx_port_bridge_join(struct dsa_switch *ds, int port, +@@ -658,26 +1023,32 @@ static int rtl83xx_port_bridge_join(struct dsa_switch *ds, int port, struct net_device *bridge) { struct rtl838x_switch_priv *priv = ds->priv; @@ -3837,7 +3865,7 @@ index e0832c42b8..a17208b72b 100644 /* Add all other ports to this port matrix. */ if (priv->ports[port].enable) { -@@ -656,7 +1067,7 @@ static void rtl83xx_port_bridge_leave(struct dsa_switch *ds, int port, +@@ -696,7 +1067,7 @@ static void rtl83xx_port_bridge_leave(struct dsa_switch *ds, int port, struct net_device *bridge) { struct rtl838x_switch_priv *priv = ds->priv; @@ -3846,7 +3874,7 @@ index e0832c42b8..a17208b72b 100644 int i; pr_debug("%s %x: %d", __func__, (u32)priv, port); -@@ -671,13 +1082,14 @@ static void rtl83xx_port_bridge_leave(struct dsa_switch *ds, int port, +@@ -711,13 +1082,14 @@ static void rtl83xx_port_bridge_leave(struct dsa_switch *ds, int port, if (dsa_is_user_port(ds, i) && i != port) { if (dsa_to_port(ds, i)->bridge_dev != bridge) continue; @@ -3864,7 +3892,7 @@ index e0832c42b8..a17208b72b 100644 /* Add all other ports to this port matrix. */ if (priv->ports[port].enable) { -@@ -774,6 +1186,7 @@ void rtl930x_fast_age(struct dsa_switch *ds, int port) +@@ -814,6 +1186,7 @@ void rtl930x_fast_age(struct dsa_switch *ds, int port) { struct rtl838x_switch_priv *priv = ds->priv; @@ -3872,7 +3900,7 @@ index e0832c42b8..a17208b72b 100644 pr_debug("FAST AGE port %d\n", port); mutex_lock(&priv->reg_mutex); sw_w32(port << 11, RTL930X_L2_TBL_FLUSH_CTRL + 4); -@@ -789,8 +1202,7 @@ static int rtl83xx_vlan_filtering(struct dsa_switch *ds, int port, +@@ -829,8 +1202,7 @@ static int rtl83xx_vlan_filtering(struct dsa_switch *ds, int port, bool vlan_filtering) { struct rtl838x_switch_priv *priv = ds->priv; @@ -3882,7 +3910,7 @@ index e0832c42b8..a17208b72b 100644 mutex_lock(&priv->reg_mutex); if (vlan_filtering) { -@@ -804,14 +1216,15 @@ static int rtl83xx_vlan_filtering(struct dsa_switch *ds, int port, +@@ -844,14 +1216,15 @@ static int rtl83xx_vlan_filtering(struct dsa_switch *ds, int port, */ if (port != priv->cpu_port) sw_w32_mask(0b10 << ((port % 16) << 1), 0b01 << ((port % 16) << 1), @@ -3902,7 +3930,7 @@ index e0832c42b8..a17208b72b 100644 } /* Do we need to do something to the CPU-Port, too? */ -@@ -826,17 +1239,17 @@ static int rtl83xx_vlan_prepare(struct dsa_switch *ds, int port, +@@ -866,17 +1239,17 @@ static int rtl83xx_vlan_prepare(struct dsa_switch *ds, int port, struct rtl838x_vlan_info info; struct rtl838x_switch_priv *priv = ds->priv; @@ -3926,7 +3954,7 @@ index e0832c42b8..a17208b72b 100644 priv->r->vlan_set_untagged(1, info.untagged_ports); pr_debug("SET: Untagged ports, VLAN %d: %llx\n", 1, info.untagged_ports); -@@ -854,7 +1267,7 @@ static void rtl83xx_vlan_add(struct dsa_switch *ds, int port, +@@ -894,7 +1267,7 @@ static void rtl83xx_vlan_add(struct dsa_switch *ds, int port, struct rtl838x_switch_priv *priv = ds->priv; int v; @@ -3935,7 +3963,7 @@ index e0832c42b8..a17208b72b 100644 port, vlan->vid_begin, vlan->vid_end, vlan->flags); if (vlan->vid_begin > 4095 || vlan->vid_end > 4095) { -@@ -876,9 +1289,6 @@ static void rtl83xx_vlan_add(struct dsa_switch *ds, int port, +@@ -916,9 +1289,6 @@ static void rtl83xx_vlan_add(struct dsa_switch *ds, int port, } for (v = vlan->vid_begin; v <= vlan->vid_end; v++) { @@ -3945,7 +3973,7 @@ index e0832c42b8..a17208b72b 100644 /* Get port memberships of this vlan */ priv->r->vlan_tables_read(v, &info); -@@ -899,10 +1309,10 @@ static void rtl83xx_vlan_add(struct dsa_switch *ds, int port, +@@ -939,10 +1309,10 @@ static void rtl83xx_vlan_add(struct dsa_switch *ds, int port, info.untagged_ports |= BIT_ULL(port); priv->r->vlan_set_untagged(v, info.untagged_ports); @@ -3958,7 +3986,7 @@ index e0832c42b8..a17208b72b 100644 } mutex_unlock(&priv->reg_mutex); -@@ -938,9 +1348,7 @@ static int rtl83xx_vlan_del(struct dsa_switch *ds, int port, +@@ -978,9 +1348,7 @@ static int rtl83xx_vlan_del(struct dsa_switch *ds, int port, /* remove port from both tables */ info.untagged_ports &= (~BIT_ULL(port)); @@ -3969,7 +3997,7 @@ index e0832c42b8..a17208b72b 100644 priv->r->vlan_set_untagged(v, info.untagged_ports); pr_debug("Untagged ports, VLAN %d: %llx\n", v, info.untagged_ports); -@@ -953,59 +1361,140 @@ static int rtl83xx_vlan_del(struct dsa_switch *ds, int port, +@@ -993,59 +1361,140 @@ static int rtl83xx_vlan_del(struct dsa_switch *ds, int port, return 0; } @@ -4121,15 +4149,6 @@ index e0832c42b8..a17208b72b 100644 + idx = rtl83xx_find_l2_hash_entry(priv, seed, false, &e); + + // Found an existing or empty entry -+ if (idx >= 0) { -+ rtl83xx_setup_l2_uc_entry(&e, port, vid, mac); -+ priv->r->write_l2_entry_using_hash(idx >> 2, idx & 0x3, &e); -+ goto out; -+ } -+ -+ // Hash buckets full, try CAM -+ rtl83xx_find_l2_cam_entry(priv, seed, false, &e); -+ if (idx >= 0) { - r[0] = 3 << 17 | port << 12; // Aging - r[0] |= vid; @@ -4137,14 +4156,23 @@ index e0832c42b8..a17208b72b 100644 - r[2] = (mac & 0xffff) << 12; /* rvid = 0 */ - rtl83xx_write_cam(idx, r); + rtl83xx_setup_l2_uc_entry(&e, port, vid, mac); -+ priv->r->write_cam(idx, &e); ++ priv->r->write_l2_entry_using_hash(idx >> 2, idx & 0x3, &e); goto out; } ++ ++ // Hash buckets full, try CAM ++ rtl83xx_find_l2_cam_entry(priv, seed, false, &e); ++ ++ if (idx >= 0) { ++ rtl83xx_setup_l2_uc_entry(&e, port, vid, mac); ++ priv->r->write_cam(idx, &e); ++ goto out; ++ } + err = -ENOTSUPP; out: mutex_unlock(&priv->reg_mutex); -@@ -1017,41 +1506,29 @@ static int rtl83xx_port_fdb_del(struct dsa_switch *ds, int port, +@@ -1057,41 +1506,29 @@ static int rtl83xx_port_fdb_del(struct dsa_switch *ds, int port, { struct rtl838x_switch_priv *priv = ds->priv; u64 mac = ether_addr_to_u64(addr); @@ -4199,7 +4227,7 @@ index e0832c42b8..a17208b72b 100644 goto out; } err = -ENOENT; -@@ -1066,9 +1543,8 @@ static int rtl83xx_port_fdb_dump(struct dsa_switch *ds, int port, +@@ -1106,9 +1543,8 @@ static int rtl83xx_port_fdb_dump(struct dsa_switch *ds, int port, struct rtl838x_l2_entry e; struct rtl838x_switch_priv *priv = ds->priv; int i; @@ -4211,7 +4239,7 @@ index e0832c42b8..a17208b72b 100644 mutex_lock(&priv->reg_mutex); -@@ -1078,14 +1554,26 @@ static int rtl83xx_port_fdb_dump(struct dsa_switch *ds, int port, +@@ -1118,14 +1554,26 @@ static int rtl83xx_port_fdb_dump(struct dsa_switch *ds, int port, if (!e.valid) continue; @@ -4242,7 +4270,7 @@ index e0832c42b8..a17208b72b 100644 } for (i = 0; i < 64; i++) { -@@ -1098,21 +1586,210 @@ static int rtl83xx_port_fdb_dump(struct dsa_switch *ds, int port, +@@ -1138,21 +1586,210 @@ static int rtl83xx_port_fdb_dump(struct dsa_switch *ds, int port, cb(e.mac, e.vid, e.is_static, data); } @@ -4456,7 +4484,7 @@ index e0832c42b8..a17208b72b 100644 for (group = 0; group < 4; group++) { if (priv->mirror_group_ports[group] == mirror->to_local_port) break; -@@ -1124,41 +1801,42 @@ static int rtl83xx_port_mirror_add(struct dsa_switch *ds, int port, +@@ -1164,41 +1801,42 @@ static int rtl83xx_port_mirror_add(struct dsa_switch *ds, int port, } } @@ -4515,7 +4543,7 @@ index e0832c42b8..a17208b72b 100644 } static void rtl83xx_port_mirror_del(struct dsa_switch *ds, int port, -@@ -1169,18 +1847,18 @@ static void rtl83xx_port_mirror_del(struct dsa_switch *ds, int port, +@@ -1209,18 +1847,18 @@ static void rtl83xx_port_mirror_del(struct dsa_switch *ds, int port, int ctrl_reg, dpm_reg, spm_reg; pr_debug("In %s\n", __func__); @@ -4538,7 +4566,7 @@ index e0832c42b8..a17208b72b 100644 if (mirror->ingress) { /* Ingress, clear source port matrix */ priv->r->mask_port_reg_be(1ULL << port, 0, spm_reg); -@@ -1188,13 +1866,214 @@ static void rtl83xx_port_mirror_del(struct dsa_switch *ds, int port, +@@ -1228,13 +1866,214 @@ static void rtl83xx_port_mirror_del(struct dsa_switch *ds, int port, /* Egress, clear destination port matrix */ priv->r->mask_port_reg_be(1ULL << port, 0, dpm_reg); } @@ -4621,8 +4649,8 @@ index e0832c42b8..a17208b72b 100644 + u64 port_bitmap = BIT_ULL(priv->cpu_port), v; + pr_debug("%s: %d\n", __func__, port); + mutex_lock(&priv->reg_mutex); -+ -+ mutex_unlock(&priv->reg_mutex); + + mutex_unlock(&priv->reg_mutex); + return 0; +} + @@ -4665,9 +4693,9 @@ index e0832c42b8..a17208b72b 100644 + err = -EINVAL; + goto out; + } - ++ +out: - mutex_unlock(&priv->reg_mutex); ++ mutex_unlock(&priv->reg_mutex); + return err; + +} @@ -4754,7 +4782,7 @@ index e0832c42b8..a17208b72b 100644 } int dsa_phy_read(struct dsa_switch *ds, int phy_addr, int phy_reg) -@@ -1203,6 +2082,8 @@ int dsa_phy_read(struct dsa_switch *ds, int phy_addr, int phy_reg) +@@ -1243,6 +2082,8 @@ int dsa_phy_read(struct dsa_switch *ds, int phy_addr, int phy_reg) u32 offset = 0; struct rtl838x_switch_priv *priv = ds->priv; @@ -4763,7 +4791,7 @@ index e0832c42b8..a17208b72b 100644 if (phy_addr >= 24 && phy_addr <= 27 && priv->ports[24].phy == PHY_RTL838X_SDS) { if (phy_addr == 26) -@@ -1210,7 +2091,7 @@ int dsa_phy_read(struct dsa_switch *ds, int phy_addr, int phy_reg) +@@ -1250,7 +2091,7 @@ int dsa_phy_read(struct dsa_switch *ds, int phy_addr, int phy_reg) val = sw_r32(RTL838X_SDS4_FIB_REG0 + offset + (phy_reg << 2)) & 0xffff; return val; } @@ -4772,7 +4800,7 @@ index e0832c42b8..a17208b72b 100644 read_phy(phy_addr, 0, phy_reg, &val); return val; } -@@ -1219,7 +2100,9 @@ int dsa_phy_write(struct dsa_switch *ds, int phy_addr, int phy_reg, u16 val) +@@ -1259,7 +2100,9 @@ int dsa_phy_write(struct dsa_switch *ds, int phy_addr, int phy_reg, u16 val) { u32 offset = 0; struct rtl838x_switch_priv *priv = ds->priv; @@ -4782,7 +4810,7 @@ index e0832c42b8..a17208b72b 100644 if (phy_addr >= 24 && phy_addr <= 27 && priv->ports[24].phy == PHY_RTL838X_SDS) { if (phy_addr == 26) -@@ -1227,6 +2110,7 @@ int dsa_phy_write(struct dsa_switch *ds, int phy_addr, int phy_reg, u16 val) +@@ -1267,6 +2110,7 @@ int dsa_phy_write(struct dsa_switch *ds, int phy_addr, int phy_reg, u16 val) sw_w32(val, RTL838X_SDS4_FIB_REG0 + offset + (phy_reg << 2)); return 0; } @@ -4790,7 +4818,7 @@ index e0832c42b8..a17208b72b 100644 return write_phy(phy_addr, 0, phy_reg, val); } -@@ -1243,6 +2127,7 @@ const struct dsa_switch_ops rtl83xx_switch_ops = { +@@ -1283,6 +2127,7 @@ const struct dsa_switch_ops rtl83xx_switch_ops = { .phylink_mac_link_down = rtl83xx_phylink_mac_link_down, .phylink_mac_link_up = rtl83xx_phylink_mac_link_up, @@ -4798,7 +4826,7 @@ index e0832c42b8..a17208b72b 100644 .get_strings = rtl83xx_get_strings, .get_ethtool_stats = rtl83xx_get_ethtool_stats, .get_sset_count = rtl83xx_get_sset_count, -@@ -1268,8 +2153,18 @@ const struct dsa_switch_ops rtl83xx_switch_ops = { +@@ -1308,8 +2153,18 @@ const struct dsa_switch_ops rtl83xx_switch_ops = { .port_fdb_del = rtl83xx_port_fdb_del, .port_fdb_dump = rtl83xx_port_fdb_dump, @@ -4817,7 +4845,7 @@ index e0832c42b8..a17208b72b 100644 }; const struct dsa_switch_ops rtl930x_switch_ops = { -@@ -1279,11 +2174,11 @@ const struct dsa_switch_ops rtl930x_switch_ops = { +@@ -1319,11 +2174,11 @@ const struct dsa_switch_ops rtl930x_switch_ops = { .phy_read = dsa_phy_read, .phy_write = dsa_phy_write, @@ -4834,7 +4862,7 @@ index e0832c42b8..a17208b72b 100644 .get_strings = rtl83xx_get_strings, .get_ethtool_stats = rtl83xx_get_ethtool_stats, -@@ -1292,6 +2187,9 @@ const struct dsa_switch_ops rtl930x_switch_ops = { +@@ -1332,6 +2187,9 @@ const struct dsa_switch_ops rtl930x_switch_ops = { .port_enable = rtl83xx_port_enable, .port_disable = rtl83xx_port_disable, @@ -4844,7 +4872,7 @@ index e0832c42b8..a17208b72b 100644 .set_ageing_time = rtl83xx_set_l2aging, .port_bridge_join = rtl83xx_port_bridge_join, .port_bridge_leave = rtl83xx_port_bridge_leave, -@@ -1306,4 +2204,15 @@ const struct dsa_switch_ops rtl930x_switch_ops = { +@@ -1346,4 +2204,15 @@ const struct dsa_switch_ops rtl930x_switch_ops = { .port_fdb_add = rtl83xx_port_fdb_add, .port_fdb_del = rtl83xx_port_fdb_del, .port_fdb_dump = rtl83xx_port_fdb_dump, @@ -11944,7 +11972,7 @@ index 0000000000..eeba29231a + return 0; +} diff --git a/target/linux/realtek/files-5.4/drivers/net/ethernet/rtl838x_eth.c b/target/linux/realtek/files-5.4/drivers/net/ethernet/rtl838x_eth.c -index 7931daff07..77438247ec 100644 +index 2f678b7384..77438247ec 100644 --- a/target/linux/realtek/files-5.4/drivers/net/ethernet/rtl838x_eth.c +++ b/target/linux/realtek/files-5.4/drivers/net/ethernet/rtl838x_eth.c @@ -34,11 +34,11 @@ extern struct rtl83xx_soc_info soc_info; @@ -12275,15 +12303,6 @@ index 7931daff07..77438247ec 100644 sw_w32_mask(0, BIT(priv->cpu_port), RTL930X_L2_UNKN_UC_FLD_PMSK); sw_w32(0x217, priv->r->mac_force_mode_ctrl + priv->cpu_port * 4); -@@ -855,7 +921,7 @@ static int rtl838x_eth_open(struct net_device *ndev) - struct ring_b *ring = priv->membase; - int i, err; - -- pr_info("%s called: RX rings %d(length %d), TX rings %d(length %d)\n", -+ pr_debug("%s called: RX rings %d(length %d), TX rings %d(length %d)\n", - __func__, priv->rxrings, priv->rxringlen, TXRINGS, TXRINGLEN); - - spin_lock_irqsave(&priv->lock, flags); @@ -883,28 +949,30 @@ static int rtl838x_eth_open(struct net_device *ndev) switch (priv->family_id) { case RTL8380_FAMILY_ID: @@ -12381,78 +12400,6 @@ index 7931daff07..77438247ec 100644 dev->stats.rx_packets++; dev->stats.rx_bytes += len; -@@ -1342,7 +1425,7 @@ static void rtl838x_validate(struct phylink_config *config, - { - __ETHTOOL_DECLARE_LINK_MODE_MASK(mask) = { 0, }; - -- pr_info("In %s\n", __func__); -+ pr_debug("In %s\n", __func__); - - if (!phy_interface_mode_is_rgmii(state->interface) && - state->interface != PHY_INTERFACE_MODE_1000BASEX && -@@ -1404,7 +1487,7 @@ static void rtl838x_mac_an_restart(struct phylink_config *config) - if (priv->family_id != RTL8380_FAMILY_ID) - return; - -- pr_info("In %s\n", __func__); -+ pr_debug("In %s\n", __func__); - /* Restart by disabling and re-enabling link */ - sw_w32(0x6192D, priv->r->mac_force_mode_ctrl + priv->cpu_port * 4); - mdelay(20); -@@ -1419,7 +1502,7 @@ static int rtl838x_mac_pcs_get_state(struct phylink_config *config, - struct rtl838x_eth_priv *priv = netdev_priv(dev); - int port = priv->cpu_port; - -- pr_info("In %s\n", __func__); -+ pr_debug("In %s\n", __func__); - - state->link = priv->r->get_mac_link_sts(port) ? 1 : 0; - state->duplex = priv->r->get_mac_link_dup_sts(port) ? 1 : 0; -@@ -1456,7 +1539,7 @@ static void rtl838x_mac_link_down(struct phylink_config *config, - struct net_device *dev = container_of(config->dev, struct net_device, dev); - struct rtl838x_eth_priv *priv = netdev_priv(dev); - -- pr_info("In %s\n", __func__); -+ pr_debug("In %s\n", __func__); - /* Stop TX/RX to port */ - sw_w32_mask(0x03, 0, priv->r->mac_port_ctrl(priv->cpu_port)); - } -@@ -1468,7 +1551,7 @@ static void rtl838x_mac_link_up(struct phylink_config *config, unsigned int mode - struct net_device *dev = container_of(config->dev, struct net_device, dev); - struct rtl838x_eth_priv *priv = netdev_priv(dev); - -- pr_info("In %s\n", __func__); -+ pr_debug("In %s\n", __func__); - /* Restart TX/RX to port */ - sw_w32_mask(0, 0x03, priv->r->mac_port_ctrl(priv->cpu_port)); - } -@@ -1479,7 +1562,7 @@ static void rtl838x_set_mac_hw(struct net_device *dev, u8 *mac) - unsigned long flags; - - spin_lock_irqsave(&priv->lock, flags); -- pr_info("In %s\n", __func__); -+ pr_debug("In %s\n", __func__); - sw_w32((mac[0] << 8) | mac[1], priv->r->mac); - sw_w32((mac[2] << 24) | (mac[3] << 16) | (mac[4] << 8) | mac[5], priv->r->mac + 4); - -@@ -1547,7 +1630,7 @@ static int rtl838x_get_link_ksettings(struct net_device *ndev, - { - struct rtl838x_eth_priv *priv = netdev_priv(ndev); - -- pr_info("%s called\n", __func__); -+ pr_debug("%s called\n", __func__); - return phylink_ethtool_ksettings_get(priv->phylink, cmd); - } - -@@ -1556,7 +1639,7 @@ static int rtl838x_set_link_ksettings(struct net_device *ndev, - { - struct rtl838x_eth_priv *priv = netdev_priv(ndev); - -- pr_info("%s called\n", __func__); -+ pr_debug("%s called\n", __func__); - return phylink_ethtool_ksettings_set(priv->phylink, cmd); - } - @@ -1596,7 +1679,7 @@ static int rtl930x_mdio_read(struct mii_bus *bus, int mii_id, int regnum) // TODO: These are hard-coded for the 2 Fibre Ports of the XGS1210 @@ -12462,34 +12409,7 @@ index 7931daff07..77438247ec 100644 if (regnum & MII_ADDR_C45) { regnum &= ~MII_ADDR_C45; -@@ -1678,7 +1761,7 @@ static int rtl931x_mdio_write(struct mii_bus *bus, int mii_id, - - static int rtl838x_mdio_reset(struct mii_bus *bus) - { -- pr_info("%s called\n", __func__); -+ pr_debug("%s called\n", __func__); - /* Disable MAC polling the PHY so that we can start configuration */ - sw_w32(0x00000000, RTL838X_SMI_POLL_CTRL); - -@@ -1693,7 +1776,7 @@ static int rtl839x_mdio_reset(struct mii_bus *bus) - { - return 0; - -- pr_info("%s called\n", __func__); -+ pr_debug("%s called\n", __func__); - /* BUG: The following does not work, but should! */ - /* Disable MAC polling the PHY so that we can start configuration */ - sw_w32(0x00000000, RTL839X_SMI_PORT_POLLING_CTRL); -@@ -1710,7 +1793,7 @@ static int rtl931x_mdio_reset(struct mii_bus *bus) - sw_w32(0x00000000, RTL931X_SMI_PORT_POLLING_CTRL); - sw_w32(0x00000000, RTL931X_SMI_PORT_POLLING_CTRL + 4); - -- pr_info("%s called\n", __func__); -+ pr_debug("%s called\n", __func__); - - return 0; - } -@@ -1719,55 +1802,57 @@ static int rtl930x_mdio_reset(struct mii_bus *bus) +@@ -1719,52 +1802,54 @@ static int rtl930x_mdio_reset(struct mii_bus *bus) { int i; int pos; @@ -12573,11 +12493,7 @@ index 7931daff07..77438247ec 100644 + u32 pn; int ret; -- pr_info("%s called\n", __func__); -+ pr_debug("%s called\n", __func__); - mii_np = of_get_child_by_name(priv->pdev->dev.of_node, "mdio-bus"); - - if (!mii_np) { + pr_debug("%s called\n", __func__); @@ -1817,6 +1902,28 @@ static int rtl838x_mdio_init(struct rtl838x_eth_priv *priv) priv->mii_bus->priv = priv; priv->mii_bus->parent = &priv->pdev->dev; @@ -12607,15 +12523,6 @@ index 7931daff07..77438247ec 100644 snprintf(priv->mii_bus->id, MII_BUS_ID_SIZE, "%pOFn", mii_np); ret = of_mdiobus_register(priv->mii_bus, mii_np); -@@ -1827,7 +1934,7 @@ err_put_node: - - static int rtl838x_mdio_remove(struct rtl838x_eth_priv *priv) - { -- pr_info("%s called\n", __func__); -+ pr_debug("%s called\n", __func__); - if (!priv->mii_bus) - return 0; - @@ -1837,6 +1944,40 @@ static int rtl838x_mdio_remove(struct rtl838x_eth_priv *priv) return 0; } @@ -15356,10 +15263,73 @@ index 0000000000..7c6d060210 + +module_dsa_tag_driver(trailer_netdev_ops); diff --git a/target/linux/realtek/image/Makefile b/target/linux/realtek/image/Makefile -index 424726c8a9..a4b2ea892c 100644 +index 18e5fedb9b..a4b2ea892c 100644 --- a/target/linux/realtek/image/Makefile +++ b/target/linux/realtek/image/Makefile -@@ -118,4 +118,13 @@ define Device/zyxel_gs1900-8hp-v2 +@@ -6,8 +6,6 @@ include $(INCLUDE_DIR)/image.mk + KERNEL_LOADADDR = 0x80000000 + KERNEL_ENTRY = 0x80000400 + +-DEVICE_VARS += ZYXEL_VERS +- + define Build/zyxel-vers + ( echo VERS;\ + for hw in $(1); do\ +@@ -86,45 +84,47 @@ define Device/netgear_gs110tpp-v1 + endef + TARGET_DEVICES += netgear_gs110tpp-v1 + +-define Device/zyxel_gs1900 ++define Device/zyxel_gs1900-10hp + SOC := rtl8380 + IMAGE_SIZE := 6976k + DEVICE_VENDOR := ZyXEL +- UIMAGE_MAGIC := 0x83800000 +- KERNEL_INITRAMFS := kernel-bin | append-dtb | gzip | zyxel-vers $$$$(ZYXEL_VERS) | \ +- uImage gzip +-endef +- +-define Device/zyxel_gs1900-10hp +- $(Device/zyxel_gs1900) + DEVICE_MODEL := GS1900-10HP +- ZYXEL_VERS := AAZI ++ UIMAGE_MAGIC := 0x83800000 ++ KERNEL_INITRAMFS := kernel-bin | append-dtb | gzip | zyxel-vers AAZI | uImage gzip + endef + TARGET_DEVICES += zyxel_gs1900-10hp + +-define Device/zyxel_gs1900-8 +- $(Device/zyxel_gs1900) +- DEVICE_MODEL := GS1900-8 +- ZYXEL_VERS := AAHH +-endef +-TARGET_DEVICES += zyxel_gs1900-8 +- + define Device/zyxel_gs1900-8hp-v1 +- $(Device/zyxel_gs1900) ++ SOC := rtl8380 ++ IMAGE_SIZE := 6976k ++ DEVICE_VENDOR := ZyXEL + DEVICE_MODEL := GS1900-8HP + DEVICE_VARIANT := v1 +- ZYXEL_VERS := AAHI + DEVICE_PACKAGES += lua-rs232 ++ UIMAGE_MAGIC := 0x83800000 ++ KERNEL_INITRAMFS := kernel-bin | append-dtb | gzip | zyxel-vers AAHI | uImage gzip + endef + TARGET_DEVICES += zyxel_gs1900-8hp-v1 + + define Device/zyxel_gs1900-8hp-v2 +- $(Device/zyxel_gs1900) ++ SOC := rtl8380 ++ IMAGE_SIZE := 6976k ++ DEVICE_VENDOR := ZyXEL + DEVICE_MODEL := GS1900-8HP + DEVICE_VARIANT := v2 +- ZYXEL_VERS := AAHI + DEVICE_PACKAGES += lua-rs232 ++ UIMAGE_MAGIC := 0x83800000 ++ KERNEL_INITRAMFS := kernel-bin | append-dtb | gzip | zyxel-vers AAHI | uImage gzip endef TARGET_DEVICES += zyxel_gs1900-8hp-v2 @@ -19325,19 +19295,6 @@ index 0000000000..0a7f1986ea + break; + default: + ret = -EOPNOTSUPP; -diff --git a/target/linux/realtek/patches-5.4/300-mips-add-rtl838x-platform.patch b/target/linux/realtek/patches-5.4/300-mips-add-rtl838x-platform.patch -index e946a5b1a0..ecc77b2a73 100644 ---- a/target/linux/realtek/patches-5.4/300-mips-add-rtl838x-platform.patch -+++ b/target/linux/realtek/patches-5.4/300-mips-add-rtl838x-platform.patch -@@ -10,7 +10,7 @@ - platforms += sgi-ip27 - --- a/arch/mips/Kconfig - +++ b/arch/mips/Kconfig --@@ -630,6 +630,26 @@ config RALINK -+@@ -631,6 +631,26 @@ config RALINK - select ARCH_HAS_RESET_CONTROLLER - select RESET_CONTROLLER - diff --git a/target/linux/realtek/patches-5.4/500-gpio-Add-Realtek-Otto-GPIO-support.patch b/target/linux/realtek/patches-5.4/500-gpio-Add-Realtek-Otto-GPIO-support.patch new file mode 100644 index 0000000000..8b43f07e8a diff --git a/backports/0009-include-set-kernel-version.mk.patch b/backports/0009-include-set-kernel-version.mk.patch index 5d2bda583..510d11f19 100644 --- a/backports/0009-include-set-kernel-version.mk.patch +++ b/backports/0009-include-set-kernel-version.mk.patch @@ -1,7 +1,7 @@ -From 3b896a540de03ca8dfd5596881f9ec6dc15d72c9 Mon Sep 17 00:00:00 2001 +From 4ed9b7d04405d5109681643f3ceebbd25f3f28e2 Mon Sep 17 00:00:00 2001 From: John Crispin Date: Wed, 7 Apr 2021 10:46:26 +0200 -Subject: [PATCH 01/32] include: set kernel-version.mk +Subject: [PATCH 09/27] include: set kernel-version.mk Signed-off-by: John Crispin --- @@ -9,7 +9,7 @@ Signed-off-by: John Crispin 1 file changed, 6 insertions(+) diff --git a/include/kernel-version.mk b/include/kernel-version.mk -index 52e5c11d75..547f57fa11 100644 +index fe81dbf603..3c109c13c8 100644 --- a/include/kernel-version.mk +++ b/include/kernel-version.mk @@ -6,9 +6,15 @@ ifdef CONFIG_TESTING_KERNEL @@ -18,12 +18,12 @@ index 52e5c11d75..547f57fa11 100644 +LINUX_VERSION-4.4 = .60 +LINUX_VERSION-4.14 = .193 - LINUX_VERSION-5.4 = .111 + LINUX_VERSION-5.4 = .142 +LINUX_VERSION-5.10 = .27 +LINUX_KERNEL_HASH-4.4.60 = 2cd8df6f1ac6a5329c5a286ec9b5956215977221a1b731597ed169fff74a9659 +LINUX_KERNEL_HASH-4.14.193 = 0b0fb41d4430e1a42738b341cbfd2f41951aa5cd02acabbd53f076119c8b9f03 - LINUX_KERNEL_HASH-5.4.111 = 21626132658dc34cb41b7aa7b80ecf83751890a71ac1a63d77aea9d488271a03 + LINUX_KERNEL_HASH-5.4.142 = 99785728968564ba27c7e552d024b560072dcbc885540912eabb5c021e231451 +LINUX_KERNEL_HASH-5.10.27 = d99dc9662951299c53a0a8d8c8d0a72a16ff861d20e927c0f9b14f63282d69d9 remove_uri_prefix=$(subst git://,,$(subst http://,,$(subst https://,,$(1)))) diff --git a/backports/0010-ar71xx-forward-port-target-to-get-routerboard-suppor.patch b/backports/0010-ar71xx-forward-port-target-to-get-routerboard-suppor.patch index 5e55aa44a..3569495cc 100644 --- a/backports/0010-ar71xx-forward-port-target-to-get-routerboard-suppor.patch +++ b/backports/0010-ar71xx-forward-port-target-to-get-routerboard-suppor.patch @@ -1,7 +1,7 @@ -From b6a89df399cae510f531473e04b5fd938b811ed7 Mon Sep 17 00:00:00 2001 +From a5f4e99a365f392feca84f29b7011fb507771f0e Mon Sep 17 00:00:00 2001 From: John Crispin Date: Tue, 20 Apr 2021 11:13:20 +0200 -Subject: [PATCH 02/32] ar71xx: forward port target to get routerboard support +Subject: [PATCH 10/27] ar71xx: forward port target to get routerboard support This is only a 1 month interim until the new nand driver for ath79 is ready @@ -1462,7 +1462,7 @@ index 2921cd5bca..b869ccae70 100644 default TARGET_INITRAMFS_COMPRESSION_LZMA if TARGET_lantiq default TARGET_INITRAMFS_COMPRESSION_LZMA if TARGET_mpc85xx diff --git a/package/kernel/linux/modules/usb.mk b/package/kernel/linux/modules/usb.mk -index 3dd20a0696..d3752c22b4 100644 +index 4191590ba7..592affe494 100644 --- a/package/kernel/linux/modules/usb.mk +++ b/package/kernel/linux/modules/usb.mk @@ -1590,7 +1590,7 @@ $(eval $(call KernelPackage,usbip-server)) diff --git a/backports/0011-backport-mkits.sh.patch b/backports/0011-backport-mkits.sh.patch index 13b151bd4..c6a5fb7d4 100644 --- a/backports/0011-backport-mkits.sh.patch +++ b/backports/0011-backport-mkits.sh.patch @@ -1,7 +1,7 @@ -From 43f832c25bb9dee1a817370ab11531e81348f177 Mon Sep 17 00:00:00 2001 +From ad860cb413d1934332de60658d5eb8fb64d19663 Mon Sep 17 00:00:00 2001 From: John Crispin Date: Sun, 9 May 2021 12:23:00 +0200 -Subject: [PATCH 42/43] backport: mkits.sh +Subject: [PATCH 11/27] backport: mkits.sh 969083634481c3ab5fb80509f385ef10ab45b55f e991c1b8a2385397fc1e657ed73878938997d951 @@ -17,10 +17,10 @@ Signed-off-by: John Crispin 5 files changed, 95 insertions(+), 12 deletions(-) diff --git a/include/image-commands.mk b/include/image-commands.mk -index bde6e030bc..f97d4363d1 100644 +index 2c917d613e..c6e8eb0293 100644 --- a/include/image-commands.mk +++ b/include/image-commands.mk -@@ -204,7 +204,7 @@ define Build/fit +@@ -203,7 +203,7 @@ define Build/fit $(if $(word 3,$(1)),-r $(IMAGE_ROOTFS) -f $(subst _,$(comma),$(DEVICE_NAME))) \ -a $(KERNEL_LOADADDR) -e $(if $(KERNEL_ENTRY),$(KERNEL_ENTRY),$(KERNEL_LOADADDR)) \ $(if $(DEVICE_FDT_NUM),-n $(DEVICE_FDT_NUM)) \ @@ -30,7 +30,7 @@ index bde6e030bc..f97d4363d1 100644 PATH=$(LINUX_DIR)/scripts/dtc:$(PATH) mkimage $(if $(word 3,$(1)),-E -B 0x1000 -p 0x1000) -f $@.its $@.new @mv $@.new $@ diff --git a/include/image.mk b/include/image.mk -index fc46012e87..7a48b789af 100644 +index b6e8ab3c84..7c2dcf0e8b 100644 --- a/include/image.mk +++ b/include/image.mk @@ -139,7 +139,7 @@ endef diff --git a/backports/0014-libubox-update-to-latest-HEAD.patch b/backports/0012-libubox-update-to-latest-HEAD.patch similarity index 61% rename from backports/0014-libubox-update-to-latest-HEAD.patch rename to backports/0012-libubox-update-to-latest-HEAD.patch index be4fc5d09..dda026c30 100644 --- a/backports/0014-libubox-update-to-latest-HEAD.patch +++ b/backports/0012-libubox-update-to-latest-HEAD.patch @@ -1,29 +1,24 @@ -From 029282d8ef8e4e813817d1c7d4aeae4208bc2da5 Mon Sep 17 00:00:00 2001 +From 2af08d2e85ee946de5f53bbd0ddf239de9b78f6d Mon Sep 17 00:00:00 2001 From: John Crispin Date: Tue, 18 May 2021 10:46:43 +0200 -Subject: [PATCH 01/52] libubox: update to latest HEAD +Subject: [PATCH 12/27] libubox: update to latest HEAD Signed-off-by: John Crispin --- - package/libs/libubox/Makefile | 10 +++++----- - 1 file changed, 5 insertions(+), 5 deletions(-) + package/libs/libubox/Makefile | 8 ++++---- + 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/package/libs/libubox/Makefile b/package/libs/libubox/Makefile -index 4d582eacfd..33aa73eef7 100644 +index d2c07783e1..33aa73eef7 100644 --- a/package/libs/libubox/Makefile +++ b/package/libs/libubox/Makefile -@@ -1,13 +1,13 @@ - include $(TOPDIR)/rules.mk - - PKG_NAME:=libubox --PKG_RELEASE=1 -+PKG_RELEASE=2 +@@ -5,9 +5,9 @@ PKG_RELEASE=2 PKG_SOURCE_PROTO:=git PKG_SOURCE_URL=$(PROJECT_GIT)/project/libubox.git --PKG_MIRROR_HASH:=97dc4eba01cf2c5d6a6d0db3747e0cdc0d95cb87e51b3115272e7d3e69a8b255 --PKG_SOURCE_DATE:=2020-12-12 --PKG_SOURCE_VERSION:=357877693ca363b12e6e7e14d345639b2440cd07 +-PKG_MIRROR_HASH:=7dd1db1e0074a9c7c722db654cce3111b3bd3cff0bfd791c4497cb0f6c22d3ca +-PKG_SOURCE_DATE:=2021-05-16 +-PKG_SOURCE_VERSION:=b14c4688612c05c78ce984d7bde633bce8703b1e +PKG_MIRROR_HASH:=1cdb91ac0ee925f133ee9f70eac131a99def312fe7cf0aed44df84eb1762e30b +PKG_SOURCE_DATE:=2021-08-19 +PKG_SOURCE_VERSION:=d716ac4bc4236031d4c3cc1ed362b502e20e3787 diff --git a/backports/0013-iw-update-to-latest-HEAD.patch b/backports/0013-iw-update-to-latest-HEAD.patch deleted file mode 100644 index c58bb4fdb..000000000 --- a/backports/0013-iw-update-to-latest-HEAD.patch +++ /dev/null @@ -1,167 +0,0 @@ -From 0ddce2498be815e098154867d0b18293fe613f12 Mon Sep 17 00:00:00 2001 -From: John Crispin -Date: Thu, 27 May 2021 11:57:10 +0200 -Subject: [PATCH 13/13] iw: update to latest HEAD - -Signed-off-by: John Crispin ---- - package/network/utils/iw/Makefile | 11 +++---- - .../utils/iw/patches/200-reduce_size.patch | 30 +++++++++---------- - 2 files changed, 21 insertions(+), 20 deletions(-) - -diff --git a/package/network/utils/iw/Makefile b/package/network/utils/iw/Makefile -index 6db9aaf105..8e11046189 100644 ---- a/package/network/utils/iw/Makefile -+++ b/package/network/utils/iw/Makefile -@@ -8,12 +8,13 @@ - include $(TOPDIR)/rules.mk - - PKG_NAME:=iw --PKG_VERSION:=5.9 --PKG_RELEASE:=1 -+PKG_VERSION:=5.9-8fab0c9e -+PKG_RELEASE:=$(AUTORELEASE) - --PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz --PKG_SOURCE_URL:=@KERNEL/software/network/iw --PKG_HASH:=293a07109aeb7e36267cf59e3ce52857e9ffae3a6666eb8ac77894b1839fe1f2 -+PKG_SOURCE_PROTO:=git -+PKG_SOURCE_URL:=https://git.kernel.org/pub/scm/linux/kernel/git/jberg/iw.git -+PKG_SOURCE_VERSION:=8fab0c9ee9db217587a58efcc37421c86edcb638 -+PKG_MIRROR_HASH:=797b322bc03952f3127ae0a7da476c14ada1bbe9a9ae234a56dd6f864c568e16 - - PKG_MAINTAINER:=Felix Fietkau - PKG_LICENSE:=GPL-2.0 -diff --git a/package/network/utils/iw/patches/200-reduce_size.patch b/package/network/utils/iw/patches/200-reduce_size.patch -index af30876012..83e11405cb 100644 ---- a/package/network/utils/iw/patches/200-reduce_size.patch -+++ b/package/network/utils/iw/patches/200-reduce_size.patch -@@ -1,6 +1,6 @@ - --- a/event.c - +++ b/event.c --@@ -944,6 +944,7 @@ static int print_event(struct nl_msg *ms -+@@ -956,6 +956,7 @@ static int print_event(struct nl_msg *ms - } - - switch (gnlh->cmd) { -@@ -8,7 +8,7 @@ - case NL80211_CMD_NEW_WIPHY: - printf("renamed to %s\n", nla_get_string(tb[NL80211_ATTR_WIPHY_NAME])); - break; --@@ -979,6 +980,7 @@ static int print_event(struct nl_msg *ms -+@@ -991,6 +992,7 @@ static int print_event(struct nl_msg *ms - case NL80211_CMD_SCHED_SCAN_RESULTS: - printf("got scheduled scan results\n"); - break; -@@ -16,7 +16,7 @@ - case NL80211_CMD_WIPHY_REG_CHANGE: - case NL80211_CMD_REG_CHANGE: - if (gnlh->cmd == NL80211_CMD_WIPHY_REG_CHANGE) --@@ -1061,6 +1063,7 @@ static int print_event(struct nl_msg *ms -+@@ -1073,6 +1075,7 @@ static int print_event(struct nl_msg *ms - mac_addr_n2a(macbuf, nla_data(tb[NL80211_ATTR_MAC])); - printf("del station %s\n", macbuf); - break; -@@ -24,7 +24,7 @@ - case NL80211_CMD_JOIN_IBSS: - mac_addr_n2a(macbuf, nla_data(tb[NL80211_ATTR_MAC])); - printf("IBSS %s joined\n", macbuf); --@@ -1254,9 +1257,9 @@ static int print_event(struct nl_msg *ms -+@@ -1271,9 +1274,9 @@ static int print_event(struct nl_msg *ms - case NL80211_CMD_CH_SWITCH_NOTIFY: - parse_ch_switch_notify(tb, gnlh->cmd); - break; -@@ -134,7 +134,7 @@ - { - --- a/scan.c - +++ b/scan.c --@@ -1297,6 +1297,9 @@ static void print_ht_op(const uint8_t ty -+@@ -1306,6 +1306,9 @@ static void print_ht_op(const uint8_t ty - printf("\t\t * secondary channel offset: %s\n", - ht_secondary_offset[data[1] & 0x3]); - printf("\t\t * STA channel width: %s\n", sta_chan_width[(data[1] & 0x4)>>2]); -@@ -144,7 +144,7 @@ - printf("\t\t * RIFS: %d\n", (data[1] & 0x8)>>3); - printf("\t\t * HT protection: %s\n", protection[data[2] & 0x3]); - printf("\t\t * non-GF present: %d\n", (data[2] & 0x4) >> 2); --@@ -1707,6 +1710,14 @@ static void print_ie(const struct ie_pri -+@@ -1716,6 +1719,14 @@ static void print_ie(const struct ie_pri - - static const struct ie_print ieprinters[] = { - [0] = { "SSID", print_ssid, 0, 32, BIT(PRINT_SCAN) | BIT(PRINT_LINK), }, -@@ -159,7 +159,7 @@ - [1] = { "Supported rates", print_supprates, 0, 255, BIT(PRINT_SCAN), }, - [3] = { "DS Parameter set", print_ds, 1, 1, BIT(PRINT_SCAN), }, - [5] = { "TIM", print_tim, 4, 255, BIT(PRINT_SCAN), }, --@@ -1716,26 +1727,20 @@ static const struct ie_print ieprinters[ -+@@ -1725,26 +1736,20 @@ static const struct ie_print ieprinters[ - [32] = { "Power constraint", print_powerconstraint, 1, 1, BIT(PRINT_SCAN), }, - [35] = { "TPC report", print_tpcreport, 2, 2, BIT(PRINT_SCAN), }, - [42] = { "ERP", print_erp, 1, 255, BIT(PRINT_SCAN), }, -@@ -187,15 +187,15 @@ - }; - - static void print_wifi_wpa(const uint8_t type, uint8_t len, const uint8_t *data, --@@ -2279,6 +2284,7 @@ void print_ies(unsigned char *ie, int ie -+@@ -2326,6 +2331,7 @@ void print_ies(unsigned char *ie, int ie - ieprinters[ie[0]].flags & BIT(ptype)) { - print_ie(&ieprinters[ie[0]], - ie[0], ie[1], ie + 2, &ie_buffer); - +#ifdef IW_FULL - } else if (ie[0] == 221 /* vendor */) { - print_vendor(ie[1], ie + 2, unknown, ptype); -- } else if (unknown) { --@@ -2288,6 +2294,7 @@ void print_ies(unsigned char *ie, int ie -+ } else if (ie[0] == 255 /* extension */) { -+@@ -2337,6 +2343,7 @@ void print_ies(unsigned char *ie, int ie - for (i=0; i Date: Wed, 30 Jun 2021 14:21:23 +0200 -Subject: [PATCH] umdns: update to latest HEAD +Subject: [PATCH 13/27] umdns: update to latest HEAD Signed-off-by: John Crispin --- diff --git a/backports/0017-kernel-add-bdpu-filter-support.patch b/backports/0014-kernel-add-bdpu-filter-support.patch similarity index 98% rename from backports/0017-kernel-add-bdpu-filter-support.patch rename to backports/0014-kernel-add-bdpu-filter-support.patch index c8f79824f..bed48a7f1 100644 --- a/backports/0017-kernel-add-bdpu-filter-support.patch +++ b/backports/0014-kernel-add-bdpu-filter-support.patch @@ -1,7 +1,7 @@ -From 97fb5323a826e6b5ad89b5281c0b9d9e92bfc0b4 Mon Sep 17 00:00:00 2001 +From 9df1500bde8e609dcbbecbefa0eb5a29d9e6f7f5 Mon Sep 17 00:00:00 2001 From: John Crispin Date: Fri, 27 Aug 2021 16:52:34 +0200 -Subject: [PATCH 59/59] kernel: add bdpu filter support +Subject: [PATCH 14/27] kernel: add bdpu filter support Signed-off-by: John Crispin --- diff --git a/backports/0015-uhttpd-add-config-option-for-json_script.patch b/backports/0015-uhttpd-add-config-option-for-json_script.patch new file mode 100644 index 000000000..02fbb177c --- /dev/null +++ b/backports/0015-uhttpd-add-config-option-for-json_script.patch @@ -0,0 +1,33 @@ +From 8ba5feb6aaba50bda126db027490c7d37e428e3b Mon Sep 17 00:00:00 2001 +From: Stijn Tintel +Date: Fri, 20 Aug 2021 16:11:12 +0300 +Subject: [PATCH 15/27] uhttpd: add config option for json_script + +Add a config option for json_script instead of unconditionally including +all json files in /etc/uhttpd in every uhttpd instance. This makes it +possible to configure a single instance with an unconditional redirect, +which is currently not possible as it would render all other uhttpd +instances unusable. + +Signed-off-by: Stijn Tintel +--- + package/network/services/uhttpd/files/uhttpd.init | 3 ++- + 1 file changed, 2 insertions(+), 1 deletion(-) + +diff --git a/package/network/services/uhttpd/files/uhttpd.init b/package/network/services/uhttpd/files/uhttpd.init +index 869f79bea2..7020912c6c 100755 +--- a/package/network/services/uhttpd/files/uhttpd.init ++++ b/package/network/services/uhttpd/files/uhttpd.init +@@ -195,7 +195,8 @@ start_instance() + append_bool "$cfg" redirect_https "-q" 0 + } + +- for file in /etc/uhttpd/*.json; do ++ config_get json_script "$cfg" json_script ++ for file in $json_script; do + [ -s "$file" ] && procd_append_param command -H "$file" + done + +-- +2.25.1 + diff --git a/backports/0016-iwinfo-update-to-latest-git-HEAD.patch b/backports/0016-iwinfo-update-to-latest-git-HEAD.patch new file mode 100644 index 000000000..a33b693b6 --- /dev/null +++ b/backports/0016-iwinfo-update-to-latest-git-HEAD.patch @@ -0,0 +1,41 @@ +From 63281b982b3692828ff453dcb9e68b8e43d628e5 Mon Sep 17 00:00:00 2001 +From: John Crispin +Date: Mon, 21 Jun 2021 12:53:28 +0200 +Subject: [PATCH 16/27] iwinfo: update to latest git HEAD + +Signed-off-by: John Crispin +--- + package/network/utils/iwinfo/Makefile | 14 +++++++++++--- + 1 file changed, 11 insertions(+), 3 deletions(-) + +diff --git a/package/network/utils/iwinfo/Makefile b/package/network/utils/iwinfo/Makefile +index 815c477988..d235f07da9 100644 +--- a/package/network/utils/iwinfo/Makefile ++++ b/package/network/utils/iwinfo/Makefile +@@ -11,12 +11,20 @@ PKG_RELEASE:=2.1 + + PKG_SOURCE_PROTO:=git + PKG_SOURCE_URL=$(PROJECT_GIT)/project/iwinfo.git +-PKG_SOURCE_DATE:=2021-04-30 +-PKG_SOURCE_VERSION:=c45f0b584b4b86f8250f90ea19afca271c114fa2 +-PKG_MIRROR_HASH:=24ad04791254a0523cd15a4fec6116d9ff121e006c93e5e41459f91347b33ec2 ++PKG_SOURCE_DATE:=2021-06-09 ++PKG_SOURCE_VERSION:=c0414642fead263a4a6a686ad3cb7e965ec8a23a ++PKG_MIRROR_HASH:=c5686bbae86753c53db03a686b034bbb80d31107cc359ebd8522ea1c82db35ea + PKG_MAINTAINER:=Jo-Philipp Wich + PKG_LICENSE:=GPL-2.0 + ++PKG_FLAGS := nonshared ++ ++PKG_CONFIG_DEPENDS := \ ++ CONFIG_PACKAGE_kmod-brcm-wl \ ++ CONFIG_PACKAGE_kmod-brcm-wl-mini \ ++ CONFIG_PACKAGE_kmod-brcm-wl-mimo \ ++ CONFIG_PACKAGE_kmod-cfg80211 ++ + IWINFO_ABI_VERSION:=20210430 + + include $(INCLUDE_DIR)/package.mk +-- +2.25.1 + diff --git a/backports/0016-kernel-modules-move-act_gact-into-kmod-sched-core.patch b/backports/0016-kernel-modules-move-act_gact-into-kmod-sched-core.patch deleted file mode 100644 index be8f380cc..000000000 --- a/backports/0016-kernel-modules-move-act_gact-into-kmod-sched-core.patch +++ /dev/null @@ -1,45 +0,0 @@ -From 6c7e11cccbd28224a9a473a36df1102b4257d356 Mon Sep 17 00:00:00 2001 -From: DENG Qingfang -Date: Fri, 9 Apr 2021 12:25:08 +0800 -Subject: [PATCH 5/6] kernel/modules: move act_gact into kmod-sched-core - -As the name suggests, act_gact has the generic actions such as dropping -and accepting packets, so move it into kmod-sched-core. - -Signed-off-by: DENG Qingfang ---- - package/kernel/linux/modules/netsupport.mk | 4 ++-- - 1 file changed, 2 insertions(+), 2 deletions(-) - -diff --git a/package/kernel/linux/modules/netsupport.mk b/package/kernel/linux/modules/netsupport.mk -index 9fd49c1392..4343e850e9 100644 ---- a/package/kernel/linux/modules/netsupport.mk -+++ b/package/kernel/linux/modules/netsupport.mk -@@ -721,7 +721,7 @@ $(eval $(call KernelPackage,mppe)) - - - SCHED_MODULES = $(patsubst $(LINUX_DIR)/net/sched/%.ko,%,$(wildcard $(LINUX_DIR)/net/sched/*.ko)) --SCHED_MODULES_CORE = sch_ingress sch_fq_codel sch_hfsc sch_htb sch_tbf cls_basic cls_fw cls_route cls_flow cls_tcindex cls_u32 em_u32 act_mirred act_skbedit cls_matchall -+SCHED_MODULES_CORE = sch_ingress sch_fq_codel sch_hfsc sch_htb sch_tbf cls_basic cls_fw cls_route cls_flow cls_tcindex cls_u32 em_u32 act_gact act_mirred act_skbedit cls_matchall - SCHED_MODULES_FILTER = $(SCHED_MODULES_CORE) act_connmark act_ctinfo sch_cake sch_netem sch_mqprio em_ipset cls_bpf cls_flower act_bpf act_vlan - SCHED_MODULES_EXTRA = $(filter-out $(SCHED_MODULES_FILTER),$(SCHED_MODULES)) - SCHED_FILES = $(patsubst %,$(LINUX_DIR)/net/sched/%.ko,$(filter $(SCHED_MODULES_CORE),$(SCHED_MODULES))) -@@ -745,6 +745,7 @@ define KernelPackage/sched-core - CONFIG_NET_CLS_ROUTE4 \ - CONFIG_NET_CLS_TCINDEX \ - CONFIG_NET_CLS_U32 \ -+ CONFIG_NET_ACT_GACT \ - CONFIG_NET_ACT_MIRRED \ - CONFIG_NET_ACT_SKBEDIT \ - CONFIG_NET_CLS_MATCHALL \ -@@ -899,7 +900,6 @@ define KernelPackage/sched - CONFIG_NET_SCH_FQ \ - CONFIG_NET_SCH_PIE \ - CONFIG_NET_ACT_POLICE \ -- CONFIG_NET_ACT_GACT \ - CONFIG_NET_ACT_IPT \ - CONFIG_NET_ACT_PEDIT \ - CONFIG_NET_ACT_SIMP \ --- -2.25.1 - diff --git a/backports/0037-netifd-update-to-latest-HEAD.patch b/backports/0017-netifd-update-to-latest-HEAD.patch similarity index 50% rename from backports/0037-netifd-update-to-latest-HEAD.patch rename to backports/0017-netifd-update-to-latest-HEAD.patch index d7fea494d..2e3c4c6d5 100644 --- a/backports/0037-netifd-update-to-latest-HEAD.patch +++ b/backports/0017-netifd-update-to-latest-HEAD.patch @@ -1,29 +1,26 @@ -From a622ab0c15a2f58b724362339d6b467c02ee7576 Mon Sep 17 00:00:00 2001 +From 3bc625814c04a24cdf16587c2adb2060a77a5e1a Mon Sep 17 00:00:00 2001 From: John Crispin Date: Thu, 27 May 2021 13:24:47 +0200 -Subject: [PATCH 01/57] netifd: update to latest HEAD +Subject: [PATCH 17/27] netifd: update to latest HEAD Signed-off-by: John Crispin --- - package/network/config/netifd/Makefile | 14 +++++++++----- - .../network/config/netifd/files/etc/udhcpc.user | 1 + - .../config/netifd/files/lib/netifd/dhcp.script | 3 +++ + package/network/config/netifd/Makefile | 8 +++----- .../netifd/patches/002-fix-dhcp-issue.patch | 17 +++++++++++++++++ - 4 files changed, 30 insertions(+), 5 deletions(-) - create mode 100644 package/network/config/netifd/files/etc/udhcpc.user + 2 files changed, 20 insertions(+), 5 deletions(-) create mode 100644 package/network/config/netifd/patches/002-fix-dhcp-issue.patch diff --git a/package/network/config/netifd/Makefile b/package/network/config/netifd/Makefile -index 7061456b08..13c1d96ed7 100644 +index 4b5f110da2..13c1d96ed7 100644 --- a/package/network/config/netifd/Makefile +++ b/package/network/config/netifd/Makefile @@ -5,16 +5,14 @@ PKG_RELEASE:=1 PKG_SOURCE_PROTO:=git PKG_SOURCE_URL=$(PROJECT_GIT)/project/netifd.git --PKG_SOURCE_DATE:=2021-01-09 --PKG_SOURCE_VERSION:=c00c8335d6188daa326ecfe5a62da15a9b9987e1 --PKG_MIRROR_HASH:=c740e51e0cec13eec336ba1c7a643db3b64a9a2235f8c1b73a566cb89e841190 +-PKG_SOURCE_DATE:=2021-07-26 +-PKG_SOURCE_VERSION:=440eb0647708274cc8d7d9e7c2bb0cfdfba90023 +-PKG_MIRROR_HASH:=eed957036ab608fdc49bdf801fc5b4405fcd2a3a5e5d3343ec39898e156c10e9 +PKG_SOURCE_DATE:=2021-09-01 +PKG_SOURCE_VERSION:=300b1220fab38600f102bb8cfcc59a29ce41b095 +PKG_MIRROR_HASH:=310fa90059795b1c956f9822db712ecc58bc19725b0f05f98c9e0a6824c8ca36 @@ -37,46 +34,6 @@ index 7061456b08..13c1d96ed7 100644 include $(INCLUDE_DIR)/package.mk include $(INCLUDE_DIR)/cmake.mk -@@ -25,6 +23,11 @@ define Package/netifd - TITLE:=OpenWrt Network Interface Configuration Daemon - endef - -+define Package/netifd/conffiles -+/etc/udhcpc.user -+/etc/udhcpc.user.d/ -+endef -+ - TARGET_CFLAGS += \ - -I$(STAGING_DIR)/usr/include/libnl-tiny \ - -I$(STAGING_DIR)/usr/include \ -@@ -40,6 +43,7 @@ define Package/netifd/install - $(INSTALL_DIR) $(1)/sbin - $(INSTALL_BIN) $(PKG_BUILD_DIR)/netifd $(1)/sbin/ - $(CP) ./files/* $(1)/ -+ $(INSTALL_DIR) $(1)/etc/udhcpc.user.d/ - $(CP) $(PKG_BUILD_DIR)/scripts/* $(1)/lib/netifd/ - endef - -diff --git a/package/network/config/netifd/files/etc/udhcpc.user b/package/network/config/netifd/files/etc/udhcpc.user -new file mode 100644 -index 0000000000..78e2ba5f18 ---- /dev/null -+++ b/package/network/config/netifd/files/etc/udhcpc.user -@@ -0,0 +1 @@ -+# This script is sourced by udhcpc's dhcp.script at every DHCP event. -diff --git a/package/network/config/netifd/files/lib/netifd/dhcp.script b/package/network/config/netifd/files/lib/netifd/dhcp.script -index 6585b641d6..e46005d84c 100755 ---- a/package/network/config/netifd/files/lib/netifd/dhcp.script -+++ b/package/network/config/netifd/files/lib/netifd/dhcp.script -@@ -112,5 +112,8 @@ esac - - # user rules - [ -f /etc/udhcpc.user ] && . /etc/udhcpc.user "$@" -+for f in /etc/udhcpc.user.d/*; do -+ [ -f "$f" ] && (. "$f" "$@") -+done - - exit 0 diff --git a/package/network/config/netifd/patches/002-fix-dhcp-issue.patch b/package/network/config/netifd/patches/002-fix-dhcp-issue.patch new file mode 100644 index 0000000000..6f1d2e708e diff --git a/backports/0038-mac80211-update-to-latest-HEAD.patch b/backports/0018-mac80211-update-to-latest-HEAD.patch similarity index 60% rename from backports/0038-mac80211-update-to-latest-HEAD.patch rename to backports/0018-mac80211-update-to-latest-HEAD.patch index 6fdd88acc..ff56c69e2 100644 --- a/backports/0038-mac80211-update-to-latest-HEAD.patch +++ b/backports/0018-mac80211-update-to-latest-HEAD.patch @@ -1,25 +1,23 @@ -From 2636d06404c24ec6c2ad8395ad1dc8d26875be7a Mon Sep 17 00:00:00 2001 +From 379e136c94ecb35b984e3ac7cc7ef493b60cb1b6 Mon Sep 17 00:00:00 2001 From: John Crispin -Date: Thu, 27 May 2021 13:25:03 +0200 -Subject: [PATCH 01/44] mac80211: update to latest HEAD +Date: Sat, 4 Sep 2021 05:47:27 +0200 +Subject: [PATCH 18/27] mac80211: update to latest HEAD Signed-off-by: John Crispin --- - package/kernel/mac80211/Makefile | 21 +- - package/kernel/mac80211/ath.mk | 13 +- + package/kernel/mac80211/Makefile | 15 +- + package/kernel/mac80211/ath.mk | 14 +- package/kernel/mac80211/broadcom.mk | 4 +- .../mac80211/files/lib/netifd/mac80211.sh | 36 - - .../files/lib/netifd/wireless/mac80211.sh | 195 ++- + .../files/lib/netifd/wireless/mac80211.sh | 184 ++- .../mac80211/files/lib/wifi/mac80211.sh | 110 +- - package/kernel/mac80211/mac80211.sh.diff | 58 + .../patches/ath/402-ath_regd_optional.patch | 2 +- - ...itting-to-stations-in-dynamic-SMPS-m.patch | 49 - .../080-ath10k_thermal_config.patch | 2 +- ...21-ath10k_init_devices_synchronously.patch | 0 - ...h10k-increase-rx-buffer-size-to-2048.patch | 2 +- - .../930-ath10k_add_tpt_led_trigger.patch | 4 +- - ...rolling-support-for-various-chipsets.patch | 4 +- - ...75-ath10k-use-tpt-trigger-by-default.patch | 2 +- + ...h10k-increase-rx-buffer-size-to-2048.patch | 0 + .../930-ath10k_add_tpt_led_trigger.patch | 0 + ...rolling-support-for-various-chipsets.patch | 2 +- + ...75-ath10k-use-tpt-trigger-by-default.patch | 0 ...980-ath10k-fix-max-antenna-gain-unit.patch | 0 ...-power-reduction-for-US-regulatory-d.patch | 0 .../201-ath5k-WAR-for-AR71xx-PCI-bug.patch | 0 @@ -36,77 +34,49 @@ Signed-off-by: John Crispin .../401-ath9k_blink_default.patch | 0 .../410-ath9k_allow_adhoc_and_ap.patch | 0 ...abled-MFP-capability-unconditionally.patch | 0 - .../500-ath9k_eeprom_debugfs.patch | 4 +- + .../500-ath9k_eeprom_debugfs.patch | 0 .../{ath => ath9k}/501-ath9k_ahb_init.patch | 0 .../510-ath9k_intr_mitigation_tweak.patch | 0 .../511-ath9k_reduce_rxbuf.patch | 0 - .../512-ath9k_channelbw_debugfs.patch | 4 +- + .../512-ath9k_channelbw_debugfs.patch | 0 .../513-ath9k_add_pci_ids.patch | 0 - .../{ath => ath9k}/530-ath9k_extra_leds.patch | 10 +- + .../{ath => ath9k}/530-ath9k_extra_leds.patch | 0 .../531-ath9k_extra_platform_leds.patch | 0 .../540-ath9k_reduce_ani_interval.patch | 0 - .../542-ath9k_debugfs_diag.patch | 4 +- + .../542-ath9k_debugfs_diag.patch | 0 .../543-ath9k_entropy_from_adc.patch | 0 ...544-ath9k-ar933x-usb-hang-workaround.patch | 0 .../545-ath9k_ani_ws_detect.patch | 0 .../547-ath9k_led_defstate_fix.patch | 0 - .../548-ath9k_enable_gpio_chip.patch | 4 +- - .../549-ath9k_enable_gpio_buttons.patch | 2 +- + .../548-ath9k_enable_gpio_chip.patch | 0 + .../549-ath9k_enable_gpio_buttons.patch | 0 .../550-ath9k-disable-bands-via-dt.patch | 0 - .../551-ath9k_ubnt_uap_plus_hsr.patch | 4 +- - .../552-ath9k-ahb_of.patch} | 2 +- + .../551-ath9k_ubnt_uap_plus_hsr.patch | 2 +- + .../552-ath9k-ahb_of.patch} | 0 .../553-ath9k_of_gpio_mask.patch | 0 - ...-register-wiphy-s-during-module_init.patch | 10 - - .../patches/build/001-fix_build.patch | 8 +- - ...700-mwl8k-missing-pci-id-for-WNR854T.patch | 2 +- - ...940-mwl8k_init_devices_synchronously.patch | 4 +- .../602-rt2x00-introduce-rt2x00eeprom.patch | 2 +- - ...ent-set_tim-by-update-beacon-content.patch | 118 ++ - .../patches/subsys/010-sync-nl80211_h.patch | 297 ++++ - .../100-remove-cryptoapi-dependencies.patch | 698 --------- + .../100-remove-cryptoapi-dependencies.patch | 699 --------- .../patches/subsys/130-disable-fils.patch | 32 - ...aes-cmac-switch-to-shash-CMAC-driver.patch | 230 --- .../132-mac80211-remove-cmac-dependency.patch | 10 - - .../subsys/150-disable_addr_notifier.patch | 6 +- - .../mac80211/patches/subsys/210-ap_scan.patch | 2 +- - ...ort-immediate-reconnect-request-hint.patch | 38 +- - ...-driver-based-disconnect-with-reconn.patch | 34 +- - ...port-to-configure-SAE-PWE-value-to-d.patch | 74 + - ...-get_default_func-move-default-flow-.patch | 2 +- - ...add-rx-decapsulation-offload-support.patch | 26 +- - ...le-QoS-support-for-nl80211-ctrl-port.patch | 116 ++ ...320-mac80211_hwsim-add-6GHz-channels.patch | 123 ++ ...211_hwsim-make-6-GHz-channels-usable.patch | 74 + ...-remove-legacy-minstrel-rate-control.patch | 2 +- - ...-minstrel_ht-fix-MINSTREL_FRAC-macro.patch | 21 + - .../370-mac80211-fix-TXQ-AC-confusion.patch | 61 - - ...pply-flow-control-on-management-fram.patch | 4 +- - ...set-sk_pacing_shift-for-802.3-txpath.patch | 2 +- - ...-Rx-timestamp-calculation-for-all-pr.patch | 2 +- - ...c80211-fix-time-is-after-bug-in-mlme.patch | 31 - - ...MPDU-session-check-from-minstrel_ht-.patch | 126 ++ - ...eee80211_tx_h_rate_ctrl-when-dequeue.patch | 114 ++ - ...te-control-support-for-encap-offload.patch | 119 ++ - ...11-minstrel_ht-fix-sample-time-check.patch | 23 + - ...iwlwifi-specific-workaround-that-bro.patch | 51 + - ...rting-aggregation-sessions-on-mesh-i.patch | 112 ++ ...introduce-aql_enable-node-in-debugfs.patch | 111 ++ ...ange-struct-txq_info-for-fewer-holes.patch | 39 + ...to-a-virtual-time-based-airtime-sche.patch | 1277 +++++++++++++++++ ...bling-4-address-mode-on-a-sta-vif-af.patch | 72 + ...on-API-to-configure-SAR-power-limita.patch | 398 +++++ ...mac80211-add-ieee80211_set_sar_specs.patch | 51 + - .../500-mac80211_configure_antenna_gain.patch | 24 +- - 92 files changed, 3737 insertions(+), 1345 deletions(-) + .../500-mac80211_configure_antenna_gain.patch | 16 +- + 64 files changed, 2420 insertions(+), 1087 deletions(-) delete mode 100644 package/kernel/mac80211/files/lib/netifd/mac80211.sh - create mode 100644 package/kernel/mac80211/mac80211.sh.diff - delete mode 100644 package/kernel/mac80211/patches/ath/560-ath9k-fix-transmitting-to-stations-in-dynamic-SMPS-m.patch rename package/kernel/mac80211/patches/{ath => ath10k}/080-ath10k_thermal_config.patch (97%) rename package/kernel/mac80211/patches/{ath => ath10k}/921-ath10k_init_devices_synchronously.patch (100%) - rename package/kernel/mac80211/patches/{ath => ath10k}/922-ath10k-increase-rx-buffer-size-to-2048.patch (96%) - rename package/kernel/mac80211/patches/{ath => ath10k}/930-ath10k_add_tpt_led_trigger.patch (89%) + rename package/kernel/mac80211/patches/{ath => ath10k}/922-ath10k-increase-rx-buffer-size-to-2048.patch (100%) + rename package/kernel/mac80211/patches/{ath => ath10k}/930-ath10k_add_tpt_led_trigger.patch (100%) rename package/kernel/mac80211/patches/{ath => ath10k}/974-ath10k_add-LED-and-GPIO-controlling-support-for-various-chipsets.patch (99%) - rename package/kernel/mac80211/patches/{ath => ath10k}/975-ath10k-use-tpt-trigger-by-default.patch (96%) + rename package/kernel/mac80211/patches/{ath => ath10k}/975-ath10k-use-tpt-trigger-by-default.patch (100%) rename package/kernel/mac80211/patches/{ath => ath10k}/980-ath10k-fix-max-antenna-gain-unit.patch (100%) rename package/kernel/mac80211/patches/{ath => ath10k}/981-ath10k-adjust-tx-power-reduction-for-US-regulatory-d.patch (100%) rename package/kernel/mac80211/patches/{ath => ath5k}/201-ath5k-WAR-for-AR71xx-PCI-bug.patch (100%) @@ -123,45 +93,32 @@ Signed-off-by: John Crispin rename package/kernel/mac80211/patches/{ath => ath9k}/401-ath9k_blink_default.patch (100%) rename package/kernel/mac80211/patches/{ath => ath9k}/410-ath9k_allow_adhoc_and_ap.patch (100%) rename package/kernel/mac80211/patches/{ath => ath9k}/450-ath9k-enabled-MFP-capability-unconditionally.patch (100%) - rename package/kernel/mac80211/patches/{ath => ath9k}/500-ath9k_eeprom_debugfs.patch (92%) + rename package/kernel/mac80211/patches/{ath => ath9k}/500-ath9k_eeprom_debugfs.patch (100%) rename package/kernel/mac80211/patches/{ath => ath9k}/501-ath9k_ahb_init.patch (100%) rename package/kernel/mac80211/patches/{ath => ath9k}/510-ath9k_intr_mitigation_tweak.patch (100%) rename package/kernel/mac80211/patches/{ath => ath9k}/511-ath9k_reduce_rxbuf.patch (100%) - rename package/kernel/mac80211/patches/{ath => ath9k}/512-ath9k_channelbw_debugfs.patch (96%) + rename package/kernel/mac80211/patches/{ath => ath9k}/512-ath9k_channelbw_debugfs.patch (100%) rename package/kernel/mac80211/patches/{ath => ath9k}/513-ath9k_add_pci_ids.patch (100%) - rename package/kernel/mac80211/patches/{ath => ath9k}/530-ath9k_extra_leds.patch (95%) + rename package/kernel/mac80211/patches/{ath => ath9k}/530-ath9k_extra_leds.patch (100%) rename package/kernel/mac80211/patches/{ath => ath9k}/531-ath9k_extra_platform_leds.patch (100%) rename package/kernel/mac80211/patches/{ath => ath9k}/540-ath9k_reduce_ani_interval.patch (100%) - rename package/kernel/mac80211/patches/{ath => ath9k}/542-ath9k_debugfs_diag.patch (96%) + rename package/kernel/mac80211/patches/{ath => ath9k}/542-ath9k_debugfs_diag.patch (100%) rename package/kernel/mac80211/patches/{ath => ath9k}/543-ath9k_entropy_from_adc.patch (100%) rename package/kernel/mac80211/patches/{ath => ath9k}/544-ath9k-ar933x-usb-hang-workaround.patch (100%) rename package/kernel/mac80211/patches/{ath => ath9k}/545-ath9k_ani_ws_detect.patch (100%) rename package/kernel/mac80211/patches/{ath => ath9k}/547-ath9k_led_defstate_fix.patch (100%) - rename package/kernel/mac80211/patches/{ath => ath9k}/548-ath9k_enable_gpio_chip.patch (98%) - rename package/kernel/mac80211/patches/{ath => ath9k}/549-ath9k_enable_gpio_buttons.patch (98%) + rename package/kernel/mac80211/patches/{ath => ath9k}/548-ath9k_enable_gpio_chip.patch (100%) + rename package/kernel/mac80211/patches/{ath => ath9k}/549-ath9k_enable_gpio_buttons.patch (100%) rename package/kernel/mac80211/patches/{ath => ath9k}/550-ath9k-disable-bands-via-dt.patch (100%) rename package/kernel/mac80211/patches/{ath => ath9k}/551-ath9k_ubnt_uap_plus_hsr.patch (99%) - rename package/kernel/mac80211/patches/{ath/552-ahb_of.patch => ath9k/552-ath9k-ahb_of.patch} (99%) + rename package/kernel/mac80211/patches/{ath/552-ahb_of.patch => ath9k/552-ath9k-ahb_of.patch} (100%) rename package/kernel/mac80211/patches/{ath => ath9k}/553-ath9k_of_gpio_mask.patch (100%) - create mode 100644 package/kernel/mac80211/patches/rtl/002-v5.13-rtlwifi-implement-set_tim-by-update-beacon-content.patch - create mode 100644 package/kernel/mac80211/patches/subsys/010-sync-nl80211_h.patch delete mode 100644 package/kernel/mac80211/patches/subsys/100-remove-cryptoapi-dependencies.patch delete mode 100644 package/kernel/mac80211/patches/subsys/130-disable-fils.patch delete mode 100644 package/kernel/mac80211/patches/subsys/131-Revert-mac80211-aes-cmac-switch-to-shash-CMAC-driver.patch delete mode 100644 package/kernel/mac80211/patches/subsys/132-mac80211-remove-cmac-dependency.patch - create mode 100644 package/kernel/mac80211/patches/subsys/302-cfg80211-Add-support-to-configure-SAE-PWE-value-to-d.patch - create mode 100644 package/kernel/mac80211/patches/subsys/316-mac80211-enable-QoS-support-for-nl80211-ctrl-port.patch create mode 100644 package/kernel/mac80211/patches/subsys/320-mac80211_hwsim-add-6GHz-channels.patch create mode 100644 package/kernel/mac80211/patches/subsys/321-mac80211_hwsim-make-6-GHz-channels-usable.patch - create mode 100644 package/kernel/mac80211/patches/subsys/353-mac80211-minstrel_ht-fix-MINSTREL_FRAC-macro.patch - delete mode 100644 package/kernel/mac80211/patches/subsys/370-mac80211-fix-TXQ-AC-confusion.patch - delete mode 100644 package/kernel/mac80211/patches/subsys/374-mac80211-fix-time-is-after-bug-in-mlme.patch - create mode 100644 package/kernel/mac80211/patches/subsys/374-mac80211-move-A-MPDU-session-check-from-minstrel_ht-.patch - create mode 100644 package/kernel/mac80211/patches/subsys/375-mac80211-call-ieee80211_tx_h_rate_ctrl-when-dequeue.patch - create mode 100644 package/kernel/mac80211/patches/subsys/376-mac80211-add-rate-control-support-for-encap-offload.patch - create mode 100644 package/kernel/mac80211/patches/subsys/377-mac80211-minstrel_ht-fix-sample-time-check.patch - create mode 100644 package/kernel/mac80211/patches/subsys/378-mac80211-remove-iwlwifi-specific-workaround-that-bro.patch - create mode 100644 package/kernel/mac80211/patches/subsys/379-mac80211-fix-starting-aggregation-sessions-on-mesh-i.patch create mode 100644 package/kernel/mac80211/patches/subsys/380-mac80211-introduce-aql_enable-node-in-debugfs.patch create mode 100644 package/kernel/mac80211/patches/subsys/381-mac80211-rearrange-struct-txq_info-for-fewer-holes.patch create mode 100644 package/kernel/mac80211/patches/subsys/382-mac80211-Switch-to-a-virtual-time-based-airtime-sche.patch @@ -170,23 +127,9 @@ Signed-off-by: John Crispin create mode 100644 package/kernel/mac80211/patches/subsys/385-mac80211-add-ieee80211_set_sar_specs.patch diff --git a/package/kernel/mac80211/Makefile b/package/kernel/mac80211/Makefile -index f6ad06452f..dd39c2d069 100644 +index dd9ec172ca..dd39c2d069 100644 --- a/package/kernel/mac80211/Makefile +++ b/package/kernel/mac80211/Makefile -@@ -10,10 +10,10 @@ include $(INCLUDE_DIR)/kernel.mk - - PKG_NAME:=mac80211 - --PKG_VERSION:=5.10.16-1 -+PKG_VERSION:=5.10.42-1 - PKG_RELEASE:=1 --PKG_SOURCE_URL:=@KERNEL/linux/kernel/projects/backports/stable/v5.10.16/ --PKG_HASH:=12856db780c5023edc47e2d18486eb3346bb7c82f1f2fc48deb3b163142f7d2d -+PKG_SOURCE_URL:=@KERNEL/linux/kernel/projects/backports/stable/v5.10.42/ -+PKG_HASH:=6876520105240844fdb32d1dcdf2bfdea291a37a96f16c892fda3776ba714fcb - - PKG_SOURCE:=backports-$(PKG_VERSION).tar.xz - PKG_BUILD_DIR:=$(KERNEL_BUILD_DIR)/backports-$(PKG_VERSION) @@ -98,7 +98,7 @@ PKG_CONFIG_DEPENDS += \ define KernelPackage/cfg80211 $(call KernelPackage/mac80211/Default) @@ -244,7 +187,7 @@ index f6ad06452f..dd39c2d069 100644 $(INSTALL_DIR) $(1)/etc/hotplug.d/ieee80211 $(INSTALL_DATA) ./files/mac80211.hotplug $(1)/etc/hotplug.d/ieee80211/10-wifi-detect diff --git a/package/kernel/mac80211/ath.mk b/package/kernel/mac80211/ath.mk -index f209c95ba8..ba03ae11a6 100644 +index f209c95ba8..ad2860a98e 100644 --- a/package/kernel/mac80211/ath.mk +++ b/package/kernel/mac80211/ath.mk @@ -34,7 +34,7 @@ ifdef CONFIG_PACKAGE_MAC80211_TRACING @@ -256,12 +199,13 @@ index f209c95ba8..ba03ae11a6 100644 config-$(CONFIG_PACKAGE_ATH_DEBUG) += ATH_DEBUG ATH10K_DEBUG ATH9K_STATION_STATISTICS config-$(CONFIG_PACKAGE_ATH_DFS) += ATH9K_DFS_CERTIFIED ATH10K_DFS_CERTIFIED config-$(CONFIG_PACKAGE_ATH_SPECTRAL) += ATH9K_COMMON_SPECTRAL ATH10K_SPECTRAL -@@ -42,11 +42,10 @@ config-$(CONFIG_PACKAGE_ATH_DYNACK) += ATH9K_DYNACK +@@ -42,11 +42,11 @@ config-$(CONFIG_PACKAGE_ATH_DYNACK) += ATH9K_DYNACK config-$(call config_package,ath9k) += ATH9K config-$(call config_package,ath9k-common) += ATH9K_COMMON config-$(call config_package,owl-loader) += ATH9K_PCI_NO_EEPROM -config-$(CONFIG_TARGET_ar71xx) += ATH9K_AHB config-$(CONFIG_TARGET_ath79) += ATH9K_AHB ++config-$(CONFIG_TARGET_ar71xx) += ATH9K_AHB config-$(CONFIG_TARGET_ipq40xx) += ATH10K_AHB config-$(CONFIG_PCI) += ATH9K_PCI -config-$(CONFIG_ATH_USER_REGD) += ATH_USER_REGD @@ -269,7 +213,7 @@ index f209c95ba8..ba03ae11a6 100644 config-$(CONFIG_ATH9K_HWRNG) += ATH9K_HWRNG config-$(CONFIG_ATH9K_SUPPORT_PCOEM) += ATH9K_PCOEM config-$(CONFIG_ATH9K_TX99) += ATH9K_TX99 -@@ -126,7 +125,7 @@ endef +@@ -126,7 +126,7 @@ endef define KernelPackage/ath $(call KernelPackage/mac80211/Default) TITLE:=Atheros common driver part @@ -278,7 +222,7 @@ index f209c95ba8..ba03ae11a6 100644 FILES:=$(PKG_BUILD_DIR)/drivers/net/wireless/ath/ath.ko MENU:=1 endef -@@ -191,7 +190,7 @@ define KernelPackage/ath9k-common +@@ -191,7 +191,7 @@ define KernelPackage/ath9k-common TITLE:=Atheros 802.11n wireless devices (common code for ath9k and ath9k_htc) URL:=https://wireless.wiki.kernel.org/en/users/drivers/ath9k HIDDEN:=1 @@ -287,7 +231,7 @@ index f209c95ba8..ba03ae11a6 100644 FILES:= \ $(PKG_BUILD_DIR)/drivers/net/wireless/ath/ath9k/ath9k_common.ko \ $(PKG_BUILD_DIR)/drivers/net/wireless/ath/ath9k/ath9k_hw.ko -@@ -201,7 +200,7 @@ define KernelPackage/ath9k +@@ -201,7 +201,7 @@ define KernelPackage/ath9k $(call KernelPackage/mac80211/Default) TITLE:=Atheros 802.11n PCI wireless cards support URL:=https://wireless.wiki.kernel.org/en/users/drivers/ath9k @@ -296,7 +240,7 @@ index f209c95ba8..ba03ae11a6 100644 FILES:= \ $(PKG_BUILD_DIR)/drivers/net/wireless/ath/ath9k/ath9k.ko AUTOLOAD:=$(call AutoProbe,ath9k) -@@ -231,7 +230,7 @@ define KernelPackage/ath9k/config +@@ -231,7 +231,7 @@ define KernelPackage/ath9k/config config ATH9K_UBNTHSR bool "Support for Ubiquiti UniFi Outdoor+ access point" @@ -370,7 +314,7 @@ index 92e5c0e395..0000000000 - done -} diff --git a/package/kernel/mac80211/files/lib/netifd/wireless/mac80211.sh b/package/kernel/mac80211/files/lib/netifd/wireless/mac80211.sh -index 92c56afd24..a58af1fef0 100644 +index 9a9c35fb5f..a58af1fef0 100644 --- a/package/kernel/mac80211/files/lib/netifd/wireless/mac80211.sh +++ b/package/kernel/mac80211/files/lib/netifd/wireless/mac80211.sh @@ -1,7 +1,6 @@ @@ -708,20 +652,7 @@ index 92c56afd24..a58af1fef0 100644 json_get_values basic_rate_list basic_rate json_get_values scan_list scan_list json_select .. -@@ -907,10 +1028,8 @@ drv_mac80211_setup() { - return 1 - } - -- [ -z "$(uci -q -P /var/state show wireless._${phy})" ] && { -- uci -q -P /var/state set wireless._${phy}=phy -- wireless_set_data phy="$phy" -- } -+ wireless_set_data phy="$phy" -+ [ -z "$(uci -q -P /var/state show wireless._${phy})" ] && uci -q -P /var/state set wireless._${phy}=phy - - OLDAPLIST=$(uci -q -P /var/state get wireless._${phy}.aplist) - OLDSPLIST=$(uci -q -P /var/state get wireless._${phy}.splist) -@@ -935,7 +1054,7 @@ drv_mac80211_setup() { +@@ -933,7 +1054,7 @@ drv_mac80211_setup() { done # convert channel to frequency @@ -730,7 +661,7 @@ index 92c56afd24..a58af1fef0 100644 [ -n "$country" ] && { iw reg get | grep -q "^country $country:" || { -@@ -960,6 +1079,7 @@ drv_mac80211_setup() { +@@ -958,6 +1079,7 @@ drv_mac80211_setup() { set_default txantenna 0xffffffff set_default distance 0 set_default antenna_gain 0 @@ -738,25 +669,6 @@ index 92c56afd24..a58af1fef0 100644 [ "$txantenna" = "all" ] && txantenna=0xffffffff [ "$rxantenna" = "all" ] && rxantenna=0xffffffff -@@ -1003,6 +1123,7 @@ drv_mac80211_setup() { - [ -n "$hostapd_ctrl" ] && { - local no_reload=1 - if [ -n "$(ubus list | grep hostapd.$primary_ap)" ]; then -+ no_reload=0 - [ "${NEW_MD5}" = "${OLD_MD5}" ] || { - ubus call hostapd.$primary_ap reload - no_reload=$? -@@ -1077,6 +1198,10 @@ drv_mac80211_teardown() { - json_select data - json_get_vars phy - json_select .. -+ [ -n "$phy" ] || { -+ echo "Bug: PHY is undefined for device '$1'" -+ return 1 -+ } - - mac80211_interface_cleanup "$phy" - uci -q -P /var/state revert wireless._${phy} diff --git a/package/kernel/mac80211/files/lib/wifi/mac80211.sh b/package/kernel/mac80211/files/lib/wifi/mac80211.sh index 3e99f06693..6aa46b0c74 100644 --- a/package/kernel/mac80211/files/lib/wifi/mac80211.sh @@ -909,70 +821,6 @@ index 3e99f06693..6aa46b0c74 100644 set wireless.radio${devidx}.disabled=1 set wireless.default_radio${devidx}=wifi-iface -diff --git a/package/kernel/mac80211/mac80211.sh.diff b/package/kernel/mac80211/mac80211.sh.diff -new file mode 100644 -index 0000000000..2fb6d472b3 ---- /dev/null -+++ b/package/kernel/mac80211/mac80211.sh.diff -@@ -0,0 +1,58 @@ -+--- mac80211.sh 2021-06-05 15:10:48.522323044 +0200 -++++ mac80211.new 2021-06-08 10:09:52.652540350 +0200 -+@@ -1036,13 +1036,6 @@ -+ local found -+ -+ for wdev in $(list_phy_interfaces "$phy"); do -+- found=0 -+- for cwdev in $OLDAPLIST $OLDSPLIST $OLDUMLIST; do -+- if [ "$wdev" = "$cwdev" ]; then -+- found=1 -+- break -+- fi -+- done -+ if [ "$found" = "0" ]; then -+ ip link set dev "$wdev" down -+ iw dev "$wdev" del -+@@ -1107,33 +1100,24 @@ -+ for_each_interface "sta adhoc mesh monitor" mac80211_prepare_vif -+ NEWAPLIST= -+ for_each_interface "ap" mac80211_prepare_vif -+- NEW_MD5=$(test -e "${hostapd_conf_file}" && md5sum ${hostapd_conf_file}) -+- OLD_MD5=$(uci -q -P /var/state get wireless._${phy}.md5) -+- if [ "${NEWAPLIST}" != "${OLDAPLIST}" ]; then -+- mac80211_vap_cleanup hostapd "${OLDAPLIST}" -+- fi -++ mac80211_vap_cleanup hostapd "${OLDAPLIST}" -+ [ -n "${NEWAPLIST}" ] && mac80211_iw_interface_add "$phy" "${NEWAPLIST%% *}" __ap -+ local add_ap=0 -+ local primary_ap=${NEWAPLIST%% *} -+ [ -n "$hostapd_ctrl" ] && { -+ local no_reload=1 -+ if [ -n "$(ubus list | grep hostapd.$primary_ap)" ]; then -+- [ "${NEW_MD5}" = "${OLD_MD5}" ] || { -+- ubus call hostapd.$primary_ap reload -+- no_reload=$? -+- if [ "$no_reload" != "0" ]; then -+- mac80211_vap_cleanup hostapd "${OLDAPLIST}" -+- mac80211_vap_cleanup wpa_supplicant "$(uci -q -P /var/state get wireless._${phy}.splist)" -+- mac80211_vap_cleanup none "$(uci -q -P /var/state get wireless._${phy}.umlist)" -+- sleep 2 -+- mac80211_iw_interface_add "$phy" "${NEWAPLIST%% *}" __ap -+- for_each_interface "sta adhoc mesh monitor" mac80211_prepare_vif -+- fi -+- } -++ mac80211_vap_cleanup hostapd "${OLDAPLIST}" -++ mac80211_vap_cleanup wpa_supplicant "$(uci -q -P /var/state get wireless._${phy}.splist)" -++ mac80211_vap_cleanup none "$(uci -q -P /var/state get wireless._${phy}.umlist)" -++ sleep 2 -++ mac80211_iw_interface_add "$phy" "${NEWAPLIST%% *}" __ap -++ for_each_interface "sta adhoc mesh monitor" mac80211_prepare_vif -+ fi -+ if [ "$no_reload" != "0" ]; then -+ add_ap=1 -+ ubus wait_for hostapd -++ ip link set $primary_ap down -+ local hostapd_res="$(ubus call hostapd config_add "{\"iface\":\"$primary_ap\", \"config\":\"${hostapd_conf_file}\"}")" -+ ret="$?" -+ [ "$ret" != 0 -o -z "$hostapd_res" ] && { diff --git a/package/kernel/mac80211/patches/ath/402-ath_regd_optional.patch b/package/kernel/mac80211/patches/ath/402-ath_regd_optional.patch index bf87d3551a..3c9180b113 100644 --- a/package/kernel/mac80211/patches/ath/402-ath_regd_optional.patch @@ -986,61 +834,6 @@ index bf87d3551a..3c9180b113 100644 ATH_COMMON= WLAN_VENDOR_ATH= ATH_DEBUG= -diff --git a/package/kernel/mac80211/patches/ath/560-ath9k-fix-transmitting-to-stations-in-dynamic-SMPS-m.patch b/package/kernel/mac80211/patches/ath/560-ath9k-fix-transmitting-to-stations-in-dynamic-SMPS-m.patch -deleted file mode 100644 -index 68f3a31548..0000000000 ---- a/package/kernel/mac80211/patches/ath/560-ath9k-fix-transmitting-to-stations-in-dynamic-SMPS-m.patch -+++ /dev/null -@@ -1,49 +0,0 @@ --From: Felix Fietkau --Date: Sun, 14 Feb 2021 19:45:50 +0100 --Subject: [PATCH] ath9k: fix transmitting to stations in dynamic SMPS mode -- --When transmitting to a receiver in dynamic SMPS mode, all transmissions that --use multiple spatial streams need to be sent using CTS-to-self or RTS/CTS to --give the receiver's extra chains some time to wake up. --This fixes the tx rate getting stuck at <= MCS7 for some clients, especially --Intel ones, which make aggressive use of SMPS. -- --Cc: stable@vger.kernel.org --Reported-by: Martin Kennedy --Signed-off-by: Felix Fietkau ----- -- ----- a/drivers/net/wireless/ath/ath9k/ath9k.h --+++ b/drivers/net/wireless/ath/ath9k/ath9k.h --@@ -179,7 +179,8 @@ struct ath_frame_info { -- s8 txq; -- u8 keyix; -- u8 rtscts_rate; --- u8 retries : 7; --+ u8 retries : 6; --+ u8 dyn_smps : 1; -- u8 baw_tracked : 1; -- u8 tx_power; -- enum ath9k_key_type keytype:2; ----- a/drivers/net/wireless/ath/ath9k/xmit.c --+++ b/drivers/net/wireless/ath/ath9k/xmit.c --@@ -1271,6 +1271,11 @@ static void ath_buf_set_rate(struct ath_ -- is_40, is_sgi, is_sp); -- if (rix < 8 && (tx_info->flags & IEEE80211_TX_CTL_STBC)) -- info->rates[i].RateFlags |= ATH9K_RATESERIES_STBC; --+ if (rix >= 8 && fi->dyn_smps) { --+ info->rates[i].RateFlags |= --+ ATH9K_RATESERIES_RTS_CTS; --+ info->flags |= ATH9K_TXDESC_CTSENA; --+ } -- -- info->txpower[i] = ath_get_rate_txpower(sc, bf, rix, -- is_40, false); --@@ -2114,6 +2119,7 @@ static void setup_frame_info(struct ieee -- fi->keyix = an->ps_key; -- else -- fi->keyix = ATH9K_TXKEYIX_INVALID; --+ fi->dyn_smps = sta && sta->smps_mode == IEEE80211_SMPS_DYNAMIC; -- fi->keytype = keytype; -- fi->framelen = framelen; -- fi->tx_power = txpower; diff --git a/package/kernel/mac80211/patches/ath/080-ath10k_thermal_config.patch b/package/kernel/mac80211/patches/ath10k/080-ath10k_thermal_config.patch similarity index 97% rename from package/kernel/mac80211/patches/ath/080-ath10k_thermal_config.patch @@ -1062,50 +855,18 @@ similarity index 100% rename from package/kernel/mac80211/patches/ath/921-ath10k_init_devices_synchronously.patch rename to package/kernel/mac80211/patches/ath10k/921-ath10k_init_devices_synchronously.patch diff --git a/package/kernel/mac80211/patches/ath/922-ath10k-increase-rx-buffer-size-to-2048.patch b/package/kernel/mac80211/patches/ath10k/922-ath10k-increase-rx-buffer-size-to-2048.patch -similarity index 96% +similarity index 100% rename from package/kernel/mac80211/patches/ath/922-ath10k-increase-rx-buffer-size-to-2048.patch rename to package/kernel/mac80211/patches/ath10k/922-ath10k-increase-rx-buffer-size-to-2048.patch -index abce361673..8f7a60eec8 100644 ---- a/package/kernel/mac80211/patches/ath/922-ath10k-increase-rx-buffer-size-to-2048.patch -+++ b/package/kernel/mac80211/patches/ath10k/922-ath10k-increase-rx-buffer-size-to-2048.patch -@@ -26,7 +26,7 @@ Forwarded: https://patchwork.kernel.org/patch/11367055/ - - --- a/drivers/net/wireless/ath/ath10k/htt.h - +++ b/drivers/net/wireless/ath/ath10k/htt.h --@@ -2242,7 +2242,7 @@ struct htt_rx_chan_info { -+@@ -2243,7 +2243,7 @@ struct htt_rx_chan_info { - * Should be: sizeof(struct htt_host_rx_desc) + max rx MSDU size, - * rounded up to a cache line size. - */ diff --git a/package/kernel/mac80211/patches/ath/930-ath10k_add_tpt_led_trigger.patch b/package/kernel/mac80211/patches/ath10k/930-ath10k_add_tpt_led_trigger.patch -similarity index 89% +similarity index 100% rename from package/kernel/mac80211/patches/ath/930-ath10k_add_tpt_led_trigger.patch rename to package/kernel/mac80211/patches/ath10k/930-ath10k_add_tpt_led_trigger.patch -index 1fedd337ac..74b3292e0c 100644 ---- a/package/kernel/mac80211/patches/ath/930-ath10k_add_tpt_led_trigger.patch -+++ b/package/kernel/mac80211/patches/ath10k/930-ath10k_add_tpt_led_trigger.patch -@@ -1,6 +1,6 @@ - --- a/drivers/net/wireless/ath/ath10k/mac.c - +++ b/drivers/net/wireless/ath/ath10k/mac.c --@@ -9713,6 +9713,21 @@ static int ath10k_mac_init_rd(struct ath -+@@ -9708,6 +9708,21 @@ static int ath10k_mac_init_rd(struct ath - return 0; - } - -@@ -22,7 +22,7 @@ - int ath10k_mac_register(struct ath10k *ar) - { - static const u32 cipher_suites[] = { --@@ -10062,6 +10077,12 @@ int ath10k_mac_register(struct ath10k *a -+@@ -10057,6 +10072,12 @@ int ath10k_mac_register(struct ath10k *a - - ar->hw->weight_multiplier = ATH10K_AIRTIME_WEIGHT_MULTIPLIER; - diff --git a/package/kernel/mac80211/patches/ath/974-ath10k_add-LED-and-GPIO-controlling-support-for-various-chipsets.patch b/package/kernel/mac80211/patches/ath10k/974-ath10k_add-LED-and-GPIO-controlling-support-for-various-chipsets.patch similarity index 99% rename from package/kernel/mac80211/patches/ath/974-ath10k_add-LED-and-GPIO-controlling-support-for-various-chipsets.patch rename to package/kernel/mac80211/patches/ath10k/974-ath10k_add-LED-and-GPIO-controlling-support-for-various-chipsets.patch -index ab7cb669bb..fa007e73a1 100644 +index ce8effe3c3..fa007e73a1 100644 --- a/package/kernel/mac80211/patches/ath/974-ath10k_add-LED-and-GPIO-controlling-support-for-various-chipsets.patch +++ b/package/kernel/mac80211/patches/ath10k/974-ath10k_add-LED-and-GPIO-controlling-support-for-various-chipsets.patch @@ -114,7 +114,7 @@ v13: @@ -1117,31 +878,10 @@ index ab7cb669bb..fa007e73a1 100644 ATH10K_DEBUGFS= ATH10K_SPECTRAL= ATH10K_THERMAL= -@@ -456,7 +456,7 @@ v13: - { - --- a/drivers/net/wireless/ath/ath10k/wmi-tlv.c - +++ b/drivers/net/wireless/ath/ath10k/wmi-tlv.c --@@ -4585,6 +4585,8 @@ static const struct wmi_ops wmi_tlv_ops -+@@ -4594,6 +4594,8 @@ static const struct wmi_ops wmi_tlv_ops - .gen_echo = ath10k_wmi_tlv_op_gen_echo, - .gen_vdev_spectral_conf = ath10k_wmi_tlv_op_gen_vdev_spectral_conf, - .gen_vdev_spectral_enable = ath10k_wmi_tlv_op_gen_vdev_spectral_enable, diff --git a/package/kernel/mac80211/patches/ath/975-ath10k-use-tpt-trigger-by-default.patch b/package/kernel/mac80211/patches/ath10k/975-ath10k-use-tpt-trigger-by-default.patch -similarity index 96% +similarity index 100% rename from package/kernel/mac80211/patches/ath/975-ath10k-use-tpt-trigger-by-default.patch rename to package/kernel/mac80211/patches/ath10k/975-ath10k-use-tpt-trigger-by-default.patch -index f7569df33c..6da7bfa725 100644 ---- a/package/kernel/mac80211/patches/ath/975-ath10k-use-tpt-trigger-by-default.patch -+++ b/package/kernel/mac80211/patches/ath10k/975-ath10k-use-tpt-trigger-by-default.patch -@@ -42,7 +42,7 @@ Signed-off-by: Mathias Kresin - if (ret) - --- a/drivers/net/wireless/ath/ath10k/mac.c - +++ b/drivers/net/wireless/ath/ath10k/mac.c --@@ -10079,7 +10079,7 @@ int ath10k_mac_register(struct ath10k *a -+@@ -10074,7 +10074,7 @@ int ath10k_mac_register(struct ath10k *a - ar->hw->weight_multiplier = ATH10K_AIRTIME_WEIGHT_MULTIPLIER; - - #ifdef CPTCFG_MAC80211_LEDS diff --git a/package/kernel/mac80211/patches/ath/980-ath10k-fix-max-antenna-gain-unit.patch b/package/kernel/mac80211/patches/ath10k/980-ath10k-fix-max-antenna-gain-unit.patch similarity index 100% rename from package/kernel/mac80211/patches/ath/980-ath10k-fix-max-antenna-gain-unit.patch @@ -1207,29 +947,9 @@ similarity index 100% rename from package/kernel/mac80211/patches/ath/450-ath9k-enabled-MFP-capability-unconditionally.patch rename to package/kernel/mac80211/patches/ath9k/450-ath9k-enabled-MFP-capability-unconditionally.patch diff --git a/package/kernel/mac80211/patches/ath/500-ath9k_eeprom_debugfs.patch b/package/kernel/mac80211/patches/ath9k/500-ath9k_eeprom_debugfs.patch -similarity index 92% +similarity index 100% rename from package/kernel/mac80211/patches/ath/500-ath9k_eeprom_debugfs.patch rename to package/kernel/mac80211/patches/ath9k/500-ath9k_eeprom_debugfs.patch -index 786a3ed3fb..48ccc81308 100644 ---- a/package/kernel/mac80211/patches/ath/500-ath9k_eeprom_debugfs.patch -+++ b/package/kernel/mac80211/patches/ath9k/500-ath9k_eeprom_debugfs.patch -@@ -1,6 +1,6 @@ - --- a/drivers/net/wireless/ath/ath9k/debug.c - +++ b/drivers/net/wireless/ath/ath9k/debug.c --@@ -1361,6 +1361,53 @@ void ath9k_deinit_debug(struct ath_softc -+@@ -1364,6 +1364,53 @@ void ath9k_deinit_debug(struct ath_softc - ath9k_cmn_spectral_deinit_debug(&sc->spec_priv); - } - -@@ -54,7 +54,7 @@ - int ath9k_init_debug(struct ath_hw *ah) - { - struct ath_common *common = ath9k_hw_common(ah); --@@ -1380,6 +1427,8 @@ int ath9k_init_debug(struct ath_hw *ah) -+@@ -1383,6 +1430,8 @@ int ath9k_init_debug(struct ath_hw *ah) - ath9k_tx99_init_debug(sc); - ath9k_cmn_spectral_init_debug(&sc->spec_priv, sc->debug.debugfs_phy); - diff --git a/package/kernel/mac80211/patches/ath/501-ath9k_ahb_init.patch b/package/kernel/mac80211/patches/ath9k/501-ath9k_ahb_init.patch similarity index 100% rename from package/kernel/mac80211/patches/ath/501-ath9k_ahb_init.patch @@ -1243,84 +963,17 @@ similarity index 100% rename from package/kernel/mac80211/patches/ath/511-ath9k_reduce_rxbuf.patch rename to package/kernel/mac80211/patches/ath9k/511-ath9k_reduce_rxbuf.patch diff --git a/package/kernel/mac80211/patches/ath/512-ath9k_channelbw_debugfs.patch b/package/kernel/mac80211/patches/ath9k/512-ath9k_channelbw_debugfs.patch -similarity index 96% +similarity index 100% rename from package/kernel/mac80211/patches/ath/512-ath9k_channelbw_debugfs.patch rename to package/kernel/mac80211/patches/ath9k/512-ath9k_channelbw_debugfs.patch -index 80e33182f7..126d1d5c62 100644 ---- a/package/kernel/mac80211/patches/ath/512-ath9k_channelbw_debugfs.patch -+++ b/package/kernel/mac80211/patches/ath9k/512-ath9k_channelbw_debugfs.patch -@@ -1,6 +1,6 @@ - --- a/drivers/net/wireless/ath/ath9k/debug.c - +++ b/drivers/net/wireless/ath/ath9k/debug.c --@@ -1408,6 +1408,52 @@ static const struct file_operations fops -+@@ -1411,6 +1411,52 @@ static const struct file_operations fops - .owner = THIS_MODULE - }; - -@@ -53,7 +53,7 @@ - int ath9k_init_debug(struct ath_hw *ah) - { - struct ath_common *common = ath9k_hw_common(ah); --@@ -1429,6 +1475,8 @@ int ath9k_init_debug(struct ath_hw *ah) -+@@ -1432,6 +1478,8 @@ int ath9k_init_debug(struct ath_hw *ah) - - debugfs_create_file("eeprom", S_IRUSR, sc->debug.debugfs_phy, sc, - &fops_eeprom); diff --git a/package/kernel/mac80211/patches/ath/513-ath9k_add_pci_ids.patch b/package/kernel/mac80211/patches/ath9k/513-ath9k_add_pci_ids.patch similarity index 100% rename from package/kernel/mac80211/patches/ath/513-ath9k_add_pci_ids.patch rename to package/kernel/mac80211/patches/ath9k/513-ath9k_add_pci_ids.patch diff --git a/package/kernel/mac80211/patches/ath/530-ath9k_extra_leds.patch b/package/kernel/mac80211/patches/ath9k/530-ath9k_extra_leds.patch -similarity index 95% +similarity index 100% rename from package/kernel/mac80211/patches/ath/530-ath9k_extra_leds.patch rename to package/kernel/mac80211/patches/ath9k/530-ath9k_extra_leds.patch -index 1f19483064..5fd5c73a2f 100644 ---- a/package/kernel/mac80211/patches/ath/530-ath9k_extra_leds.patch -+++ b/package/kernel/mac80211/patches/ath9k/530-ath9k_extra_leds.patch -@@ -1,6 +1,6 @@ - --- a/drivers/net/wireless/ath/ath9k/ath9k.h - +++ b/drivers/net/wireless/ath/ath9k/ath9k.h --@@ -843,6 +843,9 @@ static inline int ath9k_dump_btcoex(stru -+@@ -844,6 +844,9 @@ static inline int ath9k_dump_btcoex(stru - #ifdef CPTCFG_MAC80211_LEDS - void ath_init_leds(struct ath_softc *sc); - void ath_deinit_leds(struct ath_softc *sc); -@@ -10,7 +10,7 @@ - #else - static inline void ath_init_leds(struct ath_softc *sc) - { --@@ -979,6 +982,13 @@ void ath_ant_comb_scan(struct ath_softc -+@@ -980,6 +983,13 @@ void ath_ant_comb_scan(struct ath_softc - - #define ATH9K_NUM_CHANCTX 2 /* supports 2 operating channels */ - -@@ -24,7 +24,7 @@ - struct ath_softc { - struct ieee80211_hw *hw; - struct device *dev; --@@ -1032,9 +1042,8 @@ struct ath_softc { -+@@ -1033,9 +1043,8 @@ struct ath_softc { - spinlock_t chan_lock; - - #ifdef CPTCFG_MAC80211_LEDS -@@ -192,7 +192,7 @@ - #endif - --- a/drivers/net/wireless/ath/ath9k/debug.c - +++ b/drivers/net/wireless/ath/ath9k/debug.c --@@ -1453,6 +1453,61 @@ static const struct file_operations fops -+@@ -1456,6 +1456,61 @@ static const struct file_operations fops - .llseek = default_llseek, - }; - -@@ -254,7 +254,7 @@ - - int ath9k_init_debug(struct ath_hw *ah) - { --@@ -1477,6 +1532,10 @@ int ath9k_init_debug(struct ath_hw *ah) -+@@ -1480,6 +1535,10 @@ int ath9k_init_debug(struct ath_hw *ah) - &fops_eeprom); - debugfs_create_file("chanbw", S_IRUSR | S_IWUSR, sc->debug.debugfs_phy, - sc, &fops_chanbw); diff --git a/package/kernel/mac80211/patches/ath/531-ath9k_extra_platform_leds.patch b/package/kernel/mac80211/patches/ath9k/531-ath9k_extra_platform_leds.patch similarity index 100% rename from package/kernel/mac80211/patches/ath/531-ath9k_extra_platform_leds.patch @@ -1330,29 +983,9 @@ similarity index 100% rename from package/kernel/mac80211/patches/ath/540-ath9k_reduce_ani_interval.patch rename to package/kernel/mac80211/patches/ath9k/540-ath9k_reduce_ani_interval.patch diff --git a/package/kernel/mac80211/patches/ath/542-ath9k_debugfs_diag.patch b/package/kernel/mac80211/patches/ath9k/542-ath9k_debugfs_diag.patch -similarity index 96% +similarity index 100% rename from package/kernel/mac80211/patches/ath/542-ath9k_debugfs_diag.patch rename to package/kernel/mac80211/patches/ath9k/542-ath9k_debugfs_diag.patch -index 76cb63a5c8..f93a6fe5cd 100644 ---- a/package/kernel/mac80211/patches/ath/542-ath9k_debugfs_diag.patch -+++ b/package/kernel/mac80211/patches/ath9k/542-ath9k_debugfs_diag.patch -@@ -1,6 +1,6 @@ - --- a/drivers/net/wireless/ath/ath9k/debug.c - +++ b/drivers/net/wireless/ath/ath9k/debug.c --@@ -1509,6 +1509,50 @@ static const struct file_operations fops -+@@ -1512,6 +1512,50 @@ static const struct file_operations fops - #endif - - -@@ -51,7 +51,7 @@ - int ath9k_init_debug(struct ath_hw *ah) - { - struct ath_common *common = ath9k_hw_common(ah); --@@ -1536,6 +1580,8 @@ int ath9k_init_debug(struct ath_hw *ah) -+@@ -1539,6 +1583,8 @@ int ath9k_init_debug(struct ath_hw *ah) - debugfs_create_file("gpio_led", S_IWUSR, - sc->debug.debugfs_phy, sc, &fops_gpio_led); - #endif diff --git a/package/kernel/mac80211/patches/ath/543-ath9k_entropy_from_adc.patch b/package/kernel/mac80211/patches/ath9k/543-ath9k_entropy_from_adc.patch similarity index 100% rename from package/kernel/mac80211/patches/ath/543-ath9k_entropy_from_adc.patch @@ -1370,46 +1003,13 @@ similarity index 100% rename from package/kernel/mac80211/patches/ath/547-ath9k_led_defstate_fix.patch rename to package/kernel/mac80211/patches/ath9k/547-ath9k_led_defstate_fix.patch diff --git a/package/kernel/mac80211/patches/ath/548-ath9k_enable_gpio_chip.patch b/package/kernel/mac80211/patches/ath9k/548-ath9k_enable_gpio_chip.patch -similarity index 98% +similarity index 100% rename from package/kernel/mac80211/patches/ath/548-ath9k_enable_gpio_chip.patch rename to package/kernel/mac80211/patches/ath9k/548-ath9k_enable_gpio_chip.patch -index 78206d2860..88198a4562 100644 ---- a/package/kernel/mac80211/patches/ath/548-ath9k_enable_gpio_chip.patch -+++ b/package/kernel/mac80211/patches/ath9k/548-ath9k_enable_gpio_chip.patch -@@ -18,7 +18,7 @@ Signed-off-by: Felix Fietkau - - #include "common.h" - #include "debug.h" --@@ -989,6 +990,14 @@ struct ath_led { -+@@ -990,6 +991,14 @@ struct ath_led { - struct led_classdev cdev; - }; - -@@ -33,7 +33,7 @@ Signed-off-by: Felix Fietkau - struct ath_softc { - struct ieee80211_hw *hw; - struct device *dev; --@@ -1044,6 +1053,9 @@ struct ath_softc { -+@@ -1045,6 +1054,9 @@ struct ath_softc { - #ifdef CPTCFG_MAC80211_LEDS - const char *led_default_trigger; - struct list_head leds; diff --git a/package/kernel/mac80211/patches/ath/549-ath9k_enable_gpio_buttons.patch b/package/kernel/mac80211/patches/ath9k/549-ath9k_enable_gpio_buttons.patch -similarity index 98% +similarity index 100% rename from package/kernel/mac80211/patches/ath/549-ath9k_enable_gpio_buttons.patch rename to package/kernel/mac80211/patches/ath9k/549-ath9k_enable_gpio_buttons.patch -index 716e09f351..83076b8ae4 100644 ---- a/package/kernel/mac80211/patches/ath/549-ath9k_enable_gpio_buttons.patch -+++ b/package/kernel/mac80211/patches/ath9k/549-ath9k_enable_gpio_buttons.patch -@@ -10,7 +10,7 @@ Signed-off-by: Felix Fietkau - --- - --- a/drivers/net/wireless/ath/ath9k/ath9k.h - +++ b/drivers/net/wireless/ath/ath9k/ath9k.h --@@ -1055,6 +1055,7 @@ struct ath_softc { -+@@ -1056,6 +1056,7 @@ struct ath_softc { - struct list_head leds; - #ifdef CONFIG_GPIOLIB - struct ath9k_gpio_chip *gpiochip; diff --git a/package/kernel/mac80211/patches/ath/550-ath9k-disable-bands-via-dt.patch b/package/kernel/mac80211/patches/ath9k/550-ath9k-disable-bands-via-dt.patch similarity index 100% rename from package/kernel/mac80211/patches/ath/550-ath9k-disable-bands-via-dt.patch @@ -1418,7 +1018,7 @@ diff --git a/package/kernel/mac80211/patches/ath/551-ath9k_ubnt_uap_plus_hsr.pat similarity index 99% rename from package/kernel/mac80211/patches/ath/551-ath9k_ubnt_uap_plus_hsr.patch rename to package/kernel/mac80211/patches/ath9k/551-ath9k_ubnt_uap_plus_hsr.patch -index 7e3e1236f7..cd2bdbf1a0 100644 +index acb9ad443c..cd2bdbf1a0 100644 --- a/package/kernel/mac80211/patches/ath/551-ath9k_ubnt_uap_plus_hsr.patch +++ b/package/kernel/mac80211/patches/ath9k/551-ath9k_ubnt_uap_plus_hsr.patch @@ -371,7 +371,7 @@ @@ -1430,115 +1030,14 @@ index 7e3e1236f7..cd2bdbf1a0 100644 ATH9K_RFKILL= ATH9K_CHANNEL_CONTEXT= ATH9K_PCOEM= -@@ -381,7 +381,7 @@ - ATH9K_HTC_DEBUGFS= - --- a/drivers/net/wireless/ath/ath9k/Kconfig - +++ b/drivers/net/wireless/ath/ath9k/Kconfig --@@ -60,6 +60,19 @@ config ATH9K_AHB -+@@ -58,6 +58,19 @@ config ATH9K_AHB - Say Y, if you have a SoC with a compatible built-in - wireless MAC. Say N if unsure. - diff --git a/package/kernel/mac80211/patches/ath/552-ahb_of.patch b/package/kernel/mac80211/patches/ath9k/552-ath9k-ahb_of.patch -similarity index 99% +similarity index 100% rename from package/kernel/mac80211/patches/ath/552-ahb_of.patch rename to package/kernel/mac80211/patches/ath9k/552-ath9k-ahb_of.patch -index 2552bbc7a1..8fd6e4409b 100644 ---- a/package/kernel/mac80211/patches/ath/552-ahb_of.patch -+++ b/package/kernel/mac80211/patches/ath9k/552-ath9k-ahb_of.patch -@@ -325,7 +325,7 @@ - - #include "common.h" - #include "debug.h" --@@ -1011,6 +1012,9 @@ struct ath_softc { -+@@ -1012,6 +1013,9 @@ struct ath_softc { - struct ath_hw *sc_ah; - void __iomem *mem; - int irq; diff --git a/package/kernel/mac80211/patches/ath/553-ath9k_of_gpio_mask.patch b/package/kernel/mac80211/patches/ath9k/553-ath9k_of_gpio_mask.patch similarity index 100% rename from package/kernel/mac80211/patches/ath/553-ath9k_of_gpio_mask.patch rename to package/kernel/mac80211/patches/ath9k/553-ath9k_of_gpio_mask.patch -diff --git a/package/kernel/mac80211/patches/brcm/860-brcmfmac-register-wiphy-s-during-module_init.patch b/package/kernel/mac80211/patches/brcm/860-brcmfmac-register-wiphy-s-during-module_init.patch -index dc2295db1b..c9730e29fd 100644 ---- a/package/kernel/mac80211/patches/brcm/860-brcmfmac-register-wiphy-s-during-module_init.patch -+++ b/package/kernel/mac80211/patches/brcm/860-brcmfmac-register-wiphy-s-during-module_init.patch -@@ -11,16 +11,6 @@ module loads successfully. - Signed-off-by: RafaÅ‚ MiÅ‚ecki - --- - ----- a/drivers/net/wireless/broadcom/brcm80211/brcmfmac/core.c --+++ b/drivers/net/wireless/broadcom/brcm80211/brcmfmac/core.c --@@ -1557,6 +1557,7 @@ int __init brcmf_core_init(void) -- { -- if (!schedule_work(&brcmf_driver_work)) -- return -EBUSY; --+ flush_work(&brcmf_driver_work); -- -- return 0; -- } - --- a/drivers/net/wireless/broadcom/brcm80211/brcmfmac/firmware.c - +++ b/drivers/net/wireless/broadcom/brcm80211/brcmfmac/firmware.c - @@ -431,6 +431,7 @@ struct brcmf_fw { -diff --git a/package/kernel/mac80211/patches/build/001-fix_build.patch b/package/kernel/mac80211/patches/build/001-fix_build.patch -index e57ca190e4..8f63d36e2e 100644 ---- a/package/kernel/mac80211/patches/build/001-fix_build.patch -+++ b/package/kernel/mac80211/patches/build/001-fix_build.patch -@@ -55,8 +55,8 @@ - - echo "" ;\ - - done \ - - ) > Kconfig.kernel ;\ --- kver=$$($(MAKE) --no-print-directory -C $(KLIB_BUILD) kernelversion | \ --- sed 's/^\(\([3-5]\|2\.6\)\.[0-9]\+\).*/\1/;t;d') ;\ -+- kver=$$($(MAKE) --no-print-directory -C $(KLIB_BUILD) M=$(BACKPORT_DIR) \ -+- kernelversion | sed 's/^\(\([3-5]\|2\.6\)\.[0-9]\+\).*/\1/;t;d');\ - - test "$$kver" != "" || echo "Kernel version parse failed!" ;\ - - test "$$kver" != "" ;\ - - kvers="$$(seq 14 39 | sed 's/^/2.6./')" ;\ -@@ -112,8 +112,8 @@ - + @echo " done." - + - +Kconfig.versions: Kconfig.kernel --+ @kver=$$($(MAKE) --no-print-directory -C $(KLIB_BUILD) kernelversion | \ --+ sed 's/^\(\([3-5]\|2\.6\)\.[0-9]\+\).*/\1/;t;d') ;\ -++ @kver=$$($(MAKE) --no-print-directory -C $(KLIB_BUILD) M=$(BACKPORT_DIR) \ -++ kernelversion | sed 's/^\(\([3-5]\|2\.6\)\.[0-9]\+\).*/\1/;t;d');\ - + test "$$kver" != "" || echo "Kernel version parse failed!" ;\ - + test "$$kver" != "" ;\ - + kvers="$$(seq 14 39 | sed 's/^/2.6./')" ;\ -diff --git a/package/kernel/mac80211/patches/mwl/700-mwl8k-missing-pci-id-for-WNR854T.patch b/package/kernel/mac80211/patches/mwl/700-mwl8k-missing-pci-id-for-WNR854T.patch -index cfa40e1bd2..d358cfe367 100644 ---- a/package/kernel/mac80211/patches/mwl/700-mwl8k-missing-pci-id-for-WNR854T.patch -+++ b/package/kernel/mac80211/patches/mwl/700-mwl8k-missing-pci-id-for-WNR854T.patch -@@ -1,6 +1,6 @@ - --- a/drivers/net/wireless/marvell/mwl8k.c - +++ b/drivers/net/wireless/marvell/mwl8k.c --@@ -5694,6 +5694,7 @@ MODULE_FIRMWARE("mwl8k/fmimage_8366.fw") -+@@ -5695,6 +5695,7 @@ MODULE_FIRMWARE("mwl8k/fmimage_8366.fw") - MODULE_FIRMWARE(MWL8K_8366_AP_FW(MWL8K_8366_AP_FW_API)); - - static const struct pci_device_id mwl8k_pci_id_table[] = { -diff --git a/package/kernel/mac80211/patches/mwl/940-mwl8k_init_devices_synchronously.patch b/package/kernel/mac80211/patches/mwl/940-mwl8k_init_devices_synchronously.patch -index f3130f7ae7..a35cf1875a 100644 ---- a/package/kernel/mac80211/patches/mwl/940-mwl8k_init_devices_synchronously.patch -+++ b/package/kernel/mac80211/patches/mwl/940-mwl8k_init_devices_synchronously.patch -@@ -1,6 +1,6 @@ - --- a/drivers/net/wireless/marvell/mwl8k.c - +++ b/drivers/net/wireless/marvell/mwl8k.c --@@ -6279,6 +6279,8 @@ static int mwl8k_probe(struct pci_dev *p -+@@ -6280,6 +6280,8 @@ static int mwl8k_probe(struct pci_dev *p - - priv->running_bsses = 0; - -@@ -9,7 +9,7 @@ - return rc; - - err_stop_firmware: --@@ -6312,8 +6314,6 @@ static void mwl8k_remove(struct pci_dev -+@@ -6313,8 +6315,6 @@ static void mwl8k_remove(struct pci_dev - return; - priv = hw->priv; - diff --git a/package/kernel/mac80211/patches/rt2x00/602-rt2x00-introduce-rt2x00eeprom.patch b/package/kernel/mac80211/patches/rt2x00/602-rt2x00-introduce-rt2x00eeprom.patch index e74d9a9aa0..1c52132da6 100644 --- a/package/kernel/mac80211/patches/rt2x00/602-rt2x00-introduce-rt2x00eeprom.patch @@ -1551,439 +1050,12 @@ index e74d9a9aa0..1c52132da6 100644 RT2X00_LIB_CRYPTO= RT2X00_LIB_LEDS= RT2X00_LIB_DEBUGFS= -diff --git a/package/kernel/mac80211/patches/rtl/002-v5.13-rtlwifi-implement-set_tim-by-update-beacon-content.patch b/package/kernel/mac80211/patches/rtl/002-v5.13-rtlwifi-implement-set_tim-by-update-beacon-content.patch -new file mode 100644 -index 0000000000..3daf65e967 ---- /dev/null -+++ b/package/kernel/mac80211/patches/rtl/002-v5.13-rtlwifi-implement-set_tim-by-update-beacon-content.patch -@@ -0,0 +1,118 @@ -+Date: Mon, 19 Apr 2021 14:59:56 +0800 -+From: Ping-Ke Shih -+To: -+CC: , , -+ -+Subject: [PATCH] rtlwifi: implement set_tim by update beacon content -+ -+Once beacon content is changed, we update the content to wifi card by -+send_beacon_frame(). Then, STA with PS can wake up properly to receive its -+packets. -+ -+Since we update beacon content to PCI wifi devices every beacon interval, -+the only one usb device, 8192CU, needs to update beacon content when -+mac80211 calling set_tim. -+ -+Reported-by: Maciej S. Szmigiero -+Signed-off-by: Ping-Ke Shih -+Tested-by: Maciej S. Szmigiero -+--- -+ drivers/net/wireless/realtek/rtlwifi/core.c | 32 +++++++++++++++++++++ -+ drivers/net/wireless/realtek/rtlwifi/core.h | 1 + -+ drivers/net/wireless/realtek/rtlwifi/usb.c | 3 ++ -+ drivers/net/wireless/realtek/rtlwifi/wifi.h | 1 + -+ 4 files changed, 37 insertions(+) -+ -+--- a/drivers/net/wireless/realtek/rtlwifi/core.c -++++ b/drivers/net/wireless/realtek/rtlwifi/core.c -+@@ -1018,6 +1018,25 @@ static void send_beacon_frame(struct iee -+ } -+ } -+ -++void rtl_update_beacon_work_callback(struct work_struct *work) -++{ -++ struct rtl_works *rtlworks = -++ container_of(work, struct rtl_works, update_beacon_work); -++ struct ieee80211_hw *hw = rtlworks->hw; -++ struct rtl_priv *rtlpriv = rtl_priv(hw); -++ struct ieee80211_vif *vif = rtlpriv->mac80211.vif; -++ -++ if (!vif) { -++ WARN_ONCE(true, "no vif to update beacon\n"); -++ return; -++ } -++ -++ mutex_lock(&rtlpriv->locks.conf_mutex); -++ send_beacon_frame(hw, vif); -++ mutex_unlock(&rtlpriv->locks.conf_mutex); -++} -++EXPORT_SYMBOL_GPL(rtl_update_beacon_work_callback); -++ -+ static void rtl_op_bss_info_changed(struct ieee80211_hw *hw, -+ struct ieee80211_vif *vif, -+ struct ieee80211_bss_conf *bss_conf, -+@@ -1747,6 +1766,18 @@ static void rtl_op_flush(struct ieee8021 -+ rtlpriv->intf_ops->flush(hw, queues, drop); -+ } -+ -++static int rtl_op_set_tim(struct ieee80211_hw *hw, struct ieee80211_sta *sta, -++ bool set) -++{ -++ struct rtl_priv *rtlpriv = rtl_priv(hw); -++ struct rtl_hal *rtlhal = rtl_hal(rtl_priv(hw)); -++ -++ if (rtlhal->hw_type == HARDWARE_TYPE_RTL8192CU) -++ schedule_work(&rtlpriv->works.update_beacon_work); -++ -++ return 0; -++} -++ -+ /* Description: -+ * This routine deals with the Power Configuration CMD -+ * parsing for RTL8723/RTL8188E Series IC. -+@@ -1903,6 +1934,7 @@ const struct ieee80211_ops rtl_ops = { -+ .sta_add = rtl_op_sta_add, -+ .sta_remove = rtl_op_sta_remove, -+ .flush = rtl_op_flush, -++ .set_tim = rtl_op_set_tim, -+ }; -+ EXPORT_SYMBOL_GPL(rtl_ops); -+ -+--- a/drivers/net/wireless/realtek/rtlwifi/core.h -++++ b/drivers/net/wireless/realtek/rtlwifi/core.h -+@@ -60,5 +60,6 @@ void rtl_bb_delay(struct ieee80211_hw *h -+ bool rtl_cmd_send_packet(struct ieee80211_hw *hw, struct sk_buff *skb); -+ bool rtl_btc_status_false(void); -+ void rtl_dm_diginit(struct ieee80211_hw *hw, u32 cur_igval); -++void rtl_update_beacon_work_callback(struct work_struct *work); -+ -+ #endif -+--- a/drivers/net/wireless/realtek/rtlwifi/usb.c -++++ b/drivers/net/wireless/realtek/rtlwifi/usb.c -+@@ -807,6 +807,7 @@ static void rtl_usb_stop(struct ieee8021 -+ -+ tasklet_kill(&rtlusb->rx_work_tasklet); -+ cancel_work_sync(&rtlpriv->works.lps_change_work); -++ cancel_work_sync(&rtlpriv->works.update_beacon_work); -+ -+ flush_workqueue(rtlpriv->works.rtl_wq); -+ -+@@ -1033,6 +1034,8 @@ int rtl_usb_probe(struct usb_interface * -+ rtl_fill_h2c_cmd_work_callback); -+ INIT_WORK(&rtlpriv->works.lps_change_work, -+ rtl_lps_change_work_callback); -++ INIT_WORK(&rtlpriv->works.update_beacon_work, -++ rtl_update_beacon_work_callback); -+ -+ rtlpriv->usb_data_index = 0; -+ init_completion(&rtlpriv->firmware_loading_complete); -+--- a/drivers/net/wireless/realtek/rtlwifi/wifi.h -++++ b/drivers/net/wireless/realtek/rtlwifi/wifi.h -+@@ -2487,6 +2487,7 @@ struct rtl_works { -+ -+ struct work_struct lps_change_work; -+ struct work_struct fill_h2c_cmd; -++ struct work_struct update_beacon_work; -+ }; -+ -+ struct rtl_debug { -diff --git a/package/kernel/mac80211/patches/subsys/010-sync-nl80211_h.patch b/package/kernel/mac80211/patches/subsys/010-sync-nl80211_h.patch -new file mode 100644 -index 0000000000..e1f66ac1c3 ---- /dev/null -+++ b/package/kernel/mac80211/patches/subsys/010-sync-nl80211_h.patch -@@ -0,0 +1,297 @@ -+--- a/include/uapi/linux/nl80211.h -++++ b/include/uapi/linux/nl80211.h -+@@ -655,6 +655,9 @@ -+ * When a security association was established on an 802.1X network using -+ * fast transition, this event should be followed by an -+ * %NL80211_CMD_PORT_AUTHORIZED event. -++ * Following a %NL80211_CMD_ROAM event userspace can issue -++ * %NL80211_CMD_GET_SCAN in order to obtain the scan information for the -++ * new BSS the card/driver roamed to. -+ * @NL80211_CMD_DISCONNECT: drop a given connection; also used to notify -+ * userspace that a connection was dropped by the AP or due to other -+ * reasons, for this the %NL80211_ATTR_DISCONNECTED_BY_AP and -+@@ -757,7 +760,8 @@ -+ * of any other interfaces, and other interfaces will again take -+ * precedence when they are used. -+ * -+- * @NL80211_CMD_SET_WDS_PEER: Set the MAC address of the peer on a WDS interface. -++ * @NL80211_CMD_SET_WDS_PEER: Set the MAC address of the peer on a WDS interface -++ * (no longer supported). -+ * -+ * @NL80211_CMD_SET_MULTICAST_TO_UNICAST: Configure if this AP should perform -+ * multicast to unicast conversion. When enabled, all multicast packets -+@@ -1177,6 +1181,10 @@ -+ * includes the contents of the frame. %NL80211_ATTR_ACK flag is included -+ * if the recipient acknowledged the frame. -+ * -++ * @NL80211_CMD_SET_SAR_SPECS: SAR power limitation configuration is -++ * passed using %NL80211_ATTR_SAR_SPEC. %NL80211_ATTR_WIPHY is used to -++ * specify the wiphy index to be applied to. -++ * -+ * @NL80211_CMD_MAX: highest used command number -+ * @__NL80211_CMD_AFTER_LAST: internal use -+ */ -+@@ -1407,6 +1415,8 @@ enum nl80211_commands { -+ -+ NL80211_CMD_CONTROL_PORT_FRAME_TX_STATUS, -+ -++ NL80211_CMD_SET_SAR_SPECS, -++ -+ /* add new commands above here */ -+ -+ /* used to define NL80211_CMD_MAX below */ -+@@ -1750,8 +1760,9 @@ enum nl80211_commands { -+ * specify just a single bitrate, which is to be used for the beacon. -+ * The driver must also specify support for this with the extended -+ * features NL80211_EXT_FEATURE_BEACON_RATE_LEGACY, -+- * NL80211_EXT_FEATURE_BEACON_RATE_HT and -+- * NL80211_EXT_FEATURE_BEACON_RATE_VHT. -++ * NL80211_EXT_FEATURE_BEACON_RATE_HT, -++ * NL80211_EXT_FEATURE_BEACON_RATE_VHT and -++ * NL80211_EXT_FEATURE_BEACON_RATE_HE. -+ * -+ * @NL80211_ATTR_FRAME_MATCH: A binary attribute which typically must contain -+ * at least one byte, currently used with @NL80211_CMD_REGISTER_FRAME. -+@@ -1955,8 +1966,15 @@ enum nl80211_commands { -+ * @NL80211_ATTR_PROBE_RESP: Probe Response template data. Contains the entire -+ * probe-response frame. The DA field in the 802.11 header is zero-ed out, -+ * to be filled by the FW. -+- * @NL80211_ATTR_DISABLE_HT: Force HT capable interfaces to disable -+- * this feature. Currently, only supported in mac80211 drivers. -++ * @NL80211_ATTR_DISABLE_HT: Force HT capable interfaces to disable -++ * this feature during association. This is a flag attribute. -++ * Currently only supported in mac80211 drivers. -++ * @NL80211_ATTR_DISABLE_VHT: Force VHT capable interfaces to disable -++ * this feature during association. This is a flag attribute. -++ * Currently only supported in mac80211 drivers. -++ * @NL80211_ATTR_DISABLE_HE: Force HE capable interfaces to disable -++ * this feature during association. This is a flag attribute. -++ * Currently only supported in mac80211 drivers. -+ * @NL80211_ATTR_HT_CAPABILITY_MASK: Specify which bits of the -+ * ATTR_HT_CAPABILITY to which attention should be paid. -+ * Currently, only mac80211 NICs support this feature. -+@@ -2077,7 +2095,8 @@ enum nl80211_commands { -+ * until the channel switch event. -+ * @NL80211_ATTR_CH_SWITCH_BLOCK_TX: flag attribute specifying that transmission -+ * must be blocked on the current channel (before the channel switch -+- * operation). -++ * operation). Also included in the channel switch started event if quiet -++ * was requested by the AP. -+ * @NL80211_ATTR_CSA_IES: Nested set of attributes containing the IE information -+ * for the time while performing a channel switch. -+ * @NL80211_ATTR_CNTDWN_OFFS_BEACON: An array of offsets (u16) to the channel -+@@ -2527,6 +2546,20 @@ enum nl80211_commands { -+ * override mask. Used with NL80211_ATTR_S1G_CAPABILITY in -+ * NL80211_CMD_ASSOCIATE or NL80211_CMD_CONNECT. -+ * -++ * @NL80211_ATTR_SAE_PWE: Indicates the mechanism(s) allowed for SAE PWE -++ * derivation in WPA3-Personal networks which are using SAE authentication. -++ * This is a u8 attribute that encapsulates one of the values from -++ * &enum nl80211_sae_pwe_mechanism. -++ * -++ * @NL80211_ATTR_SAR_SPEC: SAR power limitation specification when -++ * used with %NL80211_CMD_SET_SAR_SPECS. The message contains fields -++ * of %nl80211_sar_attrs which specifies the sar type and related -++ * sar specs. Sar specs contains array of %nl80211_sar_specs_attrs. -++ * -++ * @NL80211_ATTR_RECONNECT_REQUESTED: flag attribute, used with deauth and -++ * disassoc events to indicate that an immediate reconnect to the AP -++ * is desired. -++ * -+ * @NUM_NL80211_ATTR: total number of nl80211_attrs available -+ * @NL80211_ATTR_MAX: highest attribute number currently defined -+ * @__NL80211_ATTR_AFTER_LAST: internal use -+@@ -3016,6 +3049,14 @@ enum nl80211_attrs { -+ NL80211_ATTR_S1G_CAPABILITY, -+ NL80211_ATTR_S1G_CAPABILITY_MASK, -+ -++ NL80211_ATTR_SAE_PWE, -++ -++ NL80211_ATTR_RECONNECT_REQUESTED, -++ -++ NL80211_ATTR_SAR_SPEC, -++ -++ NL80211_ATTR_DISABLE_HE, -++ -+ /* add attributes here, update the policy in nl80211.c */ -+ -+ __NL80211_ATTR_AFTER_LAST, -+@@ -5896,6 +5937,19 @@ enum nl80211_feature_flags { -+ * @NL80211_EXT_FEATURE_UNSOL_BCAST_PROBE_RESP: Driver/device supports -+ * unsolicited broadcast probe response transmission -+ * -++ * @NL80211_EXT_FEATURE_BEACON_RATE_HE: Driver supports beacon rate -++ * configuration (AP/mesh) with HE rates. -++ * -++ * @NL80211_EXT_FEATURE_SECURE_LTF: Device supports secure LTF measurement -++ * exchange protocol. -++ * -++ * @NL80211_EXT_FEATURE_SECURE_RTT: Device supports secure RTT measurement -++ * exchange protocol. -++ * -++ * @NL80211_EXT_FEATURE_PROT_RANGE_NEGO_AND_MEASURE: Device supports management -++ * frame protection for all management frames exchanged during the -++ * negotiation and range measurement procedure. -++ * -+ * @NUM_NL80211_EXT_FEATURES: number of extended features. -+ * @MAX_NL80211_EXT_FEATURES: highest extended feature index. -+ */ -+@@ -5956,6 +6010,10 @@ enum nl80211_ext_feature_index { -+ NL80211_EXT_FEATURE_SAE_OFFLOAD_AP, -+ NL80211_EXT_FEATURE_FILS_DISCOVERY, -+ NL80211_EXT_FEATURE_UNSOL_BCAST_PROBE_RESP, -++ NL80211_EXT_FEATURE_BEACON_RATE_HE, -++ NL80211_EXT_FEATURE_SECURE_LTF, -++ NL80211_EXT_FEATURE_SECURE_RTT, -++ NL80211_EXT_FEATURE_PROT_RANGE_NEGO_AND_MEASURE, -+ -+ /* add new features before the definition below */ -+ NUM_NL80211_EXT_FEATURES, -+@@ -6253,11 +6311,13 @@ struct nl80211_vendor_cmd_info { -+ * @NL80211_TDLS_PEER_HT: TDLS peer is HT capable. -+ * @NL80211_TDLS_PEER_VHT: TDLS peer is VHT capable. -+ * @NL80211_TDLS_PEER_WMM: TDLS peer is WMM capable. -++ * @NL80211_TDLS_PEER_HE: TDLS peer is HE capable. -+ */ -+ enum nl80211_tdls_peer_capability { -+ NL80211_TDLS_PEER_HT = 1<<0, -+ NL80211_TDLS_PEER_VHT = 1<<1, -+ NL80211_TDLS_PEER_WMM = 1<<2, -++ NL80211_TDLS_PEER_HE = 1<<3, -+ }; -+ -+ /** -+@@ -6849,6 +6909,9 @@ enum nl80211_peer_measurement_ftm_capa { -+ * if neither %NL80211_PMSR_FTM_REQ_ATTR_TRIGGER_BASED nor -+ * %NL80211_PMSR_FTM_REQ_ATTR_NON_TRIGGER_BASED is set, EDCA based -+ * ranging will be used. -++ * @NL80211_PMSR_FTM_REQ_ATTR_LMR_FEEDBACK: negotiate for LMR feedback. Only -++ * valid if either %NL80211_PMSR_FTM_REQ_ATTR_TRIGGER_BASED or -++ * %NL80211_PMSR_FTM_REQ_ATTR_NON_TRIGGER_BASED is set. -+ * -+ * @NUM_NL80211_PMSR_FTM_REQ_ATTR: internal -+ * @NL80211_PMSR_FTM_REQ_ATTR_MAX: highest attribute number -+@@ -6867,6 +6930,7 @@ enum nl80211_peer_measurement_ftm_req { -+ NL80211_PMSR_FTM_REQ_ATTR_REQUEST_CIVICLOC, -+ NL80211_PMSR_FTM_REQ_ATTR_TRIGGER_BASED, -+ NL80211_PMSR_FTM_REQ_ATTR_NON_TRIGGER_BASED, -++ NL80211_PMSR_FTM_REQ_ATTR_LMR_FEEDBACK, -+ -+ /* keep last */ -+ NUM_NL80211_PMSR_FTM_REQ_ATTR, -+@@ -7124,4 +7188,115 @@ enum nl80211_unsol_bcast_probe_resp_attr -+ NL80211_UNSOL_BCAST_PROBE_RESP_ATTR_MAX = -+ __NL80211_UNSOL_BCAST_PROBE_RESP_ATTR_LAST - 1 -+ }; -++ -++/** -++ * enum nl80211_sae_pwe_mechanism - The mechanism(s) allowed for SAE PWE -++ * derivation. Applicable only when WPA3-Personal SAE authentication is -++ * used. -++ * -++ * @NL80211_SAE_PWE_UNSPECIFIED: not specified, used internally to indicate that -++ * attribute is not present from userspace. -++ * @NL80211_SAE_PWE_HUNT_AND_PECK: hunting-and-pecking loop only -++ * @NL80211_SAE_PWE_HASH_TO_ELEMENT: hash-to-element only -++ * @NL80211_SAE_PWE_BOTH: both hunting-and-pecking loop and hash-to-element -++ * can be used. -++ */ -++enum nl80211_sae_pwe_mechanism { -++ NL80211_SAE_PWE_UNSPECIFIED, -++ NL80211_SAE_PWE_HUNT_AND_PECK, -++ NL80211_SAE_PWE_HASH_TO_ELEMENT, -++ NL80211_SAE_PWE_BOTH, -++}; -++ -++/** -++ * enum nl80211_sar_type - type of SAR specs -++ * -++ * @NL80211_SAR_TYPE_POWER: power limitation specified in 0.25dBm unit -++ * -++ */ -++enum nl80211_sar_type { -++ NL80211_SAR_TYPE_POWER, -++ -++ /* add new type here */ -++ -++ /* Keep last */ -++ NUM_NL80211_SAR_TYPE, -++}; -++ -++/** -++ * enum nl80211_sar_attrs - Attributes for SAR spec -++ * -++ * @NL80211_SAR_ATTR_TYPE: the SAR type as defined in &enum nl80211_sar_type. -++ * -++ * @NL80211_SAR_ATTR_SPECS: Nested array of SAR power -++ * limit specifications. Each specification contains a set -++ * of %nl80211_sar_specs_attrs. -++ * -++ * For SET operation, it contains array of %NL80211_SAR_ATTR_SPECS_POWER -++ * and %NL80211_SAR_ATTR_SPECS_RANGE_INDEX. -++ * -++ * For sar_capa dump, it contains array of -++ * %NL80211_SAR_ATTR_SPECS_START_FREQ -++ * and %NL80211_SAR_ATTR_SPECS_END_FREQ. -++ * -++ * @__NL80211_SAR_ATTR_LAST: Internal -++ * @NL80211_SAR_ATTR_MAX: highest sar attribute -++ * -++ * These attributes are used with %NL80211_CMD_SET_SAR_SPEC -++ */ -++enum nl80211_sar_attrs { -++ __NL80211_SAR_ATTR_INVALID, -++ -++ NL80211_SAR_ATTR_TYPE, -++ NL80211_SAR_ATTR_SPECS, -++ -++ __NL80211_SAR_ATTR_LAST, -++ NL80211_SAR_ATTR_MAX = __NL80211_SAR_ATTR_LAST - 1, -++}; -++ -++/** -++ * enum nl80211_sar_specs_attrs - Attributes for SAR power limit specs -++ * -++ * @NL80211_SAR_ATTR_SPECS_POWER: Required (s32)value to specify the actual -++ * power limit value in units of 0.25 dBm if type is -++ * NL80211_SAR_TYPE_POWER. (i.e., a value of 44 represents 11 dBm). -++ * 0 means userspace doesn't have SAR limitation on this associated range. -++ * -++ * @NL80211_SAR_ATTR_SPECS_RANGE_INDEX: Required (u32) value to specify the -++ * index of exported freq range table and the associated power limitation -++ * is applied to this range. -++ * -++ * Userspace isn't required to set all the ranges advertised by WLAN driver, -++ * and userspace can skip some certain ranges. These skipped ranges don't -++ * have SAR limitations, and they are same as setting the -++ * %NL80211_SAR_ATTR_SPECS_POWER to any unreasonable high value because any -++ * value higher than regulatory allowed value just means SAR power -++ * limitation is removed, but it's required to set at least one range. -++ * It's not allowed to set duplicated range in one SET operation. -++ * -++ * Every SET operation overwrites previous SET operation. -++ * -++ * @NL80211_SAR_ATTR_SPECS_START_FREQ: Required (u32) value to specify the start -++ * frequency of this range edge when registering SAR capability to wiphy. -++ * It's not a channel center frequency. The unit is kHz. -++ * -++ * @NL80211_SAR_ATTR_SPECS_END_FREQ: Required (u32) value to specify the end -++ * frequency of this range edge when registering SAR capability to wiphy. -++ * It's not a channel center frequency. The unit is kHz. -++ * -++ * @__NL80211_SAR_ATTR_SPECS_LAST: Internal -++ * @NL80211_SAR_ATTR_SPECS_MAX: highest sar specs attribute -++ */ -++enum nl80211_sar_specs_attrs { -++ __NL80211_SAR_ATTR_SPECS_INVALID, -++ -++ NL80211_SAR_ATTR_SPECS_POWER, -++ NL80211_SAR_ATTR_SPECS_RANGE_INDEX, -++ NL80211_SAR_ATTR_SPECS_START_FREQ, -++ NL80211_SAR_ATTR_SPECS_END_FREQ, -++ -++ __NL80211_SAR_ATTR_SPECS_LAST, -++ NL80211_SAR_ATTR_SPECS_MAX = __NL80211_SAR_ATTR_SPECS_LAST - 1, -++}; -++ -+ #endif /* __LINUX_NL80211_H */ diff --git a/package/kernel/mac80211/patches/subsys/100-remove-cryptoapi-dependencies.patch b/package/kernel/mac80211/patches/subsys/100-remove-cryptoapi-dependencies.patch deleted file mode 100644 -index 7b036e4e4c..0000000000 +index ca02dfb06f..0000000000 --- a/package/kernel/mac80211/patches/subsys/100-remove-cryptoapi-dependencies.patch +++ /dev/null -@@ -1,698 +0,0 @@ +@@ -1,699 +0,0 @@ ---- a/net/mac80211/Makefile -+++ b/net/mac80211/Makefile -@@ -7,7 +7,6 @@ mac80211-y := \ @@ -2006,7 +1078,7 @@ index 7b036e4e4c..0000000000 - ethtool.o \ ---- a/net/mac80211/aead_api.c -+++ /dev/null --@@ -1,112 +0,0 @@ +-@@ -1,113 +0,0 @@ --// SPDX-License-Identifier: GPL-2.0-only --/* -- * Copyright 2003-2004, Instant802 Networks, Inc. @@ -2032,6 +1104,7 @@ index 7b036e4e4c..0000000000 -- struct aead_request *aead_req; -- int reqsize = sizeof(*aead_req) + crypto_aead_reqsize(tfm); -- u8 *__aad; +-- int ret; -- -- aead_req = kzalloc(reqsize + aad_len, GFP_ATOMIC); -- if (!aead_req) @@ -2049,10 +1122,10 @@ index 7b036e4e4c..0000000000 -- aead_request_set_crypt(aead_req, sg, sg, data_len, b_0); -- aead_request_set_ad(aead_req, sg[0].length); -- --- crypto_aead_encrypt(aead_req); +-- ret = crypto_aead_encrypt(aead_req); -- kfree_sensitive(aead_req); -- --- return 0; +-- return ret; --} -- --int aead_decrypt(struct crypto_aead *tfm, u8 *b_0, u8 *aad, size_t aad_len, @@ -2364,7 +1437,7 @@ index 7b036e4e4c..0000000000 - #endif /* AES_GCM_H */ ---- a/net/mac80211/wpa.c -+++ b/net/mac80211/wpa.c --@@ -311,7 +311,8 @@ ieee80211_crypto_tkip_decrypt(struct iee +-@@ -312,7 +312,8 @@ ieee80211_crypto_tkip_decrypt(struct iee - } - - @@ -2374,7 +1447,7 @@ index 7b036e4e4c..0000000000 - { - __le16 mask_fc; - int a4_included, mgmt; --@@ -341,14 +342,8 @@ static void ccmp_special_blocks(struct s +-@@ -342,14 +343,8 @@ static void ccmp_special_blocks(struct s - else - qos_tid = 0; - @@ -2391,7 +1464,7 @@ index 7b036e4e4c..0000000000 - - /* Nonce: Nonce Flags | A2 | PN - * Nonce Flags: Priority (b0..b3) | Management (b4) | Reserved (b5..b7) --@@ -356,6 +351,8 @@ static void ccmp_special_blocks(struct s +-@@ -357,6 +352,8 @@ static void ccmp_special_blocks(struct s - b_0[1] = qos_tid | (mgmt << 4); - memcpy(&b_0[2], hdr->addr2, ETH_ALEN); - memcpy(&b_0[8], pn, IEEE80211_CCMP_PN_LEN); @@ -2400,7 +1473,7 @@ index 7b036e4e4c..0000000000 - - /* AAD (extra authenticate-only data) / masked 802.11 header - * FC | A1 | A2 | A3 | SC | [A4] | [QC] */ --@@ -412,7 +409,7 @@ static int ccmp_encrypt_skb(struct ieee8 +-@@ -413,7 +410,7 @@ static int ccmp_encrypt_skb(struct ieee8 - u8 *pos; - u8 pn[6]; - u64 pn64; @@ -2409,7 +1482,7 @@ index 7b036e4e4c..0000000000 - u8 b_0[AES_BLOCK_SIZE]; - - if (info->control.hw_key && --@@ -467,9 +464,11 @@ static int ccmp_encrypt_skb(struct ieee8 +-@@ -468,9 +465,11 @@ static int ccmp_encrypt_skb(struct ieee8 - return 0; - - pos += IEEE80211_CCMP_HDR_LEN; @@ -2424,7 +1497,7 @@ index 7b036e4e4c..0000000000 - } - - --@@ -542,13 +541,13 @@ ieee80211_crypto_ccmp_decrypt(struct iee +-@@ -543,13 +542,13 @@ ieee80211_crypto_ccmp_decrypt(struct iee - u8 aad[2 * AES_BLOCK_SIZE]; - u8 b_0[AES_BLOCK_SIZE]; - /* hardware didn't decrypt/verify MIC */ @@ -2440,7 +1513,7 @@ index 7b036e4e4c..0000000000 - return RX_DROP_UNUSABLE; - } - --@@ -643,7 +642,7 @@ static int gcmp_encrypt_skb(struct ieee8 +-@@ -646,7 +645,7 @@ static int gcmp_encrypt_skb(struct ieee8 - u8 *pos; - u8 pn[6]; - u64 pn64; @@ -2449,7 +1522,7 @@ index 7b036e4e4c..0000000000 - u8 j_0[AES_BLOCK_SIZE]; - - if (info->control.hw_key && --@@ -700,8 +699,10 @@ static int gcmp_encrypt_skb(struct ieee8 +-@@ -703,8 +702,10 @@ static int gcmp_encrypt_skb(struct ieee8 - - pos += IEEE80211_GCMP_HDR_LEN; - gcmp_special_blocks(skb, pn, j_0, aad); @@ -2462,7 +1535,7 @@ index 7b036e4e4c..0000000000 - } - - ieee80211_tx_result --@@ -1128,9 +1129,9 @@ ieee80211_crypto_aes_gmac_encrypt(struct +-@@ -1133,9 +1134,9 @@ ieee80211_crypto_aes_gmac_encrypt(struct - struct ieee80211_key *key = tx->key; - struct ieee80211_mmie_16 *mmie; - struct ieee80211_hdr *hdr; @@ -2474,7 +1547,7 @@ index 7b036e4e4c..0000000000 - - if (WARN_ON(skb_queue_len(&tx->skbs) != 1)) - return TX_DROP; --@@ -1176,7 +1177,7 @@ ieee80211_crypto_aes_gmac_decrypt(struct +-@@ -1181,7 +1182,7 @@ ieee80211_crypto_aes_gmac_decrypt(struct - struct ieee80211_rx_status *status = IEEE80211_SKB_RXCB(skb); - struct ieee80211_key *key = rx->key; - struct ieee80211_mmie_16 *mmie; @@ -2972,642 +2045,6 @@ index df67d2f101..0000000000 - depends on CRC32 - help - This option enables the hardware independent IEEE 802.11 -diff --git a/package/kernel/mac80211/patches/subsys/150-disable_addr_notifier.patch b/package/kernel/mac80211/patches/subsys/150-disable_addr_notifier.patch -index 8a717558a7..8d086625e4 100644 ---- a/package/kernel/mac80211/patches/subsys/150-disable_addr_notifier.patch -+++ b/package/kernel/mac80211/patches/subsys/150-disable_addr_notifier.patch -@@ -18,7 +18,7 @@ - static int ieee80211_ifa6_changed(struct notifier_block *nb, - unsigned long data, void *arg) - { --@@ -1301,14 +1301,14 @@ int ieee80211_register_hw(struct ieee802 -+@@ -1315,14 +1315,14 @@ int ieee80211_register_hw(struct ieee802 - - rtnl_unlock(); - -@@ -35,7 +35,7 @@ - local->ifa6_notifier.notifier_call = ieee80211_ifa6_changed; - result = register_inet6addr_notifier(&local->ifa6_notifier); - if (result) --@@ -1317,13 +1317,13 @@ int ieee80211_register_hw(struct ieee802 -+@@ -1331,13 +1331,13 @@ int ieee80211_register_hw(struct ieee802 - - return 0; - -@@ -52,7 +52,7 @@ - fail_ifa: - #endif - wiphy_unregister(local->hw.wiphy); --@@ -1351,10 +1351,10 @@ void ieee80211_unregister_hw(struct ieee -+@@ -1365,10 +1365,10 @@ void ieee80211_unregister_hw(struct ieee - tasklet_kill(&local->tx_pending_tasklet); - tasklet_kill(&local->tasklet); - -diff --git a/package/kernel/mac80211/patches/subsys/210-ap_scan.patch b/package/kernel/mac80211/patches/subsys/210-ap_scan.patch -index 80f995737b..ee49942459 100644 ---- a/package/kernel/mac80211/patches/subsys/210-ap_scan.patch -+++ b/package/kernel/mac80211/patches/subsys/210-ap_scan.patch -@@ -1,6 +1,6 @@ - --- a/net/mac80211/cfg.c - +++ b/net/mac80211/cfg.c --@@ -2442,7 +2442,7 @@ static int ieee80211_scan(struct wiphy * -+@@ -2444,7 +2444,7 @@ static int ieee80211_scan(struct wiphy * - * the frames sent while scanning on other channel will be - * lost) - */ -diff --git a/package/kernel/mac80211/patches/subsys/300-cfg80211-support-immediate-reconnect-request-hint.patch b/package/kernel/mac80211/patches/subsys/300-cfg80211-support-immediate-reconnect-request-hint.patch -index d3f4aa7972..8fe8723cfe 100644 ---- a/package/kernel/mac80211/patches/subsys/300-cfg80211-support-immediate-reconnect-request-hint.patch -+++ b/package/kernel/mac80211/patches/subsys/300-cfg80211-support-immediate-reconnect-request-hint.patch -@@ -31,31 +31,9 @@ Signed-off-by: Johannes Berg - - /** - * cfg80211_rx_unprot_mlme_mgmt - notification of unprotected mlme mgmt frame ----- a/include/uapi/linux/nl80211.h --+++ b/include/uapi/linux/nl80211.h --@@ -2527,6 +2527,10 @@ enum nl80211_commands { -- * override mask. Used with NL80211_ATTR_S1G_CAPABILITY in -- * NL80211_CMD_ASSOCIATE or NL80211_CMD_CONNECT. -- * --+ * @NL80211_ATTR_RECONNECT_REQUESTED: flag attribute, used with deauth and --+ * disassoc events to indicate that an immediate reconnect to the AP --+ * is desired. --+ * -- * @NUM_NL80211_ATTR: total number of nl80211_attrs available -- * @NL80211_ATTR_MAX: highest attribute number currently defined -- * @__NL80211_ATTR_AFTER_LAST: internal use --@@ -3016,6 +3020,8 @@ enum nl80211_attrs { -- NL80211_ATTR_S1G_CAPABILITY, -- NL80211_ATTR_S1G_CAPABILITY_MASK, -- --+ NL80211_ATTR_RECONNECT_REQUESTED, --+ -- /* add attributes here, update the policy in nl80211.c */ -- -- __NL80211_ATTR_AFTER_LAST, - --- a/net/mac80211/mlme.c - +++ b/net/mac80211/mlme.c --@@ -2729,7 +2729,7 @@ static void ieee80211_report_disconnect( -+@@ -2734,7 +2734,7 @@ static void ieee80211_report_disconnect( - }; - - if (tx) -@@ -64,7 +42,7 @@ Signed-off-by: Johannes Berg - else - cfg80211_rx_mlme_mgmt(sdata->dev, buf, len); - --@@ -4716,7 +4716,8 @@ void ieee80211_mgd_quiesce(struct ieee80 -+@@ -4724,7 +4724,8 @@ void ieee80211_mgd_quiesce(struct ieee80 - if (ifmgd->auth_data) - ieee80211_destroy_auth_data(sdata, false); - cfg80211_tx_mlme_mgmt(sdata->dev, frame_buf, -@@ -166,7 +144,7 @@ Signed-off-by: Johannes Berg - - --- a/net/wireless/nl80211.c - +++ b/net/wireless/nl80211.c --@@ -732,6 +732,7 @@ static const struct nla_policy nl80211_p -+@@ -736,6 +736,7 @@ static const struct nla_policy nl80211_p - NLA_POLICY_EXACT_LEN(IEEE80211_S1G_CAPABILITY_LEN), - [NL80211_ATTR_S1G_CAPABILITY_MASK] = - NLA_POLICY_EXACT_LEN(IEEE80211_S1G_CAPABILITY_LEN), -@@ -174,7 +152,7 @@ Signed-off-by: Johannes Berg - }; - - /* policy for the key attributes */ --@@ -15899,7 +15900,7 @@ static void nl80211_send_mlme_event(stru -+@@ -15903,7 +15904,7 @@ static void nl80211_send_mlme_event(stru - const u8 *buf, size_t len, - enum nl80211_commands cmd, gfp_t gfp, - int uapsd_queues, const u8 *req_ies, -@@ -183,7 +161,7 @@ Signed-off-by: Johannes Berg - { - struct sk_buff *msg; - void *hdr; --@@ -15921,6 +15922,9 @@ static void nl80211_send_mlme_event(stru -+@@ -15925,6 +15926,9 @@ static void nl80211_send_mlme_event(stru - nla_put(msg, NL80211_ATTR_REQ_IE, req_ies_len, req_ies))) - goto nla_put_failure; - -@@ -193,7 +171,7 @@ Signed-off-by: Johannes Berg - if (uapsd_queues >= 0) { - struct nlattr *nla_wmm = - nla_nest_start_noflag(msg, NL80211_ATTR_STA_WME); --@@ -15949,7 +15953,8 @@ void nl80211_send_rx_auth(struct cfg8021 -+@@ -15953,7 +15957,8 @@ void nl80211_send_rx_auth(struct cfg8021 - size_t len, gfp_t gfp) - { - nl80211_send_mlme_event(rdev, netdev, buf, len, -@@ -203,7 +181,7 @@ Signed-off-by: Johannes Berg - } - - void nl80211_send_rx_assoc(struct cfg80211_registered_device *rdev, --@@ -15959,23 +15964,25 @@ void nl80211_send_rx_assoc(struct cfg802 -+@@ -15963,23 +15968,25 @@ void nl80211_send_rx_assoc(struct cfg802 - { - nl80211_send_mlme_event(rdev, netdev, buf, len, - NL80211_CMD_ASSOCIATE, gfp, uapsd_queues, -@@ -234,7 +212,7 @@ Signed-off-by: Johannes Berg - } - - void cfg80211_rx_unprot_mlme_mgmt(struct net_device *dev, const u8 *buf, --@@ -16006,7 +16013,7 @@ void cfg80211_rx_unprot_mlme_mgmt(struct -+@@ -16010,7 +16017,7 @@ void cfg80211_rx_unprot_mlme_mgmt(struct - - trace_cfg80211_rx_unprot_mlme_mgmt(dev, buf, len); - nl80211_send_mlme_event(rdev, dev, buf, len, cmd, GFP_ATOMIC, -1, -diff --git a/package/kernel/mac80211/patches/subsys/301-mac80211-support-driver-based-disconnect-with-reconn.patch b/package/kernel/mac80211/patches/subsys/301-mac80211-support-driver-based-disconnect-with-reconn.patch -index 8f948c140e..31621ebf11 100644 ---- a/package/kernel/mac80211/patches/subsys/301-mac80211-support-driver-based-disconnect-with-reconn.patch -+++ b/package/kernel/mac80211/patches/subsys/301-mac80211-support-driver-based-disconnect-with-reconn.patch -@@ -34,7 +34,7 @@ Signed-off-by: Johannes Berg - * @vif: &struct ieee80211_vif pointer from the add_interface callback. - --- a/net/mac80211/ieee80211_i.h - +++ b/net/mac80211/ieee80211_i.h --@@ -461,7 +461,9 @@ struct ieee80211_if_managed { -+@@ -450,7 +450,9 @@ struct ieee80211_if_managed { - unsigned long probe_timeout; - int probe_send_count; - bool nullfunc_failed; -@@ -47,7 +47,7 @@ Signed-off-by: Johannes Berg - struct ieee80211_mgd_auth_data *auth_data; - --- a/net/mac80211/mlme.c - +++ b/net/mac80211/mlme.c --@@ -2720,7 +2720,7 @@ EXPORT_SYMBOL(ieee80211_ap_probereq_get) -+@@ -2725,7 +2725,7 @@ EXPORT_SYMBOL(ieee80211_ap_probereq_get) - - static void ieee80211_report_disconnect(struct ieee80211_sub_if_data *sdata, - const u8 *buf, size_t len, bool tx, -@@ -56,7 +56,7 @@ Signed-off-by: Johannes Berg - { - struct ieee80211_event event = { - .type = MLME_EVENT, --@@ -2729,7 +2729,7 @@ static void ieee80211_report_disconnect( -+@@ -2734,7 +2734,7 @@ static void ieee80211_report_disconnect( - }; - - if (tx) -@@ -65,7 +65,7 @@ Signed-off-by: Johannes Berg - else - cfg80211_rx_mlme_mgmt(sdata->dev, buf, len); - --@@ -2751,13 +2751,18 @@ static void __ieee80211_disconnect(struc -+@@ -2756,13 +2756,18 @@ static void __ieee80211_disconnect(struc - - tx = !sdata->csa_block_tx; - -@@ -89,7 +89,7 @@ Signed-off-by: Johannes Berg - tx, frame_buf); - mutex_lock(&local->mtx); - sdata->vif.csa_active = false; --@@ -2770,7 +2775,9 @@ static void __ieee80211_disconnect(struc -+@@ -2775,7 +2780,9 @@ static void __ieee80211_disconnect(struc - mutex_unlock(&local->mtx); - - ieee80211_report_disconnect(sdata, frame_buf, sizeof(frame_buf), tx, -@@ -100,7 +100,7 @@ Signed-off-by: Johannes Berg - - sdata_unlock(sdata); - } --@@ -2789,6 +2796,13 @@ static void ieee80211_beacon_connection_ -+@@ -2794,6 +2801,13 @@ static void ieee80211_beacon_connection_ - sdata_info(sdata, "Connection to AP %pM lost\n", - ifmgd->bssid); - __ieee80211_disconnect(sdata); -@@ -114,7 +114,7 @@ Signed-off-by: Johannes Berg - } else { - ieee80211_mgd_probe_ap(sdata, true); - } --@@ -2827,6 +2841,21 @@ void ieee80211_connection_loss(struct ie -+@@ -2832,6 +2846,21 @@ void ieee80211_connection_loss(struct ie - } - EXPORT_SYMBOL(ieee80211_connection_loss); - -@@ -136,7 +136,7 @@ Signed-off-by: Johannes Berg - - static void ieee80211_destroy_auth_data(struct ieee80211_sub_if_data *sdata, - bool assoc) --@@ -3130,7 +3159,7 @@ static void ieee80211_rx_mgmt_deauth(str -+@@ -3135,7 +3164,7 @@ static void ieee80211_rx_mgmt_deauth(str - ieee80211_set_disassoc(sdata, 0, 0, false, NULL); - - ieee80211_report_disconnect(sdata, (u8 *)mgmt, len, false, -@@ -145,7 +145,7 @@ Signed-off-by: Johannes Berg - return; - } - --@@ -3179,7 +3208,8 @@ static void ieee80211_rx_mgmt_disassoc(s -+@@ -3184,7 +3213,8 @@ static void ieee80211_rx_mgmt_disassoc(s - - ieee80211_set_disassoc(sdata, 0, 0, false, NULL); - -@@ -155,7 +155,7 @@ Signed-off-by: Johannes Berg - } - - static void ieee80211_get_rates(struct ieee80211_supported_band *sband, --@@ -4199,7 +4229,8 @@ static void ieee80211_rx_mgmt_beacon(str -+@@ -4204,7 +4234,8 @@ static void ieee80211_rx_mgmt_beacon(str - true, deauth_buf); - ieee80211_report_disconnect(sdata, deauth_buf, - sizeof(deauth_buf), true, -@@ -165,7 +165,7 @@ Signed-off-by: Johannes Berg - return; - } - --@@ -4344,7 +4375,7 @@ static void ieee80211_sta_connection_los -+@@ -4349,7 +4380,7 @@ static void ieee80211_sta_connection_los - tx, frame_buf); - - ieee80211_report_disconnect(sdata, frame_buf, sizeof(frame_buf), true, -@@ -174,7 +174,7 @@ Signed-off-by: Johannes Berg - } - - static int ieee80211_auth(struct ieee80211_sub_if_data *sdata) --@@ -5431,7 +5462,8 @@ int ieee80211_mgd_auth(struct ieee80211_ -+@@ -5439,7 +5470,8 @@ int ieee80211_mgd_auth(struct ieee80211_ - - ieee80211_report_disconnect(sdata, frame_buf, - sizeof(frame_buf), true, -@@ -184,7 +184,7 @@ Signed-off-by: Johannes Berg - } - - sdata_info(sdata, "authenticate with %pM\n", req->bss->bssid); --@@ -5503,7 +5535,8 @@ int ieee80211_mgd_assoc(struct ieee80211 -+@@ -5511,7 +5543,8 @@ int ieee80211_mgd_assoc(struct ieee80211 - - ieee80211_report_disconnect(sdata, frame_buf, - sizeof(frame_buf), true, -@@ -194,7 +194,7 @@ Signed-off-by: Johannes Berg - } - - if (ifmgd->auth_data && !ifmgd->auth_data->done) { --@@ -5802,7 +5835,7 @@ int ieee80211_mgd_deauth(struct ieee8021 -+@@ -5810,7 +5843,7 @@ int ieee80211_mgd_deauth(struct ieee8021 - ieee80211_destroy_auth_data(sdata, false); - ieee80211_report_disconnect(sdata, frame_buf, - sizeof(frame_buf), true, -@@ -203,7 +203,7 @@ Signed-off-by: Johannes Berg - - return 0; - } --@@ -5822,7 +5855,7 @@ int ieee80211_mgd_deauth(struct ieee8021 -+@@ -5830,7 +5863,7 @@ int ieee80211_mgd_deauth(struct ieee8021 - ieee80211_destroy_assoc_data(sdata, false, true); - ieee80211_report_disconnect(sdata, frame_buf, - sizeof(frame_buf), true, -@@ -212,7 +212,7 @@ Signed-off-by: Johannes Berg - return 0; - } - --@@ -5837,7 +5870,7 @@ int ieee80211_mgd_deauth(struct ieee8021 -+@@ -5845,7 +5878,7 @@ int ieee80211_mgd_deauth(struct ieee8021 - req->reason_code, tx, frame_buf); - ieee80211_report_disconnect(sdata, frame_buf, - sizeof(frame_buf), true, -@@ -221,7 +221,7 @@ Signed-off-by: Johannes Berg - return 0; - } - --@@ -5870,7 +5903,7 @@ int ieee80211_mgd_disassoc(struct ieee80 -+@@ -5878,7 +5911,7 @@ int ieee80211_mgd_disassoc(struct ieee80 - frame_buf); - - ieee80211_report_disconnect(sdata, frame_buf, sizeof(frame_buf), true, -diff --git a/package/kernel/mac80211/patches/subsys/302-cfg80211-Add-support-to-configure-SAE-PWE-value-to-d.patch b/package/kernel/mac80211/patches/subsys/302-cfg80211-Add-support-to-configure-SAE-PWE-value-to-d.patch -new file mode 100644 -index 0000000000..acfdae0f5b ---- /dev/null -+++ b/package/kernel/mac80211/patches/subsys/302-cfg80211-Add-support-to-configure-SAE-PWE-value-to-d.patch -@@ -0,0 +1,74 @@ -+From: Rohan Dutta -+Date: Tue, 27 Oct 2020 12:09:10 +0200 -+Subject: [PATCH] cfg80211: Add support to configure SAE PWE value to drivers -+ -+Add support to configure SAE PWE preference from userspace to drivers in -+both AP and STA modes. This is needed for cases where the driver takes -+care of Authentication frame processing (SME in the driver) so that -+correct enforcement of the acceptable PWE derivation mechanism can be -+performed. -+ -+The userspace applications can pass the sae_pwe value using the -+NL80211_ATTR_SAE_PWE attribute in the NL80211_CMD_CONNECT and -+NL80211_CMD_START_AP commands to the driver. This allows selection -+between the hunting-and-pecking loop and hash-to-element options for PWE -+derivation. For backwards compatibility, this new attribute is optional -+and if not included, the driver is notified of the value being -+unspecified. -+ -+Signed-off-by: Rohan Dutta -+Signed-off-by: Jouni Malinen -+Link: https://lore.kernel.org/r/20201027100910.22283-1-jouni@codeaurora.org -+Signed-off-by: Johannes Berg -+--- -+ -+--- a/include/net/cfg80211.h -++++ b/include/net/cfg80211.h -+@@ -1009,6 +1009,14 @@ struct survey_info { -+ * @sae_pwd: password for SAE authentication (for devices supporting SAE -+ * offload) -+ * @sae_pwd_len: length of SAE password (for devices supporting SAE offload) -++ * @sae_pwe: The mechanisms allowed for SAE PWE derivation -++ * NL80211_SAE_PWE_UNSPECIFIED: Not-specified, used to indicate userspace -++ * did not specify any preference. The driver should follow its -++ * internal policy in such a scenario. -++ * NL80211_SAE_PWE_HUNT_AND_PECK: Allow hunting-and-pecking loop only -++ * NL80211_SAE_PWE_HASH_TO_ELEMENT: Allow hash-to-element only -++ * NL80211_SAE_PWE_BOTH: Allow either hunting-and-pecking loop -++ * or hash-to-element -+ */ -+ struct cfg80211_crypto_settings { -+ u32 wpa_versions; -+@@ -1027,6 +1035,7 @@ struct cfg80211_crypto_settings { -+ const u8 *psk; -+ const u8 *sae_pwd; -+ u8 sae_pwd_len; -++ enum nl80211_sae_pwe_mechanism sae_pwe; -+ }; -+ -+ /** -+--- a/net/wireless/nl80211.c -++++ b/net/wireless/nl80211.c -+@@ -736,6 +736,9 @@ static const struct nla_policy nl80211_p -+ NLA_POLICY_EXACT_LEN(IEEE80211_S1G_CAPABILITY_LEN), -+ [NL80211_ATTR_S1G_CAPABILITY_MASK] = -+ NLA_POLICY_EXACT_LEN(IEEE80211_S1G_CAPABILITY_LEN), -++ [NL80211_ATTR_SAE_PWE] = -++ NLA_POLICY_RANGE(NLA_U8, NL80211_SAE_PWE_HUNT_AND_PECK, -++ NL80211_SAE_PWE_BOTH), -+ [NL80211_ATTR_RECONNECT_REQUESTED] = { .type = NLA_REJECT }, -+ }; -+ -+@@ -9764,6 +9767,12 @@ static int nl80211_crypto_settings(struc -+ nla_len(info->attrs[NL80211_ATTR_SAE_PASSWORD]); -+ } -+ -++ if (info->attrs[NL80211_ATTR_SAE_PWE]) -++ settings->sae_pwe = -++ nla_get_u8(info->attrs[NL80211_ATTR_SAE_PWE]); -++ else -++ settings->sae_pwe = NL80211_SAE_PWE_UNSPECIFIED; -++ -+ return 0; -+ } -+ -diff --git a/package/kernel/mac80211/patches/subsys/311-net-fq_impl-drop-get_default_func-move-default-flow-.patch b/package/kernel/mac80211/patches/subsys/311-net-fq_impl-drop-get_default_func-move-default-flow-.patch -index f8748ef123..33dbb5eb90 100644 ---- a/package/kernel/mac80211/patches/subsys/311-net-fq_impl-drop-get_default_func-move-default-flow-.patch -+++ b/package/kernel/mac80211/patches/subsys/311-net-fq_impl-drop-get_default_func-move-default-flow-.patch -@@ -68,7 +68,7 @@ Signed-off-by: Felix Fietkau - static int fq_init(struct fq *fq, int flows_cnt) - --- a/net/mac80211/ieee80211_i.h - +++ b/net/mac80211/ieee80211_i.h --@@ -857,7 +857,6 @@ enum txq_info_flags { -+@@ -846,7 +846,6 @@ enum txq_info_flags { - */ - struct txq_info { - struct fq_tin tin; -diff --git a/package/kernel/mac80211/patches/subsys/315-mac80211-add-rx-decapsulation-offload-support.patch b/package/kernel/mac80211/patches/subsys/315-mac80211-add-rx-decapsulation-offload-support.patch -index 09407f3b1d..b8bb2930f5 100644 ---- a/package/kernel/mac80211/patches/subsys/315-mac80211-add-rx-decapsulation-offload-support.patch -+++ b/package/kernel/mac80211/patches/subsys/315-mac80211-add-rx-decapsulation-offload-support.patch -@@ -132,7 +132,7 @@ Signed-off-by: Felix Fietkau - #endif /* __MAC80211_DRIVER_OPS */ - --- a/net/mac80211/iface.c - +++ b/net/mac80211/iface.c --@@ -839,7 +839,7 @@ static const struct net_device_ops ieee8 -+@@ -835,7 +835,7 @@ static const struct net_device_ops ieee8 - - }; - -@@ -141,7 +141,7 @@ Signed-off-by: Felix Fietkau - { - switch (iftype) { - /* P2P GO and client are mapped to AP/STATION types */ --@@ -859,7 +859,7 @@ static bool ieee80211_set_sdata_offload_ -+@@ -855,7 +855,7 @@ static bool ieee80211_set_sdata_offload_ - flags = sdata->vif.offload_flags; - - if (ieee80211_hw_check(&local->hw, SUPPORTS_TX_ENCAP_OFFLOAD) && -@@ -150,7 +150,7 @@ Signed-off-by: Felix Fietkau - flags |= IEEE80211_OFFLOAD_ENCAP_ENABLED; - - if (!ieee80211_hw_check(&local->hw, SUPPORTS_TX_FRAG) && --@@ -872,10 +872,21 @@ static bool ieee80211_set_sdata_offload_ -+@@ -868,10 +868,21 @@ static bool ieee80211_set_sdata_offload_ - flags &= ~IEEE80211_OFFLOAD_ENCAP_ENABLED; - } - -@@ -172,7 +172,7 @@ Signed-off-by: Felix Fietkau - return true; - } - --@@ -893,7 +904,7 @@ static void ieee80211_set_vif_encap_ops( -+@@ -889,7 +900,7 @@ static void ieee80211_set_vif_encap_ops( - } - - if (!ieee80211_hw_check(&local->hw, SUPPORTS_TX_ENCAP_OFFLOAD) || -@@ -183,7 +183,7 @@ Signed-off-by: Felix Fietkau - enabled = bss->vif.offload_flags & IEEE80211_OFFLOAD_ENCAP_ENABLED; - --- a/net/mac80211/rx.c - +++ b/net/mac80211/rx.c --@@ -4114,7 +4114,9 @@ void ieee80211_check_fast_rx(struct sta_ -+@@ -4198,7 +4198,9 @@ void ieee80211_check_fast_rx(struct sta_ - .vif_type = sdata->vif.type, - .control_port_protocol = sdata->control_port_protocol, - }, *old, *new = NULL; -@@ -193,7 +193,7 @@ Signed-off-by: Felix Fietkau - - /* use sparse to check that we don't return without updating */ - __acquire(check_fast_rx); --@@ -4227,6 +4229,17 @@ void ieee80211_check_fast_rx(struct sta_ -+@@ -4311,6 +4313,17 @@ void ieee80211_check_fast_rx(struct sta_ - if (assign) - new = kmemdup(&fastrx, sizeof(fastrx), GFP_KERNEL); - -@@ -211,7 +211,7 @@ Signed-off-by: Felix Fietkau - spin_lock_bh(&sta->lock); - old = rcu_dereference_protected(sta->fast_rx, true); - rcu_assign_pointer(sta->fast_rx, new); --@@ -4273,6 +4286,108 @@ void ieee80211_check_fast_rx_iface(struc -+@@ -4357,6 +4370,108 @@ void ieee80211_check_fast_rx_iface(struc - mutex_unlock(&local->sta_mtx); - } - -@@ -320,7 +320,7 @@ Signed-off-by: Felix Fietkau - static bool ieee80211_invoke_fast_rx(struct ieee80211_rx_data *rx, - struct ieee80211_fast_rx *fast_rx) - { --@@ -4293,9 +4408,6 @@ static bool ieee80211_invoke_fast_rx(str -+@@ -4377,9 +4492,6 @@ static bool ieee80211_invoke_fast_rx(str - } addrs __aligned(2); - struct ieee80211_sta_rx_stats *stats = &sta->rx_stats; - -@@ -330,7 +330,7 @@ Signed-off-by: Felix Fietkau - /* for parallel-rx, we need to have DUP_VALIDATED, otherwise we write - * to a common data structure; drivers can implement that per queue - * but we don't have that information in mac80211 --@@ -4369,32 +4481,6 @@ static bool ieee80211_invoke_fast_rx(str -+@@ -4453,32 +4565,6 @@ static bool ieee80211_invoke_fast_rx(str - pskb_trim(skb, skb->len - fast_rx->icv_len)) - goto drop; - -@@ -363,7 +363,7 @@ Signed-off-by: Felix Fietkau - if (rx->key && !ieee80211_has_protected(hdr->frame_control)) - goto drop; - --@@ -4406,12 +4492,6 @@ static bool ieee80211_invoke_fast_rx(str -+@@ -4490,12 +4576,6 @@ static bool ieee80211_invoke_fast_rx(str - return true; - } - -@@ -376,7 +376,7 @@ Signed-off-by: Felix Fietkau - /* do the header conversion - first grab the addresses */ - ether_addr_copy(addrs.da, skb->data + fast_rx->da_offs); - ether_addr_copy(addrs.sa, skb->data + fast_rx->sa_offs); --@@ -4420,62 +4500,14 @@ static bool ieee80211_invoke_fast_rx(str -+@@ -4504,62 +4584,14 @@ static bool ieee80211_invoke_fast_rx(str - /* push the addresses in front */ - memcpy(skb_push(skb, sizeof(addrs)), &addrs, sizeof(addrs)); - -@@ -443,7 +443,7 @@ Signed-off-by: Felix Fietkau - stats->dropped++; - return true; - } --@@ -4529,6 +4561,47 @@ static bool ieee80211_prepare_and_rx_han -+@@ -4613,6 +4645,47 @@ static bool ieee80211_prepare_and_rx_han - return true; - } - -@@ -491,7 +491,7 @@ Signed-off-by: Felix Fietkau - /* - * This is the actual Rx frames handler. as it belongs to Rx path it must - * be called with rcu_read_lock protection. --@@ -4766,15 +4839,20 @@ void ieee80211_rx_list(struct ieee80211_ -+@@ -4850,15 +4923,20 @@ void ieee80211_rx_list(struct ieee80211_ - * if it was previously present. - * Also, frames with less than 16 bytes are dropped. - */ -diff --git a/package/kernel/mac80211/patches/subsys/316-mac80211-enable-QoS-support-for-nl80211-ctrl-port.patch b/package/kernel/mac80211/patches/subsys/316-mac80211-enable-QoS-support-for-nl80211-ctrl-port.patch -new file mode 100644 -index 0000000000..4be011ffec ---- /dev/null -+++ b/package/kernel/mac80211/patches/subsys/316-mac80211-enable-QoS-support-for-nl80211-ctrl-port.patch -@@ -0,0 +1,116 @@ -+From: Markus Theil -+Date: Sat, 6 Feb 2021 12:51:12 +0100 -+Subject: [PATCH] mac80211: enable QoS support for nl80211 ctrl port -+ -+This patch unifies sending control port frames -+over nl80211 and AF_PACKET sockets a little more. -+ -+Before this patch, EAPOL frames got QoS prioritization -+only when using AF_PACKET sockets. -+ -+__ieee80211_select_queue only selects a QoS-enabled queue -+for control port frames, when the control port protocol -+is set correctly on the skb. For the AF_PACKET path this -+works, but the nl80211 path used ETH_P_802_3. -+ -+Another check for injected frames in wme.c then prevented -+the QoS TID to be copied in the frame. -+ -+In order to fix this, get rid of the frame injection marking -+for nl80211 ctrl port and set the correct ethernet protocol. -+ -+Please note: -+An erlier version of this path tried to prevent -+frame aggregation for control port frames in order to speed up -+the initial connection setup a little. This seemed to cause -+issues on my older Intel dvm-based hardware, and was therefore -+removed again. Future commits which try to reintroduce this -+have to check carefully how hw behaves with aggregated and -+non-aggregated traffic for the same TID. -+My NIC: Intel(R) Centrino(R) Ultimate-N 6300 AGN, REV=0x74 -+ -+Reported-by: kernel test robot -+Signed-off-by: Markus Theil -+Link: https://lore.kernel.org/r/20210206115112.567881-1-markus.theil@tu-ilmenau.de -+Signed-off-by: Johannes Berg -+--- -+ -+--- a/net/mac80211/status.c -++++ b/net/mac80211/status.c -+@@ -628,16 +628,12 @@ static void ieee80211_report_ack_skb(str -+ u64 cookie = IEEE80211_SKB_CB(skb)->ack.cookie; -+ struct ieee80211_sub_if_data *sdata; -+ struct ieee80211_hdr *hdr = (void *)skb->data; -+- __be16 ethertype = 0; -+- -+- if (skb->len >= ETH_HLEN && skb->protocol == cpu_to_be16(ETH_P_802_3)) -+- skb_copy_bits(skb, 2 * ETH_ALEN, ðertype, ETH_TLEN); -+ -+ rcu_read_lock(); -+ sdata = ieee80211_sdata_from_skb(local, skb); -+ if (sdata) { -+- if (ethertype == sdata->control_port_protocol || -+- ethertype == cpu_to_be16(ETH_P_PREAUTH)) -++ if (skb->protocol == sdata->control_port_protocol || -++ skb->protocol == cpu_to_be16(ETH_P_PREAUTH)) -+ cfg80211_control_port_tx_status(&sdata->wdev, -+ cookie, -+ skb->data, -+--- a/net/mac80211/tx.c -++++ b/net/mac80211/tx.c -+@@ -1195,9 +1195,7 @@ ieee80211_tx_prepare(struct ieee80211_su -+ tx->sta = rcu_dereference(sdata->u.vlan.sta); -+ if (!tx->sta && sdata->wdev.use_4addr) -+ return TX_DROP; -+- } else if (info->flags & (IEEE80211_TX_INTFL_NL80211_FRAME_TX | -+- IEEE80211_TX_CTL_INJECTED) || -+- tx->sdata->control_port_protocol == tx->skb->protocol) { -++ } else if (tx->sdata->control_port_protocol == tx->skb->protocol) { -+ tx->sta = sta_info_get_bss(sdata, hdr->addr1); -+ } -+ if (!tx->sta && !is_multicast_ether_addr(hdr->addr1)) -+@@ -5421,6 +5419,7 @@ int ieee80211_tx_control_port(struct wip -+ { -+ struct ieee80211_sub_if_data *sdata = IEEE80211_DEV_TO_SUB_IF(dev); -+ struct ieee80211_local *local = sdata->local; -++ struct sta_info *sta; -+ struct sk_buff *skb; -+ struct ethhdr *ehdr; -+ u32 ctrl_flags = 0; -+@@ -5443,8 +5442,7 @@ int ieee80211_tx_control_port(struct wip -+ if (cookie) -+ ctrl_flags |= IEEE80211_TX_CTL_REQ_TX_STATUS; -+ -+- flags |= IEEE80211_TX_INTFL_NL80211_FRAME_TX | -+- IEEE80211_TX_CTL_INJECTED; -++ flags |= IEEE80211_TX_INTFL_NL80211_FRAME_TX; -+ -+ skb = dev_alloc_skb(local->hw.extra_tx_headroom + -+ sizeof(struct ethhdr) + len); -+@@ -5461,10 +5459,25 @@ int ieee80211_tx_control_port(struct wip -+ ehdr->h_proto = proto; -+ -+ skb->dev = dev; -+- skb->protocol = htons(ETH_P_802_3); -++ skb->protocol = proto; -+ skb_reset_network_header(skb); -+ skb_reset_mac_header(skb); -+ -++ /* update QoS header to prioritize control port frames if possible, -++ * priorization also happens for control port frames send over -++ * AF_PACKET -++ */ -++ rcu_read_lock(); -++ -++ if (ieee80211_lookup_ra_sta(sdata, skb, &sta) == 0 && !IS_ERR(sta)) { -++ u16 queue = __ieee80211_select_queue(sdata, sta, skb); -++ -++ skb_set_queue_mapping(skb, queue); -++ skb_get_hash(skb); -++ } -++ -++ rcu_read_unlock(); -++ -+ /* mutex lock is only needed for incrementing the cookie counter */ -+ mutex_lock(&local->mtx); -+ diff --git a/package/kernel/mac80211/patches/subsys/320-mac80211_hwsim-add-6GHz-channels.patch b/package/kernel/mac80211/patches/subsys/320-mac80211_hwsim-add-6GHz-channels.patch new file mode 100644 index 0000000000..a7c09f00bc @@ -3830,766 +2267,6 @@ index 96ee595ac1..1cab2eb194 100644 CFLAGS_trace.o := -I$(src) rc80211_minstrel-y := \ -diff --git a/package/kernel/mac80211/patches/subsys/353-mac80211-minstrel_ht-fix-MINSTREL_FRAC-macro.patch b/package/kernel/mac80211/patches/subsys/353-mac80211-minstrel_ht-fix-MINSTREL_FRAC-macro.patch -new file mode 100644 -index 0000000000..0d475b7329 ---- /dev/null -+++ b/package/kernel/mac80211/patches/subsys/353-mac80211-minstrel_ht-fix-MINSTREL_FRAC-macro.patch -@@ -0,0 +1,21 @@ -+From: Felix Fietkau -+Date: Wed, 28 Apr 2021 21:03:13 +0200 -+Subject: [PATCH] mac80211: minstrel_ht: fix MINSTREL_FRAC macro -+ -+Add missing braces to avoid issues with e.g. using additions in the -+div expression -+ -+Signed-off-by: Felix Fietkau -+--- -+ -+--- a/net/mac80211/rc80211_minstrel_ht.h -++++ b/net/mac80211/rc80211_minstrel_ht.h -+@@ -14,7 +14,7 @@ -+ -+ /* scaled fraction values */ -+ #define MINSTREL_SCALE 12 -+-#define MINSTREL_FRAC(val, div) (((val) << MINSTREL_SCALE) / div) -++#define MINSTREL_FRAC(val, div) (((val) << MINSTREL_SCALE) / (div)) -+ #define MINSTREL_TRUNC(val) ((val) >> MINSTREL_SCALE) -+ -+ #define EWMA_LEVEL 96 /* ewma weighting factor [/EWMA_DIV] */ -diff --git a/package/kernel/mac80211/patches/subsys/370-mac80211-fix-TXQ-AC-confusion.patch b/package/kernel/mac80211/patches/subsys/370-mac80211-fix-TXQ-AC-confusion.patch -deleted file mode 100644 -index 0b7c8dd49b..0000000000 ---- a/package/kernel/mac80211/patches/subsys/370-mac80211-fix-TXQ-AC-confusion.patch -+++ /dev/null -@@ -1,61 +0,0 @@ --From: Johannes Berg --Date: Tue, 23 Mar 2021 21:05:01 +0100 --Subject: [PATCH] mac80211: fix TXQ AC confusion -- --Normally, TXQs have -- -- txq->tid = tid; -- txq->ac = ieee80211_ac_from_tid(tid); -- --However, the special management TXQ actually has -- -- txq->tid = IEEE80211_NUM_TIDS; // 16 -- txq->ac = IEEE80211_AC_VO; -- --This makes sense, but ieee80211_ac_from_tid(16) is the same --as ieee80211_ac_from_tid(0) which is just IEEE80211_AC_BE. -- --Now, normally this is fine. However, if the netdev queues --were stopped, then the code in ieee80211_tx_dequeue() will --propagate the stop from the interface (vif->txqs_stopped[]) --if the AC 2 (ieee80211_ac_from_tid(txq->tid)) is marked as --stopped. On wake, however, __ieee80211_wake_txqs() will wake --the TXQ if AC 0 (txq->ac) is woken up. -- --If a driver stops all queues with ieee80211_stop_tx_queues() --and then wakes them again with ieee80211_wake_tx_queues(), --the ieee80211_wake_txqs() tasklet will run to resync queue --and TXQ state. If all queues were woken, then what'll happen --is that _ieee80211_wake_txqs() will run in order of HW queues --0-3, typically (and certainly for iwlwifi) corresponding to --ACs 0-3, so it'll call __ieee80211_wake_txqs() for each AC in --order 0-3. -- --When __ieee80211_wake_txqs() is called for AC 0 (VO) that'll --wake up the management TXQ (remember its tid is 16), and the --driver's wake_tx_queue() will be called. That tries to get a --frame, which will immediately *stop* the TXQ again, because --now we check against AC 2, and AC 2 hasn't yet been marked as --woken up again in sdata->vif.txqs_stopped[] since we're only --in the __ieee80211_wake_txqs() call for AC 0. -- --Thus, the management TXQ will never be started again. -- --Fix this by checking txq->ac directly instead of calculating --the AC as ieee80211_ac_from_tid(txq->tid). -- --Fixes: adf8ed01e4fd ("mac80211: add an optional TXQ for other PS-buffered frames") --Signed-off-by: Johannes Berg ----- -- ----- a/net/mac80211/tx.c --+++ b/net/mac80211/tx.c --@@ -3589,7 +3589,7 @@ begin: -- test_bit(IEEE80211_TXQ_STOP_NETIF_TX, &txqi->flags)) -- goto out; -- --- if (vif->txqs_stopped[ieee80211_ac_from_tid(txq->tid)]) { --+ if (vif->txqs_stopped[txq->ac]) { -- set_bit(IEEE80211_TXQ_STOP_NETIF_TX, &txqi->flags); -- goto out; -- } -diff --git a/package/kernel/mac80211/patches/subsys/371-mac80211-don-t-apply-flow-control-on-management-fram.patch b/package/kernel/mac80211/patches/subsys/371-mac80211-don-t-apply-flow-control-on-management-fram.patch -index b439a3814c..8d094a3632 100644 ---- a/package/kernel/mac80211/patches/subsys/371-mac80211-don-t-apply-flow-control-on-management-fram.patch -+++ b/package/kernel/mac80211/patches/subsys/371-mac80211-don-t-apply-flow-control-on-management-fram.patch -@@ -28,7 +28,7 @@ Signed-off-by: Johannes Berg - * - * Transmit and frame generation functions. - */ --@@ -1403,8 +1403,17 @@ static void ieee80211_txq_enqueue(struct -+@@ -1401,8 +1401,17 @@ static void ieee80211_txq_enqueue(struct - ieee80211_set_skb_enqueue_time(skb); - - spin_lock_bh(&fq->lock); -@@ -48,7 +48,7 @@ Signed-off-by: Johannes Berg - spin_unlock_bh(&fq->lock); - } - --@@ -3846,6 +3855,9 @@ bool ieee80211_txq_airtime_check(struct -+@@ -3844,6 +3853,9 @@ bool ieee80211_txq_airtime_check(struct - if (!txq->sta) - return true; - -diff --git a/package/kernel/mac80211/patches/subsys/372-mac80211-set-sk_pacing_shift-for-802.3-txpath.patch b/package/kernel/mac80211/patches/subsys/372-mac80211-set-sk_pacing_shift-for-802.3-txpath.patch -index 4d8a91a413..5bc1469a3f 100644 ---- a/package/kernel/mac80211/patches/subsys/372-mac80211-set-sk_pacing_shift-for-802.3-txpath.patch -+++ b/package/kernel/mac80211/patches/subsys/372-mac80211-set-sk_pacing_shift-for-802.3-txpath.patch -@@ -9,7 +9,7 @@ Signed-off-by: Lorenzo Bianconi - - --- a/net/mac80211/tx.c - +++ b/net/mac80211/tx.c --@@ -4173,6 +4173,9 @@ static bool ieee80211_tx_8023(struct iee -+@@ -4171,6 +4171,9 @@ static bool ieee80211_tx_8023(struct iee - unsigned long flags; - int q = info->hw_queue; - -diff --git a/package/kernel/mac80211/patches/subsys/373-mac80211-support-Rx-timestamp-calculation-for-all-pr.patch b/package/kernel/mac80211/patches/subsys/373-mac80211-support-Rx-timestamp-calculation-for-all-pr.patch -index c432d77b2e..117fb35fcf 100644 ---- a/package/kernel/mac80211/patches/subsys/373-mac80211-support-Rx-timestamp-calculation-for-all-pr.patch -+++ b/package/kernel/mac80211/patches/subsys/373-mac80211-support-Rx-timestamp-calculation-for-all-pr.patch -@@ -15,7 +15,7 @@ Signed-off-by: Johannes Berg - - --- a/net/mac80211/ieee80211_i.h - +++ b/net/mac80211/ieee80211_i.h --@@ -1600,13 +1600,8 @@ ieee80211_have_rx_timestamp(struct ieee8 -+@@ -1587,13 +1587,8 @@ ieee80211_have_rx_timestamp(struct ieee8 - { - WARN_ON_ONCE(status->flag & RX_FLAG_MACTIME_START && - status->flag & RX_FLAG_MACTIME_END); -diff --git a/package/kernel/mac80211/patches/subsys/374-mac80211-fix-time-is-after-bug-in-mlme.patch b/package/kernel/mac80211/patches/subsys/374-mac80211-fix-time-is-after-bug-in-mlme.patch -deleted file mode 100644 -index 0573aece64..0000000000 ---- a/package/kernel/mac80211/patches/subsys/374-mac80211-fix-time-is-after-bug-in-mlme.patch -+++ /dev/null -@@ -1,31 +0,0 @@ --From: Ben Greear --Date: Tue, 30 Mar 2021 16:07:49 -0700 --Subject: [PATCH] mac80211: fix time-is-after bug in mlme -- --The incorrect timeout check caused probing to happen when it did --not need to happen. This in turn caused tx performance drop --for around 5 seconds in ath10k-ct driver. Possibly that tx drop --is due to a secondary issue, but fixing the probe to not happen --when traffic is running fixes the symptom. -- --Signed-off-by: Ben Greear --Fixes: 9abf4e49830d ("mac80211: optimize station connection monitor") --Acked-by: Felix Fietkau --Link: https://lore.kernel.org/r/20210330230749.14097-1-greearb@candelatech.com --Signed-off-by: Johannes Berg ----- -- ----- a/net/mac80211/mlme.c --+++ b/net/mac80211/mlme.c --@@ -4691,7 +4691,10 @@ static void ieee80211_sta_conn_mon_timer -- timeout = sta->rx_stats.last_rx; -- timeout += IEEE80211_CONNECTION_IDLE_TIME; -- --- if (time_is_before_jiffies(timeout)) { --+ /* If timeout is after now, then update timer to fire at --+ * the later date, but do not actually probe at this time. --+ */ --+ if (time_is_after_jiffies(timeout)) { -- mod_timer(&ifmgd->conn_mon_timer, round_jiffies_up(timeout)); -- return; -- } -diff --git a/package/kernel/mac80211/patches/subsys/374-mac80211-move-A-MPDU-session-check-from-minstrel_ht-.patch b/package/kernel/mac80211/patches/subsys/374-mac80211-move-A-MPDU-session-check-from-minstrel_ht-.patch -new file mode 100644 -index 0000000000..031f8e1636 ---- /dev/null -+++ b/package/kernel/mac80211/patches/subsys/374-mac80211-move-A-MPDU-session-check-from-minstrel_ht-.patch -@@ -0,0 +1,126 @@ -+From: Felix Fietkau -+Date: Thu, 17 Jun 2021 17:56:54 +0200 -+Subject: [PATCH] mac80211: move A-MPDU session check from minstrel_ht to -+ mac80211 -+ -+This avoids calling back into tx handlers from within the rate control module. -+Preparation for deferring rate control until tx dequeue -+ -+Signed-off-by: Felix Fietkau -+--- -+ -+--- a/include/net/mac80211.h -++++ b/include/net/mac80211.h -+@@ -6160,6 +6160,11 @@ enum rate_control_capabilities { -+ * otherwise the NSS difference doesn't bother us. -+ */ -+ RATE_CTRL_CAPA_VHT_EXT_NSS_BW = BIT(0), -++ /** -++ * @RATE_CTRL_CAPA_AMPDU_TRIGGER: -++ * mac80211 should start A-MPDU sessions on tx -++ */ -++ RATE_CTRL_CAPA_AMPDU_TRIGGER = BIT(1), -+ }; -+ -+ struct rate_control_ops { -+--- a/net/mac80211/rc80211_minstrel_ht.c -++++ b/net/mac80211/rc80211_minstrel_ht.c -+@@ -1153,29 +1153,6 @@ minstrel_downgrade_prob_rate(struct mins -+ } -+ -+ static void -+-minstrel_aggr_check(struct ieee80211_sta *pubsta, struct sk_buff *skb) -+-{ -+- struct ieee80211_hdr *hdr = (struct ieee80211_hdr *) skb->data; -+- struct sta_info *sta = container_of(pubsta, struct sta_info, sta); -+- u16 tid; -+- -+- if (skb_get_queue_mapping(skb) == IEEE80211_AC_VO) -+- return; -+- -+- if (unlikely(!ieee80211_is_data_qos(hdr->frame_control))) -+- return; -+- -+- if (unlikely(skb->protocol == cpu_to_be16(ETH_P_PAE))) -+- return; -+- -+- tid = ieee80211_get_tid(hdr); -+- if (likely(sta->ampdu_mlme.tid_tx[tid])) -+- return; -+- -+- ieee80211_start_tx_ba_session(pubsta, tid, 0); -+-} -+- -+-static void -+ minstrel_ht_tx_status(void *priv, struct ieee80211_supported_band *sband, -+ void *priv_sta, struct ieee80211_tx_status *st) -+ { -+@@ -1477,10 +1454,6 @@ minstrel_ht_get_rate(void *priv, struct -+ struct minstrel_priv *mp = priv; -+ u16 sample_idx; -+ -+- if (!(info->flags & IEEE80211_TX_CTL_AMPDU) && -+- !minstrel_ht_is_legacy_group(MI_RATE_GROUP(mi->max_prob_rate))) -+- minstrel_aggr_check(sta, txrc->skb); -+- -+ info->flags |= mi->tx_flags; -+ -+ #ifdef CPTCFG_MAC80211_DEBUGFS -+@@ -1894,6 +1867,7 @@ static u32 minstrel_ht_get_expected_thro -+ -+ static const struct rate_control_ops mac80211_minstrel_ht = { -+ .name = "minstrel_ht", -++ .capa = RATE_CTRL_CAPA_AMPDU_TRIGGER, -+ .tx_status_ext = minstrel_ht_tx_status, -+ .get_rate = minstrel_ht_get_rate, -+ .rate_init = minstrel_ht_rate_init, -+--- a/net/mac80211/tx.c -++++ b/net/mac80211/tx.c -+@@ -3931,6 +3931,29 @@ void ieee80211_txq_schedule_start(struct -+ } -+ EXPORT_SYMBOL(ieee80211_txq_schedule_start); -+ -++static void -++ieee80211_aggr_check(struct ieee80211_sub_if_data *sdata, -++ struct sta_info *sta, -++ struct sk_buff *skb) -++{ -++ struct rate_control_ref *ref = sdata->local->rate_ctrl; -++ u16 tid; -++ -++ if (!ref || !(ref->ops->capa & RATE_CTRL_CAPA_AMPDU_TRIGGER)) -++ return; -++ -++ if (!sta || !sta->sta.ht_cap.ht_supported || -++ !sta->sta.wme || skb_get_queue_mapping(skb) == IEEE80211_AC_VO || -++ skb->protocol == sdata->control_port_protocol) -++ return; -++ -++ tid = skb->priority & IEEE80211_QOS_CTL_TID_MASK; -++ if (likely(sta->ampdu_mlme.tid_tx[tid])) -++ return; -++ -++ ieee80211_start_tx_ba_session(&sta->sta, tid, 0); -++} -++ -+ void __ieee80211_subif_start_xmit(struct sk_buff *skb, -+ struct net_device *dev, -+ u32 info_flags, -+@@ -3961,6 +3984,8 @@ void __ieee80211_subif_start_xmit(struct -+ skb_get_hash(skb); -+ } -+ -++ ieee80211_aggr_check(sdata, sta, skb); -++ -+ if (sta) { -+ struct ieee80211_fast_tx *fast_tx; -+ -+@@ -4224,6 +4249,8 @@ static void ieee80211_8023_xmit(struct i -+ -+ memset(info, 0, sizeof(*info)); -+ -++ ieee80211_aggr_check(sdata, sta, skb); -++ -+ tid = skb->priority & IEEE80211_QOS_CTL_TAG1D_MASK; -+ tid_tx = rcu_dereference(sta->ampdu_mlme.tid_tx[tid]); -+ if (tid_tx) { -diff --git a/package/kernel/mac80211/patches/subsys/375-mac80211-call-ieee80211_tx_h_rate_ctrl-when-dequeue.patch b/package/kernel/mac80211/patches/subsys/375-mac80211-call-ieee80211_tx_h_rate_ctrl-when-dequeue.patch -new file mode 100644 -index 0000000000..cf84fca68a ---- /dev/null -+++ b/package/kernel/mac80211/patches/subsys/375-mac80211-call-ieee80211_tx_h_rate_ctrl-when-dequeue.patch -@@ -0,0 +1,114 @@ -+From: Ryder Lee -+Date: Fri, 28 May 2021 14:05:41 +0800 -+Subject: [PATCH] mac80211: call ieee80211_tx_h_rate_ctrl() when dequeue -+ -+Make ieee80211_tx_h_rate_ctrl() get called on dequeue to improve -+performance since it reduces the turnaround time for rate control. -+ -+Signed-off-by: Ryder Lee -+--- -+ -+--- a/net/mac80211/tx.c -++++ b/net/mac80211/tx.c -+@@ -1778,8 +1778,6 @@ static int invoke_tx_handlers_early(stru -+ CALL_TXH(ieee80211_tx_h_ps_buf); -+ CALL_TXH(ieee80211_tx_h_check_control_port_protocol); -+ CALL_TXH(ieee80211_tx_h_select_key); -+- if (!ieee80211_hw_check(&tx->local->hw, HAS_RATE_CONTROL)) -+- CALL_TXH(ieee80211_tx_h_rate_ctrl); -+ -+ txh_done: -+ if (unlikely(res == TX_DROP)) { -+@@ -1812,6 +1810,9 @@ static int invoke_tx_handlers_late(struc -+ goto txh_done; -+ } -+ -++ if (!ieee80211_hw_check(&tx->local->hw, HAS_RATE_CONTROL)) -++ CALL_TXH(ieee80211_tx_h_rate_ctrl); -++ -+ CALL_TXH(ieee80211_tx_h_michael_mic_add); -+ CALL_TXH(ieee80211_tx_h_sequence); -+ CALL_TXH(ieee80211_tx_h_fragment); -+@@ -3382,15 +3383,21 @@ out: -+ * Can be called while the sta lock is held. Anything that can cause packets to -+ * be generated will cause deadlock! -+ */ -+-static void ieee80211_xmit_fast_finish(struct ieee80211_sub_if_data *sdata, -+- struct sta_info *sta, u8 pn_offs, -+- struct ieee80211_key *key, -+- struct sk_buff *skb) -++static ieee80211_tx_result -++ieee80211_xmit_fast_finish(struct ieee80211_sub_if_data *sdata, -++ struct sta_info *sta, u8 pn_offs, -++ struct ieee80211_key *key, -++ struct ieee80211_tx_data *tx) -+ { -++ struct sk_buff *skb = tx->skb; -+ struct ieee80211_tx_info *info = IEEE80211_SKB_CB(skb); -+ struct ieee80211_hdr *hdr = (void *)skb->data; -+ u8 tid = IEEE80211_NUM_TIDS; -+ -++ if (!ieee80211_hw_check(&tx->local->hw, HAS_RATE_CONTROL) && -++ ieee80211_tx_h_rate_ctrl(tx) != TX_CONTINUE) -++ return TX_DROP; -++ -+ if (key) -+ info->control.hw_key = &key->conf; -+ -+@@ -3439,6 +3446,8 @@ static void ieee80211_xmit_fast_finish(s -+ break; -+ } -+ } -++ -++ return TX_CONTINUE; -+ } -+ -+ static bool ieee80211_xmit_fast(struct ieee80211_sub_if_data *sdata, -+@@ -3542,24 +3551,17 @@ static bool ieee80211_xmit_fast(struct i -+ tx.sta = sta; -+ tx.key = fast_tx->key; -+ -+- if (!ieee80211_hw_check(&local->hw, HAS_RATE_CONTROL)) { -+- tx.skb = skb; -+- r = ieee80211_tx_h_rate_ctrl(&tx); -+- skb = tx.skb; -+- tx.skb = NULL; -+- -+- if (r != TX_CONTINUE) { -+- if (r != TX_QUEUED) -+- kfree_skb(skb); -+- return true; -+- } -+- } -+- -+ if (ieee80211_queue_skb(local, sdata, sta, skb)) -+ return true; -+ -+- ieee80211_xmit_fast_finish(sdata, sta, fast_tx->pn_offs, -+- fast_tx->key, skb); -++ tx.skb = skb; -++ r = ieee80211_xmit_fast_finish(sdata, sta, fast_tx->pn_offs, -++ fast_tx->key, &tx); -++ tx.skb = NULL; -++ if (r == TX_DROP) { -++ kfree_skb(skb); -++ return true; -++ } -+ -+ if (sdata->vif.type == NL80211_IFTYPE_AP_VLAN) -+ sdata = container_of(sdata->bss, -+@@ -3670,8 +3672,12 @@ begin: -+ (tx.key->conf.flags & IEEE80211_KEY_FLAG_GENERATE_IV)) -+ pn_offs = ieee80211_hdrlen(hdr->frame_control); -+ -+- ieee80211_xmit_fast_finish(sta->sdata, sta, pn_offs, -+- tx.key, skb); -++ r = ieee80211_xmit_fast_finish(sta->sdata, sta, pn_offs, -++ tx.key, &tx); -++ if (r != TX_CONTINUE) { -++ ieee80211_free_txskb(&local->hw, skb); -++ goto begin; -++ } -+ } else { -+ if (invoke_tx_handlers_late(&tx)) -+ goto begin; -diff --git a/package/kernel/mac80211/patches/subsys/376-mac80211-add-rate-control-support-for-encap-offload.patch b/package/kernel/mac80211/patches/subsys/376-mac80211-add-rate-control-support-for-encap-offload.patch -new file mode 100644 -index 0000000000..43a4a1334d ---- /dev/null -+++ b/package/kernel/mac80211/patches/subsys/376-mac80211-add-rate-control-support-for-encap-offload.patch -@@ -0,0 +1,119 @@ -+From: Ryder Lee -+Date: Fri, 28 May 2021 14:05:43 +0800 -+Subject: [PATCH] mac80211: add rate control support for encap offload -+ -+The software rate control cannot deal with encap offload, so fix it. -+ -+Signed-off-by: Ryder Lee -+--- -+ -+--- a/net/mac80211/ieee80211_i.h -++++ b/net/mac80211/ieee80211_i.h -+@@ -2024,6 +2024,15 @@ static inline void ieee80211_tx_skb(stru -+ ieee80211_tx_skb_tid(sdata, skb, 7); -+ } -+ -++static inline bool ieee80211_is_tx_data(struct sk_buff *skb) -++{ -++ struct ieee80211_hdr *hdr = (struct ieee80211_hdr *)skb->data; -++ struct ieee80211_tx_info *info = IEEE80211_SKB_CB(skb); -++ -++ return info->flags & IEEE80211_TX_CTL_HW_80211_ENCAP || -++ ieee80211_is_data(hdr->frame_control); -++} -++ -+ u32 ieee802_11_parse_elems_crc(const u8 *start, size_t len, bool action, -+ struct ieee802_11_elems *elems, -+ u64 filter, u32 crc, u8 *transmitter_bssid, -+--- a/net/mac80211/rate.c -++++ b/net/mac80211/rate.c -+@@ -297,15 +297,11 @@ void ieee80211_check_rate_mask(struct ie -+ static bool rc_no_data_or_no_ack_use_min(struct ieee80211_tx_rate_control *txrc) -+ { -+ struct sk_buff *skb = txrc->skb; -+- struct ieee80211_hdr *hdr = (struct ieee80211_hdr *) skb->data; -+ struct ieee80211_tx_info *info = IEEE80211_SKB_CB(skb); -+- __le16 fc; -+- -+- fc = hdr->frame_control; -+ -+ return (info->flags & (IEEE80211_TX_CTL_NO_ACK | -+ IEEE80211_TX_CTL_USE_MINRATE)) || -+- !ieee80211_is_data(fc); -++ !ieee80211_is_tx_data(skb); -+ } -+ -+ static void rc_send_low_basicrate(struct ieee80211_tx_rate *rate, -+@@ -870,7 +866,6 @@ void ieee80211_get_tx_rates(struct ieee8 -+ int max_rates) -+ { -+ struct ieee80211_sub_if_data *sdata; -+- struct ieee80211_hdr *hdr = (struct ieee80211_hdr *) skb->data; -+ struct ieee80211_tx_info *info = IEEE80211_SKB_CB(skb); -+ struct ieee80211_supported_band *sband; -+ -+@@ -882,7 +877,7 @@ void ieee80211_get_tx_rates(struct ieee8 -+ sdata = vif_to_sdata(vif); -+ sband = sdata->local->hw.wiphy->bands[info->band]; -+ -+- if (ieee80211_is_data(hdr->frame_control)) -++ if (ieee80211_is_tx_data(skb)) -+ rate_control_apply_mask(sdata, sta, sband, dest, max_rates); -+ -+ if (dest[0].idx < 0) -+--- a/net/mac80211/tx.c -++++ b/net/mac80211/tx.c -+@@ -679,6 +679,7 @@ ieee80211_tx_h_rate_ctrl(struct ieee8021 -+ u32 len; -+ struct ieee80211_tx_rate_control txrc; -+ struct ieee80211_sta_rates *ratetbl = NULL; -++ bool encap = info->flags & IEEE80211_TX_CTL_HW_80211_ENCAP; -+ bool assoc = false; -+ -+ memset(&txrc, 0, sizeof(txrc)); -+@@ -720,7 +721,7 @@ ieee80211_tx_h_rate_ctrl(struct ieee8021 -+ * just wants a probe response. -+ */ -+ if (tx->sdata->vif.bss_conf.use_short_preamble && -+- (ieee80211_is_data(hdr->frame_control) || -++ (ieee80211_is_tx_data(tx->skb) || -+ (tx->sta && test_sta_flag(tx->sta, WLAN_STA_SHORT_PREAMBLE)))) -+ txrc.short_preamble = true; -+ -+@@ -742,7 +743,8 @@ ieee80211_tx_h_rate_ctrl(struct ieee8021 -+ "%s: Dropped data frame as no usable bitrate found while " -+ "scanning and associated. Target station: " -+ "%pM on %d GHz band\n", -+- tx->sdata->name, hdr->addr1, -++ tx->sdata->name, -++ encap ? ((struct ethhdr *)hdr)->h_dest : hdr->addr1, -+ info->band ? 5 : 2)) -+ return TX_DROP; -+ -+@@ -776,7 +778,7 @@ ieee80211_tx_h_rate_ctrl(struct ieee8021 -+ -+ if (txrc.reported_rate.idx < 0) { -+ txrc.reported_rate = tx->rate; -+- if (tx->sta && ieee80211_is_data(hdr->frame_control)) -++ if (tx->sta && ieee80211_is_tx_data(tx->skb)) -+ tx->sta->tx_stats.last_rate = txrc.reported_rate; -+ } else if (tx->sta) -+ tx->sta->tx_stats.last_rate = txrc.reported_rate; -+@@ -3660,8 +3662,16 @@ begin: -+ else -+ info->flags &= ~IEEE80211_TX_CTL_AMPDU; -+ -+- if (info->flags & IEEE80211_TX_CTL_HW_80211_ENCAP) -++ if (info->flags & IEEE80211_TX_CTL_HW_80211_ENCAP) { -++ if (!ieee80211_hw_check(&local->hw, HAS_RATE_CONTROL)) { -++ r = ieee80211_tx_h_rate_ctrl(&tx); -++ if (r != TX_CONTINUE) { -++ ieee80211_free_txskb(&local->hw, skb); -++ goto begin; -++ } -++ } -+ goto encap_out; -++ } -+ -+ if (info->control.flags & IEEE80211_TX_CTRL_FAST_XMIT) { -+ struct sta_info *sta = container_of(txq->sta, struct sta_info, -diff --git a/package/kernel/mac80211/patches/subsys/377-mac80211-minstrel_ht-fix-sample-time-check.patch b/package/kernel/mac80211/patches/subsys/377-mac80211-minstrel_ht-fix-sample-time-check.patch -new file mode 100644 -index 0000000000..d4b327c69c ---- /dev/null -+++ b/package/kernel/mac80211/patches/subsys/377-mac80211-minstrel_ht-fix-sample-time-check.patch -@@ -0,0 +1,23 @@ -+From: Felix Fietkau -+Date: Thu, 17 Jun 2021 12:05:54 +0200 -+Subject: [PATCH] mac80211: minstrel_ht: fix sample time check -+ -+We need to skip sampling if the next sample time is after jiffies, not before. -+This patch fixes an issue where in some cases only very little sampling (or none -+at all) is performed, leading to really bad data rates -+ -+Fixes: 80d55154b2f8 ("mac80211: minstrel_ht: significantly redesign the rate probing strategy") -+Signed-off-by: Felix Fietkau -+--- -+ -+--- a/net/mac80211/rc80211_minstrel_ht.c -++++ b/net/mac80211/rc80211_minstrel_ht.c -+@@ -1466,7 +1466,7 @@ minstrel_ht_get_rate(void *priv, struct -+ (info->control.flags & IEEE80211_TX_CTRL_PORT_CTRL_PROTO)) -+ return; -+ -+- if (time_is_before_jiffies(mi->sample_time)) -++ if (time_is_after_jiffies(mi->sample_time)) -+ return; -+ -+ mi->sample_time = jiffies + MINSTREL_SAMPLE_INTERVAL; -diff --git a/package/kernel/mac80211/patches/subsys/378-mac80211-remove-iwlwifi-specific-workaround-that-bro.patch b/package/kernel/mac80211/patches/subsys/378-mac80211-remove-iwlwifi-specific-workaround-that-bro.patch -new file mode 100644 -index 0000000000..a5ad377e6f ---- /dev/null -+++ b/package/kernel/mac80211/patches/subsys/378-mac80211-remove-iwlwifi-specific-workaround-that-bro.patch -@@ -0,0 +1,51 @@ -+From: Felix Fietkau -+Date: Sat, 19 Jun 2021 12:10:14 +0200 -+Subject: [PATCH] mac80211: remove iwlwifi specific workaround that broke sta -+ NDP tx -+ -+Sending nulldata packets is important for sw AP link probing and detecting -+4-address mode links. The checks that dropped these packets were apparently -+added to work around an iwlwifi firmware bug with multi-TID aggregation. -+ -+Fixes: 41cbb0f5a295 ("mac80211: add support for HE") -+Cc: stable@vger.kernel.org -+Signed-off-by: Felix Fietkau -+--- -+ -+--- a/drivers/net/wireless/intel/iwlwifi/mvm/tx.c -++++ b/drivers/net/wireless/intel/iwlwifi/mvm/tx.c -+@@ -1085,6 +1085,9 @@ static int iwl_mvm_tx_mpdu(struct iwl_mv -+ if (WARN_ON_ONCE(mvmsta->sta_id == IWL_MVM_INVALID_STA)) -+ return -1; -+ -++ if (unlikely(ieee80211_is_any_nullfunc(fc)) && sta->he_cap.has_he) -++ return -1; -++ -+ if (unlikely(ieee80211_is_probe_resp(fc))) -+ iwl_mvm_probe_resp_set_noa(mvm, skb); -+ -+--- a/net/mac80211/mlme.c -++++ b/net/mac80211/mlme.c -+@@ -1094,11 +1094,6 @@ void ieee80211_send_nullfunc(struct ieee -+ struct ieee80211_hdr_3addr *nullfunc; -+ struct ieee80211_if_managed *ifmgd = &sdata->u.mgd; -+ -+- /* Don't send NDPs when STA is connected HE */ -+- if (sdata->vif.type == NL80211_IFTYPE_STATION && -+- !(ifmgd->flags & IEEE80211_STA_DISABLE_HE)) -+- return; -+- -+ skb = ieee80211_nullfunc_get(&local->hw, &sdata->vif, -+ !ieee80211_hw_check(&local->hw, DOESNT_SUPPORT_QOS_NDP)); -+ if (!skb) -+@@ -1130,10 +1125,6 @@ static void ieee80211_send_4addr_nullfun -+ if (WARN_ON(sdata->vif.type != NL80211_IFTYPE_STATION)) -+ return; -+ -+- /* Don't send NDPs when connected HE */ -+- if (!(sdata->u.mgd.flags & IEEE80211_STA_DISABLE_HE)) -+- return; -+- -+ skb = dev_alloc_skb(local->hw.extra_tx_headroom + 30); -+ if (!skb) -+ return; -diff --git a/package/kernel/mac80211/patches/subsys/379-mac80211-fix-starting-aggregation-sessions-on-mesh-i.patch b/package/kernel/mac80211/patches/subsys/379-mac80211-fix-starting-aggregation-sessions-on-mesh-i.patch -new file mode 100644 -index 0000000000..2ad083f150 ---- /dev/null -+++ b/package/kernel/mac80211/patches/subsys/379-mac80211-fix-starting-aggregation-sessions-on-mesh-i.patch -@@ -0,0 +1,112 @@ -+From: Felix Fietkau -+Date: Tue, 29 Jun 2021 13:25:09 +0200 -+Subject: [PATCH] mac80211: fix starting aggregation sessions on mesh -+ interfaces -+ -+The logic for starting aggregation sessions was recently moved from minstrel_ht -+to mac80211, into the subif tx handler just after the sta lookup. -+Unfortunately this didn't work for mesh interfaces, since the sta lookup is -+deferred until a much later point in time on those. -+Fix this by also calling the aggregation check right after the deferred sta -+lookup. -+ -+Fixes: 08a46c642001 ("mac80211: move A-MPDU session check from minstrel_ht to mac80211") -+Signed-off-by: Felix Fietkau -+--- -+ -+--- a/net/mac80211/tx.c -++++ b/net/mac80211/tx.c -+@@ -1159,6 +1159,29 @@ static bool ieee80211_tx_prep_agg(struct -+ return queued; -+ } -+ -++static void -++ieee80211_aggr_check(struct ieee80211_sub_if_data *sdata, -++ struct sta_info *sta, -++ struct sk_buff *skb) -++{ -++ struct rate_control_ref *ref = sdata->local->rate_ctrl; -++ u16 tid; -++ -++ if (!ref || !(ref->ops->capa & RATE_CTRL_CAPA_AMPDU_TRIGGER)) -++ return; -++ -++ if (!sta || !sta->sta.ht_cap.ht_supported || -++ !sta->sta.wme || skb_get_queue_mapping(skb) == IEEE80211_AC_VO || -++ skb->protocol == sdata->control_port_protocol) -++ return; -++ -++ tid = skb->priority & IEEE80211_QOS_CTL_TID_MASK; -++ if (likely(sta->ampdu_mlme.tid_tx[tid])) -++ return; -++ -++ ieee80211_start_tx_ba_session(&sta->sta, tid, 0); -++} -++ -+ /* -+ * initialises @tx -+ * pass %NULL for the station if unknown, a valid pointer if known -+@@ -1172,6 +1195,7 @@ ieee80211_tx_prepare(struct ieee80211_su -+ struct ieee80211_local *local = sdata->local; -+ struct ieee80211_hdr *hdr; -+ struct ieee80211_tx_info *info = IEEE80211_SKB_CB(skb); -++ bool aggr_check = false; -+ int tid; -+ -+ memset(tx, 0, sizeof(*tx)); -+@@ -1200,8 +1224,10 @@ ieee80211_tx_prepare(struct ieee80211_su -+ } else if (tx->sdata->control_port_protocol == tx->skb->protocol) { -+ tx->sta = sta_info_get_bss(sdata, hdr->addr1); -+ } -+- if (!tx->sta && !is_multicast_ether_addr(hdr->addr1)) -++ if (!tx->sta && !is_multicast_ether_addr(hdr->addr1)) { -+ tx->sta = sta_info_get(sdata, hdr->addr1); -++ aggr_check = true; -++ } -+ } -+ -+ if (tx->sta && ieee80211_is_data_qos(hdr->frame_control) && -+@@ -1211,8 +1237,12 @@ ieee80211_tx_prepare(struct ieee80211_su -+ struct tid_ampdu_tx *tid_tx; -+ -+ tid = ieee80211_get_tid(hdr); -+- -+ tid_tx = rcu_dereference(tx->sta->ampdu_mlme.tid_tx[tid]); -++ if (!tid_tx && aggr_check) { -++ ieee80211_aggr_check(sdata, tx->sta, skb); -++ tid_tx = rcu_dereference(tx->sta->ampdu_mlme.tid_tx[tid]); -++ } -++ -+ if (tid_tx) { -+ bool queued; -+ -+@@ -3947,29 +3977,6 @@ void ieee80211_txq_schedule_start(struct -+ } -+ EXPORT_SYMBOL(ieee80211_txq_schedule_start); -+ -+-static void -+-ieee80211_aggr_check(struct ieee80211_sub_if_data *sdata, -+- struct sta_info *sta, -+- struct sk_buff *skb) -+-{ -+- struct rate_control_ref *ref = sdata->local->rate_ctrl; -+- u16 tid; -+- -+- if (!ref || !(ref->ops->capa & RATE_CTRL_CAPA_AMPDU_TRIGGER)) -+- return; -+- -+- if (!sta || !sta->sta.ht_cap.ht_supported || -+- !sta->sta.wme || skb_get_queue_mapping(skb) == IEEE80211_AC_VO || -+- skb->protocol == sdata->control_port_protocol) -+- return; -+- -+- tid = skb->priority & IEEE80211_QOS_CTL_TID_MASK; -+- if (likely(sta->ampdu_mlme.tid_tx[tid])) -+- return; -+- -+- ieee80211_start_tx_ba_session(&sta->sta, tid, 0); -+-} -+- -+ void __ieee80211_subif_start_xmit(struct sk_buff *skb, -+ struct net_device *dev, -+ u32 info_flags, diff --git a/package/kernel/mac80211/patches/subsys/380-mac80211-introduce-aql_enable-node-in-debugfs.patch b/package/kernel/mac80211/patches/subsys/380-mac80211-introduce-aql_enable-node-in-debugfs.patch new file mode 100644 index 0000000000..b21b671c10 @@ -6575,13 +4252,13 @@ index 0000000000..c351bc812a ++ .set_sar_specs = ieee80211_set_sar_specs, + }; diff --git a/package/kernel/mac80211/patches/subsys/500-mac80211_configure_antenna_gain.patch b/package/kernel/mac80211/patches/subsys/500-mac80211_configure_antenna_gain.patch -index 3d1bb3d6c8..b2ee61a6dc 100644 +index febe42eb9d..b2ee61a6dc 100644 --- a/package/kernel/mac80211/patches/subsys/500-mac80211_configure_antenna_gain.patch +++ b/package/kernel/mac80211/patches/subsys/500-mac80211_configure_antenna_gain.patch @@ -1,6 +1,6 @@ --- a/include/net/cfg80211.h +++ b/include/net/cfg80211.h --@@ -3736,6 +3736,7 @@ struct mgmt_frame_regs { +-@@ -3745,6 +3745,7 @@ struct mgmt_frame_regs { +@@ -3793,6 +3793,7 @@ struct mgmt_frame_regs { * (as advertised by the nl80211 feature flag.) * @get_tx_power: store the current TX power into the dbm variable; @@ -6590,37 +4267,16 @@ index 3d1bb3d6c8..b2ee61a6dc 100644 * * @set_wds_peer: set the WDS peer for a WDS interface * --@@ -4058,6 +4059,7 @@ struct cfg80211_ops { +-@@ -4067,6 +4068,7 @@ struct cfg80211_ops { +@@ -4115,6 +4116,7 @@ struct cfg80211_ops { enum nl80211_tx_power_setting type, int mbm); int (*get_tx_power)(struct wiphy *wiphy, struct wireless_dev *wdev, int *dbm); -@@ -36,7 +36,7 @@ - u8 ps_dtim_period; - --- a/include/uapi/linux/nl80211.h - +++ b/include/uapi/linux/nl80211.h --@@ -2531,6 +2531,9 @@ enum nl80211_commands { -+@@ -2560,6 +2560,9 @@ enum nl80211_commands { - * disassoc events to indicate that an immediate reconnect to the AP - * is desired. - * -@@ -46,9 +46,9 @@ - * @NUM_NL80211_ATTR: total number of nl80211_attrs available - * @NL80211_ATTR_MAX: highest attribute number currently defined - * @__NL80211_ATTR_AFTER_LAST: internal use --@@ -3022,6 +3025,8 @@ enum nl80211_attrs { -+@@ -3057,6 +3060,8 @@ enum nl80211_attrs { - -- NL80211_ATTR_RECONNECT_REQUESTED, -+ NL80211_ATTR_DISABLE_HE, - - + NL80211_ATTR_WIPHY_ANTENNA_GAIN, - + @@ -57,7 +57,7 @@ __NL80211_ATTR_AFTER_LAST, --- a/net/mac80211/cfg.c +++ b/net/mac80211/cfg.c --@@ -2707,6 +2707,19 @@ static int ieee80211_get_tx_power(struct +-@@ -2709,6 +2709,19 @@ static int ieee80211_get_tx_power(struct +@@ -2761,6 +2761,19 @@ static int ieee80211_get_tx_power(struct return 0; } @@ -6629,7 +4285,7 @@ index 3d1bb3d6c8..b2ee61a6dc 100644 static int ieee80211_set_wds_peer(struct wiphy *wiphy, struct net_device *dev, const u8 *addr) { --@@ -4137,6 +4150,7 @@ const struct cfg80211_ops mac80211_confi +-@@ -4139,6 +4152,7 @@ const struct cfg80211_ops mac80211_confi +@@ -4202,6 +4215,7 @@ const struct cfg80211_ops mac80211_confi .set_wiphy_params = ieee80211_set_wiphy_params, .set_tx_power = ieee80211_set_tx_power, @@ -6638,7 +4294,7 @@ index 3d1bb3d6c8..b2ee61a6dc 100644 CFG80211_TESTMODE_CMD(ieee80211_testmode_cmd) --- a/net/mac80211/ieee80211_i.h +++ b/net/mac80211/ieee80211_i.h --@@ -1403,6 +1403,7 @@ struct ieee80211_local { +-@@ -1390,6 +1390,7 @@ struct ieee80211_local { +@@ -1426,6 +1426,7 @@ struct ieee80211_local { int dynamic_ps_forced_timeout; @@ -6647,18 +4303,17 @@ index 3d1bb3d6c8..b2ee61a6dc 100644 local->hw.max_mtu = IEEE80211_MAX_DATA_LEN; --- a/net/wireless/nl80211.c +++ b/net/wireless/nl80211.c --@@ -733,6 +733,7 @@ static const struct nla_policy nl80211_p -- [NL80211_ATTR_S1G_CAPABILITY_MASK] = -- NLA_POLICY_EXACT_LEN(IEEE80211_S1G_CAPABILITY_LEN), +-@@ -740,6 +740,7 @@ static const struct nla_policy nl80211_p +- NLA_POLICY_RANGE(NLA_U8, NL80211_SAE_PWE_HUNT_AND_PECK, +@@ -753,6 +753,7 @@ static const struct nla_policy nl80211_p -+ NL80211_SAE_PWE_BOTH), + NL80211_SAE_PWE_BOTH), + [NL80211_ATTR_SAR_SPEC] = NLA_POLICY_NESTED(sar_policy), [NL80211_ATTR_RECONNECT_REQUESTED] = { .type = NLA_REJECT }, + [NL80211_ATTR_WIPHY_ANTENNA_GAIN] = { .type = NLA_U32 }, }; /* policy for the key attributes */ --@@ -3241,6 +3242,20 @@ static int nl80211_set_wiphy(struct sk_b +-@@ -3248,6 +3249,20 @@ static int nl80211_set_wiphy(struct sk_b +@@ -3318,6 +3319,20 @@ static int nl80211_set_wiphy(struct sk_b if (result) return result; diff --git a/backports/0039-hostapd-upsate-to-latest-HEAD.patch b/backports/0019-hostapd-update-to-latest-HEAD.patch similarity index 97% rename from backports/0039-hostapd-upsate-to-latest-HEAD.patch rename to backports/0019-hostapd-update-to-latest-HEAD.patch index 538005333..5c9a23e3a 100644 --- a/backports/0039-hostapd-upsate-to-latest-HEAD.patch +++ b/backports/0019-hostapd-update-to-latest-HEAD.patch @@ -1,16 +1,16 @@ -From b70c9429587452776241c95729481accb9c193ae Mon Sep 17 00:00:00 2001 +From 3b094ed6b1602969f0dd71b48ed220d0caace7ab Mon Sep 17 00:00:00 2001 From: John Crispin -Date: Thu, 27 May 2021 13:25:19 +0200 -Subject: [PATCH 03/57] hostapd: upsate to latest HEAD +Date: Sat, 4 Sep 2021 05:48:27 +0200 +Subject: [PATCH 19/27] hostapd: update to latest HEAD Signed-off-by: John Crispin --- package/network/services/hostapd/Makefile | 15 +- .../hostapd/files/hostapd-basic.config | 2 +- .../hostapd/files/hostapd-full.config | 4 +- - .../network/services/hostapd/files/hostapd.sh | 158 ++++++++-- + .../network/services/hostapd/files/hostapd.sh | 141 +++++++-- ...-fix-frequency-setup-with-HE-enabled.patch | 196 ------------- - .../001-wolfssl-init-RNG-with-ECC-key.patch | 43 +++ + ...> 001-wolfssl-init-RNG-with-ECC-key.patch} | 11 +- ...-init-order-disable-pri-sec-channel-.patch | 126 -------- ...andle-HT40-and-mode-downgrade-in-AP-.patch | 102 ------- ...ix-frequency-config-for-non-p2p-vht-.patch | 63 ---- @@ -72,9 +72,9 @@ Signed-off-by: John Crispin .../services/hostapd/src/src/ap/ubus.c | 214 +++++++++++++- .../services/hostapd/src/src/ap/ubus.h | 16 + .../hostapd/src/src/utils/build_features.h | 2 - - 67 files changed, 1329 insertions(+), 2331 deletions(-) + 67 files changed, 1277 insertions(+), 2334 deletions(-) delete mode 100644 package/network/services/hostapd/patches/001-HE-VHT-fix-frequency-setup-with-HE-enabled.patch - create mode 100644 package/network/services/hostapd/patches/001-wolfssl-init-RNG-with-ECC-key.patch + rename package/network/services/hostapd/patches/{802-wolfssl-init-RNG-with-ECC-key.patch => 001-wolfssl-init-RNG-with-ECC-key.patch} (76%) delete mode 100644 package/network/services/hostapd/patches/002-mesh-fix-channel-init-order-disable-pri-sec-channel-.patch delete mode 100644 package/network/services/hostapd/patches/003-wpa_supplicant-handle-HT40-and-mode-downgrade-in-AP-.patch delete mode 100644 package/network/services/hostapd/patches/004-wpa_supplicant-fix-frequency-config-for-non-p2p-vht-.patch @@ -111,7 +111,7 @@ Signed-off-by: John Crispin delete mode 100644 package/network/services/hostapd/patches/801-P2P-Fix-copying-of-secondary-device-types-for-P2P-gr.patch diff --git a/package/network/services/hostapd/Makefile b/package/network/services/hostapd/Makefile -index bd2a7c96ad..fee6889b40 100644 +index 67ea89c339..fee6889b40 100644 --- a/package/network/services/hostapd/Makefile +++ b/package/network/services/hostapd/Makefile @@ -1,19 +1,17 @@ @@ -126,7 +126,7 @@ index bd2a7c96ad..fee6889b40 100644 include $(TOPDIR)/rules.mk PKG_NAME:=hostapd --PKG_RELEASE:=32 +-PKG_RELEASE:=35 +PKG_RELEASE:=$(AUTORELEASE) PKG_SOURCE_URL:=http://w1.fi/hostap.git @@ -179,7 +179,7 @@ index df272e443a..61b6daf861 100644 # EAP-SAKE for the integrated EAP server #CONFIG_EAP_SAKE=y diff --git a/package/network/services/hostapd/files/hostapd.sh b/package/network/services/hostapd/files/hostapd.sh -index 45a49b8faa..e941fa4f77 100644 +index aa72e09eba..e941fa4f77 100644 --- a/package/network/services/hostapd/files/hostapd.sh +++ b/package/network/services/hostapd/files/hostapd.sh @@ -49,6 +49,7 @@ hostapd_append_wpa_key_mgmt() { @@ -190,17 +190,15 @@ index 45a49b8faa..e941fa4f77 100644 ;; eap-eap192) append wpa_key_mgmt "WPA-EAP-SUITE-B-192" -@@ -91,14 +92,19 @@ hostapd_add_log_config() { +@@ -91,6 +92,7 @@ hostapd_add_log_config() { hostapd_common_add_device_config() { config_add_array basic_rate config_add_array supported_rates + config_add_string beacon_rate -- config_add_string country -+ config_add_string country country3 + config_add_string country country3 config_add_boolean country_ie doth - config_add_boolean spectrum_mgmt_required - config_add_int local_pwr_constraint +@@ -99,6 +101,10 @@ hostapd_common_add_device_config() { config_add_string require_mode config_add_boolean legacy_rates config_add_int cell_density @@ -211,27 +209,17 @@ index 45a49b8faa..e941fa4f77 100644 config_add_string acs_chan_bias config_add_array hostapd_options -@@ -114,8 +120,9 @@ hostapd_prepare_device_config() { - +@@ -115,7 +121,8 @@ hostapd_prepare_device_config() { local base_cfg= -- json_get_vars country country_ie beacon_int:100 dtim_period:2 doth require_mode legacy_rates \ + json_get_vars country country3 country_ie beacon_int:100 dtim_period:2 doth require_mode legacy_rates \ - acs_chan_bias local_pwr_constraint spectrum_mgmt_required airtime_mode cell_density -+ json_get_vars country country3 country_ie beacon_int:100 dtim_period:2 doth require_mode legacy_rates \ + acs_chan_bias local_pwr_constraint spectrum_mgmt_required airtime_mode cell_density \ + rts_threshold beacon_rate rssi_reject_assoc_rssi rssi_ignore_probe_request maxassoc hostapd_set_log_options base_cfg -@@ -128,6 +135,7 @@ hostapd_prepare_device_config() { - - [ -n "$country" ] && { - append base_cfg "country_code=$country" "$N" -+ [ -n "$country3" ] && append base_cfg "country3=$country3" "$N" - - [ "$country_ie" -gt 0 ] && { - append base_cfg "ieee80211d=1" "$N" -@@ -206,11 +214,16 @@ hostapd_prepare_device_config() { +@@ -207,11 +214,16 @@ hostapd_prepare_device_config() { hostapd_add_rate brlist "$br" done @@ -248,16 +236,7 @@ index 45a49b8faa..e941fa4f77 100644 json_get_values opts hostapd_options for val in $opts; do -@@ -251,6 +264,8 @@ hostapd_common_add_bss_config() { - config_add_int acct_port - config_add_int acct_interval - -+ config_add_int bss_load_update_period chan_util_avg_period -+ - config_add_string dae_client - config_add_string dae_secret - config_add_int dae_port -@@ -266,7 +281,7 @@ hostapd_common_add_bss_config() { +@@ -269,7 +281,7 @@ hostapd_common_add_bss_config() { config_add_array domain_match domain_match2 domain_suffix_match domain_suffix_match2 config_add_string ieee80211w_mgmt_cipher @@ -266,19 +245,15 @@ index 45a49b8faa..e941fa4f77 100644 config_add_string vlan_tagged_interface vlan_bridge config_add_string vlan_file -@@ -281,9 +296,10 @@ hostapd_common_add_bss_config() { - config_add_string wps_device_type wps_device_name wps_manufacturer wps_pin - config_add_string multi_ap_backhaul_ssid multi_ap_backhaul_key - -- config_add_boolean wnm_sleep_mode bss_transition -+ config_add_boolean wnm_sleep_mode wnm_sleep_mode_no_keys bss_transition +@@ -287,6 +299,7 @@ hostapd_common_add_bss_config() { + config_add_boolean wnm_sleep_mode wnm_sleep_mode_no_keys bss_transition config_add_int time_advertisement config_add_string time_zone + config_add_string vendor_elements config_add_boolean ieee80211k rrm_neighbor_report rrm_beacon_report -@@ -308,6 +324,7 @@ hostapd_common_add_bss_config() { +@@ -311,6 +324,7 @@ hostapd_common_add_bss_config() { config_add_array supported_rates config_add_boolean sae_require_mfp @@ -286,7 +261,7 @@ index 45a49b8faa..e941fa4f77 100644 config_add_string 'owe_transition_bssid:macaddr' 'owe_transition_ssid:string' -@@ -316,7 +333,7 @@ hostapd_common_add_bss_config() { +@@ -319,7 +333,7 @@ hostapd_common_add_bss_config() { config_add_int iw_ipaddr_type_availability iw_gas_address3 config_add_string iw_hessid iw_network_auth_type iw_qos_map_set config_add_array iw_roaming_consortium iw_domain_name iw_anqp_3gpp_cell_net iw_nai_realm @@ -295,7 +270,7 @@ index 45a49b8faa..e941fa4f77 100644 config_add_boolean hs20 disable_dgaf osen config_add_int anqp_domain_id -@@ -327,12 +344,22 @@ hostapd_common_add_bss_config() { +@@ -330,12 +344,22 @@ hostapd_common_add_bss_config() { config_add_array hs20_conn_capab config_add_string osu_ssid hs20_wan_metrics hs20_operating_class hs20_t_c_filename hs20_t_c_timestamp @@ -319,7 +294,7 @@ index 45a49b8faa..e941fa4f77 100644 } hostapd_set_vlan_file() { -@@ -384,7 +411,7 @@ append_iw_anqp_3gpp_cell_net() { +@@ -387,7 +411,7 @@ append_iw_anqp_3gpp_cell_net() { if [ -z "$iw_anqp_3gpp_cell_net_conf" ]; then iw_anqp_3gpp_cell_net_conf="$1" else @@ -328,7 +303,7 @@ index 45a49b8faa..e941fa4f77 100644 fi } -@@ -396,10 +423,22 @@ append_iw_nai_realm() { +@@ -399,10 +423,22 @@ append_iw_nai_realm() { [ -n "$1" ] && append bss_conf "nai_realm=$1" "$N" } @@ -351,7 +326,7 @@ index 45a49b8faa..e941fa4f77 100644 append_osu_provider_service_desc() { append bss_conf "osu_service_desc=$1" "$N" } -@@ -447,6 +486,7 @@ append_osu_provider() { +@@ -450,6 +486,7 @@ append_osu_provider() { append bss_conf "osu_method_list=$osu_method_list" "$N" config_list_foreach "$1" osu_service_desc append_osu_provider_service_desc @@ -359,7 +334,7 @@ index 45a49b8faa..e941fa4f77 100644 config_list_foreach "$1" osu_icon append_osu_icon append bss_conf "$N" -@@ -456,6 +496,14 @@ append_hs20_conn_capab() { +@@ -459,6 +496,14 @@ append_hs20_conn_capab() { [ -n "$1" ] && append bss_conf "hs20_conn_capab=$1" "$N" } @@ -374,7 +349,7 @@ index 45a49b8faa..e941fa4f77 100644 append_airtime_sta_weight() { [ -n "$1" ] && append bss_conf "airtime_sta_weight=$1" "$N" } -@@ -479,10 +527,12 @@ hostapd_set_bss_options() { +@@ -482,10 +527,12 @@ hostapd_set_bss_options() { macfilter ssid utf8_ssid wmm uapsd hidden short_preamble rsn_preauth \ iapp_interface eapol_version dynamic_vlan ieee80211w nasid \ acct_server acct_secret acct_port acct_interval \ @@ -389,7 +364,7 @@ index 45a49b8faa..e941fa4f77 100644 set_default isolate 0 set_default maxassoc 0 -@@ -503,6 +553,7 @@ hostapd_set_bss_options() { +@@ -506,6 +553,7 @@ hostapd_set_bss_options() { set_default multi_ap 0 set_default airtime_bss_weight 0 set_default airtime_bss_limit 0 @@ -397,7 +372,7 @@ index 45a49b8faa..e941fa4f77 100644 append bss_conf "ctrl_interface=/var/run/hostapd" if [ "$isolate" -gt 0 ]; then -@@ -529,6 +580,7 @@ hostapd_set_bss_options() { +@@ -532,6 +580,7 @@ hostapd_set_bss_options() { append bss_conf "uapsd_advertisement_enabled=$uapsd" "$N" append bss_conf "utf8_ssid=$utf8_ssid" "$N" append bss_conf "multi_ap=$multi_ap" "$N" @@ -405,7 +380,7 @@ index 45a49b8faa..e941fa4f77 100644 [ "$tdls_prohibit" -gt 0 ] && append bss_conf "tdls_prohibit=$tdls_prohibit" "$N" -@@ -547,6 +599,7 @@ hostapd_set_bss_options() { +@@ -550,6 +599,7 @@ hostapd_set_bss_options() { append bss_conf "acct_server_shared_secret=$acct_secret" "$N" [ -n "$acct_interval" ] && \ append bss_conf "radius_acct_interim_interval=$acct_interval" "$N" @@ -413,7 +388,7 @@ index 45a49b8faa..e941fa4f77 100644 } case "$auth_type" in -@@ -560,6 +613,7 @@ hostapd_set_bss_options() { +@@ -563,6 +613,7 @@ hostapd_set_bss_options() { ;; esac [ -n "$sae_require_mfp" ] && append bss_conf "sae_require_mfp=$sae_require_mfp" "$N" @@ -421,7 +396,7 @@ index 45a49b8faa..e941fa4f77 100644 local vlan_possible="" -@@ -601,7 +655,7 @@ hostapd_set_bss_options() { +@@ -604,7 +655,7 @@ hostapd_set_bss_options() { auth_server auth_secret auth_port \ dae_client dae_secret dae_port \ ownip radius_client_addr \ @@ -430,7 +405,7 @@ index 45a49b8faa..e941fa4f77 100644 # radius can provide VLAN ID for clients vlan_possible=1 -@@ -613,18 +667,22 @@ hostapd_set_bss_options() { +@@ -616,18 +667,22 @@ hostapd_set_bss_options() { set_default auth_port 1812 set_default dae_port 3799 @@ -457,7 +432,7 @@ index 45a49b8faa..e941fa4f77 100644 [ -n "$ownip" ] && append bss_conf "own_ip_addr=$ownip" "$N" [ -n "$radius_client_addr" ] && append bss_conf "radius_client_addr=$radius_client_addr" "$N" -@@ -697,19 +755,24 @@ hostapd_set_bss_options() { +@@ -700,6 +755,7 @@ hostapd_set_bss_options() { append bss_conf "ssid=$ssid" "$N" [ -n "$network_bridge" ] && append bss_conf "bridge=$network_bridge" "$N" @@ -465,26 +440,7 @@ index 45a49b8faa..e941fa4f77 100644 [ -n "$iapp_interface" ] && { local ifname network_get_device ifname "$iapp_interface" || ifname="$iapp_interface" - append bss_conf "iapp_interface=$ifname" "$N" - } - -- json_get_vars time_advertisement time_zone wnm_sleep_mode bss_transition -+ json_get_vars time_advertisement time_zone wnm_sleep_mode wnm_sleep_mode_no_keys bss_transition - set_default bss_transition 0 - set_default wnm_sleep_mode 0 -+ set_default wnm_sleep_mode_no_keys 0 - - [ -n "$time_advertisement" ] && append bss_conf "time_advertisement=$time_advertisement" "$N" - [ -n "$time_zone" ] && append bss_conf "time_zone=$time_zone" "$N" -- [ "$wnm_sleep_mode" -eq "1" ] && append bss_conf "wnm_sleep_mode=1" "$N" -+ if [ "$wnm_sleep_mode" -eq "1" ]; then -+ append bss_conf "wnm_sleep_mode=1" "$N" -+ [ "$wnm_sleep_mode_no_keys" -eq "1" ] && append bss_conf "wnm_sleep_mode_no_keys=1" "$N" -+ fi - [ "$bss_transition" -eq "1" ] && append bss_conf "bss_transition=1" "$N" - - json_get_vars ieee80211k rrm_neighbor_report rrm_beacon_report -@@ -733,7 +796,7 @@ hostapd_set_bss_options() { +@@ -740,7 +796,7 @@ hostapd_set_bss_options() { append bss_conf "ftm_responder=1" "$N" [ "$stationary_ap" -eq "1" ] && append bss_conf "stationary_ap=1" "$N" [ -n "$lci" ] && append bss_conf "lci=$lci" "$N" @@ -493,7 +449,7 @@ index 45a49b8faa..e941fa4f77 100644 } fi -@@ -757,6 +820,7 @@ hostapd_set_bss_options() { +@@ -764,6 +820,7 @@ hostapd_set_bss_options() { ;; esac @@ -501,7 +457,7 @@ index 45a49b8faa..e941fa4f77 100644 append bss_conf "mobility_domain=$mobility_domain" "$N" append bss_conf "ft_psk_generate_local=$ft_psk_generate_local" "$N" append bss_conf "ft_over_ds=$ft_over_ds" "$N" -@@ -771,6 +835,13 @@ hostapd_set_bss_options() { +@@ -778,6 +835,13 @@ hostapd_set_bss_options() { set_default r0_key_lifetime 10000 set_default pmk_r1_push 0 @@ -515,7 +471,7 @@ index 45a49b8faa..e941fa4f77 100644 [ -n "$r1_key_holder" ] && append bss_conf "r1_key_holder=$r1_key_holder" "$N" append bss_conf "r0_key_lifetime=$r0_key_lifetime" "$N" append bss_conf "pmk_r1_push=$pmk_r1_push" "$N" -@@ -856,13 +927,17 @@ hostapd_set_bss_options() { +@@ -863,13 +927,17 @@ hostapd_set_bss_options() { } [ -n "$vlan_possible" -a -n "$dynamic_vlan" ] && { @@ -535,7 +491,7 @@ index 45a49b8faa..e941fa4f77 100644 [ -n "$vlan_tagged_interface" ] && \ append bss_conf "vlan_tagged_interface=$vlan_tagged_interface" "$N" [ -n "$vlan_file" ] && { -@@ -875,6 +950,7 @@ hostapd_set_bss_options() { +@@ -882,6 +950,7 @@ hostapd_set_bss_options() { json_get_vars iw_hessid iw_venue_group iw_venue_type iw_network_auth_type json_get_vars iw_roaming_consortium iw_domain_name iw_anqp_3gpp_cell_net iw_nai_realm json_get_vars iw_anqp_elem iw_qos_map_set iw_ipaddr_type_availability iw_gas_address3 @@ -543,7 +499,7 @@ index 45a49b8faa..e941fa4f77 100644 set_default iw_enabled 0 if [ "$iw_enabled" = "1" ]; then -@@ -903,6 +979,8 @@ hostapd_set_bss_options() { +@@ -910,6 +979,8 @@ hostapd_set_bss_options() { json_for_each_item append_iw_roaming_consortium iw_roaming_consortium json_for_each_item append_iw_anqp_elem iw_anqp_elem json_for_each_item append_iw_nai_realm iw_nai_realm @@ -552,7 +508,7 @@ index 45a49b8faa..e941fa4f77 100644 iw_domain_name_conf= json_for_each_item append_iw_domain_name iw_domain_name -@@ -917,9 +995,11 @@ hostapd_set_bss_options() { +@@ -924,9 +995,11 @@ hostapd_set_bss_options() { local hs20 disable_dgaf osen anqp_domain_id hs20_deauth_req_timeout \ @@ -566,7 +522,7 @@ index 45a49b8faa..e941fa4f77 100644 set_default hs20 0 set_default disable_dgaf $hs20 -@@ -938,16 +1018,31 @@ hostapd_set_bss_options() { +@@ -945,16 +1018,31 @@ hostapd_set_bss_options() { [ -n "$hs20_operating_class" ] && append bss_conf "hs20_operating_class=$hs20_operating_class" "$N" [ -n "$hs20_t_c_filename" ] && append bss_conf "hs20_t_c_filename=$hs20_t_c_filename" "$N" [ -n "$hs20_t_c_timestamp" ] && append bss_conf "hs20_t_c_timestamp=$hs20_t_c_timestamp" "$N" @@ -599,7 +555,7 @@ index 45a49b8faa..e941fa4f77 100644 set_default per_sta_vif 0 if [ "$per_sta_vif" -gt 0 ]; then -@@ -1072,16 +1167,16 @@ wpa_supplicant_set_fixed_freq() { +@@ -1079,16 +1167,16 @@ wpa_supplicant_set_fixed_freq() { append network_data "frequency=$freq" "$N$T" case "$htmode" in NOHT) append network_data "disable_ht=1" "$N$T";; @@ -620,7 +576,7 @@ index 45a49b8faa..e941fa4f77 100644 *) append network_data "disable_vht=1" "$N$T";; esac } -@@ -1099,7 +1194,8 @@ wpa_supplicant_add_network() { +@@ -1106,7 +1194,8 @@ wpa_supplicant_add_network() { ssid bssid key \ basic_rate mcast_rate \ ieee80211w ieee80211r \ @@ -630,7 +586,7 @@ index 45a49b8faa..e941fa4f77 100644 case "$auth_type" in sae|owe|eap192|eap-eap192) -@@ -1112,6 +1208,7 @@ wpa_supplicant_add_network() { +@@ -1119,6 +1208,7 @@ wpa_supplicant_add_network() { set_default ieee80211r 0 set_default multi_ap 0 @@ -638,7 +594,7 @@ index 45a49b8faa..e941fa4f77 100644 local key_mgmt='NONE' local network_data= -@@ -1143,7 +1240,10 @@ wpa_supplicant_add_network() { +@@ -1150,7 +1240,10 @@ wpa_supplicant_add_network() { scan_ssid="" } @@ -852,55 +808,51 @@ index 37c17c50af..0000000000 - - if (ssid->mesh_basic_rates == NULL) { - /* -diff --git a/package/network/services/hostapd/patches/001-wolfssl-init-RNG-with-ECC-key.patch b/package/network/services/hostapd/patches/001-wolfssl-init-RNG-with-ECC-key.patch -new file mode 100644 -index 0000000000..84fc1c9351 ---- /dev/null +diff --git a/package/network/services/hostapd/patches/802-wolfssl-init-RNG-with-ECC-key.patch b/package/network/services/hostapd/patches/001-wolfssl-init-RNG-with-ECC-key.patch +similarity index 76% +rename from package/network/services/hostapd/patches/802-wolfssl-init-RNG-with-ECC-key.patch +rename to package/network/services/hostapd/patches/001-wolfssl-init-RNG-with-ECC-key.patch +index 89d111e991..84fc1c9351 100644 +--- a/package/network/services/hostapd/patches/802-wolfssl-init-RNG-with-ECC-key.patch +++ b/package/network/services/hostapd/patches/001-wolfssl-init-RNG-with-ECC-key.patch -@@ -0,0 +1,43 @@ -+From 21ce83b4ae2b9563175fdb4fc4312096cc399cf8 Mon Sep 17 00:00:00 2001 -+From: David Bauer -+Date: Wed, 5 May 2021 00:44:34 +0200 -+Subject: [PATCH] wolfssl: add RNG to EC key -+ -+Since upstream commit 6467de5a8840 ("Randomize z ordinates in -+scalar mult when timing resistant") WolfSSL requires a RNG for -+the EC key when built hardened which is the default. -+ -+Set the RNG for the EC key to fix connections for OWE clients. -+ -+Signed-off-by: David Bauer -+--- -+ src/crypto/crypto_wolfssl.c | 4 ++++ -+ 1 file changed, 4 insertions(+) -+ -+--- a/src/crypto/crypto_wolfssl.c -++++ b/src/crypto/crypto_wolfssl.c +@@ -14,11 +14,9 @@ Signed-off-by: David Bauer + src/crypto/crypto_wolfssl.c | 4 ++++ + 1 file changed, 4 insertions(+) + +-diff --git a/src/crypto/crypto_wolfssl.c b/src/crypto/crypto_wolfssl.c +-index 2e4bf8962..ed2528159 100644 + --- a/src/crypto/crypto_wolfssl.c + +++ b/src/crypto/crypto_wolfssl.c +-@@ -1303,6 +1303,7 @@ int ecc_projective_add_point(ecc_point *P, ecc_point *Q, ecc_point *R, +@@ -1303,6 +1303,7 @@ int ecc_projective_add_point(ecc_point * -+ -+ struct crypto_ec { -+ ecc_key key; -++ WC_RNG rng; -+ mp_int a; -+ mp_int prime; -+ mp_int order; + + struct crypto_ec { + ecc_key key; +@@ -26,7 +24,7 @@ index 2e4bf8962..ed2528159 100644 + mp_int a; + mp_int prime; + mp_int order; +-@@ -1357,6 +1358,8 @@ struct crypto_ec * crypto_ec_init(int group) +@@ -1357,6 +1358,8 @@ struct crypto_ec * crypto_ec_init(int gr -+ return NULL; -+ -+ if (wc_ecc_init(&e->key) != 0 || -++ wc_InitRng(&e->rng) != 0 || -++ wc_ecc_set_rng(&e->key, &e->rng) != 0 || -+ wc_ecc_set_curve(&e->key, 0, curve_id) != 0 || -+ mp_init(&e->a) != MP_OKAY || -+ mp_init(&e->prime) != MP_OKAY || + return NULL; + + if (wc_ecc_init(&e->key) != 0 || +@@ -35,7 +33,7 @@ index 2e4bf8962..ed2528159 100644 + wc_ecc_set_curve(&e->key, 0, curve_id) != 0 || + mp_init(&e->a) != MP_OKAY || + mp_init(&e->prime) != MP_OKAY || +-@@ -1388,6 +1391,7 @@ void crypto_ec_deinit(struct crypto_ec* e) +@@ -1388,6 +1391,7 @@ void crypto_ec_deinit(struct crypto_ec* -+ mp_clear(&e->order); -+ mp_clear(&e->prime); -+ mp_clear(&e->a); -++ wc_FreeRng(&e->rng); -+ wc_ecc_free(&e->key); -+ os_free(e); -+ } + mp_clear(&e->order); + mp_clear(&e->prime); + mp_clear(&e->a); +@@ -43,6 +41,3 @@ index 2e4bf8962..ed2528159 100644 + wc_ecc_free(&e->key); + os_free(e); + } +--- +-2.31.1 +- diff --git a/package/network/services/hostapd/patches/002-mesh-fix-channel-init-order-disable-pri-sec-channel-.patch b/package/network/services/hostapd/patches/002-mesh-fix-channel-init-order-disable-pri-sec-channel-.patch deleted file mode 100644 index c7101b1dbc..0000000000 diff --git a/backports/0100-procd-add-uxc-support.patch b/backports/0020-procd-add-uxc-support.patch similarity index 93% rename from backports/0100-procd-add-uxc-support.patch rename to backports/0020-procd-add-uxc-support.patch index 4dd8c1748..325f96664 100644 --- a/backports/0100-procd-add-uxc-support.patch +++ b/backports/0020-procd-add-uxc-support.patch @@ -1,7 +1,7 @@ -From 8897bab871fb43701fad786c94af5d1b1ef123ae Mon Sep 17 00:00:00 2001 +From aab305d662fa77ef4495574c096cb1e065c1908a Mon Sep 17 00:00:00 2001 From: John Crispin Date: Sun, 25 Jul 2021 13:32:37 +0200 -Subject: [PATCH 01/46] procd: add uxc support +Subject: [PATCH 20/27] procd: add uxc support Signed-off-by: John Crispin --- @@ -11,16 +11,16 @@ Signed-off-by: John Crispin 3 files changed, 89 insertions(+), 6 deletions(-) diff --git a/package/system/procd/Makefile b/package/system/procd/Makefile -index fff9faa1bf..98f1ed1775 100644 +index 30d5adf427..98f1ed1775 100644 --- a/package/system/procd/Makefile +++ b/package/system/procd/Makefile @@ -12,9 +12,9 @@ PKG_RELEASE:=$(AUTORELEASE) PKG_SOURCE_PROTO:=git PKG_SOURCE_URL=$(PROJECT_GIT)/project/procd.git --PKG_SOURCE_DATE:=2021-02-08 --PKG_SOURCE_VERSION:=08938fe1cbc06eeaafa39448057368391d165272 --PKG_MIRROR_HASH:=efc3deac56057e929789d44742858b2a16d976f6bfa0a2036e413d10afcaeee4 +-PKG_SOURCE_DATE:=2021-02-23 +-PKG_SOURCE_VERSION:=37eed131e9967a35f47bacb3437a9d3c8a57b3f4 +-PKG_MIRROR_HASH:=2b0131ff9055ccf987cbeb5f36c2c2585dc780999df6be312fbbbcd61ce676d4 +PKG_SOURCE_DATE:=2021-08-15 +PKG_SOURCE_VERSION:=104b49d6ab25a8cf067e6d8d1f2da7defb9876d4 +PKG_MIRROR_HASH:=d13b566a14e84f6babe8b7d3dfb88e34c3dff0e97d7770d6fe71174685bca628 diff --git a/backports/0101-build-create-APK-files-parrallel-to-IPK.patch b/backports/0021-build-create-APK-files-parrallel-to-IPK.patch similarity index 96% rename from backports/0101-build-create-APK-files-parrallel-to-IPK.patch rename to backports/0021-build-create-APK-files-parrallel-to-IPK.patch index 816b6b43a..55688dc7f 100644 --- a/backports/0101-build-create-APK-files-parrallel-to-IPK.patch +++ b/backports/0021-build-create-APK-files-parrallel-to-IPK.patch @@ -1,7 +1,7 @@ -From 0a31ac2bfc8aa43c2a5e43eac81c4647dbf2d1b7 Mon Sep 17 00:00:00 2001 +From 23c15e2536d0fa5ed81c5bdfe7623d3370dca997 Mon Sep 17 00:00:00 2001 From: Paul Spooren Date: Fri, 2 Oct 2020 23:30:30 -1000 -Subject: [PATCH 01/45] build: create APK files parrallel to IPK +Subject: [PATCH 21/27] build: create APK files parrallel to IPK Create APK files based on the folder and control files of IPK packages. @@ -16,11 +16,11 @@ Signed-off-by: Paul Spooren create mode 100755 scripts/apk-make-index.sh diff --git a/include/package-ipkg.mk b/include/package-ipkg.mk -index c2017cd220..b0177070f8 100644 +index e972b7de0b..5c31b1774f 100644 --- a/include/package-ipkg.mk +++ b/include/package-ipkg.mk @@ -102,6 +102,7 @@ ifeq ($(DUMP),) - ABIV_$(1):=$(if $(filter-out kmod-%,$(1)),$(ABI_VERSION)) + ABIV_$(1):=$(call FormatABISuffix,$(1),$(ABI_VERSION)) PDIR_$(1):=$(call FeedPackageDir,$(1)) IPKG_$(1):=$$(PDIR_$(1))/$(1)$$(ABIV_$(1))_$(VERSION)_$(PKGARCH).ipk + APK_$(1):=$$(PDIR_$(1))/$(1)$$(ABIV_$(1))_$(VERSION)_$(PKGARCH).apk diff --git a/backports/0102-fstools-update-to-git-HEAD.patch b/backports/0022-fstools-update-to-git-HEAD.patch similarity index 96% rename from backports/0102-fstools-update-to-git-HEAD.patch rename to backports/0022-fstools-update-to-git-HEAD.patch index 3a48a72c9..54be4da02 100644 --- a/backports/0102-fstools-update-to-git-HEAD.patch +++ b/backports/0022-fstools-update-to-git-HEAD.patch @@ -1,7 +1,7 @@ -From 2239c3c87a723bee8efa64ecf22c61a15433517e Mon Sep 17 00:00:00 2001 +From 8e8b3e443a7f1d0644f43888c8683698f26d4d13 Mon Sep 17 00:00:00 2001 From: Daniel Golle Date: Sun, 25 Jul 2021 01:20:31 +0100 -Subject: [PATCH 102/146] fstools: update to git HEAD +Subject: [PATCH 22/27] fstools: update to git HEAD bad1835 fstools: add partname volume driver 19d7d93 libfstools: partname: several fixes diff --git a/backports/0103-tools-libressl-update-to-3.3.3.patch b/backports/0023-tools-libressl-update-to-3.3.3.patch similarity index 90% rename from backports/0103-tools-libressl-update-to-3.3.3.patch rename to backports/0023-tools-libressl-update-to-3.3.3.patch index 1ebf0e4b4..f6235c360 100644 --- a/backports/0103-tools-libressl-update-to-3.3.3.patch +++ b/backports/0023-tools-libressl-update-to-3.3.3.patch @@ -1,7 +1,7 @@ -From c40bb49f31443d9c03043c4361e4af56e5c3eba4 Mon Sep 17 00:00:00 2001 +From 873052b99d6597209957ec32898fa56324cf34a4 Mon Sep 17 00:00:00 2001 From: Rosen Penev Date: Sat, 19 Jun 2021 14:45:11 -0700 -Subject: [PATCH 103/146] tools/libressl: update to 3.3.3 +Subject: [PATCH 23/27] tools/libressl: update to 3.3.3 Fix wrong FPIC variable usage. Fixes compilation under sparc64 host. diff --git a/backports/0104-uvol-backport-package.patch b/backports/0024-uvol-backport-package.patch similarity index 99% rename from backports/0104-uvol-backport-package.patch rename to backports/0024-uvol-backport-package.patch index 6f8d05489..98a53bd81 100644 --- a/backports/0104-uvol-backport-package.patch +++ b/backports/0024-uvol-backport-package.patch @@ -1,7 +1,7 @@ -From b915cb9a73c7696f25994c3f63fed4e6ea3aa55b Mon Sep 17 00:00:00 2001 +From 08809a60a8f2c065a38c24fcdbd69b939e5c29d9 Mon Sep 17 00:00:00 2001 From: John Crispin Date: Fri, 13 Aug 2021 08:46:57 +0200 -Subject: [PATCH 05/46] uvol: backport package +Subject: [PATCH 24/27] uvol: backport package Signed-off-by: John Crispin --- @@ -25,7 +25,7 @@ Signed-off-by: John Crispin diff --git a/package/system/uvol/Makefile b/package/system/uvol/Makefile new file mode 100644 -index 0000000000..e988d51682 +index 0000000000..bd70410c5e --- /dev/null +++ b/package/system/uvol/Makefile @@ -0,0 +1,77 @@ diff --git a/backports/0105-apk-backport-package.patch b/backports/0025-apk-backport-package.patch similarity index 99% rename from backports/0105-apk-backport-package.patch rename to backports/0025-apk-backport-package.patch index 9f7099014..5178ba423 100644 --- a/backports/0105-apk-backport-package.patch +++ b/backports/0025-apk-backport-package.patch @@ -1,7 +1,7 @@ -From 6741963067c4be8999896a5e653dc0d72487e392 Mon Sep 17 00:00:00 2001 +From bf98d3c1de524ca50cbc09f825a4b0648e353624 Mon Sep 17 00:00:00 2001 From: John Crispin Date: Fri, 13 Aug 2021 08:47:11 +0200 -Subject: [PATCH 06/46] apk: backport package +Subject: [PATCH 25/27] apk: backport package Signed-off-by: John Crispin --- diff --git a/backports/0106-lua-lzlib-backport-package.patch b/backports/0026-lua-lzlib-backport-package.patch similarity index 96% rename from backports/0106-lua-lzlib-backport-package.patch rename to backports/0026-lua-lzlib-backport-package.patch index 1a9f46257..7da20ad35 100644 --- a/backports/0106-lua-lzlib-backport-package.patch +++ b/backports/0026-lua-lzlib-backport-package.patch @@ -1,7 +1,7 @@ -From 900d18f3ae2cd5bb3d8d6e2584d2280cb5302e01 Mon Sep 17 00:00:00 2001 +From ec862d472fca676cc04ce71b640e880ecefdd477 Mon Sep 17 00:00:00 2001 From: John Crispin Date: Fri, 13 Aug 2021 08:48:02 +0200 -Subject: [PATCH 106/146] lua-lzlib: backport package +Subject: [PATCH 26/27] lua-lzlib: backport package Signed-off-by: John Crispin --- diff --git a/backports/0107-lua-make-it-easier-to-detect-host-built-Lua.patch b/backports/0027-lua-make-it-easier-to-detect-host-built-Lua.patch similarity index 86% rename from backports/0107-lua-make-it-easier-to-detect-host-built-Lua.patch rename to backports/0027-lua-make-it-easier-to-detect-host-built-Lua.patch index 7c902b45c..6cd7e7cfa 100644 --- a/backports/0107-lua-make-it-easier-to-detect-host-built-Lua.patch +++ b/backports/0027-lua-make-it-easier-to-detect-host-built-Lua.patch @@ -1,7 +1,7 @@ -From 5c8a575ec759105e63a3aad033289d124516ec69 Mon Sep 17 00:00:00 2001 +From 5fc717aa60b36934892d6d77c0637fc53aa7f761 Mon Sep 17 00:00:00 2001 From: Daniel Golle Date: Sat, 10 Jul 2021 20:21:26 +0100 -Subject: [PATCH 107/146] lua: make it easier to detect host-built Lua +Subject: [PATCH 27/27] lua: make it easier to detect host-built Lua Install pkg-config file also for host-build, clean up Lua symlinks. @@ -12,7 +12,7 @@ Signed-off-by: Daniel Golle 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/package/utils/lua/Makefile b/package/utils/lua/Makefile -index a54ef7d25a..be18880cb1 100644 +index d262d1e1fc..e15142d8d2 100644 --- a/package/utils/lua/Makefile +++ b/package/utils/lua/Makefile @@ -134,8 +134,12 @@ define Host/Install diff --git a/backports/0035-uhttp-update-to-latest-HEAD.patch b/backports/0035-uhttp-update-to-latest-HEAD.patch deleted file mode 100644 index a80df7c5c..000000000 --- a/backports/0035-uhttp-update-to-latest-HEAD.patch +++ /dev/null @@ -1,157 +0,0 @@ -From patchwork Fri Aug 20 13:11:12 2021 -Content-Type: text/plain; charset="utf-8" -MIME-Version: 1.0 -Content-Transfer-Encoding: 7bit -X-Patchwork-Submitter: Stijn Tintel -X-Patchwork-Id: 1519040 -X-Patchwork-Delegate: stijn@linux-ipv6.be -Return-Path: - -X-Original-To: incoming@patchwork.ozlabs.org -Delivered-To: patchwork-incoming@bilbo.ozlabs.org -Authentication-Results: ozlabs.org; - spf=none (no SPF record) smtp.mailfrom=lists.openwrt.org - (client-ip=2607:7c80:54:e::133; helo=bombadil.infradead.org; - envelope-from=openwrt-devel-bounces+incoming=patchwork.ozlabs.org@lists.openwrt.org; - receiver=) -Authentication-Results: ozlabs.org; - dkim=pass (2048-bit key; - secure) header.d=lists.infradead.org header.i=@lists.infradead.org - header.a=rsa-sha256 header.s=bombadil.20210309 header.b=r2Ly8Vhy; - dkim=fail reason="signature verification failed" (1024-bit key; - unprotected) header.d=linux-ipv6.be header.i=@linux-ipv6.be - header.a=rsa-sha256 header.s=502B7754-045F-11E5-BBC5-64595FD46BE8 - header.b=BipII9T0; - dkim-atps=neutral -Received: from bombadil.infradead.org (bombadil.infradead.org - [IPv6:2607:7c80:54:e::133]) - (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) - key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest - SHA256) - (No client certificate requested) - by ozlabs.org (Postfix) with ESMTPS id 4Grhsz3FQvz9s1l - for ; Fri, 20 Aug 2021 23:13:59 +1000 (AEST) -DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; - d=lists.infradead.org; s=bombadil.20210309; h=Sender: - Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: - List-Archive:List-Unsubscribe:List-Id:MIME-Version:Message-Id:Date:Subject:Cc - :To:From:Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From: - Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To:References: - List-Owner; bh=Dxw7atu76L/aBQntt7pW1jTYPCULL0mkcY2U1BYT2sI=; b=r2Ly8VhysFZseN - kLaheAFj130coCdyeHSxT/951GnDDBkmyursFZAP2hBLaKv9Z+9HpHIGM3sOiNhM/zDKfabNJ/1D2 - CV4iyPpVkhRxG9t6HPpPx94E6J5Oknl7l6eyL04DWUB28EzXcoBSMiP0zYsoOWjI8sQO8wITNp6hf - neAM1VlZlNb22n5/Wu5oD1RoEiMUS5GeyhU7kEFEWpC45rcpyuQdvHpPLMn5GkcqCOO6i90E7BKAK - ipYG2tptIjqjrmR+nC6CPRavA+hSG/o6HzDSYNJvWmgVjCc6RpN/xliN03Rum4+mbDtMEB4Wpidmj - FepfgPqKxWRJ0UiXBJew==; -Received: from localhost ([::1] helo=bombadil.infradead.org) - by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) - id 1mH4J2-00BF23-C2; Fri, 20 Aug 2021 13:11:32 +0000 -Received: from mail.tintel.eu ([51.83.127.189]) - by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) - id 1mH4Iw-00BF1P-CR - for openwrt-devel@lists.openwrt.org; Fri, 20 Aug 2021 13:11:30 +0000 -Received: from localhost (localhost [IPv6:::1]) - by mail.tintel.eu (Postfix) with ESMTP id 1BE4C4486AC4; - Fri, 20 Aug 2021 15:11:14 +0200 (CEST) -Received: from mail.tintel.eu ([IPv6:::1]) - by localhost (mail.tintel.eu [IPv6:::1]) (amavisd-new, port 10032) - with ESMTP id npDXmiQngdDU; Fri, 20 Aug 2021 15:11:13 +0200 (CEST) -Received: from localhost (localhost [IPv6:::1]) - by mail.tintel.eu (Postfix) with ESMTP id 5B1EC4486ACC; - Fri, 20 Aug 2021 15:11:13 +0200 (CEST) -DKIM-Filter: OpenDKIM Filter v2.10.3 mail.tintel.eu 5B1EC4486ACC -DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linux-ipv6.be; - s=502B7754-045F-11E5-BBC5-64595FD46BE8; t=1629465073; - bh=3YKw9bephsRsf4MDuHSX4MioHjRWefi/5PEc54pFn4g=; - h=From:To:Date:Message-Id:MIME-Version; - b=BipII9T0eY8ENYqcdZ7rxKFn6rwkKKOhJ2IoeLZ1fx4lgpPuGWsZrexzqU6mYTDRa - Aihei2/ovPeWgUDbzfjNC9hIqv0fXRaEW0sCAPZGOP6gNHWNCkJxuPqYI+4pjijRRt - 6YYC2qCi8DqzQJv7St1FqeVFoIaF8SfbniBW+1N4= -X-Virus-Scanned: amavisd-new at mail.tintel.eu -Received: from mail.tintel.eu ([IPv6:::1]) - by localhost (mail.tintel.eu [IPv6:::1]) (amavisd-new, port 10026) - with ESMTP id J5m0pY66LdR7; Fri, 20 Aug 2021 15:11:13 +0200 (CEST) -Received: from taz.sof.bg.adlevio.net (unknown [IPv6:2001:67c:21bc:20::10]) - by mail.tintel.eu (Postfix) with SMTP id 17DF94486AC4; - Fri, 20 Aug 2021 15:11:13 +0200 (CEST) -Received: (nullmailer pid 141125 invoked by uid 1000); - Fri, 20 Aug 2021 13:11:12 -0000 -From: Stijn Tintel -To: openwrt-devel@lists.openwrt.org -Cc: nbd@nbd.name -Subject: [PATCH] uhttpd: add config option for json_script -Date: Fri, 20 Aug 2021 16:11:12 +0300 -Message-Id: <20210820131112.141077-1-stijn@linux-ipv6.be> -X-Mailer: git-send-email 2.31.1 -MIME-Version: 1.0 -X-Rspamd-Queue-Id: 17DF94486AC4 -X-Spamd-Result: default: False [0.00 / 15.00]; - IP_WHITELIST(0.00)[2001:67c:21bc:20::10]; - ASN(0.00)[asn:200533, ipnet:2001:67c:21bc::/48, country:BG] -X-Rspamd-Server: skulls -X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 -X-CRM114-CacheID: sfid-20210820_061126_592239_17869382 -X-CRM114-Status: UNSURE ( 9.50 ) -X-CRM114-Notice: Please train this message. -X-Spam-Score: 0.2 (/) -X-Spam-Report: Spam detection software, - running on the system "bombadil.infradead.org", - has NOT identified this incoming email as spam. The original - message has been attached to this so you can view it or label - similar future email. If you have any questions, see - the administrator of that system for details. - Content preview: Add a config option for json_script instead of - unconditionally - including all json files in /etc/uhttpd in every uhttpd instance. This makes - it possible to configure a single instance with an unconditi [...] - Content analysis details: (0.2 points, 5.0 required) - pts rule name description - ---- ---------------------- - -------------------------------------------------- - -0.0 SPF_PASS SPF: sender matches SPF record - -0.0 SPF_HELO_PASS SPF: HELO matches SPF record - 0.1 DKIM_SIGNED Message has a DKIM or DK signature, - not necessarily - valid - 0.1 DKIM_INVALID DKIM or DK signature exists, but is not valid -X-BeenThere: openwrt-devel@lists.openwrt.org -X-Mailman-Version: 2.1.34 -Precedence: list -List-Id: OpenWrt Development List -List-Unsubscribe: , - -List-Archive: -List-Post: -List-Help: -List-Subscribe: , - -Sender: "openwrt-devel" -Errors-To: - openwrt-devel-bounces+incoming=patchwork.ozlabs.org@lists.openwrt.org - -Add a config option for json_script instead of unconditionally including -all json files in /etc/uhttpd in every uhttpd instance. This makes it -possible to configure a single instance with an unconditional redirect, -which is currently not possible as it would render all other uhttpd -instances unusable. - -Signed-off-by: Stijn Tintel ---- - package/network/services/uhttpd/Makefile | 2 +- - package/network/services/uhttpd/files/uhttpd.init | 3 ++- - 2 files changed, 3 insertions(+), 2 deletions(-) - -diff --git a/package/network/services/uhttpd/files/uhttpd.init b/package/network/services/uhttpd/files/uhttpd.init -index e7709941c2..30fd7b4259 100755 ---- a/package/network/services/uhttpd/files/uhttpd.init -+++ b/package/network/services/uhttpd/files/uhttpd.init -@@ -196,7 +196,8 @@ start_instance() - append_bool "$cfg" redirect_https "-q" 0 - } - -- for file in /etc/uhttpd/*.json; do -+ config_get json_script "$cfg" json_script -+ for file in $json_script; do - [ -s "$file" ] && procd_append_param command -H "$file" - done - diff --git a/backports/0036-iwinfo-update-to-latest-git-HEAD.patch b/backports/0036-iwinfo-update-to-latest-git-HEAD.patch deleted file mode 100644 index 0ef295efe..000000000 --- a/backports/0036-iwinfo-update-to-latest-git-HEAD.patch +++ /dev/null @@ -1,39 +0,0 @@ -From c90fec205137d8d8c1197722a39d5c700ae3f6b1 Mon Sep 17 00:00:00 2001 -From: John Crispin -Date: Mon, 21 Jun 2021 12:53:28 +0200 -Subject: [PATCH 02/36] iwinfo: update to latest git HEAD - -Signed-off-by: John Crispin ---- - package/network/utils/iwinfo/Makefile | 8 ++++---- - 1 file changed, 4 insertions(+), 4 deletions(-) - -diff --git a/package/network/utils/iwinfo/Makefile b/package/network/utils/iwinfo/Makefile -index 3454d615a9..b7c8370bba 100644 ---- a/package/network/utils/iwinfo/Makefile -+++ b/package/network/utils/iwinfo/Makefile -@@ -11,9 +11,9 @@ PKG_RELEASE:=1 - - PKG_SOURCE_PROTO:=git - PKG_SOURCE_URL=$(PROJECT_GIT)/project/iwinfo.git --PKG_SOURCE_DATE:=2021-01-31 --PKG_SOURCE_VERSION:=4a32b33e9606f1bc1125f4bc24b0581349e55f2e --PKG_MIRROR_HASH:=414e5d150efaadba21103e66f862be66a94dcf83c16a2850f7c05051a9b0739d -+PKG_SOURCE_DATE:=2021-06-09 -+PKG_SOURCE_VERSION:=c0414642fead263a4a6a686ad3cb7e965ec8a23a -+PKG_MIRROR_HASH:=c5686bbae86753c53db03a686b034bbb80d31107cc359ebd8522ea1c82db35ea - PKG_MAINTAINER:=Jo-Philipp Wich - PKG_LICENSE:=GPL-2.0 - -@@ -25,7 +25,7 @@ PKG_CONFIG_DEPENDS := \ - CONFIG_PACKAGE_kmod-brcm-wl-mimo \ - CONFIG_PACKAGE_kmod-cfg80211 - --IWINFO_ABI_VERSION:=20210106 -+IWINFO_ABI_VERSION:=20210430 - - include $(INCLUDE_DIR)/package.mk - --- -2.25.1 - diff --git a/backports/0040-mt76-update-to-latest-HEAD.patch b/backports/0040-mt76-update-to-latest-HEAD.patch deleted file mode 100644 index 1d3132b50..000000000 --- a/backports/0040-mt76-update-to-latest-HEAD.patch +++ /dev/null @@ -1,51 +0,0 @@ -From e01de214b2492e1b8001d6057211017b5f0f6f49 Mon Sep 17 00:00:00 2001 -From: John Crispin -Date: Thu, 27 May 2021 13:25:41 +0200 -Subject: [PATCH 04/44] mt76: update to latest HEAD - -Signed-off-by: John Crispin ---- - package/kernel/mt76/Makefile | 11 ++++++----- - 1 file changed, 6 insertions(+), 5 deletions(-) - -diff --git a/package/kernel/mt76/Makefile b/package/kernel/mt76/Makefile -index e9e95fa9b3..431c57a240 100644 ---- a/package/kernel/mt76/Makefile -+++ b/package/kernel/mt76/Makefile -@@ -8,11 +8,12 @@ PKG_LICENSE_FILES:= - - PKG_SOURCE_URL:=https://github.com/openwrt/mt76 - PKG_SOURCE_PROTO:=git --PKG_SOURCE_DATE:=2021-04-11 --PKG_SOURCE_VERSION:=bf45b30d891961dd7c4139dddb58b909ea2c2b5a --PKG_MIRROR_HASH:=431cecf80dafa986e805f809522721c2bb26289867d6770695d49baf8b471bea -+PKG_SOURCE_DATE:=2021-07-15 -+PKG_SOURCE_VERSION:=bbebea7d6dc64313132226adc3f7369d36e9359d -+PKG_MIRROR_HASH:=17cd74e72c1f6c8742b698bf6772afacc6fba71b233af8c4d59530600cf44d5b - - PKG_MAINTAINER:=Felix Fietkau -+PKG_USE_NINJA:=0 - PKG_BUILD_PARALLEL:=1 - - PKG_CONFIG_DEPENDS += \ -@@ -155,7 +156,7 @@ define KernelPackage/mt7615-common - $(KernelPackage/mt76-default) - TITLE:=MediaTek MT7615 wireless driver common code - HIDDEN:=1 -- DEPENDS+=@PCI_SUPPORT +kmod-mt76-core +kmod-mt76-connac -+ DEPENDS+=@PCI_SUPPORT +kmod-mt76-core +kmod-mt76-connac +kmod-hwmon-core - FILES:= $(PKG_BUILD_DIR)/mt7615/mt7615-common.ko - endef - -@@ -213,7 +214,7 @@ endef - define KernelPackage/mt7915e - $(KernelPackage/mt76-default) - TITLE:=MediaTek MT7915e wireless driver -- DEPENDS+=@PCI_SUPPORT +kmod-mt7615-common +@DRIVER_11AX_SUPPORT -+ DEPENDS+=@PCI_SUPPORT +kmod-mt7615-common +kmod-hwmon-core +kmod-thermal +@DRIVER_11AX_SUPPORT - FILES:= $(PKG_BUILD_DIR)/mt7915/mt7915e.ko - AUTOLOAD:=$(call AutoProbe,mt7915e) - endef --- -2.25.1 - diff --git a/backports/0041-ar71xx-hacks.patch b/backports/0041-ar71xx-hacks.patch deleted file mode 100644 index 083df031a..000000000 --- a/backports/0041-ar71xx-hacks.patch +++ /dev/null @@ -1,53 +0,0 @@ -From d01d8c9e5cf7de98222860011d1d5b362bfde005 Mon Sep 17 00:00:00 2001 -From: John Crispin -Date: Mon, 12 Jul 2021 13:09:25 +0200 -Subject: [PATCH 01/39] ar71xx: hacks - -Signed-off-by: John Crispin ---- - package/kernel/linux/modules/crypto.mk | 2 +- - package/kernel/mac80211/ath.mk | 1 + - target/linux/ar71xx/files/arch/mips/ath79/mach-rb91x.c | 2 ++ - 3 files changed, 4 insertions(+), 1 deletion(-) - -diff --git a/package/kernel/linux/modules/crypto.mk b/package/kernel/linux/modules/crypto.mk -index 19b0d4696b..1b1c1e1a51 100644 ---- a/package/kernel/linux/modules/crypto.mk -+++ b/package/kernel/linux/modules/crypto.mk -@@ -882,7 +882,7 @@ define KernelPackage/crypto-sha256 - CONFIG_CRYPTO_SHA256_SSSE3 - FILES:= \ - $(LINUX_DIR)/crypto/sha256_generic.ko \ -- $(LINUX_DIR)/lib/crypto/libsha256.ko -+ $(LINUX_DIR)/lib/crypto/libsha256.ko@ge4.15 - AUTOLOAD:=$(call AutoLoad,09,sha256_generic) - $(call AddDepends/crypto) - endef -diff --git a/package/kernel/mac80211/ath.mk b/package/kernel/mac80211/ath.mk -index ba03ae11a6..ad2860a98e 100644 ---- a/package/kernel/mac80211/ath.mk -+++ b/package/kernel/mac80211/ath.mk -@@ -43,6 +43,7 @@ config-$(call config_package,ath9k) += ATH9K - config-$(call config_package,ath9k-common) += ATH9K_COMMON - config-$(call config_package,owl-loader) += ATH9K_PCI_NO_EEPROM - config-$(CONFIG_TARGET_ath79) += ATH9K_AHB -+config-$(CONFIG_TARGET_ar71xx) += ATH9K_AHB - config-$(CONFIG_TARGET_ipq40xx) += ATH10K_AHB - config-$(CONFIG_PCI) += ATH9K_PCI - config-$(CONFIG_ATH_USER_REGD) += ATH_USER_REGD ATH_REG_DYNAMIC_USER_REG_HINTS -diff --git a/target/linux/ar71xx/files/arch/mips/ath79/mach-rb91x.c b/target/linux/ar71xx/files/arch/mips/ath79/mach-rb91x.c -index 9620718962..2cdf97efd6 100644 ---- a/target/linux/ar71xx/files/arch/mips/ath79/mach-rb91x.c -+++ b/target/linux/ar71xx/files/arch/mips/ath79/mach-rb91x.c -@@ -271,6 +271,8 @@ static const struct rb_board_info rb711gr100_boards[] __initconst = { - RB_BOARD_INFO("911G-5HPnD", 0), - RB_BOARD_INFO("912UAG-2HPnD", RB91X_FLAG_USB | RB91X_FLAG_PCIE), - RB_BOARD_INFO("912UAG-5HPnD", RB91X_FLAG_USB | RB91X_FLAG_PCIE), -+ RB_BOARD_INFO("RB912UAG-2HPnD", RB91X_FLAG_USB | RB91X_FLAG_PCIE), -+ RB_BOARD_INFO("RB912UAG-5HPnD", RB91X_FLAG_USB | RB91X_FLAG_PCIE), - }; - - static u32 rb711gr100_get_flags(const struct rb_info *info) --- -2.25.1 - diff --git a/config.yml b/config.yml index e37fdc3f1..14daada7f 100644 --- a/config.yml +++ b/config.yml @@ -1,6 +1,6 @@ repo: https://github.com/openwrt/openwrt.git branch: openwrt-21.02 -revision: 6fd65c657351908302b37447675ee352ec927d93 +revision: 378769b5551714ccaa821b481bfeecbf362f351e output_dir: ./output patch_folders: diff --git a/patches/0001-.gitignore-add-the-profiles-folder.patch b/patches/0001-.gitignore-add-the-profiles-folder.patch index 2873f27b8..1e7b8cac7 100644 --- a/patches/0001-.gitignore-add-the-profiles-folder.patch +++ b/patches/0001-.gitignore-add-the-profiles-folder.patch @@ -1,7 +1,7 @@ -From 77f9263187df8db1da9b6e859a46c8f9ec854035 Mon Sep 17 00:00:00 2001 +From 534b0e8d0ff1407c2c0e8e8c650f47ce6060a7a4 Mon Sep 17 00:00:00 2001 From: John Crispin Date: Tue, 22 Sep 2020 18:02:55 +0200 -Subject: [PATCH 01/21] .gitignore: add the /profiles folder +Subject: [PATCH 01/43] .gitignore: add the /profiles folder Signed-off-by: John Crispin --- @@ -9,7 +9,7 @@ Signed-off-by: John Crispin 1 file changed, 1 insertion(+) diff --git a/.gitignore b/.gitignore -index b6bfe1a525..a2a910ef13 100644 +index 9647daa5a4..70a592e12f 100644 --- a/.gitignore +++ b/.gitignore @@ -16,6 +16,7 @@ diff --git a/patches/0002-Revert-toolchain-gcc-Remove-support-for-GCC-5.patch b/patches/0002-Revert-toolchain-gcc-Remove-support-for-GCC-5.patch index 15fe9e127..fcbe0080b 100644 --- a/patches/0002-Revert-toolchain-gcc-Remove-support-for-GCC-5.patch +++ b/patches/0002-Revert-toolchain-gcc-Remove-support-for-GCC-5.patch @@ -1,7 +1,7 @@ -From 0778b48ab16067d538021c0bedf1e5312347dcc6 Mon Sep 17 00:00:00 2001 +From 2947f1c2ac5e300d209b952979da30e92330a01f Mon Sep 17 00:00:00 2001 From: John Crispin Date: Mon, 25 Jan 2021 06:40:20 +0100 -Subject: [PATCH 02/21] Revert "toolchain: gcc: Remove support for GCC 5" +Subject: [PATCH 02/43] Revert "toolchain: gcc: Remove support for GCC 5" This reverts commit 080dc619d4780a1f7b14082b77b28686e694f72d. --- diff --git a/patches/0003-pending-scripts-add-gen_config.py.patch b/patches/0003-pending-scripts-add-gen_config.py.patch index 8e3f7ac98..ec1ee7922 100644 --- a/patches/0003-pending-scripts-add-gen_config.py.patch +++ b/patches/0003-pending-scripts-add-gen_config.py.patch @@ -1,7 +1,7 @@ -From f9d39a389ef2a3bbf326580a0769519c1f3bad5f Mon Sep 17 00:00:00 2001 +From 4b5a9307be956685ed6bd14a3e2cb8727eae0b08 Mon Sep 17 00:00:00 2001 From: John Crispin Date: Fri, 19 Jun 2020 10:45:22 +0200 -Subject: [PATCH 01/37] pending: scripts: add gen_config.py +Subject: [PATCH 03/43] pending: scripts: add gen_config.py This script is used to setup the tree based on the profiles/. diff --git a/patches/0004-scripts-update-feed-script.patch b/patches/0004-scripts-update-feed-script.patch index 6c31fec33..5b2e7c025 100644 --- a/patches/0004-scripts-update-feed-script.patch +++ b/patches/0004-scripts-update-feed-script.patch @@ -1,7 +1,7 @@ -From 501a2989de4295029f419406c20f72e10a914db4 Mon Sep 17 00:00:00 2001 +From 2abc67a0fbfbf50f4af2baaee07eb10d214973e4 Mon Sep 17 00:00:00 2001 From: John Crispin Date: Fri, 19 Jun 2020 13:25:27 +0200 -Subject: [PATCH 04/21] scripts: update feed script +Subject: [PATCH 04/43] scripts: update feed script gen_config.py requires the latest version of the feeds script. diff --git a/patches/0005-scripts-ubinize-image.sh-allow-setting-the-rootfs-na.patch b/patches/0005-scripts-ubinize-image.sh-allow-setting-the-rootfs-na.patch index 9a5cc92b4..279207a61 100644 --- a/patches/0005-scripts-ubinize-image.sh-allow-setting-the-rootfs-na.patch +++ b/patches/0005-scripts-ubinize-image.sh-allow-setting-the-rootfs-na.patch @@ -1,7 +1,7 @@ -From f7b13fd5ac28e13e7ef2c95f3fda2c3ec3b78b39 Mon Sep 17 00:00:00 2001 +From 41347924799ff4f16a12d8f740f5c66b10eb8c43 Mon Sep 17 00:00:00 2001 From: John Crispin Date: Sun, 9 Aug 2020 20:58:52 +0200 -Subject: [PATCH 05/21] scripts/ubinize-image.sh: allow setting the rootfs name +Subject: [PATCH 05/43] scripts/ubinize-image.sh: allow setting the rootfs name This patch allows us to use a different rootfs name. Some QCA boards will require the in ubi rfs to be called ubi_rootfs. @@ -13,7 +13,7 @@ Signed-off-by: John Crispin 2 files changed, 9 insertions(+), 1 deletion(-) diff --git a/include/image-commands.mk b/include/image-commands.mk -index bddbed6052..bde6e030bc 100644 +index c6e8eb0293..d4bce80e68 100644 --- a/include/image-commands.mk +++ b/include/image-commands.mk @@ -86,6 +86,7 @@ define Build/append-ubi diff --git a/patches/0006-base-files-set-default-password-to-openwifi.patch b/patches/0006-base-files-set-default-password-to-openwifi.patch index 945557bf3..3d295ea22 100644 --- a/patches/0006-base-files-set-default-password-to-openwifi.patch +++ b/patches/0006-base-files-set-default-password-to-openwifi.patch @@ -1,7 +1,7 @@ -From a067af45a93ebc68f89a8adc88a25f11b4cd9620 Mon Sep 17 00:00:00 2001 +From 73116492498c07a2f9c45a7a66a4b03ac103d37d Mon Sep 17 00:00:00 2001 From: John Crispin Date: Thu, 30 Jul 2020 16:51:04 +0200 -Subject: [PATCH 06/21] base-files: set default password to "openwifi" +Subject: [PATCH 06/43] base-files: set default password to "openwifi" Signed-off-by: John Crispin --- @@ -11,10 +11,10 @@ Signed-off-by: John Crispin 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/package/base-files/files/bin/config_generate b/package/base-files/files/bin/config_generate -index ee3958e733..66b11c8a2e 100755 +index 596fcf41fa..30e7c119f7 100755 --- a/package/base-files/files/bin/config_generate +++ b/package/base-files/files/bin/config_generate -@@ -282,7 +282,7 @@ generate_static_system() { +@@ -303,7 +303,7 @@ generate_static_system() { add system system set system.@system[-1].hostname='OpenWrt' set system.@system[-1].timezone='UTC' diff --git a/patches/0007-base-files-update-banner.patch b/patches/0007-base-files-update-banner.patch index 8024004ac..610232c0b 100644 --- a/patches/0007-base-files-update-banner.patch +++ b/patches/0007-base-files-update-banner.patch @@ -1,7 +1,7 @@ -From 86494392a8ae5374e000298b6e06c2bcd4f82cb9 Mon Sep 17 00:00:00 2001 +From a819600041c0fade872c023637ba0c6c5890de78 Mon Sep 17 00:00:00 2001 From: John Crispin Date: Fri, 31 Jul 2020 17:15:13 +0200 -Subject: [PATCH 07/21] base-files: update banner +Subject: [PATCH 07/43] base-files: update banner Use OpenWiFi for the banner. diff --git a/patches/0008-base-files-add-the-wlan-ap-repo-hash.patch b/patches/0008-base-files-add-the-wlan-ap-repo-hash.patch index 5bd7468cd..41c92e311 100644 --- a/patches/0008-base-files-add-the-wlan-ap-repo-hash.patch +++ b/patches/0008-base-files-add-the-wlan-ap-repo-hash.patch @@ -1,7 +1,7 @@ -From 5ed64f1cde06fa3f0fb27c618c86aeeb9309d845 Mon Sep 17 00:00:00 2001 +From f887c60cee77011e009d87639560079b828a452a Mon Sep 17 00:00:00 2001 From: John Crispin Date: Sat, 29 Aug 2020 08:25:41 +0200 -Subject: [PATCH 12/38] base-files: add the wlan-ap repo hash +Subject: [PATCH 08/43] base-files: add the wlan-ap repo hash currently the banner will show the revision of the build tree. This patch adds the hash of the wlan-ap tree. @@ -44,10 +44,10 @@ index a4b47c8a57..214f32974b 100644 -e 's,%h,$(call sed_escape,$(VERSION_HWREV)),g' diff --git a/package/base-files/Makefile b/package/base-files/Makefile -index 8a1ddf96f5..0ff6fa84c1 100644 +index 9db4812981..99cb5476f7 100644 --- a/package/base-files/Makefile +++ b/package/base-files/Makefile -@@ -205,6 +205,7 @@ define Package/base-files/install +@@ -209,6 +209,7 @@ define Package/base-files/install $(if $(CONFIG_TARGET_PREINIT_DISABLE_FAILSAFE), \ rm -f $(1)/etc/banner.failsafe,) @@ -118,7 +118,7 @@ index 0000000000..4e8f05a700 +2.25.1 + diff --git a/scripts/gen_config.py b/scripts/gen_config.py -index 124dfd596a..e9418d776c 100755 +index a36f244e56..a348386124 100755 --- a/scripts/gen_config.py +++ b/scripts/gen_config.py @@ -62,7 +62,7 @@ def load_yaml(fname: str, profile: dict, include = True): diff --git a/patches/0009-base-files-make-sysupgrade-work-on-qcom-AX.patch b/patches/0009-base-files-make-sysupgrade-work-on-qcom-AX.patch index c2f60b791..f627784cd 100644 --- a/patches/0009-base-files-make-sysupgrade-work-on-qcom-AX.patch +++ b/patches/0009-base-files-make-sysupgrade-work-on-qcom-AX.patch @@ -1,7 +1,7 @@ -From c6beeb8b4854b12b72a3ff2ed141129023f08eaf Mon Sep 17 00:00:00 2001 +From dfc5ca4495315d293ccdb1c52d7d29a133ba596b Mon Sep 17 00:00:00 2001 From: John Crispin Date: Mon, 22 Jun 2020 14:32:45 +0200 -Subject: [PATCH 09/21] base-files: make sysupgrade work on qcom AX +Subject: [PATCH 09/43] base-files: make sysupgrade work on qcom AX The qsdk v4.4 ubi layer does not detach the rootfs properly during sysupgrade. Pull in the ubu force detach patch from owrt-15.05. diff --git a/patches/0010-base-files-add-support-for-v4.4-style-netdev-led-tri.patch b/patches/0010-base-files-add-support-for-v4.4-style-netdev-led-tri.patch index 5e2e399b7..ed84164bd 100644 --- a/patches/0010-base-files-add-support-for-v4.4-style-netdev-led-tri.patch +++ b/patches/0010-base-files-add-support-for-v4.4-style-netdev-led-tri.patch @@ -1,7 +1,7 @@ -From 0d04a28c9646e245021282bc38740ae2ced17a08 Mon Sep 17 00:00:00 2001 +From db79fb81502c935be1295c258fb4738dfb2351bd Mon Sep 17 00:00:00 2001 From: John Crispin Date: Wed, 23 Sep 2020 17:34:44 +0200 -Subject: [PATCH 10/21] base-files: add support for v4.4 style netdev led +Subject: [PATCH 10/43] base-files: add support for v4.4 style netdev led triggers Current owrt scripting cant handle the old v4.4 style sysfs API of led diff --git a/patches/0011-busybox-enable-the-watchdog-tool.patch b/patches/0011-busybox-enable-the-watchdog-tool.patch index f3c305b7c..42cc3138a 100644 --- a/patches/0011-busybox-enable-the-watchdog-tool.patch +++ b/patches/0011-busybox-enable-the-watchdog-tool.patch @@ -1,7 +1,7 @@ -From c3e8689eba6ceafc23973883131349ef89c714ed Mon Sep 17 00:00:00 2001 +From 5c54120d8b707a1022052edd562cea1a358a9bce Mon Sep 17 00:00:00 2001 From: John Crispin Date: Tue, 28 Jul 2020 09:21:04 +0200 -Subject: [PATCH 11/21] busybox: enable the watchdog tool +Subject: [PATCH 11/43] busybox: enable the watchdog tool procd can currently only handle the main wdt. Enable the busybox applet until procd can handle multiple devices. @@ -12,7 +12,7 @@ Signed-off-by: John Crispin 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package/utils/busybox/Config-defaults.in b/package/utils/busybox/Config-defaults.in -index 04148df267..2389bbb8e0 100644 +index 168c73b24c..d35ce0b7b8 100644 --- a/package/utils/busybox/Config-defaults.in +++ b/package/utils/busybox/Config-defaults.in @@ -2182,7 +2182,7 @@ config BUSYBOX_DEFAULT_VOLNAME diff --git a/patches/0012-dnsmasq-add-relay-option82-support.patch b/patches/0012-dnsmasq-add-relay-option82-support.patch index 62718c1ea..910b67a0b 100644 --- a/patches/0012-dnsmasq-add-relay-option82-support.patch +++ b/patches/0012-dnsmasq-add-relay-option82-support.patch @@ -1,7 +1,7 @@ -From 8ca8d0669ea2b36a5542d9bcda32cddf9cd7cd0f Mon Sep 17 00:00:00 2001 +From 42e7cc0388b258ae0f391e7b0dbab9b53b067124 Mon Sep 17 00:00:00 2001 From: John Crispin Date: Tue, 8 Jun 2021 09:12:38 +0200 -Subject: [PATCH] dnsmasq: add relay / option82 support +Subject: [PATCH 12/43] dnsmasq: add relay / option82 support Signed-off-by: John Crispin --- @@ -11,10 +11,10 @@ Signed-off-by: John Crispin create mode 100644 package/network/services/dnsmasq/patches/200-option82.patch diff --git a/package/network/services/dnsmasq/files/dnsmasq.init b/package/network/services/dnsmasq/files/dnsmasq.init -index 680e72f9e7..51f405b73c 100644 +index 205bfb4cf6..dacd476cd4 100644 --- a/package/network/services/dnsmasq/files/dnsmasq.init +++ b/package/network/services/dnsmasq/files/dnsmasq.init -@@ -761,12 +761,14 @@ dhcp_relay_add() { +@@ -777,12 +777,14 @@ dhcp_relay_add() { [ -n "$server_addr" ] || return 0 config_get interface "$cfg" interface diff --git a/patches/0013-base-files-ignore-sysupgrade-that-was-not-ours.patch b/patches/0013-base-files-ignore-sysupgrade-that-was-not-ours.patch index 15a901088..b82cb8bfe 100644 --- a/patches/0013-base-files-ignore-sysupgrade-that-was-not-ours.patch +++ b/patches/0013-base-files-ignore-sysupgrade-that-was-not-ours.patch @@ -1,7 +1,7 @@ -From 4fb2a69f3bbdab006a6b751ce39203cfdade9ae6 Mon Sep 17 00:00:00 2001 +From 9fb93fbd42f8f1f3036580b6666b40ab343509f8 Mon Sep 17 00:00:00 2001 From: John Crispin Date: Thu, 17 Jun 2021 08:47:51 +0200 -Subject: [PATCH] base-files: ignore sysupgrade that was not ours +Subject: [PATCH 13/43] base-files: ignore sysupgrade that was not ours Signed-off-by: John Crispin --- diff --git a/patches/0014-ipq806x-simplify-ecw5410-dts.patch b/patches/0014-ipq806x-simplify-ecw5410-dts.patch index 2de77203c..b6e197046 100644 --- a/patches/0014-ipq806x-simplify-ecw5410-dts.patch +++ b/patches/0014-ipq806x-simplify-ecw5410-dts.patch @@ -1,7 +1,7 @@ -From b820ffd87781ef60bd6b5ef64162adf9cbb7d72b Mon Sep 17 00:00:00 2001 +From 8b82aea440583198be21bbbe4e3f6d7bd814aad8 Mon Sep 17 00:00:00 2001 From: John Crispin Date: Thu, 17 Jun 2021 16:13:40 +0200 -Subject: [PATCH 2/4] ipq806x: simplify ecw5410 dts +Subject: [PATCH 14/43] ipq806x: simplify ecw5410 dts Signed-off-by: John Crispin --- @@ -37,7 +37,7 @@ index 3befc40630..e5715a79aa 100644 linksys,ea8500) caldata_extract "art" 0x5000 0x2f20 diff --git a/target/linux/ipq806x/files/arch/arm/boot/dts/qcom-ipq8068-ecw5410.dts b/target/linux/ipq806x/files/arch/arm/boot/dts/qcom-ipq8068-ecw5410.dts -index 712910c261..e6fc3453b0 100644 +index 712910c261..e87ef16b9a 100644 --- a/target/linux/ipq806x/files/arch/arm/boot/dts/qcom-ipq8068-ecw5410.dts +++ b/target/linux/ipq806x/files/arch/arm/boot/dts/qcom-ipq8068-ecw5410.dts @@ -95,6 +95,16 @@ diff --git a/patches/0015-ipq807x-buildsystem-patches-required-by-the-target.patch b/patches/0015-ipq807x-buildsystem-patches-required-by-the-target.patch index 033e585fd..1e759a563 100644 --- a/patches/0015-ipq807x-buildsystem-patches-required-by-the-target.patch +++ b/patches/0015-ipq807x-buildsystem-patches-required-by-the-target.patch @@ -1,7 +1,7 @@ -From c0442b28c993b63a5af510448e01083f3d681475 Mon Sep 17 00:00:00 2001 +From 2a1e093c78738b3c3e47bbf357efe571ff04d8aa Mon Sep 17 00:00:00 2001 From: John Crispin Date: Mon, 15 Feb 2021 15:20:44 +0100 -Subject: [PATCH 15/21] ipq807x: buildsystem patches required by the target +Subject: [PATCH 15/43] ipq807x: buildsystem patches required by the target The target uses the v4.4 kernel and requires these patches to build properly. diff --git a/patches/0016-linux-modules-fix-some-v4.4-dependencies.patch b/patches/0016-linux-modules-fix-some-v4.4-dependencies.patch index 6cf32e5f1..a044a00f0 100644 --- a/patches/0016-linux-modules-fix-some-v4.4-dependencies.patch +++ b/patches/0016-linux-modules-fix-some-v4.4-dependencies.patch @@ -1,7 +1,7 @@ -From 6942520b7623e3fc793a229e04af2b74fd19f556 Mon Sep 17 00:00:00 2001 +From 5cb922f8d91e2bdd48807adf26336e61b03747a6 Mon Sep 17 00:00:00 2001 From: John Crispin Date: Wed, 24 Mar 2021 15:03:30 +0100 -Subject: [PATCH 16/21] linux/modules: fix some v4.4 dependencies +Subject: [PATCH 16/43] linux/modules: fix some v4.4 dependencies NFT has different deps on v4.4. @@ -27,13 +27,13 @@ Signed-off-by: John Crispin toolchain/gcc/Config.in | 5 +++ toolchain/gcc/Config.version | 1 + toolchain/kernel-headers/Makefile | 2 +- - 21 files changed, 145 insertions(+), 40 deletions(-) + 20 files changed, 143 insertions(+), 40 deletions(-) diff --git a/config/Config-images.in b/config/Config-images.in -index 2921cd5bca..969b57efee 100644 +index b869ccae70..de11c52676 100644 --- a/config/Config-images.in +++ b/config/Config-images.in -@@ -17,6 +17,7 @@ menu "Target Images" +@@ -18,6 +18,7 @@ menu "Target Images" default TARGET_INITRAMFS_COMPRESSION_LZMA if TARGET_lantiq default TARGET_INITRAMFS_COMPRESSION_LZMA if TARGET_mpc85xx default TARGET_INITRAMFS_COMPRESSION_LZMA if TARGET_ramips @@ -42,7 +42,7 @@ index 2921cd5bca..969b57efee 100644 depends on TARGET_ROOTFS_INITRAMFS help diff --git a/include/image.mk b/include/image.mk -index 2530108211..10e7063f41 100644 +index 7c2dcf0e8b..6fc02a3f6b 100644 --- a/include/image.mk +++ b/include/image.mk @@ -153,6 +153,7 @@ endif @@ -62,7 +62,7 @@ index 2530108211..10e7063f41 100644 define Image/pad-to dd if=$(1) of=$(1).new bs=$(2) conv=sync diff --git a/include/kernel.mk b/include/kernel.mk -index d2a5b42138..4e9561c93c 100644 +index e4074a48f4..56fa06b2eb 100644 --- a/include/kernel.mk +++ b/include/kernel.mk @@ -44,7 +44,7 @@ else @@ -261,7 +261,7 @@ index 7526224972..691f8fb186 100644 __config_list = $(firstword $(wildcard $(call __config_name_list,$(1)))) find_kernel_config=$(if $(__config_list),$(__config_list),$(lastword $(__config_name_list))) diff --git a/package/kernel/linux/modules/can.mk b/package/kernel/linux/modules/can.mk -index 58c257db5b..3bf0359c11 100644 +index 3060fc0966..5542c4fe0a 100644 --- a/package/kernel/linux/modules/can.mk +++ b/package/kernel/linux/modules/can.mk @@ -248,7 +248,8 @@ define KernelPackage/can-usb-kvaser @@ -275,10 +275,10 @@ index 58c257db5b..3bf0359c11 100644 $(call AddDepends/can,+kmod-usb-core) endef diff --git a/package/kernel/linux/modules/crypto.mk b/package/kernel/linux/modules/crypto.mk -index e9e78e7967..e7776c096c 100644 +index b50ed06824..a68459d989 100644 --- a/package/kernel/linux/modules/crypto.mk +++ b/package/kernel/linux/modules/crypto.mk -@@ -377,7 +377,7 @@ $(eval $(call KernelPackage,crypto-hw-padlock)) +@@ -387,7 +387,7 @@ $(eval $(call KernelPackage,crypto-hw-padlock)) define KernelPackage/crypto-hw-safexcel TITLE:= MVEBU SafeXcel Crypto Engine module @@ -287,7 +287,7 @@ index e9e78e7967..e7776c096c 100644 +kmod-crypto-authenc +kmod-crypto-md5 +kmod-crypto-hmac +kmod-crypto-sha256 +kmod-crypto-sha512 KCONFIG:= \ CONFIG_CRYPTO_HW=y \ -@@ -549,8 +549,10 @@ ifndef CONFIG_TARGET_x86_64 +@@ -710,8 +710,10 @@ ifndef CONFIG_TARGET_x86_64 $(LINUX_DIR)/arch/x86/crypto/twofish-i586.ko \ $(LINUX_DIR)/arch/x86/crypto/serpent-sse2-i586.ko \ $(LINUX_DIR)/arch/x86/crypto/glue_helper.ko \ @@ -299,7 +299,7 @@ index e9e78e7967..e7776c096c 100644 AUTOLOAD+= $(call AutoLoad,10,cryptd glue_helper \ serpent-sse2-i586 twofish-i586 blowfish_generic) endef -@@ -569,7 +571,8 @@ define KernelPackage/crypto-misc/x86/64 +@@ -730,7 +732,8 @@ define KernelPackage/crypto-misc/x86/64 $(LINUX_DIR)/arch/x86/crypto/twofish-avx-x86_64.ko \ $(LINUX_DIR)/arch/x86/crypto/serpent-avx-x86_64.ko \ $(LINUX_DIR)/arch/x86/crypto/camellia-aesni-avx2.ko \ @@ -413,7 +413,7 @@ index e2bb1d0681..1be05e182a 100644 endef diff --git a/package/kernel/linux/modules/netsupport.mk b/package/kernel/linux/modules/netsupport.mk -index 2c2fe82fa0..36e1732c11 100644 +index 1eec9f9b63..4343e850e9 100644 --- a/package/kernel/linux/modules/netsupport.mk +++ b/package/kernel/linux/modules/netsupport.mk @@ -375,7 +375,7 @@ $(eval $(call KernelPackage,ip6-vti)) @@ -425,7 +425,7 @@ index 2c2fe82fa0..36e1732c11 100644 KCONFIG:=CONFIG_XFRM_INTERFACE FILES:=$(LINUX_DIR)/net/xfrm/xfrm_interface.ko AUTOLOAD:=$(call AutoProbe,xfrm_interface) -@@ -764,7 +764,7 @@ $(eval $(call KernelPackage,sched-core)) +@@ -765,7 +765,7 @@ $(eval $(call KernelPackage,sched-core)) define KernelPackage/sched-cake SUBMENU:=$(NETWORK_SUPPORT_MENU) TITLE:=Cake fq_codel/blue derived shaper @@ -434,7 +434,7 @@ index 2c2fe82fa0..36e1732c11 100644 KCONFIG:=CONFIG_NET_SCH_CAKE FILES:=$(LINUX_DIR)/net/sched/sch_cake.ko AUTOLOAD:=$(call AutoProbe,sch_cake) -@@ -1147,7 +1147,7 @@ $(eval $(call KernelPackage,rxrpc)) +@@ -1154,7 +1154,7 @@ $(eval $(call KernelPackage,rxrpc)) define KernelPackage/mpls SUBMENU:=$(NETWORK_SUPPORT_MENU) TITLE:=MPLS support @@ -508,7 +508,7 @@ index 83d998c83a..784adcb744 100644 FILES:= $(LINUX_DIR)/drivers/char/tpm/tpm.ko AUTOLOAD:=$(call AutoLoad,10,tpm,1) diff --git a/package/kernel/linux/modules/usb.mk b/package/kernel/linux/modules/usb.mk -index 3dd20a0696..e3acb4bf79 100644 +index 592affe494..41d12cb08a 100644 --- a/package/kernel/linux/modules/usb.mk +++ b/package/kernel/linux/modules/usb.mk @@ -458,9 +458,28 @@ endef diff --git a/patches/0017-ipq807x-add-the-Qualcomm-AX-target-support.patch b/patches/0017-ipq807x-add-the-Qualcomm-AX-target-support.patch index 35fdbae72..17b55d3a0 100644 --- a/patches/0017-ipq807x-add-the-Qualcomm-AX-target-support.patch +++ b/patches/0017-ipq807x-add-the-Qualcomm-AX-target-support.patch @@ -1,7 +1,7 @@ -From 67774c73ab28997107e29487a95d9c96e11398f7 Mon Sep 17 00:00:00 2001 +From 6ec4c8f7d24c34c5855278fe13bde4e5e43ba293 Mon Sep 17 00:00:00 2001 From: John Crispin Date: Sat, 18 Jul 2020 08:53:44 +0200 -Subject: [PATCH 01/22] ipq807x: add the Qualcomm AX target support +Subject: [PATCH 17/43] ipq807x: add the Qualcomm AX target support Signed-off-by: John Crispin --- @@ -119,7 +119,7 @@ index f71114b5da..4a85d83118 100644 string "Custom Kernel Build User Name" default "builder" if BUILDBOT diff --git a/include/image.mk b/include/image.mk -index 5ee6d309e4..7a48b789af 100644 +index 6fc02a3f6b..92b23321b1 100644 --- a/include/image.mk +++ b/include/image.mk @@ -179,6 +179,10 @@ define Image/pad-root-squashfs @@ -186,10 +186,10 @@ index 0000000000..6c429f1852 + +exit 0 diff --git a/target/linux/ipq40xx/base-files/etc/hotplug.d/firmware/11-ath10k-caldata b/target/linux/ipq40xx/base-files/etc/hotplug.d/firmware/11-ath10k-caldata -index c4d9dd78e3..6670d310db 100644 +index b12c9af9a7..b7ee73b12e 100644 --- a/target/linux/ipq40xx/base-files/etc/hotplug.d/firmware/11-ath10k-caldata +++ b/target/linux/ipq40xx/base-files/etc/hotplug.d/firmware/11-ath10k-caldata -@@ -254,6 +254,11 @@ case "$FIRMWARE" in +@@ -265,6 +265,11 @@ case "$FIRMWARE" in caldata_extract "ART" 0x5000 0x2f20 ath10k_patch_mac $(macaddr_add $(cat /sys/class/net/eth0/address) -1) ;; diff --git a/patches/0018-ramips-add-tplink-ex228-support.patch b/patches/0018-ramips-add-tplink-ex228-support.patch index 9015988d0..c5c00d88c 100644 --- a/patches/0018-ramips-add-tplink-ex228-support.patch +++ b/patches/0018-ramips-add-tplink-ex228-support.patch @@ -1,7 +1,7 @@ -From 842b431559c3992e182190b7f96c4407978723c7 Mon Sep 17 00:00:00 2001 +From 2970ecaae31c8e42cf1ef5cff2a78cf57701070e Mon Sep 17 00:00:00 2001 From: John Crispin Date: Thu, 27 May 2021 16:48:27 +0200 -Subject: [PATCH] ramips: add tplink ex228 support +Subject: [PATCH 18/43] ramips: add tplink ex228 support Signed-off-by: John Crispin --- @@ -148,10 +148,10 @@ index 0000000000..9e5cc9ef01 + }; +}; diff --git a/target/linux/ramips/image/mt7621.mk b/target/linux/ramips/image/mt7621.mk -index a8f558326d..1a84abc842 100644 +index a3bc14d59d..6e0b9b5f76 100644 --- a/target/linux/ramips/image/mt7621.mk +++ b/target/linux/ramips/image/mt7621.mk -@@ -1138,6 +1138,16 @@ define Device/tplink_eap235-wall-v1 +@@ -1271,6 +1271,16 @@ define Device/tplink_eap235-wall-v1 endef TARGET_DEVICES += tplink_eap235-wall-v1 @@ -169,11 +169,11 @@ index a8f558326d..1a84abc842 100644 $(Device/dsa-migration) $(Device/tplink-safeloader) diff --git a/target/linux/ramips/mt7621/base-files/etc/board.d/02_network b/target/linux/ramips/mt7621/base-files/etc/board.d/02_network -index 89e679be7c..b6b8b6482d 100755 +index 4b44669b84..1c4e29dd97 100755 --- a/target/linux/ramips/mt7621/base-files/etc/board.d/02_network +++ b/target/linux/ramips/mt7621/base-files/etc/board.d/02_network -@@ -36,6 +36,7 @@ ramips_setup_interfaces() - ;; +@@ -25,6 +25,7 @@ ramips_setup_interfaces() + ampedwireless,ally-r1900k|\ gehua,ghl-r-001|\ hiwifi,hc5962|\ + tplink,ex228|\ @@ -181,13 +181,13 @@ index 89e679be7c..b6b8b6482d 100755 xiaomi,mi-router-ac2100|\ xiaomi,redmi-router-ac2100) diff --git a/target/linux/ramips/mt7621/base-files/lib/upgrade/platform.sh b/target/linux/ramips/mt7621/base-files/lib/upgrade/platform.sh -index c9152c5cf4..853a464ea5 100755 +index c2ad4d3ed6..acaa62d171 100755 --- a/target/linux/ramips/mt7621/base-files/lib/upgrade/platform.sh +++ b/target/linux/ramips/mt7621/base-files/lib/upgrade/platform.sh -@@ -61,6 +61,7 @@ platform_do_upgrade() { - netgear,wac104|\ +@@ -73,6 +73,7 @@ platform_do_upgrade() { netgear,wac124|\ netis,wf2881|\ + sercomm,na502|\ + tplink,ex228|\ xiaomi,mi-router-3g|\ xiaomi,mi-router-3-pro|\ diff --git a/patches/0019-lldp-add-TIP-tweaks.patch b/patches/0019-lldp-add-TIP-tweaks.patch index 7b603ed90..9bc522d66 100644 --- a/patches/0019-lldp-add-TIP-tweaks.patch +++ b/patches/0019-lldp-add-TIP-tweaks.patch @@ -1,7 +1,7 @@ -From 7a4571cc0c12d54d0aca93dfedbe8dc33cff39fa Mon Sep 17 00:00:00 2001 +From 58242d355b483e105affd0c69c681e46e88ad84c Mon Sep 17 00:00:00 2001 From: John Crispin Date: Fri, 4 Dec 2020 16:29:35 +0100 -Subject: [PATCH 01/11] lldp: add TIP tweaks +Subject: [PATCH 19/43] lldp: add TIP tweaks Signed-off-by: John Crispin --- diff --git a/patches/0020-ramips-make-wifi-work.patch b/patches/0020-ramips-make-wifi-work.patch index a505c5fa4..13d1f8cd8 100644 --- a/patches/0020-ramips-make-wifi-work.patch +++ b/patches/0020-ramips-make-wifi-work.patch @@ -1,7 +1,7 @@ -From 949cec1e6873109d29ee435d9f2370fbbb7b9700 Mon Sep 17 00:00:00 2001 +From e00ffc2ad678216a318106da687701aafa5a1ac7 Mon Sep 17 00:00:00 2001 From: John Crispin Date: Fri, 4 Dec 2020 16:29:16 +0100 -Subject: [PATCH 20/21] ramips: make wifi work +Subject: [PATCH 20/43] ramips: make wifi work Signed-off-by: John Crispin --- @@ -9,7 +9,7 @@ Signed-off-by: John Crispin 1 file changed, 1 insertion(+) diff --git a/target/linux/ramips/mt76x8/config-5.4 b/target/linux/ramips/mt76x8/config-5.4 -index ec21b3722b..725aa9b070 100644 +index dfd01598ad..e82b775758 100644 --- a/target/linux/ramips/mt76x8/config-5.4 +++ b/target/linux/ramips/mt76x8/config-5.4 @@ -46,6 +46,7 @@ CONFIG_CPU_R4K_CACHE_TLB=y diff --git a/patches/0021-ugps-update-to-latest-HEAD.patch b/patches/0021-ugps-update-to-latest-HEAD.patch index 45efe095b..bdec92d51 100644 --- a/patches/0021-ugps-update-to-latest-HEAD.patch +++ b/patches/0021-ugps-update-to-latest-HEAD.patch @@ -1,7 +1,7 @@ -From efdbdcd3503315022a3270886826656be116345b Mon Sep 17 00:00:00 2001 +From 6e5fd4e18759885bd25aa182d5cc7ce1c7f8eeea Mon Sep 17 00:00:00 2001 From: John Crispin Date: Sat, 19 Jun 2021 16:00:43 +0200 -Subject: [PATCH 38/38] ugps: update to latest HEAD +Subject: [PATCH 21/43] ugps: update to latest HEAD Signed-off-by: John Crispin --- @@ -9,16 +9,16 @@ Signed-off-by: John Crispin 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/package/utils/ugps/Makefile b/package/utils/ugps/Makefile -index 4ce64d9631..e9a7f4fa8f 100644 +index c70a7b7ea6..389138d1dd 100644 --- a/package/utils/ugps/Makefile +++ b/package/utils/ugps/Makefile -@@ -12,9 +12,9 @@ PKG_RELEASE:=1 +@@ -12,9 +12,9 @@ PKG_RELEASE:=$(AUTORELEASE) PKG_SOURCE_URL=$(PROJECT_GIT)/project/ugps.git PKG_SOURCE_PROTO:=git --PKG_SOURCE_DATE:=2020-08-29 --PKG_SOURCE_VERSION:=511a5b3c84fa715ef0305cf26c98619c12a4867a --PKG_MIRROR_HASH:=551d57b4c18da4c4695fa2f7a959c25a03be35d14cf872785e7db740f12366e2 +-PKG_SOURCE_DATE:=2021-06-08 +-PKG_SOURCE_VERSION:=5e88403fc0d39ae8a270d2c6c6e9c8a4d5232cf3 +-PKG_MIRROR_HASH:=a3dfc2cc6def3b634d8b7cda9139926be3d876cf2faa5251c4821987954442a5 +PKG_SOURCE_DATE:=2021-07-19 +PKG_SOURCE_VERSION:=350b960b6f8b08409dcef719ef1e1e0c8911040f +PKG_MIRROR_HASH:=94d489072f8fccc26f624c3d3c65e7cb40e4b6267df5fb39d4e0e78469006bde diff --git a/patches/0022-Revert-ipq40xx-revert-usage-of-VLAN-S-TAG.patch b/patches/0022-Revert-ipq40xx-revert-usage-of-VLAN-S-TAG.patch index f0f9a96c8..62c4fae54 100644 --- a/patches/0022-Revert-ipq40xx-revert-usage-of-VLAN-S-TAG.patch +++ b/patches/0022-Revert-ipq40xx-revert-usage-of-VLAN-S-TAG.patch @@ -1,7 +1,7 @@ -From 91d0510ff553a1dd43312eee44ef6290a9eb751c Mon Sep 17 00:00:00 2001 +From 687576be91062e5ab25e8ff4e2d990799a34210f Mon Sep 17 00:00:00 2001 From: John Crispin Date: Thu, 8 Apr 2021 10:46:29 +0200 -Subject: [PATCH] Revert "ipq40xx: revert usage of VLAN S-TAG" +Subject: [PATCH 22/43] Revert "ipq40xx: revert usage of VLAN S-TAG" This reverts commit cdc8d4b46f0811292fffc6094acd81e854b5f4a5. diff --git a/patches/0023-ipq40xx-add-ath10k-ct-fw.cfg-stubs.patch b/patches/0023-ipq40xx-add-ath10k-ct-fw.cfg-stubs.patch index aa3a3c40b..455d44eba 100644 --- a/patches/0023-ipq40xx-add-ath10k-ct-fw.cfg-stubs.patch +++ b/patches/0023-ipq40xx-add-ath10k-ct-fw.cfg-stubs.patch @@ -1,7 +1,7 @@ -From 558605338e87ebac7358026eb86b7ba5f4c228a1 Mon Sep 17 00:00:00 2001 +From f6f9f9f095bdd05c66f23357228b90a8daeedd14 Mon Sep 17 00:00:00 2001 From: John Crispin Date: Thu, 25 Mar 2021 08:03:48 +0100 -Subject: [PATCH 23/23] ipq40xx: add ath10k-ct fw.cfg stubs +Subject: [PATCH 23/43] ipq40xx: add ath10k-ct fw.cfg stubs Signed-off-by: John Crispin --- diff --git a/patches/0024-ipq40xx-fix-ecw5211-support.patch b/patches/0024-ipq40xx-fix-ecw5211-support.patch deleted file mode 100644 index a83a3eb2d..000000000 --- a/patches/0024-ipq40xx-fix-ecw5211-support.patch +++ /dev/null @@ -1,25 +0,0 @@ -From c82870ef8a2ae4798ede9393254c1e18798e5d01 Mon Sep 17 00:00:00 2001 -From: John Crispin -Date: Tue, 15 Jun 2021 17:03:14 +0200 -Subject: [PATCH] ipq40xx: fix ecw5211 support - -Signed-off-by: John Crispin ---- - target/linux/ipq40xx/image/generic.mk | 1 + - 1 file changed, 1 insertion(+) - -diff --git a/target/linux/ipq40xx/image/generic.mk b/target/linux/ipq40xx/image/generic.mk -index 1de17dd15a..487bba77b0 100644 ---- a/target/linux/ipq40xx/image/generic.mk -+++ b/target/linux/ipq40xx/image/generic.mk -@@ -371,6 +371,7 @@ define Device/edgecore_ecw5211 - SOC := qcom-ipq4018 - BLOCKSIZE := 128k - PAGESIZE := 2048 -+ DEVICE_DTS_CONFIG := config@ap.dk01.1-c2 - DEVICE_PACKAGES := kmod-tpm-i2c-atmel kmod-usb-acm uboot-envtools - endef - TARGET_DEVICES += edgecore_ecw5211 --- -2.25.1 - diff --git a/patches/0025-target-add-pstore-support.patch b/patches/0024-target-add-pstore-support.patch similarity index 85% rename from patches/0025-target-add-pstore-support.patch rename to patches/0024-target-add-pstore-support.patch index 80940ac93..caffbf1b4 100644 --- a/patches/0025-target-add-pstore-support.patch +++ b/patches/0024-target-add-pstore-support.patch @@ -1,23 +1,21 @@ -From e0ff8f29f0c0c147b34fe943698e8f95dfa6c688 Mon Sep 17 00:00:00 2001 +From 17dbf01adfa8cc4704873a57ae3676fe09f961fa Mon Sep 17 00:00:00 2001 From: John Crispin Date: Tue, 30 Mar 2021 19:03:43 +0200 -Subject: [PATCH 1/6] target: add pstore support +Subject: [PATCH 24/43] target: add pstore support Signed-off-by: John Crispin --- target/linux/generic/config-5.10 | 15 ++++++++++++++- target/linux/generic/config-5.4 | 14 +++++++++++++- .../linux/ipq40xx/patches-5.4/903-pstore.patch | 17 +++++++++++++++++ - .../patches-5.10/160-add-pstore-support.patch | 17 +++++++++++++++++ - 4 files changed, 61 insertions(+), 2 deletions(-) + 3 files changed, 44 insertions(+), 2 deletions(-) create mode 100644 target/linux/ipq40xx/patches-5.4/903-pstore.patch - create mode 100644 target/linux/mediatek/patches-5.10/160-add-pstore-support.patch diff --git a/target/linux/generic/config-5.10 b/target/linux/generic/config-5.10 -index ba6317e35f..3e911a2619 100644 +index 4eb5607f17..2582e8851a 100644 --- a/target/linux/generic/config-5.10 +++ b/target/linux/generic/config-5.10 -@@ -4424,7 +4424,20 @@ CONFIG_PROC_SYSCTL=y +@@ -4506,7 +4506,20 @@ CONFIG_PROC_SYSCTL=y # CONFIG_PSAMPLE is not set # CONFIG_PSB6970_PHY is not set # CONFIG_PSI is not set @@ -40,10 +38,10 @@ index ba6317e35f..3e911a2619 100644 # CONFIG_PTP_1588_CLOCK is not set # CONFIG_PTP_1588_CLOCK_IDT82P33 is not set diff --git a/target/linux/generic/config-5.4 b/target/linux/generic/config-5.4 -index a0193ca718..da2cc8db65 100644 +index da0e2e2186..b6673ede4d 100644 --- a/target/linux/generic/config-5.4 +++ b/target/linux/generic/config-5.4 -@@ -4136,7 +4136,19 @@ CONFIG_PROC_SYSCTL=y +@@ -4177,7 +4177,19 @@ CONFIG_PROC_SYSCTL=y # CONFIG_PSAMPLE is not set # CONFIG_PSB6970_PHY is not set # CONFIG_PSI is not set diff --git a/patches/0026-ath79-add-support-for-Indio-305AC.patch b/patches/0025-ath79-add-Support-for-Indio-305AC.patch similarity index 93% rename from patches/0026-ath79-add-support-for-Indio-305AC.patch rename to patches/0025-ath79-add-Support-for-Indio-305AC.patch index 47e8aabe4..23a4bdac2 100644 --- a/patches/0026-ath79-add-support-for-Indio-305AC.patch +++ b/patches/0025-ath79-add-Support-for-Indio-305AC.patch @@ -1,7 +1,7 @@ -From 008a385635cafdce3498ebd6a6b429a1aa2e03bd Mon Sep 17 00:00:00 2001 +From da01b2ec475761de8ac92045329483f8a9cf7438 Mon Sep 17 00:00:00 2001 From: Rohan Nathi Date: Thu, 24 Jun 2021 13:48:45 +0000 -Subject: [PATCH] ath79: add Support for Indio 305AC +Subject: [PATCH 25/43] ath79: add Support for Indio 305AC Signed-off-by: Rohan Nathi --- @@ -134,10 +134,10 @@ index 0000000000..763fdcefa8 + mtd-cal-data = <&art 0x1000>; +}; diff --git a/target/linux/ath79/generic/base-files/etc/hotplug.d/firmware/11-ath10k-caldata b/target/linux/ath79/generic/base-files/etc/hotplug.d/firmware/11-ath10k-caldata -index 5a44dd94e5..94afc9c726 100644 +index 783895525b..80f755b343 100644 --- a/target/linux/ath79/generic/base-files/etc/hotplug.d/firmware/11-ath10k-caldata +++ b/target/linux/ath79/generic/base-files/etc/hotplug.d/firmware/11-ath10k-caldata -@@ -43,6 +43,7 @@ case "$FIRMWARE" in +@@ -44,6 +44,7 @@ case "$FIRMWARE" in ubnt,powerbeam-5ac-500|\ ubnt,powerbeam-5ac-gen2|\ ubnt,unifiac-pro|\ @@ -146,10 +146,10 @@ index 5a44dd94e5..94afc9c726 100644 caldata_extract "art" 0x5000 0x844 ;; diff --git a/target/linux/ath79/image/generic.mk b/target/linux/ath79/image/generic.mk -index d93ebbaeba..da95360281 100644 +index ce4e462a40..24778e8f1c 100644 --- a/target/linux/ath79/image/generic.mk +++ b/target/linux/ath79/image/generic.mk -@@ -2191,6 +2191,17 @@ define Device/yuncore_a770 +@@ -2209,6 +2209,17 @@ define Device/yuncore_a770 endef TARGET_DEVICES += yuncore_a770 diff --git a/patches/0027-ath79-tl-wpa8630p-fixes.patch b/patches/0026-ath79-tl-wpa8630p-fixes.patch similarity index 88% rename from patches/0027-ath79-tl-wpa8630p-fixes.patch rename to patches/0026-ath79-tl-wpa8630p-fixes.patch index 75bd24ad2..2a7133c30 100644 --- a/patches/0027-ath79-tl-wpa8630p-fixes.patch +++ b/patches/0026-ath79-tl-wpa8630p-fixes.patch @@ -1,7 +1,7 @@ -From a14a7d3580ba376227eba8c28d7e632f0f4e1ffc Mon Sep 17 00:00:00 2001 +From 643d734b0d05bc9e5fe1b4588bf0876c9fd87bd4 Mon Sep 17 00:00:00 2001 From: John Crispin Date: Wed, 30 Jun 2021 11:36:13 +0200 -Subject: [PATCH 35/36] ath79: tl-wpa8630p fixes +Subject: [PATCH 26/43] ath79: tl-wpa8630p fixes * a certificates partition and change default port mapping @@ -30,10 +30,10 @@ index 9e6d23de4e..c39dbc515b 100644 }; diff --git a/target/linux/ath79/generic/base-files/etc/board.d/02_network b/target/linux/ath79/generic/base-files/etc/board.d/02_network -index b8bc38348e..f300077dba 100755 +index 31c0f11861..3ba3d72abc 100755 --- a/target/linux/ath79/generic/base-files/etc/board.d/02_network +++ b/target/linux/ath79/generic/base-files/etc/board.d/02_network -@@ -380,7 +380,7 @@ ath79_setup_interfaces() +@@ -385,7 +385,7 @@ ath79_setup_interfaces() tplink,tl-wpa8630p-v2.1-eu) # port 5 (internal) is the power-line port ucidef_add_switch "switch0" \ diff --git a/patches/0028-ath79-add-support-for-TP-Link-CPE710-v1.patch b/patches/0027-ath79-add-support-for-TP-Link-CPE710-v1.patch similarity index 95% rename from patches/0028-ath79-add-support-for-TP-Link-CPE710-v1.patch rename to patches/0027-ath79-add-support-for-TP-Link-CPE710-v1.patch index c623244e7..432816be4 100644 --- a/patches/0028-ath79-add-support-for-TP-Link-CPE710-v1.patch +++ b/patches/0027-ath79-add-support-for-TP-Link-CPE710-v1.patch @@ -1,7 +1,7 @@ -From 84b1c4894ff871686c4bd7152aca47a323857db6 Mon Sep 17 00:00:00 2001 +From 6ecffc2057aa1261846e51a3966b8710f605910a Mon Sep 17 00:00:00 2001 From: Andrew Cameron Date: Mon, 12 Apr 2021 13:24:33 -0500 -Subject: [PATCH] ath79: add support for TP-Link CPE710-v1 +Subject: [PATCH 27/43] ath79: add support for TP-Link CPE710-v1 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit @@ -186,7 +186,7 @@ index 0000000000..830c3d30b8 + }; +}; diff --git a/target/linux/ath79/generic/base-files/etc/board.d/01_leds b/target/linux/ath79/generic/base-files/etc/board.d/01_leds -index fae5ac7c92..5c7e39e48f 100755 +index 7c5eeb1112..05bdf60f78 100755 --- a/target/linux/ath79/generic/base-files/etc/board.d/01_leds +++ b/target/linux/ath79/generic/base-files/etc/board.d/01_leds @@ -164,7 +164,8 @@ enterasys,ws-ap3705i|\ @@ -200,7 +200,7 @@ index fae5ac7c92..5c7e39e48f 100755 ;; compex,wpj344-16m|\ diff --git a/target/linux/ath79/generic/base-files/etc/board.d/02_network b/target/linux/ath79/generic/base-files/etc/board.d/02_network -index f300077dba..4fe605dee7 100755 +index 3ba3d72abc..d70432ad2b 100755 --- a/target/linux/ath79/generic/base-files/etc/board.d/02_network +++ b/target/linux/ath79/generic/base-files/etc/board.d/02_network @@ -63,6 +63,7 @@ ath79_setup_interfaces() @@ -212,10 +212,10 @@ index f300077dba..4fe605dee7 100755 tplink,eap225-v3|\ tplink,eap245-v1|\ diff --git a/target/linux/ath79/generic/base-files/etc/hotplug.d/firmware/11-ath10k-caldata b/target/linux/ath79/generic/base-files/etc/hotplug.d/firmware/11-ath10k-caldata -index 94afc9c726..fc110af75c 100644 +index 80f755b343..4d7940d6ba 100644 --- a/target/linux/ath79/generic/base-files/etc/hotplug.d/firmware/11-ath10k-caldata +++ b/target/linux/ath79/generic/base-files/etc/hotplug.d/firmware/11-ath10k-caldata -@@ -228,6 +228,12 @@ case "$FIRMWARE" in +@@ -229,6 +229,12 @@ case "$FIRMWARE" in ln -sf /lib/firmware/ath10k/pre-cal-pci-0000\:00\:00.0.bin \ /lib/firmware/ath10k/QCA9888/hw2.0/board.bin ;; @@ -229,7 +229,7 @@ index 94afc9c726..fc110af75c 100644 tplink,eap225-v3|\ tplink,eap225-wall-v2|\ diff --git a/target/linux/ath79/image/generic-tp-link.mk b/target/linux/ath79/image/generic-tp-link.mk -index 0058d74f77..e8c081eab1 100644 +index be6aa06b55..78340f650e 100644 --- a/target/linux/ath79/image/generic-tp-link.mk +++ b/target/linux/ath79/image/generic-tp-link.mk @@ -362,6 +362,17 @@ define Device/tplink_cpe610-v2 @@ -251,10 +251,10 @@ index 0058d74f77..e8c081eab1 100644 $(Device/tplink-safeloader) LOADER_TYPE := elf diff --git a/tools/firmware-utils/src/tplink-safeloader.c b/tools/firmware-utils/src/tplink-safeloader.c -index 2bc4a3cb82..2bba417dfc 100644 +index 70e21f99cb..c519a6d367 100644 --- a/tools/firmware-utils/src/tplink-safeloader.c +++ b/tools/firmware-utils/src/tplink-safeloader.c -@@ -537,6 +537,43 @@ static struct device_info boards[] = { +@@ -530,6 +530,43 @@ static struct device_info boards[] = { .first_sysupgrade_partition = "os-image", .last_sysupgrade_partition = "support-list", }, diff --git a/patches/0029-ipq4019-add-CIG-wf610d.patch b/patches/0028-ipq4019-add-CIG-wf610d.patch similarity index 95% rename from patches/0029-ipq4019-add-CIG-wf610d.patch rename to patches/0028-ipq4019-add-CIG-wf610d.patch index a93e9f321..66b2a961d 100644 --- a/patches/0029-ipq4019-add-CIG-wf610d.patch +++ b/patches/0028-ipq4019-add-CIG-wf610d.patch @@ -1,7 +1,7 @@ -From 859bdaad5959f972babb268eff24901b116703c8 Mon Sep 17 00:00:00 2001 +From 7244d33107173856db10bb2084146137704e7e18 Mon Sep 17 00:00:00 2001 From: John Crispin -Date: Tue, 13 Apr 2021 16:59:32 +0200 -Subject: [PATCH] ipq4019: add CIG wf610d +Date: Sat, 4 Sep 2021 05:56:53 +0200 +Subject: [PATCH 28/43] ipq4019: add CIG wf610d Signed-off-by: John Crispin --- @@ -19,10 +19,10 @@ Signed-off-by: John Crispin create mode 100755 target/linux/ipq40xx/files/arch/arm/boot/dts/qcom-ipq4029-ap-cig-wf610d.dts diff --git a/package/firmware/ipq-wifi/Makefile b/package/firmware/ipq-wifi/Makefile -index e5f10a1f98..513ad4ea67 100644 +index e3b25bb556..b996ee311f 100644 --- a/package/firmware/ipq-wifi/Makefile +++ b/package/firmware/ipq-wifi/Makefile -@@ -47,7 +47,8 @@ ALLWIFIBOARDS:= \ +@@ -49,7 +49,8 @@ ALLWIFIBOARDS:= \ nec_wg2600hp3 \ plasmacloud_pa1200 \ plasmacloud_pa2200 \ @@ -32,7 +32,7 @@ index e5f10a1f98..513ad4ea67 100644 ALLWIFIPACKAGES:=$(foreach BOARD,$(ALLWIFIBOARDS),ipq-wifi-$(BOARD)) -@@ -131,5 +132,6 @@ $(eval $(call generate-ipq-wifi-package,nec_wg2600hp3,NEC Platforms WG2600HP3)) +@@ -135,5 +136,6 @@ $(eval $(call generate-ipq-wifi-package,nec_wg2600hp3,NEC Platforms WG2600HP3)) $(eval $(call generate-ipq-wifi-package,plasmacloud_pa1200,Plasma Cloud PA1200)) $(eval $(call generate-ipq-wifi-package,plasmacloud_pa2200,Plasma Cloud PA2200)) $(eval $(call generate-ipq-wifi-package,qxwlan_e2600ac,Qxwlan E2600AC)) @@ -100,7 +100,7 @@ literal 0 HcmV?d00001 diff --git a/target/linux/ipq40xx/base-files/etc/board.d/01_leds b/target/linux/ipq40xx/base-files/etc/board.d/01_leds -index 3e0f3ab258..f9674126ba 100755 +index ac11655904..c1d4e693f2 100755 --- a/target/linux/ipq40xx/base-files/etc/board.d/01_leds +++ b/target/linux/ipq40xx/base-files/etc/board.d/01_leds @@ -30,6 +30,7 @@ edgecore,oap100) @@ -111,7 +111,7 @@ index 3e0f3ab258..f9674126ba 100755 engenius,eap1300) ucidef_set_led_netdev "lan" "LAN" "blue:lan" "eth0" ucidef_set_led_wlan "wlan2g" "WLAN2G" "blue:wlan2g" "phy0tpt" -@@ -61,6 +62,8 @@ qxwlan,e2600ac-c2) +@@ -69,6 +70,8 @@ qxwlan,e2600ac-c2) ucidef_set_led_wlan "wlan2g" "WLAN0" "green:wlan0" "phy0tpt" ucidef_set_led_wlan "wlan5g" "WLAN1" "green:wlan1" "phy1tpt" ;; @@ -121,10 +121,10 @@ index 3e0f3ab258..f9674126ba 100755 zyxel,wre6606) ucidef_set_led_wlan "wlan2g" "WLAN2G" "green:wlan2g" "phy0tpt" diff --git a/target/linux/ipq40xx/base-files/etc/board.d/02_network b/target/linux/ipq40xx/base-files/etc/board.d/02_network -index 8b7364ff33..dcdb790c84 100755 +index 1d4c78833a..d62a2e5061 100755 --- a/target/linux/ipq40xx/base-files/etc/board.d/02_network +++ b/target/linux/ipq40xx/base-files/etc/board.d/02_network -@@ -41,6 +41,7 @@ ipq40xx_setup_interfaces() +@@ -42,6 +42,7 @@ ipq40xx_setup_interfaces() ;; asus,map-ac2200|\ cilab,meshpoint-one|\ @@ -133,7 +133,7 @@ index 8b7364ff33..dcdb790c84 100755 edgecore,oap100|\ openmesh,a42|\ diff --git a/target/linux/ipq40xx/base-files/etc/hotplug.d/firmware/11-ath10k-caldata b/target/linux/ipq40xx/base-files/etc/hotplug.d/firmware/11-ath10k-caldata -index 6670d310db..5eae9c6e80 100644 +index b7ee73b12e..3948c08984 100644 --- a/target/linux/ipq40xx/base-files/etc/hotplug.d/firmware/11-ath10k-caldata +++ b/target/linux/ipq40xx/base-files/etc/hotplug.d/firmware/11-ath10k-caldata @@ -93,6 +93,10 @@ case "$FIRMWARE" in @@ -147,7 +147,7 @@ index 6670d310db..5eae9c6e80 100644 cellc,rtl30vw |\ compex,wpj419 |\ compex,wpj428 |\ -@@ -197,6 +201,10 @@ case "$FIRMWARE" in +@@ -202,6 +206,10 @@ case "$FIRMWARE" in caldata_extract "ART" 0x5000 0x2f20 ath10k_patch_mac $(mtd_get_mac_binary ORGDATA 0x2c) ;; @@ -589,10 +589,10 @@ index 0000000000..e75e35e8ef + +}; diff --git a/target/linux/ipq40xx/image/generic.mk b/target/linux/ipq40xx/image/generic.mk -index 4e40b8be50..1de17dd15a 100644 +index a435a127fa..31f4971c90 100644 --- a/target/linux/ipq40xx/image/generic.mk +++ b/target/linux/ipq40xx/image/generic.mk -@@ -273,6 +273,20 @@ define Device/cilab_meshpoint-one +@@ -271,6 +271,20 @@ define Device/cilab_meshpoint-one endef TARGET_DEVICES += cilab_meshpoint-one @@ -614,19 +614,19 @@ index 4e40b8be50..1de17dd15a 100644 $(call Device/FitImage) $(call Device/UbiFit) diff --git a/target/linux/ipq40xx/patches-5.4/901-arm-boot-add-dts-files.patch b/target/linux/ipq40xx/patches-5.4/901-arm-boot-add-dts-files.patch -index a3d3341587..aec0d01ed6 100644 +index 6b7c68bf63..aa2fc4bd17 100644 --- a/target/linux/ipq40xx/patches-5.4/901-arm-boot-add-dts-files.patch +++ b/target/linux/ipq40xx/patches-5.4/901-arm-boot-add-dts-files.patch @@ -10,7 +10,7 @@ Signed-off-by: John Crispin --- a/arch/arm/boot/dts/Makefile +++ b/arch/arm/boot/dts/Makefile --@@ -837,11 +837,58 @@ dtb-$(CONFIG_ARCH_QCOM) += \ -+@@ -837,11 +837,59 @@ dtb-$(CONFIG_ARCH_QCOM) += \ +-@@ -837,11 +837,60 @@ dtb-$(CONFIG_ARCH_QCOM) += \ ++@@ -837,11 +837,61 @@ dtb-$(CONFIG_ARCH_QCOM) += \ qcom-apq8074-dragonboard.dtb \ qcom-apq8084-ifc6540.dtb \ qcom-apq8084-mtp.dtb \ -@@ -43,6 +43,7 @@ Signed-off-by: John Crispin +@@ -45,6 +45,7 @@ Signed-off-by: John Crispin qcom-ipq4019-ap.dk07.1-c1.dtb \ qcom-ipq4019-ap.dk07.1-c2.dtb \ + qcom-ipq4019-a62.dtb \ diff --git a/patches/0030-base-files-add-a-turnoff-command-to-the-led-script.patch b/patches/0029-base-files-add-a-turnoff-command-to-the-led-script.patch similarity index 91% rename from patches/0030-base-files-add-a-turnoff-command-to-the-led-script.patch rename to patches/0029-base-files-add-a-turnoff-command-to-the-led-script.patch index f4e6ceab9..6f4c9de36 100644 --- a/patches/0030-base-files-add-a-turnoff-command-to-the-led-script.patch +++ b/patches/0029-base-files-add-a-turnoff-command-to-the-led-script.patch @@ -1,7 +1,7 @@ -From 5da505e5f59e93a8a6e928ad6c09a076f9889af1 Mon Sep 17 00:00:00 2001 +From bc2e9052af84664a2caae0581aa745d09240b160 Mon Sep 17 00:00:00 2001 From: John Crispin Date: Mon, 19 Apr 2021 13:49:20 +0200 -Subject: [PATCH 01/10] base-files: add a turnoff command to the led script +Subject: [PATCH 29/43] base-files: add a turnoff command to the led script Signed-off-by: John Crispin --- diff --git a/patches/0030-ath10k-ct-update-the-driver.patch b/patches/0030-ath10k-ct-update-the-driver.patch new file mode 100644 index 000000000..283ebe9c8 --- /dev/null +++ b/patches/0030-ath10k-ct-update-the-driver.patch @@ -0,0 +1,30 @@ +From ed5a8958378d84bba92a70f2a56a962be73c4b3b Mon Sep 17 00:00:00 2001 +From: John Crispin +Date: Fri, 23 Apr 2021 16:16:31 +0200 +Subject: [PATCH 30/43] ath10k-ct: update the driver + +Signed-off-by: John Crispin +--- + package/kernel/ath10k-ct/Makefile | 6 +++--- + 1 file changed, 3 insertions(+), 3 deletions(-) + +diff --git a/package/kernel/ath10k-ct/Makefile b/package/kernel/ath10k-ct/Makefile +index 5681c5c2cd..24e0702e2c 100644 +--- a/package/kernel/ath10k-ct/Makefile ++++ b/package/kernel/ath10k-ct/Makefile +@@ -8,9 +8,9 @@ PKG_LICENSE_FILES:= + + PKG_SOURCE_URL:=https://github.com/greearb/ath10k-ct.git + PKG_SOURCE_PROTO:=git +-PKG_SOURCE_DATE:=2021-06-03 +-PKG_SOURCE_VERSION:=b44cd7b2e7b0df5995ece18f358d4dfc40834ba1 +-PKG_MIRROR_HASH:=59f961ad425eb1a48fa9c391a325cc0f23845daec9d12673445d3077f9756cf0 ++PKG_SOURCE_DATE:=2021-04-23 ++PKG_SOURCE_VERSION:=8eca56d1514042b4af34004e0bbf69e40351d499 ++PKG_MIRROR_HASH:=4ce22470b0cd15cc3cb04478678407e976c48010baab517fa1ac37685b791d95 + + # Build the 5.10 ath10k-ct driver version. + # Probably this should match as closely as +-- +2.25.1 + diff --git a/patches/0031-ath10k-ct-update-the-driver.patch b/patches/0031-ath10k-ct-update-the-driver.patch deleted file mode 100644 index 8a5c98903..000000000 --- a/patches/0031-ath10k-ct-update-the-driver.patch +++ /dev/null @@ -1,75 +0,0 @@ -From 644f52a193d0430e41d6c28c221e801a0e87affa Mon Sep 17 00:00:00 2001 -From: John Crispin -Date: Fri, 23 Apr 2021 16:16:31 +0200 -Subject: [PATCH] ath10k-ct: update the driver - -Signed-off-by: John Crispin ---- - package/kernel/ath10k-ct/Makefile | 6 +-- - ...64-ath10k-commit-rates-from-mac80211.patch | 37 ------------------- - 2 files changed, 3 insertions(+), 40 deletions(-) - delete mode 100644 package/kernel/ath10k-ct/patches/164-ath10k-commit-rates-from-mac80211.patch - -diff --git a/package/kernel/ath10k-ct/Makefile b/package/kernel/ath10k-ct/Makefile -index a225bd8b19..8c2c36062d 100644 ---- a/package/kernel/ath10k-ct/Makefile -+++ b/package/kernel/ath10k-ct/Makefile -@@ -8,9 +8,9 @@ PKG_LICENSE_FILES:= - - PKG_SOURCE_URL:=https://github.com/greearb/ath10k-ct.git - PKG_SOURCE_PROTO:=git --PKG_SOURCE_DATE:=2021-01-11 --PKG_SOURCE_VERSION:=9fe1df7d4f783b6b0cd1c99d11979e5a6e6fc40b --PKG_MIRROR_HASH:=4e30e256716611045e930b95eadaa8bfcadd5bdd8bbe3869cfe0f377920e812b -+PKG_SOURCE_DATE:=2021-04-23 -+PKG_SOURCE_VERSION:=8eca56d1514042b4af34004e0bbf69e40351d499 -+PKG_MIRROR_HASH:=4ce22470b0cd15cc3cb04478678407e976c48010baab517fa1ac37685b791d95 - - # Build the 5.10 ath10k-ct driver version. - # Probably this should match as closely as -diff --git a/package/kernel/ath10k-ct/patches/164-ath10k-commit-rates-from-mac80211.patch b/package/kernel/ath10k-ct/patches/164-ath10k-commit-rates-from-mac80211.patch -deleted file mode 100644 -index 842f3ea2a5..0000000000 ---- a/package/kernel/ath10k-ct/patches/164-ath10k-commit-rates-from-mac80211.patch -+++ /dev/null -@@ -1,37 +0,0 @@ --From: Sven Eckelmann --Date: Tue, 26 Feb 2019 08:06:35 +0100 --Subject: ath10k-ct: apply mac80211 rates to ath10k-ct rate state -- --The rates from mac80211 have to be copied to the state of ath10k-ct or --otherwise the ath10k_check_apply_special_rates function overwrites --them again with some default values. This breaks for example the --mcast_rate set for a wifi-iface. -- --Signed-off-by: Sven Eckelmann -- ----- a/ath10k-5.10/mac.c --+++ b/ath10k-5.10/mac.c --@@ -6774,6 +6774,7 @@ static void ath10k_recalculate_mgmt_rate -- return; -- } -- --+ arvif->mgt_rate[def->chan->band] = hw_rate_code; -- vdev_param = ar->wmi.vdev_param->mgmt_rate; -- ret = ath10k_wmi_vdev_set_param(ar, arvif->vdev_id, vdev_param, -- hw_rate_code); --@@ -7000,6 +7001,7 @@ static void ath10k_bss_info_changed(stru -- "mac vdev %d mcast_rate %x\n", -- arvif->vdev_id, rate); -- --+ arvif->mcast_rate[band] = rate; -- vdev_param = ar->wmi.vdev_param->mcast_data_rate; -- ret = ath10k_wmi_vdev_set_param(ar, arvif->vdev_id, -- vdev_param, rate); --@@ -7008,6 +7010,7 @@ static void ath10k_bss_info_changed(stru -- "failed to set mcast rate on vdev %i: %d\n", -- arvif->vdev_id, ret); -- --+ arvif->bcast_rate[band] = rate; -- vdev_param = ar->wmi.vdev_param->bcast_data_rate; -- ret = ath10k_wmi_vdev_set_param(ar, arvif->vdev_id, -- vdev_param, rate); --- -2.25.1 - diff --git a/patches/0032-ipq40xx-add-tplink-ec420-support.patch b/patches/0031-ipq40xx-add-tplink-ec420-support.patch similarity index 99% rename from patches/0032-ipq40xx-add-tplink-ec420-support.patch rename to patches/0031-ipq40xx-add-tplink-ec420-support.patch index 9ca0c17b0..fd4be5e4b 100644 --- a/patches/0032-ipq40xx-add-tplink-ec420-support.patch +++ b/patches/0031-ipq40xx-add-tplink-ec420-support.patch @@ -1,7 +1,7 @@ -From fa71a84201e148d5eb9c36cb7acb9d9d2fa8fca9 Mon Sep 17 00:00:00 2001 +From 0f91fe9eea8820e68b3d754e768a673ed165b3ce Mon Sep 17 00:00:00 2001 From: John Crispin -Date: Fri, 18 Jun 2021 11:07:02 +0200 -Subject: [PATCH 1/7] ipq40xx: add tplink ec420 support +Date: Sat, 4 Sep 2021 05:59:39 +0200 +Subject: [PATCH 31/43] ipq40xx: add tplink ec420 support Signed-off-by: John Crispin --- @@ -34,10 +34,10 @@ index b24cbf979e..44a8688dbe 100644 ubootenv_add_uci_config "/dev/mtd6" "0x0" "0x10000" "0x10000" ;; diff --git a/package/firmware/ipq-wifi/Makefile b/package/firmware/ipq-wifi/Makefile -index 513ad4ea67..87dcf9a769 100644 +index b996ee311f..c9d113ae6a 100644 --- a/package/firmware/ipq-wifi/Makefile +++ b/package/firmware/ipq-wifi/Makefile -@@ -48,7 +48,8 @@ ALLWIFIBOARDS:= \ +@@ -50,7 +50,8 @@ ALLWIFIBOARDS:= \ plasmacloud_pa1200 \ plasmacloud_pa2200 \ qxwlan_e2600ac \ @@ -47,7 +47,7 @@ index 513ad4ea67..87dcf9a769 100644 ALLWIFIPACKAGES:=$(foreach BOARD,$(ALLWIFIBOARDS),ipq-wifi-$(BOARD)) -@@ -133,5 +134,6 @@ $(eval $(call generate-ipq-wifi-package,plasmacloud_pa1200,Plasma Cloud PA1200)) +@@ -137,5 +138,6 @@ $(eval $(call generate-ipq-wifi-package,plasmacloud_pa1200,Plasma Cloud PA1200)) $(eval $(call generate-ipq-wifi-package,plasmacloud_pa2200,Plasma Cloud PA2200)) $(eval $(call generate-ipq-wifi-package,qxwlan_e2600ac,Qxwlan E2600AC)) $(eval $(call generate-ipq-wifi-package,cig_wf610d,CIG WF_610D)) @@ -1095,11 +1095,11 @@ literal 0 HcmV?d00001 diff --git a/target/linux/ipq40xx/base-files/etc/board.d/02_network b/target/linux/ipq40xx/base-files/etc/board.d/02_network -index 597fa9f08b..238376afca 100755 +index d62a2e5061..16f6040b6e 100755 --- a/target/linux/ipq40xx/base-files/etc/board.d/02_network +++ b/target/linux/ipq40xx/base-files/etc/board.d/02_network -@@ -31,8 +31,9 @@ ipq40xx_setup_interfaces() - meraki,mr33|\ +@@ -32,8 +32,9 @@ ipq40xx_setup_interfaces() + mikrotik,sxtsq-5-ac|\ netgear,ex6100v2|\ netgear,ex6150v2|\ + tp-link,ec420-g1|\ @@ -1110,7 +1110,7 @@ index 597fa9f08b..238376afca 100755 aruba,ap-303h) ucidef_set_interfaces_lan_wan "eth0" "eth1" diff --git a/target/linux/ipq40xx/base-files/etc/hotplug.d/firmware/11-ath10k-caldata b/target/linux/ipq40xx/base-files/etc/hotplug.d/firmware/11-ath10k-caldata -index 5eae9c6e80..8d3006381d 100644 +index 3948c08984..c8943d3ba3 100644 --- a/target/linux/ipq40xx/base-files/etc/hotplug.d/firmware/11-ath10k-caldata +++ b/target/linux/ipq40xx/base-files/etc/hotplug.d/firmware/11-ath10k-caldata @@ -46,6 +46,9 @@ case "$FIRMWARE" in @@ -1123,7 +1123,7 @@ index 5eae9c6e80..8d3006381d 100644 esac ;; "ath10k/pre-cal-ahb-a000000.wifi.bin") -@@ -154,6 +157,9 @@ case "$FIRMWARE" in +@@ -159,6 +162,9 @@ case "$FIRMWARE" in caldata_extract "ART" 0x1000 0x2f20 ath10k_patch_mac $(macaddr_add $(cat /sys/class/net/eth0/address) -2) ;; @@ -1133,7 +1133,7 @@ index 5eae9c6e80..8d3006381d 100644 esac ;; "ath10k/pre-cal-ahb-a800000.wifi.bin") -@@ -262,11 +268,6 @@ case "$FIRMWARE" in +@@ -273,11 +279,6 @@ case "$FIRMWARE" in caldata_extract "ART" 0x5000 0x2f20 ath10k_patch_mac $(macaddr_add $(cat /sys/class/net/eth0/address) -1) ;; @@ -1146,7 +1146,7 @@ index 5eae9c6e80..8d3006381d 100644 ;; *) diff --git a/target/linux/ipq40xx/base-files/lib/upgrade/platform.sh b/target/linux/ipq40xx/base-files/lib/upgrade/platform.sh -index 5582696759..530545e442 100644 +index 54683977cd..cbdd12c750 100644 --- a/target/linux/ipq40xx/base-files/lib/upgrade/platform.sh +++ b/target/linux/ipq40xx/base-files/lib/upgrade/platform.sh @@ -72,7 +72,8 @@ platform_do_upgrade() { @@ -1441,10 +1441,10 @@ index 0000000000..9f6fdd5e76 +}; + diff --git a/target/linux/ipq40xx/image/generic.mk b/target/linux/ipq40xx/image/generic.mk -index 487bba77b0..860b5e03bf 100644 +index 31f4971c90..ec3e779a44 100644 --- a/target/linux/ipq40xx/image/generic.mk +++ b/target/linux/ipq40xx/image/generic.mk -@@ -820,3 +820,18 @@ define Device/zyxel_wre6606 +@@ -816,3 +816,18 @@ define Device/zyxel_wre6606 DEVICE_PACKAGES := -kmod-ath10k-ct kmod-ath10k-ct-smallbuffers endef TARGET_DEVICES += zyxel_wre6606 diff --git a/patches/0033-ipq806x-update-to-latest-HEAD.patch b/patches/0032-ipq806x-update-to-latest-HEAD.patch similarity index 99% rename from patches/0033-ipq806x-update-to-latest-HEAD.patch rename to patches/0032-ipq806x-update-to-latest-HEAD.patch index 6875f054f..71c236267 100644 --- a/patches/0033-ipq806x-update-to-latest-HEAD.patch +++ b/patches/0032-ipq806x-update-to-latest-HEAD.patch @@ -1,16 +1,15 @@ -From f50e63e5eb4a8b3a15985183c337301f87e5b6ed Mon Sep 17 00:00:00 2001 +From a16429d604a6c2cff7b2791e380fc57827485f03 Mon Sep 17 00:00:00 2001 From: John Crispin -Date: Wed, 18 Aug 2021 12:13:29 +0200 -Subject: [PATCH] ipq806x: update to latest HEAD +Date: Sat, 4 Sep 2021 06:01:17 +0200 +Subject: [PATCH 32/43] ipq806x: update to latest HEAD Signed-off-by: John Crispin --- target/linux/ipq806x/Makefile | 1 + .../ipq806x/base-files/etc/board.d/01_leds | 1 - - .../ipq806x/base-files/etc/board.d/02_network | 22 +- + .../ipq806x/base-files/etc/board.d/02_network | 17 +- .../etc/hotplug.d/firmware/11-ath10k-caldata | 58 +- .../ipq806x/base-files/etc/init.d/bootcount | 7 +- - .../ipq806x/base-files/etc/init.d/cpufreq | 17 + .../base-files/lib/preinit/04_reorder_eth | 13 + .../ipq806x/base-files/lib/upgrade/asrock.sh | 4 +- .../base-files/lib/upgrade/platform.sh | 19 +- @@ -93,7 +92,6 @@ Signed-off-by: John Crispin ...-dt-Add-L2-frequency-scaling-support.patch | 199 ---- ...056-cpufreq-dt-Add-missing-rcu-locks.patch | 23 - ...conflicts-with-OpenWrt-auto-mounting.patch | 23 - - ...sens-support-configurable-interrupts.patch | 2 +- .../0069-arm-boot-add-dts-files.patch | 3 +- .../083-ipq8064-dtsi-additions.patch | 84 +- ...qcom-cpufreq-nvmem-support-specific-.patch | 51 + @@ -106,8 +104,7 @@ Signed-off-by: John Crispin ...conflicts-with-OpenWrt-auto-mounting.patch | 24 + .../patches-5.4/851-add-gsbi1-dts.patch | 2 +- .../linux/ipq806x/patches-5.4/999-at803.patch | 12 - - 101 files changed, 9212 insertions(+), 1367 deletions(-) - create mode 100755 target/linux/ipq806x/base-files/etc/init.d/cpufreq + 99 files changed, 9190 insertions(+), 1365 deletions(-) create mode 100644 target/linux/ipq806x/base-files/lib/preinit/04_reorder_eth create mode 100644 target/linux/ipq806x/config-5.10 create mode 100644 target/linux/ipq806x/files/arch/arm/boot/dts/qcom-ipq8065-rt4230w-rev6.dts @@ -194,7 +191,7 @@ index 284f9e2c1d..74b94a29b4 100755 # Copyright (C) 2015 OpenWrt.org # diff --git a/target/linux/ipq806x/base-files/etc/board.d/02_network b/target/linux/ipq806x/base-files/etc/board.d/02_network -index ddef4b7ac6..1a1cec51aa 100755 +index 1e00b97092..1a1cec51aa 100755 --- a/target/linux/ipq806x/base-files/etc/board.d/02_network +++ b/target/linux/ipq806x/base-files/etc/board.d/02_network @@ -1,4 +1,3 @@ @@ -227,23 +224,7 @@ index ddef4b7ac6..1a1cec51aa 100755 ;; linksys,ea7500-v1) hw_mac_addr=$(mtd_get_mac_ascii devinfo hw_mac_addr) -@@ -51,7 +57,6 @@ nec,wg2600hp3) - "2:lan" "3:lan" "4:lan" "5:lan" "0@eth1" "1:wan" "6@eth0" - ;; - netgear,r7800 |\ --tplink,ad7200 |\ - tplink,c2600) - ucidef_add_switch "switch0" \ - "1:lan:4" "2:lan:3" "3:lan:2" "4:lan:1" "6@eth1" "5:wan" "0@eth0" -@@ -66,11 +71,18 @@ qcom,ipq8064-db149) - ucidef_add_switch "switch0" \ - "1:lan" "2:lan" "3:lan" "4:lan" "6u@eth1" "5:wan" "0u@eth0" - ;; -+tplink,ad7200) -+ ucidef_add_switch "switch0" \ -+ "2:lan:1" "3:lan:2" "4:lan:3" "5:lan:4" "6@eth1" "1:wan" "0@eth0" -+ ;; - ubnt,unifi-ac-hd) +@@ -73,7 +79,10 @@ ubnt,unifi-ac-hd) ucidef_set_interface_lan "eth0 eth1" ;; zyxel,nbg6817) @@ -404,29 +385,6 @@ index 7a54c34dba..cb32a4ed35 100755 ;; edgecore,ecw5410) fw_setenv bootcount 0 -diff --git a/target/linux/ipq806x/base-files/etc/init.d/cpufreq b/target/linux/ipq806x/base-files/etc/init.d/cpufreq -new file mode 100755 -index 0000000000..19278902ed ---- /dev/null -+++ b/target/linux/ipq806x/base-files/etc/init.d/cpufreq -@@ -0,0 +1,17 @@ -+#!/bin/sh /etc/rc.common -+ -+START=15 -+ -+boot() { -+ local governor -+ -+ governor=$(cat /sys/devices/system/cpu/cpufreq/policy0/scaling_governor) -+ -+ if [ "$governor" = "ondemand" ]; then -+ # Effective only with ondemand -+ echo 600000 > /sys/devices/system/cpu/cpufreq/policy0/scaling_min_freq -+ echo 600000 > /sys/devices/system/cpu/cpufreq/policy1/scaling_min_freq -+ echo 10 > /sys/devices/system/cpu/cpufreq/ondemand/sampling_down_factor -+ echo 50 > /sys/devices/system/cpu/cpufreq/ondemand/up_threshold -+ fi -+} diff --git a/target/linux/ipq806x/base-files/lib/preinit/04_reorder_eth b/target/linux/ipq806x/base-files/lib/preinit/04_reorder_eth new file mode 100644 index 0000000000..9f58473617 @@ -6662,7 +6620,7 @@ diff --git a/target/linux/ipq806x/patches-5.4/0002-dmaengine-Add-ADM-driver.patc similarity index 82% rename from target/linux/ipq806x/patches-5.4/0002-dmaengine-Add-ADM-driver.patch rename to target/linux/ipq806x/patches-5.10/100-v5.11-dmaengine-qcom-add_ADM_driver.patch -index aa7d2e791e..2d24da01e4 100644 +index 7aa46526f2..2d24da01e4 100644 --- a/target/linux/ipq806x/patches-5.4/0002-dmaengine-Add-ADM-driver.patch +++ b/target/linux/ipq806x/patches-5.10/100-v5.11-dmaengine-qcom-add_ADM_driver.patch @@ -1,86 +1,88 @@ @@ -6714,7 +6672,7 @@ index aa7d2e791e..2d24da01e4 100644 --- a/drivers/dma/qcom/Kconfig +++ b/drivers/dma/qcom/Kconfig --@@ -28,3 +28,13 @@ config QCOM_HIDMA +-@@ -29,3 +29,13 @@ config QCOM_HIDMA - (user to kernel, kernel to kernel, etc.). It only supports - memcpy interface. The core is not intended for general - purpose slave DMA. @@ -9874,19 +9832,6 @@ index ff6f6edf49..0000000000 - /* - * The last SMEM partition may have its size marked as - * something like 0xffffffff, which means "until the end of the -diff --git a/target/linux/ipq806x/patches-5.4/0063-2-tsens-support-configurable-interrupts.patch b/target/linux/ipq806x/patches-5.4/0063-2-tsens-support-configurable-interrupts.patch -index 585bd62a58..54488f25a8 100644 ---- a/target/linux/ipq806x/patches-5.4/0063-2-tsens-support-configurable-interrupts.patch -+++ b/target/linux/ipq806x/patches-5.4/0063-2-tsens-support-configurable-interrupts.patch -@@ -163,7 +163,7 @@ Signed-off-by: Rajith Cherian - mutex_unlock(&tzd->lock); - - return tzd; --@@ -762,7 +802,10 @@ static const char * const trip_types[] = -+@@ -765,7 +805,10 @@ static const char * const trip_types[] = - [THERMAL_TRIP_ACTIVE] = "active", - [THERMAL_TRIP_PASSIVE] = "passive", - [THERMAL_TRIP_HOT] = "hot", diff --git a/target/linux/ipq806x/patches-5.4/0069-arm-boot-add-dts-files.patch b/target/linux/ipq806x/patches-5.4/0069-arm-boot-add-dts-files.patch index 055a4cbc30..b97d36fd7c 100644 --- a/target/linux/ipq806x/patches-5.4/0069-arm-boot-add-dts-files.patch diff --git a/patches/0034-feeds.conf.default-drop-luci.patch b/patches/0033-feeds.conf.default-drop-luci.patch similarity index 86% rename from patches/0034-feeds.conf.default-drop-luci.patch rename to patches/0033-feeds.conf.default-drop-luci.patch index 9870f674c..c0742997e 100644 --- a/patches/0034-feeds.conf.default-drop-luci.patch +++ b/patches/0033-feeds.conf.default-drop-luci.patch @@ -1,7 +1,7 @@ -From 1a20d4d44bf4601fef37aaf0e9f12d1bee89a022 Mon Sep 17 00:00:00 2001 +From a53506fd073dd451840c3c1974e579a8861f9205 Mon Sep 17 00:00:00 2001 From: John Crispin Date: Tue, 4 May 2021 16:48:48 +0200 -Subject: [PATCH] feeds.conf.default: drop luci +Subject: [PATCH 33/43] feeds.conf.default: drop luci we require luci-trunk for the gateway images. diff --git a/patches/0034-ath79-various-fixes.patch b/patches/0034-ath79-various-fixes.patch new file mode 100644 index 000000000..ab9786a09 --- /dev/null +++ b/patches/0034-ath79-various-fixes.patch @@ -0,0 +1,38 @@ +From 83b7e4074c238cb64f727cde16cdfcc530aaa329 Mon Sep 17 00:00:00 2001 +From: John Crispin +Date: Sat, 8 May 2021 11:30:32 +0200 +Subject: [PATCH 34/43] ath79: various fixes + +* free up additional 1MB rootfs space +* make the target use bridge-vlan +* use the single eth port as wan + +Signed-off-by: John Crispin +--- + target/linux/ath79/generic/base-files/etc/board.d/02_network | 3 ++- + 1 file changed, 2 insertions(+), 1 deletion(-) + +diff --git a/target/linux/ath79/generic/base-files/etc/board.d/02_network b/target/linux/ath79/generic/base-files/etc/board.d/02_network +index d70432ad2b..b0b152ba74 100755 +--- a/target/linux/ath79/generic/base-files/etc/board.d/02_network ++++ b/target/linux/ath79/generic/base-files/etc/board.d/02_network +@@ -95,7 +95,7 @@ ath79_setup_interfaces() + ubnt,unifi|\ + wd,mynet-wifi-rangeextender|\ + winchannel,wb2000) +- ucidef_set_interface_lan "eth0" ++ ucidef_set_interface_wan "eth0" + ;; + airtight,c-75) + ucidef_add_switch "switch0" \ +@@ -675,6 +675,7 @@ ath79_setup_macs() + + board_config_update + board=$(board_name) ++ucidef_set_bridge_device bridge + ath79_setup_interfaces $board + ath79_setup_macs $board + board_config_flush +-- +2.25.1 + diff --git a/patches/0035-ath79-various-fixes.patch b/patches/0035-ath79-various-fixes.patch deleted file mode 100644 index a2b9a2028..000000000 --- a/patches/0035-ath79-various-fixes.patch +++ /dev/null @@ -1,88 +0,0 @@ -From 167c998efc5ba755bafc1aca1bf68d9e694e4c10 Mon Sep 17 00:00:00 2001 -From: John Crispin -Date: Sat, 8 May 2021 11:30:32 +0200 -Subject: [PATCH] ath79: various fixes - -* free up additional 1MB rootfs space -* make the target use bridge-vlan -* use the single eth port as wan - -Signed-off-by: John Crispin ---- - target/linux/ath79/dts/ar9344_tplink_cpe.dtsi | 20 ++++++++----------- - .../generic/base-files/etc/board.d/02_network | 3 ++- - tools/firmware-utils/src/tplink-safeloader.c | 4 ++-- - 3 files changed, 12 insertions(+), 15 deletions(-) - -diff --git a/target/linux/ath79/dts/ar9344_tplink_cpe.dtsi b/target/linux/ath79/dts/ar9344_tplink_cpe.dtsi -index d4b7de440a..c5ab963174 100644 ---- a/target/linux/ath79/dts/ar9344_tplink_cpe.dtsi -+++ b/target/linux/ath79/dts/ar9344_tplink_cpe.dtsi -@@ -59,20 +59,16 @@ - partition@40000 { - label = "firmware"; - reg = <0x040000 0x780000>; -+ }; - -- compatible = "fixed-partitions"; -- #address-cells = <1>; -- #size-cells = <1>; -- -- partition@0 { -- label = "kernel"; -- reg = <0x000000 0x300000>; -- }; -+ partition@040000 { -+ label = "kernel"; -+ reg = <0x040000 0x210000>; -+ }; - -- partition@300000 { -- label = "rootfs"; -- reg = <0x300000 0x480000>; -- }; -+ partition@340000 { -+ label = "rootfs"; -+ reg = <0x250000 0x560000>; - }; - - partition@7c0000 { -diff --git a/target/linux/ath79/generic/base-files/etc/board.d/02_network b/target/linux/ath79/generic/base-files/etc/board.d/02_network -index 1e522b91c6..b8bc38348e 100755 ---- a/target/linux/ath79/generic/base-files/etc/board.d/02_network -+++ b/target/linux/ath79/generic/base-files/etc/board.d/02_network -@@ -94,7 +94,7 @@ ath79_setup_interfaces() - ubnt,unifi|\ - wd,mynet-wifi-rangeextender|\ - winchannel,wb2000) -- ucidef_set_interface_lan "eth0" -+ ucidef_set_interface_wan "eth0" - ;; - airtight,c-75) - ucidef_add_switch "switch0" \ -@@ -669,6 +669,7 @@ ath79_setup_macs() - - board_config_update - board=$(board_name) -+ucidef_set_bridge_device bridge - ath79_setup_interfaces $board - ath79_setup_macs $board - board_config_flush -diff --git a/tools/firmware-utils/src/tplink-safeloader.c b/tools/firmware-utils/src/tplink-safeloader.c -index ac71b3305e..2bc4a3cb82 100644 ---- a/tools/firmware-utils/src/tplink-safeloader.c -+++ b/tools/firmware-utils/src/tplink-safeloader.c -@@ -443,8 +443,8 @@ static struct device_info boards[] = { - {"default-mac", 0x30000, 0x00020}, - {"product-info", 0x31100, 0x00100}, - {"signature", 0x32000, 0x00400}, -- {"os-image", 0x40000, 0x300000}, -- {"file-system", 0x340000, 0x470000}, -+ {"os-image", 0x40000, 0x210000}, -+ {"file-system", 0x250000, 0x560000}, - {"soft-version", 0x7b0000, 0x00100}, - {"support-list", 0x7b1000, 0x00400}, - {"user-config", 0x7c0000, 0x10000}, --- -2.25.1 - diff --git a/patches/0036-certificates-add-ability-to-persistently-store-certi.patch b/patches/0035-certificates-add-ability-to-persistently-store-certi.patch similarity index 60% rename from patches/0036-certificates-add-ability-to-persistently-store-certi.patch rename to patches/0035-certificates-add-ability-to-persistently-store-certi.patch index 51d38c47a..300234437 100644 --- a/patches/0036-certificates-add-ability-to-persistently-store-certi.patch +++ b/patches/0035-certificates-add-ability-to-persistently-store-certi.patch @@ -1,16 +1,15 @@ -From 6d0385f31cc4f19df8fc51b56bb08af7c9c0922a Mon Sep 17 00:00:00 2001 +From ee837f028bd7af515d30a8a90cc2b5ee61eecf19 Mon Sep 17 00:00:00 2001 From: John Crispin -Date: Sun, 23 May 2021 09:59:53 +0200 -Subject: [PATCH 07/11] certificates: add ability to persistently store +Date: Sat, 4 Sep 2021 06:04:54 +0200 +Subject: [PATCH 35/43] certificates: add ability to persistently store certificates Signed-off-by: John Crispin --- - target/linux/ath79/dts/qca9563_tplink_cpe710-v1.dts | 7 ++++++- - .../files/arch/arm/boot/dts/qcom-ipq4019-xx8300.dtsi | 3 +-- - .../linux/ramips/dts/mt7628an_tplink_8m-split-uboot.dtsi | 7 ++++++- - .../linux/realtek/dts/rtl8392_edgecore_ecs4100-12ph.dts | 8 ++++++-- - 4 files changed, 19 insertions(+), 6 deletions(-) + target/linux/ath79/dts/qca9563_tplink_cpe710-v1.dts | 7 ++++++- + .../files/arch/arm/boot/dts/qcom-ipq4019-xx8300.dtsi | 3 +-- + .../linux/ramips/dts/mt7628an_tplink_8m-split-uboot.dtsi | 7 ++++++- + 3 files changed, 13 insertions(+), 4 deletions(-) diff --git a/target/linux/ath79/dts/qca9563_tplink_cpe710-v1.dts b/target/linux/ath79/dts/qca9563_tplink_cpe710-v1.dts index 830c3d30b8..71c6381f86 100644 @@ -63,28 +62,6 @@ index b6ce7b1f56..471be72001 100644 }; partition@7c0000 { -diff --git a/target/linux/realtek/dts/rtl8392_edgecore_ecs4100-12ph.dts b/target/linux/realtek/dts/rtl8392_edgecore_ecs4100-12ph.dts -index 303b79ac83..7a228aea86 100644 ---- a/target/linux/realtek/dts/rtl8392_edgecore_ecs4100-12ph.dts -+++ b/target/linux/realtek/dts/rtl8392_edgecore_ecs4100-12ph.dts -@@ -176,11 +176,15 @@ - reg = <0x100000 0x100000>; - read-only; - }; -- partition@b260000 { -+ partition@200000 { - label = "firmware"; -- reg = <0x200000 0xe00000>; -+ reg = <0x200000 0xdf0000>; - compatible = "openwrt,uimage", "denx,uimage"; - }; -+ partition@ff0000 { -+ label = "certificates"; -+ reg = <0xff0000 0x10000>; -+ }; - }; - }; - }; -- 2.25.1 diff --git a/patches/0037-ipq4018-add-EdgeCore-SPW2AC1200-support.patch b/patches/0036-ipq4018-add-EdgeCore-SPW2AC1200-support.patch similarity index 93% rename from patches/0037-ipq4018-add-EdgeCore-SPW2AC1200-support.patch rename to patches/0036-ipq4018-add-EdgeCore-SPW2AC1200-support.patch index 66aac5c96..27fa74952 100644 --- a/patches/0037-ipq4018-add-EdgeCore-SPW2AC1200-support.patch +++ b/patches/0036-ipq4018-add-EdgeCore-SPW2AC1200-support.patch @@ -1,7 +1,7 @@ -From c651355c099a42c12f1953f4d027b32172a45bbb Mon Sep 17 00:00:00 2001 +From f7eed3ee6f7bb086a9bc0e049cc411d1bc98ed33 Mon Sep 17 00:00:00 2001 From: John Crispin -Date: Thu, 1 Jul 2021 16:37:24 +0200 -Subject: [PATCH] ipq4018: add EdgeCore SPW2AC1200 support +Date: Sat, 4 Sep 2021 06:15:19 +0200 +Subject: [PATCH 36/43] ipq4018: add EdgeCore SPW2AC1200 support Signed-off-by: John Crispin --- @@ -17,7 +17,7 @@ Signed-off-by: John Crispin create mode 100644 target/linux/ipq40xx/files/arch/arm/boot/dts/qcom-ipq4018-spw2ac1200.dts diff --git a/package/boot/uboot-envtools/files/ipq40xx b/package/boot/uboot-envtools/files/ipq40xx -index b24cbf979e..ac66a7f2bd 100644 +index 44a8688dbe..ab489a6e18 100644 --- a/package/boot/uboot-envtools/files/ipq40xx +++ b/package/boot/uboot-envtools/files/ipq40xx @@ -34,6 +34,7 @@ case "$board" in @@ -29,10 +29,10 @@ index b24cbf979e..ac66a7f2bd 100644 glinet,gl-b1300 |\ luma,wrtq-329acn |\ diff --git a/target/linux/ipq40xx/base-files/etc/board.d/01_leds b/target/linux/ipq40xx/base-files/etc/board.d/01_leds -index f9674126ba..efd5d002db 100755 +index c1d4e693f2..d473448137 100755 --- a/target/linux/ipq40xx/base-files/etc/board.d/01_leds +++ b/target/linux/ipq40xx/base-files/etc/board.d/01_leds -@@ -63,6 +63,7 @@ qxwlan,e2600ac-c2) +@@ -71,6 +71,7 @@ qxwlan,e2600ac-c2) ucidef_set_led_wlan "wlan5g" "WLAN1" "green:wlan1" "phy1tpt" ;; edgecore,ecw5211 |\ @@ -41,10 +41,10 @@ index f9674126ba..efd5d002db 100755 zyxel,nbg6617 |\ zyxel,wre6606) diff --git a/target/linux/ipq40xx/base-files/etc/board.d/02_network b/target/linux/ipq40xx/base-files/etc/board.d/02_network -index 597fa9f08b..7bc8c5e6aa 100755 +index 16f6040b6e..0240798bbb 100755 --- a/target/linux/ipq40xx/base-files/etc/board.d/02_network +++ b/target/linux/ipq40xx/base-files/etc/board.d/02_network -@@ -43,6 +43,7 @@ ipq40xx_setup_interfaces() +@@ -45,6 +45,7 @@ ipq40xx_setup_interfaces() cilab,meshpoint-one|\ cig,wf610d|\ edgecore,ecw5211|\ @@ -53,10 +53,10 @@ index 597fa9f08b..7bc8c5e6aa 100755 openmesh,a42|\ openmesh,a62) diff --git a/target/linux/ipq40xx/base-files/etc/hotplug.d/firmware/11-ath10k-caldata b/target/linux/ipq40xx/base-files/etc/hotplug.d/firmware/11-ath10k-caldata -index a9bbc791b8..da7931d018 100644 +index c8943d3ba3..ad2946f636 100644 --- a/target/linux/ipq40xx/base-files/etc/hotplug.d/firmware/11-ath10k-caldata +++ b/target/linux/ipq40xx/base-files/etc/hotplug.d/firmware/11-ath10k-caldata -@@ -101,6 +101,7 @@ case "$FIRMWARE" in +@@ -104,6 +104,7 @@ case "$FIRMWARE" in compex,wpj419 |\ compex,wpj428 |\ edgecore,ecw5211 |\ @@ -64,7 +64,7 @@ index a9bbc791b8..da7931d018 100644 edgecore,oap100 |\ engenius,eap1300 |\ engenius,eap2200 |\ -@@ -212,6 +213,7 @@ case "$FIRMWARE" in +@@ -220,6 +221,7 @@ case "$FIRMWARE" in compex,wpj419 |\ compex,wpj428 |\ edgecore,ecw5211 |\ @@ -73,7 +73,7 @@ index a9bbc791b8..da7931d018 100644 engenius,eap1300 |\ engenius,eap2200 |\ diff --git a/target/linux/ipq40xx/base-files/lib/upgrade/platform.sh b/target/linux/ipq40xx/base-files/lib/upgrade/platform.sh -index 530545e442..f6fc828134 100644 +index cbdd12c750..84abd181dc 100644 --- a/target/linux/ipq40xx/base-files/lib/upgrade/platform.sh +++ b/target/linux/ipq40xx/base-files/lib/upgrade/platform.sh @@ -76,7 +76,9 @@ platform_do_upgrade() { @@ -426,10 +426,10 @@ index 0000000000..a152ba57f4 + status = "okay"; +}; diff --git a/target/linux/ipq40xx/image/generic.mk b/target/linux/ipq40xx/image/generic.mk -index ee648edc50..e4e437bb95 100644 +index ec3e779a44..4448ed6083 100644 --- a/target/linux/ipq40xx/image/generic.mk +++ b/target/linux/ipq40xx/image/generic.mk -@@ -376,6 +376,19 @@ define Device/edgecore_ecw5211 +@@ -374,6 +374,19 @@ define Device/edgecore_ecw5211 endef TARGET_DEVICES += edgecore_ecw5211 @@ -450,15 +450,15 @@ index ee648edc50..e4e437bb95 100644 $(call Device/FitImage) $(call Device/UbiFit) diff --git a/target/linux/ipq40xx/patches-5.4/901-arm-boot-add-dts-files.patch b/target/linux/ipq40xx/patches-5.4/901-arm-boot-add-dts-files.patch -index aec0d01ed6..492cc67b2c 100644 +index aa2fc4bd17..ae0b8f2025 100644 --- a/target/linux/ipq40xx/patches-5.4/901-arm-boot-add-dts-files.patch +++ b/target/linux/ipq40xx/patches-5.4/901-arm-boot-add-dts-files.patch @@ -10,7 +10,7 @@ Signed-off-by: John Crispin --- a/arch/arm/boot/dts/Makefile +++ b/arch/arm/boot/dts/Makefile --@@ -837,11 +837,59 @@ dtb-$(CONFIG_ARCH_QCOM) += \ -+@@ -837,11 +837,60 @@ dtb-$(CONFIG_ARCH_QCOM) += \ +-@@ -837,11 +837,61 @@ dtb-$(CONFIG_ARCH_QCOM) += \ ++@@ -837,11 +837,62 @@ dtb-$(CONFIG_ARCH_QCOM) += \ qcom-apq8074-dragonboard.dtb \ qcom-apq8084-ifc6540.dtb \ qcom-apq8084-mtp.dtb \ diff --git a/patches/0037-Revert-libusb-update-to-1.0.24.patch b/patches/0037-Revert-libusb-update-to-1.0.24.patch new file mode 100644 index 000000000..0875da753 --- /dev/null +++ b/patches/0037-Revert-libusb-update-to-1.0.24.patch @@ -0,0 +1,141 @@ +From 0cb58169aa1f1b29c0c713469bdc7b352cdf85f3 Mon Sep 17 00:00:00 2001 +From: John Crispin +Date: Fri, 2 Jul 2021 12:02:04 +0200 +Subject: [PATCH 21/27] Revert "libusb: update to 1.0.24" + +This reverts commit 0798b13d7df0deafd005b14d52420c4f480d146e. +--- + package/libs/libusb/Makefile | 6 +- + ...n-the-Changelog-and-clean-up-a-stray.patch | 29 --------- + ...parsing-of-descriptors-for-multi-con.patch | 61 ------------------- + 3 files changed, 3 insertions(+), 93 deletions(-) + delete mode 100644 package/libs/libusb/patches/001-Correct-a-typo-in-the-Changelog-and-clean-up-a-stray.patch + delete mode 100644 package/libs/libusb/patches/002-linux_usbfs-Fix-parsing-of-descriptors-for-multi-con.patch + +diff --git a/package/libs/libusb/Makefile b/package/libs/libusb/Makefile +index 6b80b3848d..1667fb2840 100644 +--- a/package/libs/libusb/Makefile ++++ b/package/libs/libusb/Makefile +@@ -8,14 +8,14 @@ + include $(TOPDIR)/rules.mk + + PKG_NAME:=libusb +-PKG_VERSION:=1.0.24 +-PKG_RELEASE:=$(AUTORELEASE) ++PKG_VERSION:=1.0.22 ++PKG_RELEASE:=2 + + PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2 + PKG_SOURCE_URL:=\ + https://github.com/libusb/libusb/releases/download/v$(PKG_VERSION) \ + @SF/$(PKG_NAME) +-PKG_HASH:=7efd2685f7b327326dcfb85cee426d9b871fd70e22caa15bb68d595ce2a2b12a ++PKG_HASH:=75aeb9d59a4fdb800d329a545c2e6799f732362193b465ea198f2aa275518157 + + PKG_MAINTAINER:= Felix Fietkau + PKG_LICENSE:=LGPL-2.1-or-later +diff --git a/package/libs/libusb/patches/001-Correct-a-typo-in-the-Changelog-and-clean-up-a-stray.patch b/package/libs/libusb/patches/001-Correct-a-typo-in-the-Changelog-and-clean-up-a-stray.patch +deleted file mode 100644 +index b17d6178d3..0000000000 +--- a/package/libs/libusb/patches/001-Correct-a-typo-in-the-Changelog-and-clean-up-a-stray.patch ++++ /dev/null +@@ -1,29 +0,0 @@ +-From 369af149e3ad92514a2d24f112cedfeb7acaf558 Mon Sep 17 00:00:00 2001 +-From: Chris Dickens +-Date: Sun, 13 Dec 2020 15:46:27 -0800 +-Subject: [PATCH] Correct a typo in the Changelog and clean up a stray file +- +-Signed-off-by: Chris Dickens +---- +- ChangeLog | 2 +- +- libusb/version_nano.h | 2 +- +- test | 0 +- 3 files changed, 2 insertions(+), 2 deletions(-) +- delete mode 100644 test +- +---- a/ChangeLog +-+++ b/ChangeLog +-@@ -12,7 +12,7 @@ visit: http://log.libusb.info +- * Darwin (macOS): use IOUSBDevice as darwin_device_class explicitly (#693) +- * Linux: Drop support for kernel older than 2.6.32 +- * Linux: Provide an event thread name (#689) +--* Linux: Wait until all USBs have been reaped before freeing them (#607) +-+* Linux: Wait until all URBs have been reaped before freeing them (#607) +- * NetBSD: Recognize device timeouts (#710) +- * OpenBSD: Allow opening ugen devices multiple times (#763) +- * OpenBSD: Support libusb_get_port_number() (#764) +---- a/libusb/version_nano.h +-+++ b/libusb/version_nano.h +-@@ -1 +1 @@ +--#define LIBUSB_NANO 11584 +-+#define LIBUSB_NANO 11585 +diff --git a/package/libs/libusb/patches/002-linux_usbfs-Fix-parsing-of-descriptors-for-multi-con.patch b/package/libs/libusb/patches/002-linux_usbfs-Fix-parsing-of-descriptors-for-multi-con.patch +deleted file mode 100644 +index a53a8900de..0000000000 +--- a/package/libs/libusb/patches/002-linux_usbfs-Fix-parsing-of-descriptors-for-multi-con.patch ++++ /dev/null +@@ -1,61 +0,0 @@ +-From f6d2cb561402c3b6d3627c0eb89e009b503d9067 Mon Sep 17 00:00:00 2001 +-From: Chris Dickens +-Date: Sun, 13 Dec 2020 15:49:19 -0800 +-Subject: [PATCH] linux_usbfs: Fix parsing of descriptors for +- multi-configuration devices +- +-Commit e2be556bd2 ("linux_usbfs: Parse config descriptors during device +-initialization") introduced a regression for devices with multiple +-configurations. The logic that verifies the reported length of the +-configuration descriptors failed to count the length of the +-configuration descriptor itself and would truncate the actual length by +-9 bytes, leading to a parsing error for subsequent descriptors. +- +-Closes #825 +- +-Signed-off-by: Chris Dickens +---- +- libusb/os/linux_usbfs.c | 12 ++++++++---- +- libusb/version_nano.h | 2 +- +- 2 files changed, 9 insertions(+), 5 deletions(-) +- +---- a/libusb/os/linux_usbfs.c +-+++ b/libusb/os/linux_usbfs.c +-@@ -641,7 +641,12 @@ static int seek_to_next_config(struct li +- uint8_t *buffer, size_t len) +- { +- struct usbi_descriptor_header *header; +-- int offset = 0; +-+ int offset; +-+ +-+ /* Start seeking past the config descriptor */ +-+ offset = LIBUSB_DT_CONFIG_SIZE; +-+ buffer += LIBUSB_DT_CONFIG_SIZE; +-+ len -= LIBUSB_DT_CONFIG_SIZE; +- +- while (len > 0) { +- if (len < 2) { +-@@ -718,7 +723,7 @@ static int parse_config_descriptors(stru +- } +- +- if (priv->sysfs_dir) { +-- /* +-+ /* +- * In sysfs wTotalLength is ignored, instead the kernel returns a +- * config descriptor with verified bLength fields, with descriptors +- * with an invalid bLength removed. +-@@ -727,8 +732,7 @@ static int parse_config_descriptors(stru +- int offset; +- +- if (num_configs > 1 && idx < num_configs - 1) { +-- offset = seek_to_next_config(ctx, buffer + LIBUSB_DT_CONFIG_SIZE, +-- remaining - LIBUSB_DT_CONFIG_SIZE); +-+ offset = seek_to_next_config(ctx, buffer, remaining); +- if (offset < 0) +- return offset; +- sysfs_config_len = (uint16_t)offset; +---- a/libusb/version_nano.h +-+++ b/libusb/version_nano.h +-@@ -1 +1 @@ +--#define LIBUSB_NANO 11585 +-+#define LIBUSB_NANO 11586 +-- +2.25.1 + diff --git a/patches/0038-Revert-libusb-update-to-1.0.24.patch b/patches/0038-Revert-libusb-update-to-1.0.24.patch deleted file mode 100644 index c60e92c9b..000000000 --- a/patches/0038-Revert-libusb-update-to-1.0.24.patch +++ /dev/null @@ -1,35 +0,0 @@ -From 4f4e6eec1cab67d6cea9bfa61da5fbbd1a21fdee Mon Sep 17 00:00:00 2001 -From: John Crispin -Date: Fri, 2 Jul 2021 12:02:04 +0200 -Subject: [PATCH] Revert "libusb: update to 1.0.24" - -This reverts commit 0798b13d7df0deafd005b14d52420c4f480d146e. ---- - package/libs/libusb/Makefile | 6 +++--- - 1 file changed, 3 insertions(+), 3 deletions(-) - -diff --git a/package/libs/libusb/Makefile b/package/libs/libusb/Makefile -index e931536339..1667fb2840 100644 ---- a/package/libs/libusb/Makefile -+++ b/package/libs/libusb/Makefile -@@ -8,14 +8,14 @@ - include $(TOPDIR)/rules.mk - - PKG_NAME:=libusb --PKG_VERSION:=1.0.24 --PKG_RELEASE:=1 -+PKG_VERSION:=1.0.22 -+PKG_RELEASE:=2 - - PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2 - PKG_SOURCE_URL:=\ - https://github.com/libusb/libusb/releases/download/v$(PKG_VERSION) \ - @SF/$(PKG_NAME) --PKG_HASH:=7efd2685f7b327326dcfb85cee426d9b871fd70e22caa15bb68d595ce2a2b12a -+PKG_HASH:=75aeb9d59a4fdb800d329a545c2e6799f732362193b465ea198f2aa275518157 - - PKG_MAINTAINER:= Felix Fietkau - PKG_LICENSE:=LGPL-2.1-or-later --- -2.25.1 - diff --git a/patches/0039-firewall-enable-ssh-on-wan-during-early-boot-stage.patch b/patches/0038-firewall-enable-ssh-on-wan-during-early-boot-stage.patch similarity index 85% rename from patches/0039-firewall-enable-ssh-on-wan-during-early-boot-stage.patch rename to patches/0038-firewall-enable-ssh-on-wan-during-early-boot-stage.patch index 001b109ba..c7c27c488 100644 --- a/patches/0039-firewall-enable-ssh-on-wan-during-early-boot-stage.patch +++ b/patches/0038-firewall-enable-ssh-on-wan-during-early-boot-stage.patch @@ -1,7 +1,7 @@ -From 1147a7312c432eebe0de619463fae582051e2e97 Mon Sep 17 00:00:00 2001 +From a7bfcdcf6675076c1a8a71aac6e2d8793345e8a6 Mon Sep 17 00:00:00 2001 From: John Crispin Date: Mon, 12 Jul 2021 13:10:48 +0200 -Subject: [PATCH 37/37] firewall: enable ssh on wan during early boot stage +Subject: [PATCH 38/43] firewall: enable ssh on wan during early boot stage Signed-off-by: John Crispin --- diff --git a/patches/0040-netifd-fix-compile-on-older-kernels.patch b/patches/0039-netifd-fix-compile-on-older-kernels.patch similarity index 93% rename from patches/0040-netifd-fix-compile-on-older-kernels.patch rename to patches/0039-netifd-fix-compile-on-older-kernels.patch index a8c394919..a19e69cce 100644 --- a/patches/0040-netifd-fix-compile-on-older-kernels.patch +++ b/patches/0039-netifd-fix-compile-on-older-kernels.patch @@ -1,7 +1,7 @@ -From 5bf7a4a5befe6add789249fe02b737e353137146 Mon Sep 17 00:00:00 2001 +From 4b7e51305fcbf27d8c447e165484f513f9ec7185 Mon Sep 17 00:00:00 2001 From: John Crispin Date: Wed, 4 Aug 2021 08:36:30 +0200 -Subject: [PATCH] netifd: fix compile on older kernels +Subject: [PATCH 39/43] netifd: fix compile on older kernels The ethtool features do not exist on ancient qualcomm kernels. Disable that feature if running on QCA. diff --git a/patches/0041-ipq40xx-add-Wallys-DR40x9-support.patch b/patches/0040-ipq40xx-add-Wallys-DR40x9-support.patch similarity index 95% rename from patches/0041-ipq40xx-add-Wallys-DR40x9-support.patch rename to patches/0040-ipq40xx-add-Wallys-DR40x9-support.patch index c08091d4f..20dc0b871 100644 --- a/patches/0041-ipq40xx-add-Wallys-DR40x9-support.patch +++ b/patches/0040-ipq40xx-add-Wallys-DR40x9-support.patch @@ -1,7 +1,7 @@ -From 5a0366889960ae89594177854b77889cdf22ac63 Mon Sep 17 00:00:00 2001 +From 5a9dfd7deb119a2960b062afb9c1a5e7ddc4cf2e Mon Sep 17 00:00:00 2001 From: Robert Marko -Date: Fri, 13 Aug 2021 18:28:21 +0200 -Subject: [PATCH] ipq40xx: add Wallys DR40x9 support +Date: Sat, 4 Sep 2021 06:19:42 +0200 +Subject: [PATCH 40/43] ipq40xx: add Wallys DR40x9 support Adds support for the Wallys DR40x9 series boards. They come in IPQ4019 and IPQ4029 versions. @@ -54,10 +54,10 @@ Signed-off-by: Robert Marko create mode 100644 target/linux/ipq40xx/files/arch/arm/boot/dts/qcom-ipq40x9-dr40x9.dts diff --git a/package/firmware/ipq-wifi/Makefile b/package/firmware/ipq-wifi/Makefile -index 87dcf9a769..192e8dcf7e 100644 +index c9d113ae6a..b222ce30d6 100644 --- a/package/firmware/ipq-wifi/Makefile +++ b/package/firmware/ipq-wifi/Makefile -@@ -49,6 +49,7 @@ ALLWIFIBOARDS:= \ +@@ -51,6 +51,7 @@ ALLWIFIBOARDS:= \ plasmacloud_pa2200 \ qxwlan_e2600ac \ cig_wf610d \ @@ -65,7 +65,7 @@ index 87dcf9a769..192e8dcf7e 100644 tp-link_ec420-g1 ALLWIFIPACKAGES:=$(foreach BOARD,$(ALLWIFIBOARDS),ipq-wifi-$(BOARD)) -@@ -135,5 +136,6 @@ $(eval $(call generate-ipq-wifi-package,plasmacloud_pa2200,Plasma Cloud PA2200)) +@@ -139,5 +140,6 @@ $(eval $(call generate-ipq-wifi-package,plasmacloud_pa2200,Plasma Cloud PA2200)) $(eval $(call generate-ipq-wifi-package,qxwlan_e2600ac,Qxwlan E2600AC)) $(eval $(call generate-ipq-wifi-package,cig_wf610d,CIG WF_610D)) $(eval $(call generate-ipq-wifi-package,tp-link_ec420-g1,tp-link EC420-G1)) @@ -135,7 +135,7 @@ literal 0 HcmV?d00001 diff --git a/target/linux/ipq40xx/base-files/etc/board.d/02_network b/target/linux/ipq40xx/base-files/etc/board.d/02_network -index 9d03b620ce..cfcf518907 100755 +index 0240798bbb..5a2a3a47f7 100755 --- a/target/linux/ipq40xx/base-files/etc/board.d/02_network +++ b/target/linux/ipq40xx/base-files/etc/board.d/02_network @@ -19,7 +19,8 @@ ipq40xx_setup_interfaces() @@ -163,7 +163,7 @@ index c255707f91..e1f75fd4bd 100755 board_config_flush diff --git a/target/linux/ipq40xx/base-files/etc/hotplug.d/firmware/11-ath10k-caldata b/target/linux/ipq40xx/base-files/etc/hotplug.d/firmware/11-ath10k-caldata -index 56b9935541..561c8289e7 100644 +index ad2946f636..64bb4efaf8 100644 --- a/target/linux/ipq40xx/base-files/etc/hotplug.d/firmware/11-ath10k-caldata +++ b/target/linux/ipq40xx/base-files/etc/hotplug.d/firmware/11-ath10k-caldata @@ -115,7 +115,8 @@ case "$FIRMWARE" in @@ -176,7 +176,7 @@ index 56b9935541..561c8289e7 100644 caldata_extract "0:ART" 0x1000 0x2f20 ;; devolo,magic-2-wifi-next) -@@ -227,7 +228,8 @@ case "$FIRMWARE" in +@@ -232,7 +233,8 @@ case "$FIRMWARE" in plasmacloud,pa2200 |\ qxwlan,e2600ac-c1 |\ qxwlan,e2600ac-c2 |\ @@ -187,7 +187,7 @@ index 56b9935541..561c8289e7 100644 ;; devolo,magic-2-wifi-next) diff --git a/target/linux/ipq40xx/base-files/lib/upgrade/platform.sh b/target/linux/ipq40xx/base-files/lib/upgrade/platform.sh -index f6fc828134..7ebe0396f6 100644 +index 84abd181dc..8840372ba9 100644 --- a/target/linux/ipq40xx/base-files/lib/upgrade/platform.sh +++ b/target/linux/ipq40xx/base-files/lib/upgrade/platform.sh @@ -73,6 +73,7 @@ platform_do_upgrade() { @@ -592,10 +592,10 @@ index 0000000000..cb3296f5e5 + status = "okay"; +}; diff --git a/target/linux/ipq40xx/image/generic.mk b/target/linux/ipq40xx/image/generic.mk -index e4e437bb95..7cbfecb233 100644 +index 4448ed6083..540f1f2778 100644 --- a/target/linux/ipq40xx/image/generic.mk +++ b/target/linux/ipq40xx/image/generic.mk -@@ -834,6 +834,19 @@ define Device/zyxel_wre6606 +@@ -830,6 +830,19 @@ define Device/zyxel_wre6606 endef TARGET_DEVICES += zyxel_wre6606 @@ -616,19 +616,19 @@ index e4e437bb95..7cbfecb233 100644 $(call Device/FitImage) $(call Device/UbiFit) diff --git a/target/linux/ipq40xx/patches-5.4/901-arm-boot-add-dts-files.patch b/target/linux/ipq40xx/patches-5.4/901-arm-boot-add-dts-files.patch -index 492cc67b2c..4d686df304 100644 +index ae0b8f2025..826e17b0e9 100644 --- a/target/linux/ipq40xx/patches-5.4/901-arm-boot-add-dts-files.patch +++ b/target/linux/ipq40xx/patches-5.4/901-arm-boot-add-dts-files.patch @@ -10,7 +10,7 @@ Signed-off-by: John Crispin --- a/arch/arm/boot/dts/Makefile +++ b/arch/arm/boot/dts/Makefile --@@ -837,11 +837,60 @@ dtb-$(CONFIG_ARCH_QCOM) += \ -+@@ -837,11 +837,61 @@ dtb-$(CONFIG_ARCH_QCOM) += \ +-@@ -837,11 +837,62 @@ dtb-$(CONFIG_ARCH_QCOM) += \ ++@@ -837,11 +837,63 @@ dtb-$(CONFIG_ARCH_QCOM) += \ qcom-apq8074-dragonboard.dtb \ qcom-apq8084-ifc6540.dtb \ qcom-apq8084-mtp.dtb \ -@@ -68,6 +68,7 @@ Signed-off-by: John Crispin +@@ -70,6 +70,7 @@ Signed-off-by: John Crispin + qcom-ipq4029-gl-b1300.dtb \ + qcom-ipq4029-gl-s1300.dtb \ + qcom-ipq4029-mr33.dtb \ diff --git a/patches/0042-base-files-fix-rootfs_data_max-support-during-sysupg.patch b/patches/0041-base-files-fix-rootfs_data_max-support-during-sysupg.patch similarity index 81% rename from patches/0042-base-files-fix-rootfs_data_max-support-during-sysupg.patch rename to patches/0041-base-files-fix-rootfs_data_max-support-during-sysupg.patch index 0ab5232c0..cb9ca351c 100644 --- a/patches/0042-base-files-fix-rootfs_data_max-support-during-sysupg.patch +++ b/patches/0041-base-files-fix-rootfs_data_max-support-during-sysupg.patch @@ -1,7 +1,8 @@ -From b673b8dad0cb6392c7097dfe75b2919b13ecd1c6 Mon Sep 17 00:00:00 2001 +From 35412c4626e6b2195421452926dd9b2854bceb9a Mon Sep 17 00:00:00 2001 From: John Crispin Date: Tue, 17 Aug 2021 17:29:22 +0200 -Subject: [PATCH] base-files: fix rootfs_data_max support during sysupgrade +Subject: [PATCH 41/43] base-files: fix rootfs_data_max support during + sysupgrade Signed-off-by: John Crispin --- diff --git a/patches/0043-ipq40xx-add-HFCL-ION4-support.patch b/patches/0042-ipq40xx-add-HFCL-ION4-support.patch similarity index 94% rename from patches/0043-ipq40xx-add-HFCL-ION4-support.patch rename to patches/0042-ipq40xx-add-HFCL-ION4-support.patch index ed5331780..f16caa9c1 100644 --- a/patches/0043-ipq40xx-add-HFCL-ION4-support.patch +++ b/patches/0042-ipq40xx-add-HFCL-ION4-support.patch @@ -1,7 +1,7 @@ -From f9a7699980b31760712245ea1dab0641ac7425e1 Mon Sep 17 00:00:00 2001 +From 5804d7fe3e3860c33a6957320661efd40b077a9e Mon Sep 17 00:00:00 2001 From: John Crispin Date: Thu, 26 Aug 2021 17:34:47 +0200 -Subject: [PATCH] ipq40xx: add HFCL ION4 support +Subject: [PATCH 42/43] ipq40xx: add HFCL ION4 support Signed-off-by: John Crispin --- @@ -34,10 +34,10 @@ index ab489a6e18..fd7ad69eff 100644 config_load ubootenv diff --git a/package/firmware/ipq-wifi/Makefile b/package/firmware/ipq-wifi/Makefile -index 23fc4caa2e..e887e5ad1c 100644 +index b222ce30d6..cd7bfc3c82 100644 --- a/package/firmware/ipq-wifi/Makefile +++ b/package/firmware/ipq-wifi/Makefile -@@ -51,7 +51,8 @@ ALLWIFIBOARDS:= \ +@@ -52,7 +52,8 @@ ALLWIFIBOARDS:= \ qxwlan_e2600ac \ cig_wf610d \ wallys_dr40x9 \ @@ -47,7 +47,7 @@ index 23fc4caa2e..e887e5ad1c 100644 ALLWIFIPACKAGES:=$(foreach BOARD,$(ALLWIFIBOARDS),ipq-wifi-$(BOARD)) -@@ -139,5 +140,6 @@ $(eval $(call generate-ipq-wifi-package,qxwlan_e2600ac,Qxwlan E2600AC)) +@@ -141,5 +142,6 @@ $(eval $(call generate-ipq-wifi-package,qxwlan_e2600ac,Qxwlan E2600AC)) $(eval $(call generate-ipq-wifi-package,cig_wf610d,CIG WF_610D)) $(eval $(call generate-ipq-wifi-package,tp-link_ec420-g1,tp-link EC420-G1)) $(eval $(call generate-ipq-wifi-package,wallys_dr40x9,Wallys DR40X9)) @@ -55,10 +55,10 @@ index 23fc4caa2e..e887e5ad1c 100644 $(foreach PACKAGE,$(ALLWIFIPACKAGES),$(eval $(call BuildPackage,$(PACKAGE)))) diff --git a/target/linux/ipq40xx/base-files/etc/board.d/01_leds b/target/linux/ipq40xx/base-files/etc/board.d/01_leds -index efd5d002db..85fa1bcfbf 100755 +index d473448137..d944d72184 100755 --- a/target/linux/ipq40xx/base-files/etc/board.d/01_leds +++ b/target/linux/ipq40xx/base-files/etc/board.d/01_leds -@@ -70,6 +70,10 @@ zyxel,wre6606) +@@ -78,6 +78,10 @@ zyxel,wre6606) ucidef_set_led_wlan "wlan2g" "WLAN2G" "green:wlan2g" "phy0tpt" ucidef_set_led_wlan "wlan5g" "WLAN5G" "green:wlan5g" "phy1tpt" ;; @@ -70,10 +70,10 @@ index efd5d002db..85fa1bcfbf 100755 board_config_flush diff --git a/target/linux/ipq40xx/base-files/etc/board.d/02_network b/target/linux/ipq40xx/base-files/etc/board.d/02_network -index cfcf518907..84596dcf88 100755 +index 5a2a3a47f7..e4b009bf93 100755 --- a/target/linux/ipq40xx/base-files/etc/board.d/02_network +++ b/target/linux/ipq40xx/base-files/etc/board.d/02_network -@@ -33,6 +33,7 @@ ipq40xx_setup_interfaces() +@@ -34,6 +34,7 @@ ipq40xx_setup_interfaces() netgear,ex6100v2|\ netgear,ex6150v2|\ tp-link,ec420-g1|\ @@ -82,10 +82,10 @@ index cfcf518907..84596dcf88 100755 ucidef_set_interface_wan "eth0" ;; diff --git a/target/linux/ipq40xx/base-files/etc/hotplug.d/firmware/11-ath10k-caldata b/target/linux/ipq40xx/base-files/etc/hotplug.d/firmware/11-ath10k-caldata -index 561c8289e7..d38decf77b 100644 +index 64bb4efaf8..97dd1b4039 100644 --- a/target/linux/ipq40xx/base-files/etc/hotplug.d/firmware/11-ath10k-caldata +++ b/target/linux/ipq40xx/base-files/etc/hotplug.d/firmware/11-ath10k-caldata -@@ -162,6 +162,9 @@ case "$FIRMWARE" in +@@ -167,6 +167,9 @@ case "$FIRMWARE" in tp-link,ec420-g1) caldata_extract "0:ART" 0x1000 0x2f20 ;; @@ -95,7 +95,7 @@ index 561c8289e7..d38decf77b 100644 esac ;; "ath10k/pre-cal-ahb-a800000.wifi.bin") -@@ -272,6 +275,9 @@ case "$FIRMWARE" in +@@ -283,6 +286,9 @@ case "$FIRMWARE" in caldata_extract "ART" 0x5000 0x2f20 ath10k_patch_mac $(macaddr_add $(cat /sys/class/net/eth0/address) -1) ;; @@ -106,7 +106,7 @@ index 561c8289e7..d38decf77b 100644 ;; *) diff --git a/target/linux/ipq40xx/base-files/lib/upgrade/platform.sh b/target/linux/ipq40xx/base-files/lib/upgrade/platform.sh -index 7ebe0396f6..c404f32f41 100644 +index 8840372ba9..53bc1adeb5 100644 --- a/target/linux/ipq40xx/base-files/lib/upgrade/platform.sh +++ b/target/linux/ipq40xx/base-files/lib/upgrade/platform.sh @@ -74,6 +74,7 @@ platform_do_upgrade() { @@ -350,10 +350,10 @@ index 0000000000..7437b98c02 + vlan_tag = <0 0x20>; +}; diff --git a/target/linux/ipq40xx/image/generic.mk b/target/linux/ipq40xx/image/generic.mk -index 93a896e75d..ac7a5c7dfa 100644 +index 540f1f2778..ae1e2e49cf 100644 --- a/target/linux/ipq40xx/image/generic.mk +++ b/target/linux/ipq40xx/image/generic.mk -@@ -861,3 +861,21 @@ define Device/tp-link_ec420_g1 +@@ -857,3 +857,21 @@ define Device/tp-link_ec420_g1 DEVICE_PACKAGES := ath10k-firmware-qca9984-ct ipq-wifi-tp-link_ec420-g1 uboot-envtools endef TARGET_DEVICES += tp-link_ec420_g1 diff --git a/patches/0042-ipq806x-add-edgecore_ssw2ac2600-support.patch b/patches/0043-ipq806x-add-edgecore_ssw2ac2600-support.patch similarity index 98% rename from patches/0042-ipq806x-add-edgecore_ssw2ac2600-support.patch rename to patches/0043-ipq806x-add-edgecore_ssw2ac2600-support.patch index c80abe739..5654bbda6 100644 --- a/patches/0042-ipq806x-add-edgecore_ssw2ac2600-support.patch +++ b/patches/0043-ipq806x-add-edgecore_ssw2ac2600-support.patch @@ -1,7 +1,7 @@ -From e5f38285a39a57f3f6faa6450e8b9e9847dfcc7a Mon Sep 17 00:00:00 2001 +From 282fff50a526b7eef8f4ffbaf9c2a01c407920ad Mon Sep 17 00:00:00 2001 From: John Crispin Date: Wed, 18 Aug 2021 15:49:56 +0200 -Subject: [PATCH] ipq806x: add edgecore_ssw2ac2600 support +Subject: [PATCH 43/43] ipq806x: add edgecore_ssw2ac2600 support Signed-off-by: John Crispin --- @@ -33,7 +33,7 @@ index 96a4ee6450..1b49fd51d4 100644 ubootenv_add_uci_config "/dev/mtd11" "0x0" "0x10000" "0x10000" ;; diff --git a/package/firmware/ipq-wifi/Makefile b/package/firmware/ipq-wifi/Makefile -index 192e8dcf7e..23fc4caa2e 100644 +index cd7bfc3c82..a400ac9470 100644 --- a/package/firmware/ipq-wifi/Makefile +++ b/package/firmware/ipq-wifi/Makefile @@ -33,6 +33,7 @@ ALLWIFIBOARDS:= \ @@ -44,7 +44,7 @@ index 192e8dcf7e..23fc4caa2e 100644 edgecore_oap100 \ engenius_eap2200 \ engenius_emd1 \ -@@ -119,6 +120,7 @@ $(eval $(call generate-ipq-wifi-package,cellc_rtl30vw, Cell C RTL30VW)) +@@ -122,6 +123,7 @@ $(eval $(call generate-ipq-wifi-package,cellc_rtl30vw, Cell C RTL30VW)) $(eval $(call generate-ipq-wifi-package,devolo_magic-2-wifi-next,devolo Magic 2 WiFi next)) $(eval $(call generate-ipq-wifi-package,dlink_dap2610,D-Link DAP-2610)) $(eval $(call generate-ipq-wifi-package,edgecore_ecw5410,Edgecore ECW5410))