From 5b8709d9f251c8ce1a0c8e1444ab0be4b4a4de21 Mon Sep 17 00:00:00 2001 From: Andrew Cameron Date: Wed, 6 Nov 2019 20:12:55 -0600 Subject: [PATCH 01/17] ath79: add support for the TP-LINK WBS510 V2 This adds support for a popular low-cost 5GHz N based AP Specifications: - SoC: Atheros AR9344 - RAM: 64MB - Storage: 8 MB SPI NOR - Wireless: 5GHz 300 Mbps, 2x RP-SMA connector, 27 dBm TX power - Ethernet: 1x 10/100 Mbps with 24V POE IN, 1x 10/100 Mbps Installation: Flash factory image through stock firmware WEB UI or through TFTP To get to TFTP recovery just hold reset button while powering on for around 4-5 seconds and release. Rename factory image to recovery.bin Stock TFTP server IP:192.168.0.100 Stock device TFTP adress:192.168.0.254 Signed-off-by: Andrew Cameron --- .../ath79/dts/ar9344_tplink_wbs510-v2.dts | 13 ++++++++ .../generic/base-files/etc/board.d/01_leds | 3 +- .../generic/base-files/etc/board.d/02_network | 1 + .../base-files/etc/board.d/03_gpio_switches | 3 +- target/linux/ath79/image/generic-tp-link.mk | 11 +++++++ tools/firmware-utils/src/tplink-safeloader.c | 33 +++++++++++++++++++ 6 files changed, 62 insertions(+), 2 deletions(-) create mode 100644 target/linux/ath79/dts/ar9344_tplink_wbs510-v2.dts diff --git a/target/linux/ath79/dts/ar9344_tplink_wbs510-v2.dts b/target/linux/ath79/dts/ar9344_tplink_wbs510-v2.dts new file mode 100644 index 0000000000..5c55d78904 --- /dev/null +++ b/target/linux/ath79/dts/ar9344_tplink_wbs510-v2.dts @@ -0,0 +1,13 @@ +// SPDX-License-Identifier: GPL-2.0-or-later OR MIT +/dts-v1/; + +#include "ar9344_tplink_cpexxx-v1.dtsi" + +/ { + compatible = "tplink,wbs510-v2", "qca,ar9344"; + model = "TP-Link WBS510 v2"; +}; + +&led_link4 { + gpios = <&gpio 2 GPIO_ACTIVE_LOW>; +}; 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 d54e770240..5bb1d92a60 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 @@ -175,7 +175,8 @@ tplink,cpe210-v1|\ tplink,cpe220-v2|\ tplink,cpe220-v3|\ tplink,cpe510-v1|\ -tplink,wbs210-v2) +tplink,wbs210-v2|\ +tplink,wbs510-v2) ucidef_set_led_netdev "lan0" "LAN0" "tp-link:green:lan0" "eth1" ucidef_set_led_switch "lan1" "LAN1" "tp-link:green:lan1" "switch0" "0x10" ucidef_set_rssimon "wlan0" "200000" "1" 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 07f3c4e83c..dcc0b8be23 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 @@ -92,6 +92,7 @@ ath79_setup_interfaces() tplink,cpe220-v3|\ tplink,cpe510-v1|\ tplink,wbs210-v2|\ + tplink,wbs510-v2|\ ubnt,nanostation-m|\ ubnt,routerstation) ucidef_set_interfaces_lan_wan "eth1" "eth0" diff --git a/target/linux/ath79/generic/base-files/etc/board.d/03_gpio_switches b/target/linux/ath79/generic/base-files/etc/board.d/03_gpio_switches index 9bce6cc51b..844b212152 100755 --- a/target/linux/ath79/generic/base-files/etc/board.d/03_gpio_switches +++ b/target/linux/ath79/generic/base-files/etc/board.d/03_gpio_switches @@ -46,7 +46,8 @@ tplink,cpe210-v1|\ tplink,cpe220-v2|\ tplink,cpe220-v3|\ tplink,cpe510-v1|\ -tplink,wbs210-v2) +tplink,wbs210-v2|\ +tplink,wbs510-v2) ucidef_add_gpio_switch "poe_passthrough" "PoE Passthrough" "20" ;; ubnt,nanostation-ac) diff --git a/target/linux/ath79/image/generic-tp-link.mk b/target/linux/ath79/image/generic-tp-link.mk index 114c20d3d5..6efed954e4 100644 --- a/target/linux/ath79/image/generic-tp-link.mk +++ b/target/linux/ath79/image/generic-tp-link.mk @@ -548,3 +548,14 @@ define Device/tplink_wbs210-v2 TPLINK_BOARD_ID := WBS210V2 endef TARGET_DEVICES += tplink_wbs210-v2 + +define Device/tplink_wbs510-v2 + $(Device/tplink-loader-okli) + ATH_SOC := ar9344 + IMAGE_SIZE := 7680k + DEVICE_MODEL := WBS510 + DEVICE_VARIANT := v2 + DEVICE_PACKAGES := rssileds + TPLINK_BOARD_ID := WBS510V2 +endef +TARGET_DEVICES += tplink_wbs510-v2 diff --git a/tools/firmware-utils/src/tplink-safeloader.c b/tools/firmware-utils/src/tplink-safeloader.c index 3ec1fb6ce7..89955725d0 100644 --- a/tools/firmware-utils/src/tplink-safeloader.c +++ b/tools/firmware-utils/src/tplink-safeloader.c @@ -570,6 +570,39 @@ static struct device_info boards[] = { .last_sysupgrade_partition = "support-list", }, + { + .id = "WBS510V2", + .vendor = "CPE510(TP-LINK|UN|N300-5):1.0\r\n", + .support_list = + "SupportList:\r\n" + "WBS510(TP-LINK|UN|N300-5|00000000):2.0\r\n" + "WBS510(TP-LINK|US|N300-5|55530000):2.0\r\n" + "WBS510(TP-LINK|EU|N300-5|45550000):2.0\r\n" + "WBS510(TP-LINK|CA|N300-5|43410000):2.0\r\n", + .support_trail = '\xff', + .soft_ver = NULL, + + .partitions = { + {"fs-uboot", 0x00000, 0x20000}, + {"partition-table", 0x20000, 0x02000}, + {"default-mac", 0x30000, 0x00020}, + {"product-info", 0x31100, 0x00100}, + {"signature", 0x32000, 0x00400}, + {"os-image", 0x40000, 0x200000}, + {"file-system", 0x240000, 0x570000}, + {"soft-version", 0x7b0000, 0x00100}, + {"support-list", 0x7b1000, 0x00400}, + {"user-config", 0x7c0000, 0x10000}, + {"default-config", 0x7d0000, 0x10000}, + {"log", 0x7e0000, 0x10000}, + {"radio", 0x7f0000, 0x10000}, + {NULL, 0, 0} + }, + + .first_sysupgrade_partition = "os-image", + .last_sysupgrade_partition = "support-list", + }, + /** Firmware layout for the C2600 */ { .id = "C2600", From 20fdfe37d21f19901eec86ace8da0c083faa7ebc Mon Sep 17 00:00:00 2001 From: Andrew Cameron Date: Thu, 7 Nov 2019 21:36:02 -0600 Subject: [PATCH 02/17] ath79: add support for the TP-LINK WBS510 V1 This adds support for a popular low-cost 5GHz N based AP Specifications: - SoC: Atheros AR9344 - RAM: 64MB - Storage: 8 MB SPI NOR - Wireless: 5GHz 300 Mbps, 2x RP-SMA connector, 27 dBm TX power - Ethernet: 1x 10/100 Mbps with 24V POE IN, 1x 10/100 Mbps Installation: Flash factory image through stock firmware WEB UI or through TFTP To get to TFTP recovery just hold reset button while powering on for around 4-5 seconds and release. Rename factory image to recovery.bin Stock TFTP server IP:192.168.0.100 Stock device TFTP adress:192.168.0.254 Signed-off-by: Andrew Cameron --- target/linux/ath79/dts/ar9344_tplink_wbs510-v1.dts | 13 +++++++++++++ .../ath79/generic/base-files/etc/board.d/01_leds | 1 + .../ath79/generic/base-files/etc/board.d/02_network | 1 + .../generic/base-files/etc/board.d/03_gpio_switches | 1 + target/linux/ath79/image/generic-tp-link.mk | 12 ++++++++++++ tools/firmware-utils/src/tplink-safeloader.c | 3 ++- 6 files changed, 30 insertions(+), 1 deletion(-) create mode 100644 target/linux/ath79/dts/ar9344_tplink_wbs510-v1.dts diff --git a/target/linux/ath79/dts/ar9344_tplink_wbs510-v1.dts b/target/linux/ath79/dts/ar9344_tplink_wbs510-v1.dts new file mode 100644 index 0000000000..ba6fab2c1a --- /dev/null +++ b/target/linux/ath79/dts/ar9344_tplink_wbs510-v1.dts @@ -0,0 +1,13 @@ +// SPDX-License-Identifier: GPL-2.0-or-later OR MIT +/dts-v1/; + +#include "ar9344_tplink_cpexxx-v1.dtsi" + +/ { + compatible = "tplink,wbs510-v1", "qca,ar9344"; + model = "TP-Link WBS510 v1"; +}; + +&led_link4 { + gpios = <&gpio 2 GPIO_ACTIVE_LOW>; +}; 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 5bb1d92a60..c914090cf9 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 @@ -176,6 +176,7 @@ tplink,cpe220-v2|\ tplink,cpe220-v3|\ tplink,cpe510-v1|\ tplink,wbs210-v2|\ +tplink,wbs510-v1|\ tplink,wbs510-v2) ucidef_set_led_netdev "lan0" "LAN0" "tp-link:green:lan0" "eth1" ucidef_set_led_switch "lan1" "LAN1" "tp-link:green:lan1" "switch0" "0x10" 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 dcc0b8be23..06e2ae4cc0 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 @@ -92,6 +92,7 @@ ath79_setup_interfaces() tplink,cpe220-v3|\ tplink,cpe510-v1|\ tplink,wbs210-v2|\ + tplink,wbs510-v1|\ tplink,wbs510-v2|\ ubnt,nanostation-m|\ ubnt,routerstation) diff --git a/target/linux/ath79/generic/base-files/etc/board.d/03_gpio_switches b/target/linux/ath79/generic/base-files/etc/board.d/03_gpio_switches index 844b212152..967e2c7680 100755 --- a/target/linux/ath79/generic/base-files/etc/board.d/03_gpio_switches +++ b/target/linux/ath79/generic/base-files/etc/board.d/03_gpio_switches @@ -47,6 +47,7 @@ tplink,cpe220-v2|\ tplink,cpe220-v3|\ tplink,cpe510-v1|\ tplink,wbs210-v2|\ +tplink,wbs510-v1|\ tplink,wbs510-v2) ucidef_add_gpio_switch "poe_passthrough" "PoE Passthrough" "20" ;; diff --git a/target/linux/ath79/image/generic-tp-link.mk b/target/linux/ath79/image/generic-tp-link.mk index 6efed954e4..eeaeaf53f4 100644 --- a/target/linux/ath79/image/generic-tp-link.mk +++ b/target/linux/ath79/image/generic-tp-link.mk @@ -549,6 +549,18 @@ define Device/tplink_wbs210-v2 endef TARGET_DEVICES += tplink_wbs210-v2 +define Device/tplink_wbs510-v1 + $(Device/tplink-loader-okli) + ATH_SOC := ar9344 + IMAGE_SIZE := 7680k + DEVICE_MODEL := WBS510 + DEVICE_VARIANT := v1 + DEVICE_PACKAGES := rssileds + TPLINK_BOARD_ID := WBS510 + SUPPORTED_DEVICES += wbs510 +endef +TARGET_DEVICES += tplink_wbs510-v1 + define Device/tplink_wbs510-v2 $(Device/tplink-loader-okli) ATH_SOC := ar9344 diff --git a/tools/firmware-utils/src/tplink-safeloader.c b/tools/firmware-utils/src/tplink-safeloader.c index 89955725d0..4e85bd59ca 100644 --- a/tools/firmware-utils/src/tplink-safeloader.c +++ b/tools/firmware-utils/src/tplink-safeloader.c @@ -545,7 +545,8 @@ static struct device_info boards[] = { "SupportList:\r\n" "WBS510(TP-LINK|UN|N300-5):1.20\r\n" "WBS510(TP-LINK|US|N300-5):1.20\r\n" - "WBS510(TP-LINK|EU|N300-5):1.20\r\n", + "WBS510(TP-LINK|EU|N300-5):1.20\r\n" + "WBS510(TP-LINK|CA|N300-5):1.20\r\n", .support_trail = '\xff', .soft_ver = NULL, From db9e9e8382169ef85ea5994c958cfba7c87abfd8 Mon Sep 17 00:00:00 2001 From: Koen Vandeputte Date: Thu, 21 Nov 2019 14:03:58 +0100 Subject: [PATCH 03/17] kernel: bump 4.14 to 4.14.155 Refreshed all patches. Altered patches: - 707-dpaa-ethernet-support-layerscape.patch Remove upstreamed: - 034-v4.20-MIPS-BCM47XX-Enable-USB-power-on-Netgear-WNDR3400v3.patch - 001-4.21-01-BCM63XX-fix-switch-core-reset-on-BCM6368.patch - 073-qcom-ipq4019-fix-cpu0-s-qcom-saw2-reg-value.patch Compile-tested on: cns3xxx Runtime-tested on: cns3xxx Signed-off-by: Koen Vandeputte --- include/kernel-version.mk | 4 +- ...able-USB-power-on-Netgear-WNDR3400v3.patch | 48 -------------- ...63xx_enet-do-not-rely-on-probe-order.patch | 4 +- ...-managed-functions-for-clock-ioremap.patch | 16 ++--- ...net-drop-unneeded-NULL-phy_clk-check.patch | 4 +- ...enet-just-use-enet-as-the-clock-name.patch | 4 +- ...-platform-data-for-dma-channel-numbe.patch | 4 +- ...x_enet-remove-pointless-mac_id-check.patch | 2 +- ...-platform-device-id-directly-for-mii.patch | 4 +- ...3XX-fix-switch-core-reset-on-BCM6368.patch | 26 -------- ...402_bcm63xx_enet_vlan_incoming_fixed.patch | 2 +- ...-move-phy_-dis-connect-into-probe-re.patch | 22 +++---- ...enable-rgmii-clock-on-external-ports.patch | 2 +- .../423-bcm63xx_enet_add_b53_support.patch | 12 ++-- ...4-bcm63xx_enet_no_request_mem_region.patch | 2 +- .../804-bcm63xx_enet_63268_rgmii_ports.patch | 2 +- ...q4019-fix-cpu0-s-qcom-saw2-reg-value.patch | 33 ---------- ...ow-to-set-regulator-without-opp_list.patch | 2 +- ...rt-adjusting-OPP-voltages-at-runtime.patch | 2 +- ...per-to-get-an-opp-regulator-for-devi.patch | 2 +- ...e-voltage-tolerance-when-adjusting-t.patch | 4 +- ...707-dpaa-ethernet-support-layerscape.patch | 62 +++++++++---------- ...-ports-count-from-xhci-in-xhci_mtk_s.patch | 2 +- 23 files changed, 79 insertions(+), 186 deletions(-) delete mode 100644 target/linux/brcm47xx/patches-4.14/034-v4.20-MIPS-BCM47XX-Enable-USB-power-on-Netgear-WNDR3400v3.patch delete mode 100644 target/linux/brcm63xx/patches-4.14/001-4.21-01-BCM63XX-fix-switch-core-reset-on-BCM6368.patch delete mode 100644 target/linux/ipq40xx/patches-4.14/073-qcom-ipq4019-fix-cpu0-s-qcom-saw2-reg-value.patch diff --git a/include/kernel-version.mk b/include/kernel-version.mk index 87a39a8790..0050a35ff5 100644 --- a/include/kernel-version.mk +++ b/include/kernel-version.mk @@ -7,11 +7,11 @@ ifdef CONFIG_TESTING_KERNEL endif LINUX_VERSION-4.9 = .202 -LINUX_VERSION-4.14 = .154 +LINUX_VERSION-4.14 = .155 LINUX_VERSION-4.19 = .84 LINUX_KERNEL_HASH-4.9.202 = 8108ec1cd10fc40821c84e9f087dba10b1767aad66596f4a36925faef55e4ebf -LINUX_KERNEL_HASH-4.14.154 = 86de4a24379a78d67fc08b2e249ccf7b689eb6c37fbe329fc3dfbe8ab4300603 +LINUX_KERNEL_HASH-4.14.155 = 77d61979556b81c95b81452fa10e1fe9368cbe2f9f80a13e4669b0464722e481 LINUX_KERNEL_HASH-4.19.84 = 868b4a92619cb00ab142a20a67f000525b9605820d1b66faa4a183133eac0660 remove_uri_prefix=$(subst git://,,$(subst http://,,$(subst https://,,$(1)))) diff --git a/target/linux/brcm47xx/patches-4.14/034-v4.20-MIPS-BCM47XX-Enable-USB-power-on-Netgear-WNDR3400v3.patch b/target/linux/brcm47xx/patches-4.14/034-v4.20-MIPS-BCM47XX-Enable-USB-power-on-Netgear-WNDR3400v3.patch deleted file mode 100644 index c824e28317..0000000000 --- a/target/linux/brcm47xx/patches-4.14/034-v4.20-MIPS-BCM47XX-Enable-USB-power-on-Netgear-WNDR3400v3.patch +++ /dev/null @@ -1,48 +0,0 @@ -From feef7918667b84f9d5653c501542dd8d84ae32af Mon Sep 17 00:00:00 2001 -From: Tuomas Tynkkynen -Date: Sun, 19 Aug 2018 22:20:23 +0300 -Subject: [PATCH] MIPS: BCM47XX: Enable USB power on Netgear WNDR3400v3 -MIME-Version: 1.0 -Content-Type: text/plain; charset=UTF-8 -Content-Transfer-Encoding: 8bit - -Setting GPIO 21 high seems to be required to enable power to USB ports -on the WNDR3400v3. As there is already similar code for WNR3500L, -make the existing USB power GPIO code generic and use that. - -Signed-off-by: Tuomas Tynkkynen -Acked-by: Hauke Mehrtens -Signed-off-by: Paul Burton -Patchwork: https://patchwork.linux-mips.org/patch/20259/ -Cc: Rafał Miłecki -Cc: linux-mips@linux-mips.org -Cc: linux-kernel@vger.kernel.org ---- - arch/mips/bcm47xx/workarounds.c | 8 +++++--- - 1 file changed, 5 insertions(+), 3 deletions(-) - ---- a/arch/mips/bcm47xx/workarounds.c -+++ b/arch/mips/bcm47xx/workarounds.c -@@ -5,9 +5,8 @@ - #include - #include - --static void __init bcm47xx_workarounds_netgear_wnr3500l(void) -+static void __init bcm47xx_workarounds_enable_usb_power(int usb_power) - { -- const int usb_power = 12; - int err; - - err = gpio_request_one(usb_power, GPIOF_OUT_INIT_HIGH, "usb_power"); -@@ -23,7 +22,10 @@ void __init bcm47xx_workarounds(void) - - switch (board) { - case BCM47XX_BOARD_NETGEAR_WNR3500L: -- bcm47xx_workarounds_netgear_wnr3500l(); -+ bcm47xx_workarounds_enable_usb_power(12); -+ break; -+ case BCM47XX_BOARD_NETGEAR_WNDR3400_V3: -+ bcm47xx_workarounds_enable_usb_power(21); - break; - default: - /* No workaround(s) needed */ diff --git a/target/linux/brcm63xx/patches-4.14/001-4.15-10-bcm63xx_enet-do-not-rely-on-probe-order.patch b/target/linux/brcm63xx/patches-4.14/001-4.15-10-bcm63xx_enet-do-not-rely-on-probe-order.patch index fd3ced47b0..b339580c48 100644 --- a/target/linux/brcm63xx/patches-4.14/001-4.15-10-bcm63xx_enet-do-not-rely-on-probe-order.patch +++ b/target/linux/brcm63xx/patches-4.14/001-4.15-10-bcm63xx_enet-do-not-rely-on-probe-order.patch @@ -14,7 +14,7 @@ Signed-off-by: Jonas Gorski --- a/drivers/net/ethernet/broadcom/bcm63xx_enet.c +++ b/drivers/net/ethernet/broadcom/bcm63xx_enet.c -@@ -1722,10 +1722,8 @@ static int bcm_enet_probe(struct platfor +@@ -1723,10 +1723,8 @@ static int bcm_enet_probe(struct platfor const char *clk_name; int i, ret; @@ -26,7 +26,7 @@ Signed-off-by: Jonas Gorski res_irq = platform_get_resource(pdev, IORESOURCE_IRQ, 0); res_irq_rx = platform_get_resource(pdev, IORESOURCE_IRQ, 1); -@@ -2700,11 +2698,8 @@ static int bcm_enetsw_probe(struct platf +@@ -2701,11 +2699,8 @@ static int bcm_enetsw_probe(struct platf struct resource *res_mem; int ret, irq_rx, irq_tx; diff --git a/target/linux/brcm63xx/patches-4.14/001-4.15-11-bcm63xx_enet-use-managed-functions-for-clock-ioremap.patch b/target/linux/brcm63xx/patches-4.14/001-4.15-11-bcm63xx_enet-use-managed-functions-for-clock-ioremap.patch index f007750b3c..cf0971c911 100644 --- a/target/linux/brcm63xx/patches-4.14/001-4.15-11-bcm63xx_enet-use-managed-functions-for-clock-ioremap.patch +++ b/target/linux/brcm63xx/patches-4.14/001-4.15-11-bcm63xx_enet-use-managed-functions-for-clock-ioremap.patch @@ -13,7 +13,7 @@ Signed-off-by: Jonas Gorski --- a/drivers/net/ethernet/broadcom/bcm63xx_enet.c +++ b/drivers/net/ethernet/broadcom/bcm63xx_enet.c -@@ -1767,14 +1767,14 @@ static int bcm_enet_probe(struct platfor +@@ -1768,14 +1768,14 @@ static int bcm_enet_probe(struct platfor clk_name = "enet1"; } @@ -30,7 +30,7 @@ Signed-off-by: Jonas Gorski /* initialize default and fetch platform data */ priv->rx_ring_size = BCMENET_DEF_RX_DESC; -@@ -1802,7 +1802,7 @@ static int bcm_enet_probe(struct platfor +@@ -1803,7 +1803,7 @@ static int bcm_enet_probe(struct platfor if (priv->mac_id == 0 && priv->has_phy && !priv->use_external_mii) { /* using internal PHY, enable clock */ @@ -39,7 +39,7 @@ Signed-off-by: Jonas Gorski if (IS_ERR(priv->phy_clk)) { ret = PTR_ERR(priv->phy_clk); priv->phy_clk = NULL; -@@ -1810,7 +1810,7 @@ static int bcm_enet_probe(struct platfor +@@ -1811,7 +1811,7 @@ static int bcm_enet_probe(struct platfor } ret = clk_prepare_enable(priv->phy_clk); if (ret) @@ -48,7 +48,7 @@ Signed-off-by: Jonas Gorski } /* do minimal hardware init to be able to probe mii bus */ -@@ -1907,14 +1907,8 @@ out_uninit_hw: +@@ -1908,14 +1908,8 @@ out_uninit_hw: if (priv->phy_clk) clk_disable_unprepare(priv->phy_clk); @@ -63,7 +63,7 @@ Signed-off-by: Jonas Gorski out: free_netdev(dev); return ret; -@@ -1950,12 +1944,10 @@ static int bcm_enet_remove(struct platfo +@@ -1951,12 +1945,10 @@ static int bcm_enet_remove(struct platfo } /* disable hw block clocks */ @@ -78,7 +78,7 @@ Signed-off-by: Jonas Gorski free_netdev(dev); return 0; -@@ -2738,26 +2730,20 @@ static int bcm_enetsw_probe(struct platf +@@ -2739,26 +2731,20 @@ static int bcm_enetsw_probe(struct platf if (ret) goto out; @@ -111,7 +111,7 @@ Signed-off-by: Jonas Gorski priv->rx_chan = 0; priv->tx_chan = 1; -@@ -2789,15 +2775,6 @@ static int bcm_enetsw_probe(struct platf +@@ -2790,15 +2776,6 @@ static int bcm_enetsw_probe(struct platf out_disable_clk: clk_disable_unprepare(priv->mac_clk); @@ -127,7 +127,7 @@ Signed-off-by: Jonas Gorski out: free_netdev(dev); return ret; -@@ -2809,20 +2786,13 @@ static int bcm_enetsw_remove(struct plat +@@ -2810,20 +2787,13 @@ static int bcm_enetsw_remove(struct plat { struct bcm_enet_priv *priv; struct net_device *dev; diff --git a/target/linux/brcm63xx/patches-4.14/001-4.15-12-bcm63xx_enet-drop-unneeded-NULL-phy_clk-check.patch b/target/linux/brcm63xx/patches-4.14/001-4.15-12-bcm63xx_enet-drop-unneeded-NULL-phy_clk-check.patch index d2784386a2..34fdd5c41e 100644 --- a/target/linux/brcm63xx/patches-4.14/001-4.15-12-bcm63xx_enet-drop-unneeded-NULL-phy_clk-check.patch +++ b/target/linux/brcm63xx/patches-4.14/001-4.15-12-bcm63xx_enet-drop-unneeded-NULL-phy_clk-check.patch @@ -13,7 +13,7 @@ Signed-off-by: Jonas Gorski --- a/drivers/net/ethernet/broadcom/bcm63xx_enet.c +++ b/drivers/net/ethernet/broadcom/bcm63xx_enet.c -@@ -1904,8 +1904,7 @@ out_free_mdio: +@@ -1905,8 +1905,7 @@ out_free_mdio: out_uninit_hw: /* turn off mdc clock */ enet_writel(priv, 0, ENET_MIISC_REG); @@ -23,7 +23,7 @@ Signed-off-by: Jonas Gorski out_disable_clk_mac: clk_disable_unprepare(priv->mac_clk); -@@ -1944,9 +1943,7 @@ static int bcm_enet_remove(struct platfo +@@ -1945,9 +1944,7 @@ static int bcm_enet_remove(struct platfo } /* disable hw block clocks */ diff --git a/target/linux/brcm63xx/patches-4.14/001-4.16-01-bcm63xx_enet-just-use-enet-as-the-clock-name.patch b/target/linux/brcm63xx/patches-4.14/001-4.16-01-bcm63xx_enet-just-use-enet-as-the-clock-name.patch index b3405e0eb2..c489001332 100644 --- a/target/linux/brcm63xx/patches-4.14/001-4.16-01-bcm63xx_enet-just-use-enet-as-the-clock-name.patch +++ b/target/linux/brcm63xx/patches-4.14/001-4.16-01-bcm63xx_enet-just-use-enet-as-the-clock-name.patch @@ -13,7 +13,7 @@ Signed-off-by: Jonas Gorski --- a/drivers/net/ethernet/broadcom/bcm63xx_enet.c +++ b/drivers/net/ethernet/broadcom/bcm63xx_enet.c -@@ -1719,7 +1719,6 @@ static int bcm_enet_probe(struct platfor +@@ -1720,7 +1720,6 @@ static int bcm_enet_probe(struct platfor struct bcm63xx_enet_platform_data *pd; struct resource *res_mem, *res_irq, *res_irq_rx, *res_irq_tx; struct mii_bus *bus; @@ -21,7 +21,7 @@ Signed-off-by: Jonas Gorski int i, ret; if (!bcm_enet_shared_base[0]) -@@ -1760,14 +1759,12 @@ static int bcm_enet_probe(struct platfor +@@ -1761,14 +1760,12 @@ static int bcm_enet_probe(struct platfor if (priv->mac_id == 0) { priv->rx_chan = 0; priv->tx_chan = 1; diff --git a/target/linux/brcm63xx/patches-4.14/001-4.16-02-bcm63xx_enet-use-platform-data-for-dma-channel-numbe.patch b/target/linux/brcm63xx/patches-4.14/001-4.16-02-bcm63xx_enet-use-platform-data-for-dma-channel-numbe.patch index 3a998e9309..f3ddd7445c 100644 --- a/target/linux/brcm63xx/patches-4.14/001-4.16-02-bcm63xx_enet-use-platform-data-for-dma-channel-numbe.patch +++ b/target/linux/brcm63xx/patches-4.14/001-4.16-02-bcm63xx_enet-use-platform-data-for-dma-channel-numbe.patch @@ -45,7 +45,7 @@ Signed-off-by: Jonas Gorski /* --- a/drivers/net/ethernet/broadcom/bcm63xx_enet.c +++ b/drivers/net/ethernet/broadcom/bcm63xx_enet.c -@@ -1755,15 +1755,6 @@ static int bcm_enet_probe(struct platfor +@@ -1756,15 +1756,6 @@ static int bcm_enet_probe(struct platfor priv->irq_tx = res_irq_tx->start; priv->mac_id = pdev->id; @@ -61,7 +61,7 @@ Signed-off-by: Jonas Gorski priv->mac_clk = devm_clk_get(&pdev->dev, "enet"); if (IS_ERR(priv->mac_clk)) { ret = PTR_ERR(priv->mac_clk); -@@ -1795,6 +1786,8 @@ static int bcm_enet_probe(struct platfor +@@ -1796,6 +1787,8 @@ static int bcm_enet_probe(struct platfor priv->dma_chan_width = pd->dma_chan_width; priv->dma_has_sram = pd->dma_has_sram; priv->dma_desc_shift = pd->dma_desc_shift; diff --git a/target/linux/brcm63xx/patches-4.14/001-4.16-03-bcm63xx_enet-remove-pointless-mac_id-check.patch b/target/linux/brcm63xx/patches-4.14/001-4.16-03-bcm63xx_enet-remove-pointless-mac_id-check.patch index cead5c2269..a656e4f0ab 100644 --- a/target/linux/brcm63xx/patches-4.14/001-4.16-03-bcm63xx_enet-remove-pointless-mac_id-check.patch +++ b/target/linux/brcm63xx/patches-4.14/001-4.16-03-bcm63xx_enet-remove-pointless-mac_id-check.patch @@ -14,7 +14,7 @@ Signed-off-by: Jonas Gorski --- a/drivers/net/ethernet/broadcom/bcm63xx_enet.c +++ b/drivers/net/ethernet/broadcom/bcm63xx_enet.c -@@ -1790,7 +1790,7 @@ static int bcm_enet_probe(struct platfor +@@ -1791,7 +1791,7 @@ static int bcm_enet_probe(struct platfor priv->tx_chan = pd->tx_chan; } diff --git a/target/linux/brcm63xx/patches-4.14/001-4.16-04-bcm63xx_enet-use-platform-device-id-directly-for-mii.patch b/target/linux/brcm63xx/patches-4.14/001-4.16-04-bcm63xx_enet-use-platform-device-id-directly-for-mii.patch index 200178b350..cab9e5a37a 100644 --- a/target/linux/brcm63xx/patches-4.14/001-4.16-04-bcm63xx_enet-use-platform-device-id-directly-for-mii.patch +++ b/target/linux/brcm63xx/patches-4.14/001-4.16-04-bcm63xx_enet-use-platform-device-id-directly-for-mii.patch @@ -15,7 +15,7 @@ Signed-off-by: Jonas Gorski --- a/drivers/net/ethernet/broadcom/bcm63xx_enet.c +++ b/drivers/net/ethernet/broadcom/bcm63xx_enet.c -@@ -1753,7 +1753,6 @@ static int bcm_enet_probe(struct platfor +@@ -1754,7 +1754,6 @@ static int bcm_enet_probe(struct platfor dev->irq = priv->irq = res_irq->start; priv->irq_rx = res_irq_rx->start; priv->irq_tx = res_irq_tx->start; @@ -23,7 +23,7 @@ Signed-off-by: Jonas Gorski priv->mac_clk = devm_clk_get(&pdev->dev, "enet"); if (IS_ERR(priv->mac_clk)) { -@@ -1821,7 +1820,7 @@ static int bcm_enet_probe(struct platfor +@@ -1822,7 +1821,7 @@ static int bcm_enet_probe(struct platfor bus->priv = priv; bus->read = bcm_enet_mdio_read_phylib; bus->write = bcm_enet_mdio_write_phylib; diff --git a/target/linux/brcm63xx/patches-4.14/001-4.21-01-BCM63XX-fix-switch-core-reset-on-BCM6368.patch b/target/linux/brcm63xx/patches-4.14/001-4.21-01-BCM63XX-fix-switch-core-reset-on-BCM6368.patch deleted file mode 100644 index 3914865c89..0000000000 --- a/target/linux/brcm63xx/patches-4.14/001-4.21-01-BCM63XX-fix-switch-core-reset-on-BCM6368.patch +++ /dev/null @@ -1,26 +0,0 @@ -From f1af8bb8e0879a3c2d9679a7274c2774335e9876 Mon Sep 17 00:00:00 2001 -From: Jonas Gorski -Date: Wed, 14 Nov 2018 12:06:41 +0100 -Subject: [PATCH] MIPS: BCM63XX: fix switch core reset on BCM6368 - -The Ethernet Switch core mask was set to 0, causing the switch core to -be not reset on BCM6368 on boot. Provide the proper mask so the switch -core gets reset to a known good state. - -Fixes: 799faa626c71 ("MIPS: BCM63XX: add core reset helper") -Signed-off-by: Jonas Gorski ---- - arch/mips/bcm63xx/reset.c | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - ---- a/arch/mips/bcm63xx/reset.c -+++ b/arch/mips/bcm63xx/reset.c -@@ -120,7 +120,7 @@ - #define BCM6368_RESET_DSL 0 - #define BCM6368_RESET_SAR SOFTRESET_6368_SAR_MASK - #define BCM6368_RESET_EPHY SOFTRESET_6368_EPHY_MASK --#define BCM6368_RESET_ENETSW 0 -+#define BCM6368_RESET_ENETSW SOFTRESET_6368_ENETSW_MASK - #define BCM6368_RESET_PCM SOFTRESET_6368_PCM_MASK - #define BCM6368_RESET_MPI SOFTRESET_6368_MPI_MASK - #define BCM6368_RESET_PCIE 0 diff --git a/target/linux/brcm63xx/patches-4.14/402_bcm63xx_enet_vlan_incoming_fixed.patch b/target/linux/brcm63xx/patches-4.14/402_bcm63xx_enet_vlan_incoming_fixed.patch index 6275306975..3604910d39 100644 --- a/target/linux/brcm63xx/patches-4.14/402_bcm63xx_enet_vlan_incoming_fixed.patch +++ b/target/linux/brcm63xx/patches-4.14/402_bcm63xx_enet_vlan_incoming_fixed.patch @@ -1,6 +1,6 @@ --- a/drivers/net/ethernet/broadcom/bcm63xx_enet.c +++ b/drivers/net/ethernet/broadcom/bcm63xx_enet.c -@@ -1636,7 +1636,7 @@ static int bcm_enet_change_mtu(struct ne +@@ -1637,7 +1637,7 @@ static int bcm_enet_change_mtu(struct ne return -EBUSY; /* add ethernet header + vlan tag size */ diff --git a/target/linux/brcm63xx/patches-4.14/404-NET-bcm63xx_enet-move-phy_-dis-connect-into-probe-re.patch b/target/linux/brcm63xx/patches-4.14/404-NET-bcm63xx_enet-move-phy_-dis-connect-into-probe-re.patch index 13eecaf0ed..c9532e6cb4 100644 --- a/target/linux/brcm63xx/patches-4.14/404-NET-bcm63xx_enet-move-phy_-dis-connect-into-probe-re.patch +++ b/target/linux/brcm63xx/patches-4.14/404-NET-bcm63xx_enet-move-phy_-dis-connect-into-probe-re.patch @@ -15,7 +15,7 @@ Signed-off-by: Jonas Gorski --- a/drivers/net/ethernet/broadcom/bcm63xx_enet.c +++ b/drivers/net/ethernet/broadcom/bcm63xx_enet.c -@@ -869,10 +869,8 @@ static int bcm_enet_open(struct net_devi +@@ -870,10 +870,8 @@ static int bcm_enet_open(struct net_devi struct bcm_enet_priv *priv; struct sockaddr addr; struct device *kdev; @@ -26,7 +26,7 @@ Signed-off-by: Jonas Gorski void *p; u32 val; -@@ -880,40 +878,10 @@ static int bcm_enet_open(struct net_devi +@@ -881,40 +879,10 @@ static int bcm_enet_open(struct net_devi kdev = &priv->pdev->dev; if (priv->has_phy) { @@ -68,7 +68,7 @@ Signed-off-by: Jonas Gorski } /* mask all interrupts and request them */ -@@ -923,7 +891,7 @@ static int bcm_enet_open(struct net_devi +@@ -924,7 +892,7 @@ static int bcm_enet_open(struct net_devi ret = request_irq(dev->irq, bcm_enet_isr_mac, 0, dev->name, dev); if (ret) @@ -77,7 +77,7 @@ Signed-off-by: Jonas Gorski ret = request_irq(priv->irq_rx, bcm_enet_isr_dma, 0, dev->name, dev); -@@ -1085,8 +1053,8 @@ static int bcm_enet_open(struct net_devi +@@ -1086,8 +1054,8 @@ static int bcm_enet_open(struct net_devi enet_dmac_writel(priv, priv->dma_chan_int_mask, ENETDMAC_IRMASK, priv->tx_chan); @@ -88,7 +88,7 @@ Signed-off-by: Jonas Gorski else bcm_enet_adjust_link(dev); -@@ -1127,10 +1095,6 @@ out_freeirq_rx: +@@ -1128,10 +1096,6 @@ out_freeirq_rx: out_freeirq: free_irq(dev->irq, dev); @@ -99,7 +99,7 @@ Signed-off-by: Jonas Gorski return ret; } -@@ -1235,10 +1199,6 @@ static int bcm_enet_stop(struct net_devi +@@ -1236,10 +1200,6 @@ static int bcm_enet_stop(struct net_devi free_irq(priv->irq_rx, dev); free_irq(dev->irq, dev); @@ -110,7 +110,7 @@ Signed-off-by: Jonas Gorski return 0; } -@@ -1804,14 +1764,49 @@ static int bcm_enet_probe(struct platfor +@@ -1805,14 +1765,49 @@ static int bcm_enet_probe(struct platfor /* do minimal hardware init to be able to probe mii bus */ bcm_enet_hw_preinit(priv); @@ -161,7 +161,7 @@ Signed-off-by: Jonas Gorski } bus = priv->mii_bus; -@@ -1835,6 +1830,35 @@ static int bcm_enet_probe(struct platfor +@@ -1836,6 +1831,35 @@ static int bcm_enet_probe(struct platfor dev_err(&pdev->dev, "unable to register mdio bus\n"); goto out_free_mdio; } @@ -197,7 +197,7 @@ Signed-off-by: Jonas Gorski } else { /* run platform code to initialize PHY device */ -@@ -1842,47 +1866,16 @@ static int bcm_enet_probe(struct platfor +@@ -1843,47 +1867,16 @@ static int bcm_enet_probe(struct platfor pd->mii_config(dev, 1, bcm_enet_mdio_read_mii, bcm_enet_mdio_write_mii)) { dev_err(&pdev->dev, "unable to configure mdio bus\n"); @@ -249,7 +249,7 @@ Signed-off-by: Jonas Gorski if (priv->mii_bus) mdiobus_unregister(priv->mii_bus); -@@ -1890,6 +1883,9 @@ out_free_mdio: +@@ -1891,6 +1884,9 @@ out_free_mdio: if (priv->mii_bus) mdiobus_free(priv->mii_bus); @@ -259,7 +259,7 @@ Signed-off-by: Jonas Gorski out_uninit_hw: /* turn off mdc clock */ enet_writel(priv, 0, ENET_MIISC_REG); -@@ -1920,6 +1916,7 @@ static int bcm_enet_remove(struct platfo +@@ -1921,6 +1917,7 @@ static int bcm_enet_remove(struct platfo enet_writel(priv, 0, ENET_MIISC_REG); if (priv->has_phy) { diff --git a/target/linux/brcm63xx/patches-4.14/408-bcm63xx_enet-enable-rgmii-clock-on-external-ports.patch b/target/linux/brcm63xx/patches-4.14/408-bcm63xx_enet-enable-rgmii-clock-on-external-ports.patch index 7a1a56a00e..7bd1e51e7e 100644 --- a/target/linux/brcm63xx/patches-4.14/408-bcm63xx_enet-enable-rgmii-clock-on-external-ports.patch +++ b/target/linux/brcm63xx/patches-4.14/408-bcm63xx_enet-enable-rgmii-clock-on-external-ports.patch @@ -32,7 +32,7 @@ Subject: [PATCH 54/81] bcm63xx_enet: enable rgmii clock on external ports #define ENETSW_MDIOC_EXT_MASK (1 << 16) --- a/drivers/net/ethernet/broadcom/bcm63xx_enet.c +++ b/drivers/net/ethernet/broadcom/bcm63xx_enet.c -@@ -2191,6 +2191,18 @@ static int bcm_enetsw_open(struct net_de +@@ -2192,6 +2192,18 @@ static int bcm_enetsw_open(struct net_de priv->sw_port_link[i] = 0; } diff --git a/target/linux/brcm63xx/patches-4.14/423-bcm63xx_enet_add_b53_support.patch b/target/linux/brcm63xx/patches-4.14/423-bcm63xx_enet_add_b53_support.patch index ba2a8f93dd..58f1b13d38 100644 --- a/target/linux/brcm63xx/patches-4.14/423-bcm63xx_enet_add_b53_support.patch +++ b/target/linux/brcm63xx/patches-4.14/423-bcm63xx_enet_add_b53_support.patch @@ -20,7 +20,7 @@ #include #include "bcm63xx_enet.h" -@@ -1936,7 +1937,8 @@ static int bcm_enet_remove(struct platfo +@@ -1937,7 +1938,8 @@ static int bcm_enet_remove(struct platfo return 0; } @@ -30,7 +30,7 @@ .probe = bcm_enet_probe, .remove = bcm_enet_remove, .driver = { -@@ -1945,6 +1947,42 @@ struct platform_driver bcm63xx_enet_driv +@@ -1946,6 +1948,42 @@ struct platform_driver bcm63xx_enet_driv }, }; @@ -73,7 +73,7 @@ /* * switch mii access callbacks */ -@@ -2203,29 +2241,6 @@ static int bcm_enetsw_open(struct net_de +@@ -2204,29 +2242,6 @@ static int bcm_enetsw_open(struct net_de enetsw_writeb(priv, rgmii_ctrl, ENETSW_RGMII_CTRL_REG(i)); } @@ -103,7 +103,7 @@ /* initialize flow control buffer allocation */ enet_dma_writel(priv, ENETDMA_BUFALLOC_FORCE_MASK | 0, ENETDMA_BUFALLOC_REG(priv->rx_chan)); -@@ -2684,6 +2699,9 @@ static int bcm_enetsw_probe(struct platf +@@ -2685,6 +2700,9 @@ static int bcm_enetsw_probe(struct platf struct bcm63xx_enetsw_platform_data *pd; struct resource *res_mem; int ret, irq_rx, irq_tx; @@ -113,7 +113,7 @@ if (!bcm_enet_shared_base[0]) return -EPROBE_DEFER; -@@ -2766,6 +2784,43 @@ static int bcm_enetsw_probe(struct platf +@@ -2767,6 +2785,43 @@ static int bcm_enetsw_probe(struct platf priv->pdev = pdev; priv->net_dev = dev; @@ -157,7 +157,7 @@ return 0; out_disable_clk: -@@ -2787,6 +2842,9 @@ static int bcm_enetsw_remove(struct plat +@@ -2788,6 +2843,9 @@ static int bcm_enetsw_remove(struct plat priv = netdev_priv(dev); unregister_netdev(dev); diff --git a/target/linux/brcm63xx/patches-4.14/424-bcm63xx_enet_no_request_mem_region.patch b/target/linux/brcm63xx/patches-4.14/424-bcm63xx_enet_no_request_mem_region.patch index 79f6b9a1d2..6235c8cad6 100644 --- a/target/linux/brcm63xx/patches-4.14/424-bcm63xx_enet_no_request_mem_region.patch +++ b/target/linux/brcm63xx/patches-4.14/424-bcm63xx_enet_no_request_mem_region.patch @@ -1,6 +1,6 @@ --- a/drivers/net/ethernet/broadcom/bcm63xx_enet.c +++ b/drivers/net/ethernet/broadcom/bcm63xx_enet.c -@@ -2743,9 +2743,9 @@ static int bcm_enetsw_probe(struct platf +@@ -2744,9 +2744,9 @@ static int bcm_enetsw_probe(struct platf if (ret) goto out; diff --git a/target/linux/brcm63xx/patches-4.14/804-bcm63xx_enet_63268_rgmii_ports.patch b/target/linux/brcm63xx/patches-4.14/804-bcm63xx_enet_63268_rgmii_ports.patch index 743b04b438..2d990f78e8 100644 --- a/target/linux/brcm63xx/patches-4.14/804-bcm63xx_enet_63268_rgmii_ports.patch +++ b/target/linux/brcm63xx/patches-4.14/804-bcm63xx_enet_63268_rgmii_ports.patch @@ -1,6 +1,6 @@ --- a/drivers/net/ethernet/broadcom/bcm63xx_enet.c +++ b/drivers/net/ethernet/broadcom/bcm63xx_enet.c -@@ -2238,6 +2238,10 @@ static int bcm_enetsw_open(struct net_de +@@ -2239,6 +2239,10 @@ static int bcm_enetsw_open(struct net_de rgmii_ctrl = enetsw_readb(priv, ENETSW_RGMII_CTRL_REG(i)); rgmii_ctrl |= ENETSW_RGMII_CTRL_GMII_CLK_EN; diff --git a/target/linux/ipq40xx/patches-4.14/073-qcom-ipq4019-fix-cpu0-s-qcom-saw2-reg-value.patch b/target/linux/ipq40xx/patches-4.14/073-qcom-ipq4019-fix-cpu0-s-qcom-saw2-reg-value.patch deleted file mode 100644 index ac128ab9e1..0000000000 --- a/target/linux/ipq40xx/patches-4.14/073-qcom-ipq4019-fix-cpu0-s-qcom-saw2-reg-value.patch +++ /dev/null @@ -1,33 +0,0 @@ -From d60e006ec0e425877aacc61c7ece3da0434a8fce Mon Sep 17 00:00:00 2001 -From: Christian Lamparter -Date: Mon, 23 Jul 2018 16:34:54 +0200 -Subject: [PATCH 7/8] qcom: ipq4019: fix cpu0's qcom,saw2 reg value - -while compiling an ipq4019 target, dtc will complain: -regulator@b089000 unit address format error, expected "2089000" - -The saw0 regulator reg value seems to be -copied and pasted from qcom-ipq8064.dtsi. - -This patch fixes the reg value to match that of the -unit address which in turn silences the warning. -(There is no driver for qcom,saw2 right now. -So this went unnoticed) - -Signed-off-by: Christian Lamparter -Signed-off-by: John Crispin ---- - arch/arm/boot/dts/qcom-ipq4019.dtsi | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - ---- a/arch/arm/boot/dts/qcom-ipq4019.dtsi -+++ b/arch/arm/boot/dts/qcom-ipq4019.dtsi -@@ -266,7 +266,7 @@ - - saw0: regulator@b089000 { - compatible = "qcom,saw2"; -- reg = <0x02089000 0x1000>, <0x0b009000 0x1000>; -+ reg = <0x0b089000 0x1000>, <0x0b009000 0x1000>; - regulator; - }; - diff --git a/target/linux/ipq806x/patches-4.14/0048-PM-OPP-HACK-Allow-to-set-regulator-without-opp_list.patch b/target/linux/ipq806x/patches-4.14/0048-PM-OPP-HACK-Allow-to-set-regulator-without-opp_list.patch index 7c78d444f8..cca2fcaa4f 100644 --- a/target/linux/ipq806x/patches-4.14/0048-PM-OPP-HACK-Allow-to-set-regulator-without-opp_list.patch +++ b/target/linux/ipq806x/patches-4.14/0048-PM-OPP-HACK-Allow-to-set-regulator-without-opp_list.patch @@ -10,7 +10,7 @@ Signed-off-by: Georgi Djakov --- a/drivers/base/power/opp/core.c +++ b/drivers/base/power/opp/core.c -@@ -1280,11 +1280,13 @@ struct opp_table *dev_pm_opp_set_regulat +@@ -1292,11 +1292,13 @@ struct opp_table *dev_pm_opp_set_regulat if (!opp_table) return ERR_PTR(-ENOMEM); diff --git a/target/linux/ipq806x/patches-4.14/0049-PM-OPP-Support-adjusting-OPP-voltages-at-runtime.patch b/target/linux/ipq806x/patches-4.14/0049-PM-OPP-Support-adjusting-OPP-voltages-at-runtime.patch index ef48e9f01b..9f7c8185e9 100644 --- a/target/linux/ipq806x/patches-4.14/0049-PM-OPP-Support-adjusting-OPP-voltages-at-runtime.patch +++ b/target/linux/ipq806x/patches-4.14/0049-PM-OPP-Support-adjusting-OPP-voltages-at-runtime.patch @@ -27,7 +27,7 @@ Signed-off-by: Georgi Djakov --- a/drivers/base/power/opp/core.c +++ b/drivers/base/power/opp/core.c -@@ -1608,6 +1608,83 @@ put_table: +@@ -1620,6 +1620,83 @@ put_table: } /** diff --git a/target/linux/ipq806x/patches-4.14/0051-PM-OPP-Add-a-helper-to-get-an-opp-regulator-for-devi.patch b/target/linux/ipq806x/patches-4.14/0051-PM-OPP-Add-a-helper-to-get-an-opp-regulator-for-devi.patch index 22ae309801..7819dc0dd8 100644 --- a/target/linux/ipq806x/patches-4.14/0051-PM-OPP-Add-a-helper-to-get-an-opp-regulator-for-devi.patch +++ b/target/linux/ipq806x/patches-4.14/0051-PM-OPP-Add-a-helper-to-get-an-opp-regulator-for-devi.patch @@ -12,7 +12,7 @@ Signed-off-by: Georgi Djakov --- a/drivers/base/power/opp/core.c +++ b/drivers/base/power/opp/core.c -@@ -126,6 +126,27 @@ unsigned long dev_pm_opp_get_freq(struct +@@ -131,6 +131,27 @@ unsigned long dev_pm_opp_get_freq(struct } EXPORT_SYMBOL_GPL(dev_pm_opp_get_freq); diff --git a/target/linux/ipq806x/patches-4.14/0052-PM-OPP-Update-the-voltage-tolerance-when-adjusting-t.patch b/target/linux/ipq806x/patches-4.14/0052-PM-OPP-Update-the-voltage-tolerance-when-adjusting-t.patch index 7cde22be0b..3105b4ea1b 100644 --- a/target/linux/ipq806x/patches-4.14/0052-PM-OPP-Update-the-voltage-tolerance-when-adjusting-t.patch +++ b/target/linux/ipq806x/patches-4.14/0052-PM-OPP-Update-the-voltage-tolerance-when-adjusting-t.patch @@ -17,7 +17,7 @@ Signed-off-by: Georgi Djakov --- a/drivers/base/power/opp/core.c +++ b/drivers/base/power/opp/core.c -@@ -1652,6 +1652,7 @@ int dev_pm_opp_adjust_voltage(struct dev +@@ -1664,6 +1664,7 @@ int dev_pm_opp_adjust_voltage(struct dev struct opp_table *opp_table; struct dev_pm_opp *new_opp, *tmp_opp, *opp = ERR_PTR(-ENODEV); int r = 0; @@ -25,7 +25,7 @@ Signed-off-by: Georgi Djakov /* keep the node allocated */ new_opp = kmalloc(sizeof(*new_opp), GFP_KERNEL); -@@ -1688,6 +1689,10 @@ int dev_pm_opp_adjust_voltage(struct dev +@@ -1700,6 +1701,10 @@ int dev_pm_opp_adjust_voltage(struct dev /* plug in new node */ new_opp->supplies[0].u_volt = u_volt; diff --git a/target/linux/layerscape/patches-4.14/707-dpaa-ethernet-support-layerscape.patch b/target/linux/layerscape/patches-4.14/707-dpaa-ethernet-support-layerscape.patch index 18d4e47e04..e09a39e113 100644 --- a/target/linux/layerscape/patches-4.14/707-dpaa-ethernet-support-layerscape.patch +++ b/target/linux/layerscape/patches-4.14/707-dpaa-ethernet-support-layerscape.patch @@ -922,7 +922,7 @@ Signed-off-by: Zhao Qiang * * We must do this before dma_map_single(DMA_TO_DEVICE), because we may * need to write into the skb. -@@ -2036,12 +2091,129 @@ static inline int dpaa_xmit(struct dpaa_ +@@ -2036,6 +2091,121 @@ static inline int dpaa_xmit(struct dpaa_ return 0; } @@ -935,15 +935,15 @@ Signed-off-by: Zhao Qiang + * the buffers + */ + -+#define DPAA_A010022_HEADROOM 256 ++#define DPAA_A010022_HEADROOM 256 +#define CROSS_4K_BOUND(start, size) \ -+ (((start) + (size)) > (((start) + 0x1000) & ~0xFFF)) ++ (((start) + (size)) > (((start) + 0x1000) & ~0xFFF)) + +static bool dpaa_errata_a010022_has_dma_issue(struct sk_buff *skb, + struct dpaa_priv *priv) +{ + int nr_frags, i = 0; -+ skb_frag_t *frag; ++ skb_frag_t *frag; + + /* Transfers that do not start at 16B aligned addresses will be split; + * Transfers that cross a 4K page boundary will also be split @@ -1023,7 +1023,6 @@ Signed-off-by: Zhao Qiang + goto err; + } + copy_skb_header(nskb, skb); -+ + /* We move the headroom when we align it so we have to reset the + * network and transport header offsets relative to the new data + * pointer. The checksum offload relies on these offsets. @@ -1042,9 +1041,10 @@ Signed-off-by: Zhao Qiang +} +#endif + - static int dpaa_start_xmit(struct sk_buff *skb, struct net_device *net_dev) + static netdev_tx_t + dpaa_start_xmit(struct sk_buff *skb, struct net_device *net_dev) { - const int queue_mapping = skb_get_queue_mapping(skb); +@@ -2043,6 +2213,7 @@ dpaa_start_xmit(struct sk_buff *skb, str bool nonlinear = skb_is_nonlinear(skb); struct rtnl_link_stats64 *percpu_stats; struct dpaa_percpu_priv *percpu_priv; @@ -1052,7 +1052,7 @@ Signed-off-by: Zhao Qiang struct dpaa_priv *priv; struct qm_fd fd; int offset = 0; -@@ -2069,24 +2241,47 @@ static int dpaa_start_xmit(struct sk_buf +@@ -2070,24 +2241,47 @@ dpaa_start_xmit(struct sk_buff *skb, str /* MAX_SKB_FRAGS is equal or larger than our dpaa_SGT_MAX_ENTRIES; * make sure we don't feed FMan with more fragments than it supports. */ @@ -1108,7 +1108,7 @@ Signed-off-by: Zhao Qiang if (likely(dpaa_xmit(priv, percpu_stats, queue_mapping, &fd) == 0)) return NETDEV_TX_OK; -@@ -2218,14 +2413,8 @@ static enum qman_cb_dqrr_result rx_error +@@ -2219,14 +2413,8 @@ static enum qman_cb_dqrr_result rx_error if (dpaa_eth_napi_schedule(percpu_priv, portal)) return qman_cb_dqrr_stop; @@ -1125,7 +1125,7 @@ Signed-off-by: Zhao Qiang return qman_cb_dqrr_consume; } -@@ -2234,6 +2423,7 @@ static enum qman_cb_dqrr_result rx_defau +@@ -2235,6 +2423,7 @@ static enum qman_cb_dqrr_result rx_defau struct qman_fq *fq, const struct qm_dqrr_entry *dq) { @@ -1133,7 +1133,7 @@ Signed-off-by: Zhao Qiang struct rtnl_link_stats64 *percpu_stats; struct dpaa_percpu_priv *percpu_priv; const struct qm_fd *fd = &dq->fd; -@@ -2247,6 +2437,7 @@ static enum qman_cb_dqrr_result rx_defau +@@ -2248,6 +2437,7 @@ static enum qman_cb_dqrr_result rx_defau struct sk_buff *skb; int *count_ptr; void *vaddr; @@ -1141,7 +1141,7 @@ Signed-off-by: Zhao Qiang fd_status = be32_to_cpu(fd->status); fd_format = qm_fd_get_format(fd); -@@ -2289,12 +2480,12 @@ static enum qman_cb_dqrr_result rx_defau +@@ -2290,12 +2480,12 @@ static enum qman_cb_dqrr_result rx_defau if (!dpaa_bp) return qman_cb_dqrr_consume; @@ -1157,7 +1157,7 @@ Signed-off-by: Zhao Qiang /* The only FD types that we may receive are contig and S/G */ WARN_ON((fd_format != qm_fd_contig) && (fd_format != qm_fd_sg)); -@@ -2305,12 +2496,22 @@ static enum qman_cb_dqrr_result rx_defau +@@ -2306,12 +2496,22 @@ static enum qman_cb_dqrr_result rx_defau (*count_ptr)--; if (likely(fd_format == qm_fd_contig)) @@ -1182,7 +1182,7 @@ Signed-off-by: Zhao Qiang skb->protocol = eth_type_trans(skb, net_dev); if (net_dev->features & NETIF_F_RXHASH && priv->keygen_in_use && -@@ -2439,6 +2640,44 @@ static void dpaa_eth_napi_disable(struct +@@ -2440,6 +2640,44 @@ static void dpaa_eth_napi_disable(struct } } @@ -1227,7 +1227,7 @@ Signed-off-by: Zhao Qiang static int dpaa_open(struct net_device *net_dev) { struct mac_device *mac_dev; -@@ -2449,12 +2688,9 @@ static int dpaa_open(struct net_device * +@@ -2450,12 +2688,9 @@ static int dpaa_open(struct net_device * mac_dev = priv->mac_dev; dpaa_eth_napi_enable(priv); @@ -1242,7 +1242,7 @@ Signed-off-by: Zhao Qiang for (i = 0; i < ARRAY_SIZE(mac_dev->port); i++) { err = fman_port_enable(mac_dev->port[i]); -@@ -2495,11 +2731,58 @@ static int dpaa_eth_stop(struct net_devi +@@ -2496,11 +2731,58 @@ static int dpaa_eth_stop(struct net_devi return err; } @@ -1304,7 +1304,7 @@ Signed-off-by: Zhao Qiang } static const struct net_device_ops dpaa_ops = { -@@ -2653,7 +2936,6 @@ static inline u16 dpaa_get_headroom(stru +@@ -2654,7 +2936,6 @@ static inline u16 dpaa_get_headroom(stru static int dpaa_eth_probe(struct platform_device *pdev) { struct dpaa_bp *dpaa_bps[DPAA_BPS_NUM] = {NULL}; @@ -1312,7 +1312,7 @@ Signed-off-by: Zhao Qiang struct net_device *net_dev = NULL; struct dpaa_fq *dpaa_fq, *tmp; struct dpaa_priv *priv = NULL; -@@ -2662,7 +2944,51 @@ static int dpaa_eth_probe(struct platfor +@@ -2663,7 +2944,51 @@ static int dpaa_eth_probe(struct platfor int err = 0, i, channel; struct device *dev; @@ -1365,7 +1365,7 @@ Signed-off-by: Zhao Qiang /* Allocate this early, so we can store relevant information in * the private area -@@ -2670,7 +2996,7 @@ static int dpaa_eth_probe(struct platfor +@@ -2671,7 +2996,7 @@ static int dpaa_eth_probe(struct platfor net_dev = alloc_etherdev_mq(sizeof(*priv), DPAA_ETH_TXQ_NUM); if (!net_dev) { dev_err(dev, "alloc_etherdev_mq() failed\n"); @@ -1374,7 +1374,7 @@ Signed-off-by: Zhao Qiang } /* Do this here, so we can be verbose early */ -@@ -2682,13 +3008,6 @@ static int dpaa_eth_probe(struct platfor +@@ -2683,13 +3008,6 @@ static int dpaa_eth_probe(struct platfor priv->msg_enable = netif_msg_init(debug, DPAA_MSG_DEFAULT); @@ -1388,7 +1388,7 @@ Signed-off-by: Zhao Qiang /* If fsl_fm_max_frm is set to a higher value than the all-common 1500, * we choose conservatively and let the user explicitly set a higher * MTU via ifconfig. Otherwise, the user may end up with different MTUs -@@ -2704,21 +3023,13 @@ static int dpaa_eth_probe(struct platfor +@@ -2705,21 +3023,13 @@ static int dpaa_eth_probe(struct platfor priv->buf_layout[RX].priv_data_size = DPAA_RX_PRIV_DATA_SIZE; /* Rx */ priv->buf_layout[TX].priv_data_size = DPAA_TX_PRIV_DATA_SIZE; /* Tx */ @@ -1414,7 +1414,7 @@ Signed-off-by: Zhao Qiang /* the raw size of the buffers used for reception */ dpaa_bps[i]->raw_size = bpool_buffer_raw_size(i, DPAA_BPS_NUM); /* avoid runtime computations by keeping the usable size here */ -@@ -2726,11 +3037,8 @@ static int dpaa_eth_probe(struct platfor +@@ -2727,11 +3037,8 @@ static int dpaa_eth_probe(struct platfor dpaa_bps[i]->dev = dev; err = dpaa_bp_alloc_pool(dpaa_bps[i]); @@ -1428,7 +1428,7 @@ Signed-off-by: Zhao Qiang priv->dpaa_bps[i] = dpaa_bps[i]; } -@@ -2741,7 +3049,7 @@ static int dpaa_eth_probe(struct platfor +@@ -2742,7 +3049,7 @@ static int dpaa_eth_probe(struct platfor err = dpaa_alloc_all_fqs(dev, &priv->dpaa_fq_list, &port_fqs); if (err < 0) { dev_err(dev, "dpaa_alloc_all_fqs() failed\n"); @@ -1437,7 +1437,7 @@ Signed-off-by: Zhao Qiang } priv->mac_dev = mac_dev; -@@ -2750,12 +3058,12 @@ static int dpaa_eth_probe(struct platfor +@@ -2751,12 +3058,12 @@ static int dpaa_eth_probe(struct platfor if (channel < 0) { dev_err(dev, "dpaa_get_channel() failed\n"); err = channel; @@ -1452,7 +1452,7 @@ Signed-off-by: Zhao Qiang * and add this pool channel to each's dequeue mask. */ dpaa_eth_add_channel(priv->channel); -@@ -2770,20 +3078,20 @@ static int dpaa_eth_probe(struct platfor +@@ -2771,20 +3078,20 @@ static int dpaa_eth_probe(struct platfor err = dpaa_eth_cgr_init(priv); if (err < 0) { dev_err(dev, "Error initializing CGR\n"); @@ -1476,7 +1476,7 @@ Signed-off-by: Zhao Qiang } priv->tx_headroom = dpaa_get_headroom(&priv->buf_layout[TX]); -@@ -2793,7 +3101,7 @@ static int dpaa_eth_probe(struct platfor +@@ -2794,7 +3101,7 @@ static int dpaa_eth_probe(struct platfor err = dpaa_eth_init_ports(mac_dev, dpaa_bps, DPAA_BPS_NUM, &port_fqs, &priv->buf_layout[0], dev); if (err) @@ -1485,7 +1485,7 @@ Signed-off-by: Zhao Qiang /* Rx traffic distribution based on keygen hashing defaults to on */ priv->keygen_in_use = true; -@@ -2802,11 +3110,7 @@ static int dpaa_eth_probe(struct platfor +@@ -2803,11 +3110,7 @@ static int dpaa_eth_probe(struct platfor if (!priv->percpu_priv) { dev_err(dev, "devm_alloc_percpu() failed\n"); err = -ENOMEM; @@ -1498,7 +1498,7 @@ Signed-off-by: Zhao Qiang } priv->num_tc = 1; -@@ -2815,11 +3119,11 @@ static int dpaa_eth_probe(struct platfor +@@ -2816,11 +3119,11 @@ static int dpaa_eth_probe(struct platfor /* Initialize NAPI */ err = dpaa_napi_add(net_dev); if (err < 0) @@ -1512,7 +1512,7 @@ Signed-off-by: Zhao Qiang dpaa_eth_sysfs_init(&net_dev->dev); -@@ -2828,32 +3132,21 @@ static int dpaa_eth_probe(struct platfor +@@ -2829,32 +3132,21 @@ static int dpaa_eth_probe(struct platfor return 0; @@ -1551,7 +1551,7 @@ Signed-off-by: Zhao Qiang return err; } -@@ -2890,6 +3183,23 @@ static int dpaa_remove(struct platform_d +@@ -2891,6 +3183,23 @@ static int dpaa_remove(struct platform_d return err; } @@ -1575,7 +1575,7 @@ Signed-off-by: Zhao Qiang static const struct platform_device_id dpaa_devtype[] = { { .name = "dpaa-ethernet", -@@ -2914,6 +3224,10 @@ static int __init dpaa_load(void) +@@ -2915,6 +3224,10 @@ static int __init dpaa_load(void) pr_debug("FSL DPAA Ethernet driver\n"); diff --git a/target/linux/mediatek/patches-4.14/0127-usb-xhci-mtk-use-ports-count-from-xhci-in-xhci_mtk_s.patch b/target/linux/mediatek/patches-4.14/0127-usb-xhci-mtk-use-ports-count-from-xhci-in-xhci_mtk_s.patch index 15c1b29dca..f17da7003f 100644 --- a/target/linux/mediatek/patches-4.14/0127-usb-xhci-mtk-use-ports-count-from-xhci-in-xhci_mtk_s.patch +++ b/target/linux/mediatek/patches-4.14/0127-usb-xhci-mtk-use-ports-count-from-xhci-in-xhci_mtk_s.patch @@ -17,7 +17,7 @@ Signed-off-by: Greg Kroah-Hartman --- a/drivers/usb/host/xhci-mtk-sch.c +++ b/drivers/usb/host/xhci-mtk-sch.c -@@ -287,12 +287,13 @@ static bool need_bw_sch(struct usb_host_ +@@ -289,12 +289,13 @@ static bool need_bw_sch(struct usb_host_ int xhci_mtk_sch_init(struct xhci_hcd_mtk *mtk) { From e29500eb849a18fa988a6ce53e10ad8c188e35df Mon Sep 17 00:00:00 2001 From: Koen Vandeputte Date: Thu, 21 Nov 2019 14:09:35 +0100 Subject: [PATCH 04/17] kernel: bump 4.19 to 4.19.85 Refreshed all patches. Altered patches: - 080-sata_support.patch Remove upstreamed: - 034-v4.20-MIPS-BCM47XX-Enable-USB-power-on-Netgear-WNDR3400v3.patch - 001-4.21-01-BCM63XX-fix-switch-core-reset-on-BCM6368.patch - 073-qcom-ipq4019-fix-cpu0-s-qcom-saw2-reg-value.patch Compile-tested on: cns3xxx Runtime-tested on: cns3xxx Signed-off-by: Koen Vandeputte --- include/kernel-version.mk | 4 +- ...-t-prevent-IRQ-usage-of-output-GPIOs.patch | 4 +- ...Disable-TCP-Segmentation-Offload-TSO.patch | 2 +- ...e-link-events-to-minimize-poll-storm.patch | 2 +- ...use-default-alignment-for-rx-buffers.patch | 2 +- ...-link-energy-detect-powerdown-for-ex.patch | 2 +- ...-gpio-Allow-nonexclusive-GPIO-access.patch | 2 +- ...le-nonexclusive-gpiods-from-DT-nodes.patch | 2 +- ...able-USB-power-on-Netgear-WNDR3400v3.patch | 48 ------------------- ...3XX-fix-switch-core-reset-on-BCM6368.patch | 26 ---------- ...402_bcm63xx_enet_vlan_incoming_fixed.patch | 2 +- ...-move-phy_-dis-connect-into-probe-re.patch | 22 ++++----- ...enable-rgmii-clock-on-external-ports.patch | 2 +- .../423-bcm63xx_enet_add_b53_support.patch | 12 ++--- ...4-bcm63xx_enet_no_request_mem_region.patch | 2 +- .../804-bcm63xx_enet_63268_rgmii_ports.patch | 2 +- .../patches-4.19/080-sata_support.patch | 28 ++++++++--- ...w_table-add-hardware-offload-support.patch | 6 +-- ...q4019-fix-cpu0-s-qcom-saw2-reg-value.patch | 34 ------------- .../0101-pci-mediatek-backport-fix-pcie.patch | 8 ++-- 20 files changed, 59 insertions(+), 153 deletions(-) delete mode 100644 target/linux/brcm47xx/patches-4.19/030-v4.20-MIPS-BCM47XX-Enable-USB-power-on-Netgear-WNDR3400v3.patch delete mode 100644 target/linux/brcm63xx/patches-4.19/001-4.21-01-BCM63XX-fix-switch-core-reset-on-BCM6368.patch delete mode 100644 target/linux/ipq40xx/patches-4.19/073-v4.20-ARM-dts-qcom-ipq4019-fix-cpu0-s-qcom-saw2-reg-value.patch diff --git a/include/kernel-version.mk b/include/kernel-version.mk index 0050a35ff5..e8be42afc4 100644 --- a/include/kernel-version.mk +++ b/include/kernel-version.mk @@ -8,11 +8,11 @@ endif LINUX_VERSION-4.9 = .202 LINUX_VERSION-4.14 = .155 -LINUX_VERSION-4.19 = .84 +LINUX_VERSION-4.19 = .85 LINUX_KERNEL_HASH-4.9.202 = 8108ec1cd10fc40821c84e9f087dba10b1767aad66596f4a36925faef55e4ebf LINUX_KERNEL_HASH-4.14.155 = 77d61979556b81c95b81452fa10e1fe9368cbe2f9f80a13e4669b0464722e481 -LINUX_KERNEL_HASH-4.19.84 = 868b4a92619cb00ab142a20a67f000525b9605820d1b66faa4a183133eac0660 +LINUX_KERNEL_HASH-4.19.85 = 7bf435970aeeafd46263f49730087a61c4858d8b8fc5a4002ceac971b45f4fb7 remove_uri_prefix=$(subst git://,,$(subst http://,,$(subst https://,,$(1)))) sanitize_uri=$(call qstrip,$(subst @,_,$(subst :,_,$(subst .,_,$(subst -,_,$(subst /,_,$(1))))))) diff --git a/target/linux/brcm2708/patches-4.19/950-0129-gpiolib-Don-t-prevent-IRQ-usage-of-output-GPIOs.patch b/target/linux/brcm2708/patches-4.19/950-0129-gpiolib-Don-t-prevent-IRQ-usage-of-output-GPIOs.patch index 2f1d32754c..c28ce4081f 100644 --- a/target/linux/brcm2708/patches-4.19/950-0129-gpiolib-Don-t-prevent-IRQ-usage-of-output-GPIOs.patch +++ b/target/linux/brcm2708/patches-4.19/950-0129-gpiolib-Don-t-prevent-IRQ-usage-of-output-GPIOs.patch @@ -26,7 +26,7 @@ Signed-off-by: Phil Elwell /* Device and char device-related information */ static DEFINE_IDA(gpio_ida); static dev_t gpio_devt; -@@ -2634,7 +2636,7 @@ int gpiod_direction_output(struct gpio_d +@@ -2654,7 +2656,7 @@ int gpiod_direction_output(struct gpio_d value = !!value; /* GPIOs used for IRQs shall not be set as output */ @@ -35,7 +35,7 @@ Signed-off-by: Phil Elwell gpiod_err(desc, "%s: tried to set a GPIO tied to an IRQ as output\n", __func__); -@@ -3333,7 +3335,7 @@ int gpiochip_lock_as_irq(struct gpio_chi +@@ -3353,7 +3355,7 @@ int gpiochip_lock_as_irq(struct gpio_chi } } diff --git a/target/linux/brcm2708/patches-4.19/950-0134-net-lan78xx-Disable-TCP-Segmentation-Offload-TSO.patch b/target/linux/brcm2708/patches-4.19/950-0134-net-lan78xx-Disable-TCP-Segmentation-Offload-TSO.patch index 6a403d4861..b33c4f4374 100644 --- a/target/linux/brcm2708/patches-4.19/950-0134-net-lan78xx-Disable-TCP-Segmentation-Offload-TSO.patch +++ b/target/linux/brcm2708/patches-4.19/950-0134-net-lan78xx-Disable-TCP-Segmentation-Offload-TSO.patch @@ -37,7 +37,7 @@ Signed-off-by: Dave Stevenson static int lan78xx_read_reg(struct lan78xx_net *dev, u32 index, u32 *data) { u32 *buf = kmalloc(sizeof(u32), GFP_KERNEL); -@@ -3006,8 +3015,14 @@ static int lan78xx_bind(struct lan78xx_n +@@ -3011,8 +3020,14 @@ static int lan78xx_bind(struct lan78xx_n if (DEFAULT_RX_CSUM_ENABLE) dev->net->features |= NETIF_F_RXCSUM; diff --git a/target/linux/brcm2708/patches-4.19/950-0298-lan78xx-Debounce-link-events-to-minimize-poll-storm.patch b/target/linux/brcm2708/patches-4.19/950-0298-lan78xx-Debounce-link-events-to-minimize-poll-storm.patch index d4e61c2186..bff441c5e0 100644 --- a/target/linux/brcm2708/patches-4.19/950-0298-lan78xx-Debounce-link-events-to-minimize-poll-storm.patch +++ b/target/linux/brcm2708/patches-4.19/950-0298-lan78xx-Debounce-link-events-to-minimize-poll-storm.patch @@ -28,7 +28,7 @@ See: https://github.com/raspberrypi/linux/issues/2447 static int lan78xx_read_reg(struct lan78xx_net *dev, u32 index, u32 *data) { u32 *buf = kmalloc(sizeof(u32), GFP_KERNEL); -@@ -3819,7 +3824,12 @@ static int lan78xx_probe(struct usb_inte +@@ -3824,7 +3829,12 @@ static int lan78xx_probe(struct usb_inte dev->pipe_intr = usb_rcvintpipe(dev->udev, dev->ep_intr->desc.bEndpointAddress & USB_ENDPOINT_NUMBER_MASK); diff --git a/target/linux/brcm2708/patches-4.19/950-0479-lan78xx-use-default-alignment-for-rx-buffers.patch b/target/linux/brcm2708/patches-4.19/950-0479-lan78xx-use-default-alignment-for-rx-buffers.patch index 3bc2582dc4..d8cf36f1ea 100644 --- a/target/linux/brcm2708/patches-4.19/950-0479-lan78xx-use-default-alignment-for-rx-buffers.patch +++ b/target/linux/brcm2708/patches-4.19/950-0479-lan78xx-use-default-alignment-for-rx-buffers.patch @@ -12,7 +12,7 @@ in both dwc_otg and in ipv6 processing. --- a/drivers/net/usb/lan78xx.c +++ b/drivers/net/usb/lan78xx.c -@@ -3253,7 +3253,7 @@ static int rx_submit(struct lan78xx_net +@@ -3258,7 +3258,7 @@ static int rx_submit(struct lan78xx_net size_t size = dev->rx_urb_size; int ret = 0; diff --git a/target/linux/brcm2708/patches-4.19/950-0542-net-genet-enable-link-energy-detect-powerdown-for-ex.patch b/target/linux/brcm2708/patches-4.19/950-0542-net-genet-enable-link-energy-detect-powerdown-for-ex.patch index 8a1d2f143d..c29457500e 100644 --- a/target/linux/brcm2708/patches-4.19/950-0542-net-genet-enable-link-energy-detect-powerdown-for-ex.patch +++ b/target/linux/brcm2708/patches-4.19/950-0542-net-genet-enable-link-energy-detect-powerdown-for-ex.patch @@ -20,7 +20,7 @@ Signed-off-by: Jonathan Bell --- a/drivers/net/ethernet/broadcom/genet/bcmmii.c +++ b/drivers/net/ethernet/broadcom/genet/bcmmii.c -@@ -286,6 +286,8 @@ int bcmgenet_mii_probe(struct net_device +@@ -285,6 +285,8 @@ int bcmgenet_mii_probe(struct net_device /* Communicate the integrated PHY revision */ if (priv->internal_phy) phy_flags = priv->gphy_rev; diff --git a/target/linux/brcm2708/patches-4.19/950-0802-regulator-gpio-Allow-nonexclusive-GPIO-access.patch b/target/linux/brcm2708/patches-4.19/950-0802-regulator-gpio-Allow-nonexclusive-GPIO-access.patch index 2c41dc0127..6276642997 100644 --- a/target/linux/brcm2708/patches-4.19/950-0802-regulator-gpio-Allow-nonexclusive-GPIO-access.patch +++ b/target/linux/brcm2708/patches-4.19/950-0802-regulator-gpio-Allow-nonexclusive-GPIO-access.patch @@ -41,7 +41,7 @@ Signed-off-by: Mark Brown --- a/drivers/gpio/gpiolib.c +++ b/drivers/gpio/gpiolib.c -@@ -3959,8 +3959,23 @@ struct gpio_desc *__must_check gpiod_get +@@ -3979,8 +3979,23 @@ struct gpio_desc *__must_check gpiod_get * the device name as label */ status = gpiod_request(desc, con_id ? con_id : devname); diff --git a/target/linux/brcm2708/patches-4.19/950-0803-gpio-Enable-nonexclusive-gpiods-from-DT-nodes.patch b/target/linux/brcm2708/patches-4.19/950-0803-gpio-Enable-nonexclusive-gpiods-from-DT-nodes.patch index f7564a58c0..d8e87919cf 100644 --- a/target/linux/brcm2708/patches-4.19/950-0803-gpio-Enable-nonexclusive-gpiods-from-DT-nodes.patch +++ b/target/linux/brcm2708/patches-4.19/950-0803-gpio-Enable-nonexclusive-gpiods-from-DT-nodes.patch @@ -23,7 +23,7 @@ Signed-off-by: Mark Brown --- a/drivers/gpio/gpiolib.c +++ b/drivers/gpio/gpiolib.c -@@ -4033,6 +4033,8 @@ struct gpio_desc *gpiod_get_from_of_node +@@ -4053,6 +4053,8 @@ struct gpio_desc *gpiod_get_from_of_node transitory = flags & OF_GPIO_TRANSITORY; ret = gpiod_request(desc, label); diff --git a/target/linux/brcm47xx/patches-4.19/030-v4.20-MIPS-BCM47XX-Enable-USB-power-on-Netgear-WNDR3400v3.patch b/target/linux/brcm47xx/patches-4.19/030-v4.20-MIPS-BCM47XX-Enable-USB-power-on-Netgear-WNDR3400v3.patch deleted file mode 100644 index c824e28317..0000000000 --- a/target/linux/brcm47xx/patches-4.19/030-v4.20-MIPS-BCM47XX-Enable-USB-power-on-Netgear-WNDR3400v3.patch +++ /dev/null @@ -1,48 +0,0 @@ -From feef7918667b84f9d5653c501542dd8d84ae32af Mon Sep 17 00:00:00 2001 -From: Tuomas Tynkkynen -Date: Sun, 19 Aug 2018 22:20:23 +0300 -Subject: [PATCH] MIPS: BCM47XX: Enable USB power on Netgear WNDR3400v3 -MIME-Version: 1.0 -Content-Type: text/plain; charset=UTF-8 -Content-Transfer-Encoding: 8bit - -Setting GPIO 21 high seems to be required to enable power to USB ports -on the WNDR3400v3. As there is already similar code for WNR3500L, -make the existing USB power GPIO code generic and use that. - -Signed-off-by: Tuomas Tynkkynen -Acked-by: Hauke Mehrtens -Signed-off-by: Paul Burton -Patchwork: https://patchwork.linux-mips.org/patch/20259/ -Cc: Rafał Miłecki -Cc: linux-mips@linux-mips.org -Cc: linux-kernel@vger.kernel.org ---- - arch/mips/bcm47xx/workarounds.c | 8 +++++--- - 1 file changed, 5 insertions(+), 3 deletions(-) - ---- a/arch/mips/bcm47xx/workarounds.c -+++ b/arch/mips/bcm47xx/workarounds.c -@@ -5,9 +5,8 @@ - #include - #include - --static void __init bcm47xx_workarounds_netgear_wnr3500l(void) -+static void __init bcm47xx_workarounds_enable_usb_power(int usb_power) - { -- const int usb_power = 12; - int err; - - err = gpio_request_one(usb_power, GPIOF_OUT_INIT_HIGH, "usb_power"); -@@ -23,7 +22,10 @@ void __init bcm47xx_workarounds(void) - - switch (board) { - case BCM47XX_BOARD_NETGEAR_WNR3500L: -- bcm47xx_workarounds_netgear_wnr3500l(); -+ bcm47xx_workarounds_enable_usb_power(12); -+ break; -+ case BCM47XX_BOARD_NETGEAR_WNDR3400_V3: -+ bcm47xx_workarounds_enable_usb_power(21); - break; - default: - /* No workaround(s) needed */ diff --git a/target/linux/brcm63xx/patches-4.19/001-4.21-01-BCM63XX-fix-switch-core-reset-on-BCM6368.patch b/target/linux/brcm63xx/patches-4.19/001-4.21-01-BCM63XX-fix-switch-core-reset-on-BCM6368.patch deleted file mode 100644 index 3914865c89..0000000000 --- a/target/linux/brcm63xx/patches-4.19/001-4.21-01-BCM63XX-fix-switch-core-reset-on-BCM6368.patch +++ /dev/null @@ -1,26 +0,0 @@ -From f1af8bb8e0879a3c2d9679a7274c2774335e9876 Mon Sep 17 00:00:00 2001 -From: Jonas Gorski -Date: Wed, 14 Nov 2018 12:06:41 +0100 -Subject: [PATCH] MIPS: BCM63XX: fix switch core reset on BCM6368 - -The Ethernet Switch core mask was set to 0, causing the switch core to -be not reset on BCM6368 on boot. Provide the proper mask so the switch -core gets reset to a known good state. - -Fixes: 799faa626c71 ("MIPS: BCM63XX: add core reset helper") -Signed-off-by: Jonas Gorski ---- - arch/mips/bcm63xx/reset.c | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - ---- a/arch/mips/bcm63xx/reset.c -+++ b/arch/mips/bcm63xx/reset.c -@@ -120,7 +120,7 @@ - #define BCM6368_RESET_DSL 0 - #define BCM6368_RESET_SAR SOFTRESET_6368_SAR_MASK - #define BCM6368_RESET_EPHY SOFTRESET_6368_EPHY_MASK --#define BCM6368_RESET_ENETSW 0 -+#define BCM6368_RESET_ENETSW SOFTRESET_6368_ENETSW_MASK - #define BCM6368_RESET_PCM SOFTRESET_6368_PCM_MASK - #define BCM6368_RESET_MPI SOFTRESET_6368_MPI_MASK - #define BCM6368_RESET_PCIE 0 diff --git a/target/linux/brcm63xx/patches-4.19/402_bcm63xx_enet_vlan_incoming_fixed.patch b/target/linux/brcm63xx/patches-4.19/402_bcm63xx_enet_vlan_incoming_fixed.patch index 7ef200ed99..c3b5778e0a 100644 --- a/target/linux/brcm63xx/patches-4.19/402_bcm63xx_enet_vlan_incoming_fixed.patch +++ b/target/linux/brcm63xx/patches-4.19/402_bcm63xx_enet_vlan_incoming_fixed.patch @@ -1,6 +1,6 @@ --- a/drivers/net/ethernet/broadcom/bcm63xx_enet.c +++ b/drivers/net/ethernet/broadcom/bcm63xx_enet.c -@@ -1633,7 +1633,7 @@ static int bcm_enet_change_mtu(struct ne +@@ -1634,7 +1634,7 @@ static int bcm_enet_change_mtu(struct ne return -EBUSY; /* add ethernet header + vlan tag size */ diff --git a/target/linux/brcm63xx/patches-4.19/404-NET-bcm63xx_enet-move-phy_-dis-connect-into-probe-re.patch b/target/linux/brcm63xx/patches-4.19/404-NET-bcm63xx_enet-move-phy_-dis-connect-into-probe-re.patch index 2eb36f8216..e30bd5b107 100644 --- a/target/linux/brcm63xx/patches-4.19/404-NET-bcm63xx_enet-move-phy_-dis-connect-into-probe-re.patch +++ b/target/linux/brcm63xx/patches-4.19/404-NET-bcm63xx_enet-move-phy_-dis-connect-into-probe-re.patch @@ -15,7 +15,7 @@ Signed-off-by: Jonas Gorski --- a/drivers/net/ethernet/broadcom/bcm63xx_enet.c +++ b/drivers/net/ethernet/broadcom/bcm63xx_enet.c -@@ -866,10 +866,8 @@ static int bcm_enet_open(struct net_devi +@@ -867,10 +867,8 @@ static int bcm_enet_open(struct net_devi struct bcm_enet_priv *priv; struct sockaddr addr; struct device *kdev; @@ -26,7 +26,7 @@ Signed-off-by: Jonas Gorski void *p; u32 val; -@@ -877,40 +875,10 @@ static int bcm_enet_open(struct net_devi +@@ -878,40 +876,10 @@ static int bcm_enet_open(struct net_devi kdev = &priv->pdev->dev; if (priv->has_phy) { @@ -68,7 +68,7 @@ Signed-off-by: Jonas Gorski } /* mask all interrupts and request them */ -@@ -920,7 +888,7 @@ static int bcm_enet_open(struct net_devi +@@ -921,7 +889,7 @@ static int bcm_enet_open(struct net_devi ret = request_irq(dev->irq, bcm_enet_isr_mac, 0, dev->name, dev); if (ret) @@ -77,7 +77,7 @@ Signed-off-by: Jonas Gorski ret = request_irq(priv->irq_rx, bcm_enet_isr_dma, 0, dev->name, dev); -@@ -1082,8 +1050,8 @@ static int bcm_enet_open(struct net_devi +@@ -1083,8 +1051,8 @@ static int bcm_enet_open(struct net_devi enet_dmac_writel(priv, priv->dma_chan_int_mask, ENETDMAC_IRMASK, priv->tx_chan); @@ -88,7 +88,7 @@ Signed-off-by: Jonas Gorski else bcm_enet_adjust_link(dev); -@@ -1124,10 +1092,6 @@ out_freeirq_rx: +@@ -1125,10 +1093,6 @@ out_freeirq_rx: out_freeirq: free_irq(dev->irq, dev); @@ -99,7 +99,7 @@ Signed-off-by: Jonas Gorski return ret; } -@@ -1232,10 +1196,6 @@ static int bcm_enet_stop(struct net_devi +@@ -1233,10 +1197,6 @@ static int bcm_enet_stop(struct net_devi free_irq(priv->irq_rx, dev); free_irq(dev->irq, dev); @@ -110,7 +110,7 @@ Signed-off-by: Jonas Gorski return 0; } -@@ -1801,14 +1761,47 @@ static int bcm_enet_probe(struct platfor +@@ -1802,14 +1762,47 @@ static int bcm_enet_probe(struct platfor /* do minimal hardware init to be able to probe mii bus */ bcm_enet_hw_preinit(priv); @@ -159,7 +159,7 @@ Signed-off-by: Jonas Gorski } bus = priv->mii_bus; -@@ -1832,6 +1825,35 @@ static int bcm_enet_probe(struct platfor +@@ -1833,6 +1826,35 @@ static int bcm_enet_probe(struct platfor dev_err(&pdev->dev, "unable to register mdio bus\n"); goto out_free_mdio; } @@ -195,7 +195,7 @@ Signed-off-by: Jonas Gorski } else { /* run platform code to initialize PHY device */ -@@ -1839,45 +1861,16 @@ static int bcm_enet_probe(struct platfor +@@ -1840,45 +1862,16 @@ static int bcm_enet_probe(struct platfor pd->mii_config(dev, 1, bcm_enet_mdio_read_mii, bcm_enet_mdio_write_mii)) { dev_err(&pdev->dev, "unable to configure mdio bus\n"); @@ -245,7 +245,7 @@ Signed-off-by: Jonas Gorski if (priv->mii_bus) mdiobus_unregister(priv->mii_bus); -@@ -1885,6 +1878,9 @@ out_free_mdio: +@@ -1886,6 +1879,9 @@ out_free_mdio: if (priv->mii_bus) mdiobus_free(priv->mii_bus); @@ -255,7 +255,7 @@ Signed-off-by: Jonas Gorski out_uninit_hw: /* turn off mdc clock */ enet_writel(priv, 0, ENET_MIISC_REG); -@@ -1915,6 +1911,7 @@ static int bcm_enet_remove(struct platfo +@@ -1916,6 +1912,7 @@ static int bcm_enet_remove(struct platfo enet_writel(priv, 0, ENET_MIISC_REG); if (priv->has_phy) { diff --git a/target/linux/brcm63xx/patches-4.19/408-bcm63xx_enet-enable-rgmii-clock-on-external-ports.patch b/target/linux/brcm63xx/patches-4.19/408-bcm63xx_enet-enable-rgmii-clock-on-external-ports.patch index 772e40b2b5..86940ae14d 100644 --- a/target/linux/brcm63xx/patches-4.19/408-bcm63xx_enet-enable-rgmii-clock-on-external-ports.patch +++ b/target/linux/brcm63xx/patches-4.19/408-bcm63xx_enet-enable-rgmii-clock-on-external-ports.patch @@ -32,7 +32,7 @@ Subject: [PATCH 54/81] bcm63xx_enet: enable rgmii clock on external ports #define ENETSW_MDIOC_EXT_MASK (1 << 16) --- a/drivers/net/ethernet/broadcom/bcm63xx_enet.c +++ b/drivers/net/ethernet/broadcom/bcm63xx_enet.c -@@ -2184,6 +2184,18 @@ static int bcm_enetsw_open(struct net_de +@@ -2185,6 +2185,18 @@ static int bcm_enetsw_open(struct net_de priv->sw_port_link[i] = 0; } diff --git a/target/linux/brcm63xx/patches-4.19/423-bcm63xx_enet_add_b53_support.patch b/target/linux/brcm63xx/patches-4.19/423-bcm63xx_enet_add_b53_support.patch index 641c477ee5..3f093cf65c 100644 --- a/target/linux/brcm63xx/patches-4.19/423-bcm63xx_enet_add_b53_support.patch +++ b/target/linux/brcm63xx/patches-4.19/423-bcm63xx_enet_add_b53_support.patch @@ -20,7 +20,7 @@ #include #include "bcm63xx_enet.h" -@@ -1931,7 +1932,8 @@ static int bcm_enet_remove(struct platfo +@@ -1932,7 +1933,8 @@ static int bcm_enet_remove(struct platfo return 0; } @@ -30,7 +30,7 @@ .probe = bcm_enet_probe, .remove = bcm_enet_remove, .driver = { -@@ -1940,6 +1942,42 @@ struct platform_driver bcm63xx_enet_driv +@@ -1941,6 +1943,42 @@ struct platform_driver bcm63xx_enet_driv }, }; @@ -73,7 +73,7 @@ /* * switch mii access callbacks */ -@@ -2196,29 +2234,6 @@ static int bcm_enetsw_open(struct net_de +@@ -2197,29 +2235,6 @@ static int bcm_enetsw_open(struct net_de enetsw_writeb(priv, rgmii_ctrl, ENETSW_RGMII_CTRL_REG(i)); } @@ -103,7 +103,7 @@ /* initialize flow control buffer allocation */ enet_dma_writel(priv, ENETDMA_BUFALLOC_FORCE_MASK | 0, ENETDMA_BUFALLOC_REG(priv->rx_chan)); -@@ -2674,6 +2689,9 @@ static int bcm_enetsw_probe(struct platf +@@ -2675,6 +2690,9 @@ static int bcm_enetsw_probe(struct platf struct bcm63xx_enetsw_platform_data *pd; struct resource *res_mem; int ret, irq_rx, irq_tx; @@ -113,7 +113,7 @@ if (!bcm_enet_shared_base[0]) return -EPROBE_DEFER; -@@ -2754,6 +2772,43 @@ static int bcm_enetsw_probe(struct platf +@@ -2755,6 +2773,43 @@ static int bcm_enetsw_probe(struct platf priv->pdev = pdev; priv->net_dev = dev; @@ -157,7 +157,7 @@ return 0; out_disable_clk: -@@ -2775,6 +2830,9 @@ static int bcm_enetsw_remove(struct plat +@@ -2776,6 +2831,9 @@ static int bcm_enetsw_remove(struct plat priv = netdev_priv(dev); unregister_netdev(dev); diff --git a/target/linux/brcm63xx/patches-4.19/424-bcm63xx_enet_no_request_mem_region.patch b/target/linux/brcm63xx/patches-4.19/424-bcm63xx_enet_no_request_mem_region.patch index f2b18b76d6..e956deac1a 100644 --- a/target/linux/brcm63xx/patches-4.19/424-bcm63xx_enet_no_request_mem_region.patch +++ b/target/linux/brcm63xx/patches-4.19/424-bcm63xx_enet_no_request_mem_region.patch @@ -1,6 +1,6 @@ --- a/drivers/net/ethernet/broadcom/bcm63xx_enet.c +++ b/drivers/net/ethernet/broadcom/bcm63xx_enet.c -@@ -2733,9 +2733,9 @@ static int bcm_enetsw_probe(struct platf +@@ -2734,9 +2734,9 @@ static int bcm_enetsw_probe(struct platf if (ret) goto out; diff --git a/target/linux/brcm63xx/patches-4.19/804-bcm63xx_enet_63268_rgmii_ports.patch b/target/linux/brcm63xx/patches-4.19/804-bcm63xx_enet_63268_rgmii_ports.patch index d9cf170dae..683221d76e 100644 --- a/target/linux/brcm63xx/patches-4.19/804-bcm63xx_enet_63268_rgmii_ports.patch +++ b/target/linux/brcm63xx/patches-4.19/804-bcm63xx_enet_63268_rgmii_ports.patch @@ -1,6 +1,6 @@ --- a/drivers/net/ethernet/broadcom/bcm63xx_enet.c +++ b/drivers/net/ethernet/broadcom/bcm63xx_enet.c -@@ -2231,6 +2231,10 @@ static int bcm_enetsw_open(struct net_de +@@ -2232,6 +2232,10 @@ static int bcm_enetsw_open(struct net_de rgmii_ctrl = enetsw_readb(priv, ENETSW_RGMII_CTRL_REG(i)); rgmii_ctrl |= ENETSW_RGMII_CTRL_GMII_CLK_EN; diff --git a/target/linux/cns3xxx/patches-4.19/080-sata_support.patch b/target/linux/cns3xxx/patches-4.19/080-sata_support.patch index 20871916fb..65a5275bec 100644 --- a/target/linux/cns3xxx/patches-4.19/080-sata_support.patch +++ b/target/linux/cns3xxx/patches-4.19/080-sata_support.patch @@ -1,6 +1,6 @@ --- a/drivers/ata/ahci_platform.c +++ b/drivers/ata/ahci_platform.c -@@ -37,12 +37,23 @@ static struct scsi_host_template ahci_pl +@@ -44,11 +44,18 @@ static struct scsi_host_template ahci_pl AHCI_SHT(DRV_NAME), }; @@ -15,12 +15,26 @@ { struct device *dev = &pdev->dev; struct ahci_host_priv *hpriv; -+ const struct ata_port_info *info = &ahci_port_info; +- const struct ata_port_info *port; ++ const struct ata_port_info *port = &ahci_port_info; int rc; -+ if (IS_ENABLED(CONFIG_ARCH_CNS3XXX)) -+ info = &cns3xxx_port_info; -+ hpriv = ahci_platform_get_resources(pdev, - AHCI_PLATFORM_GET_RESETS); - if (IS_ERR(hpriv)) +@@ -66,9 +73,14 @@ static int ahci_probe(struct platform_de + if (of_device_is_compatible(dev->of_node, "hisilicon,hisi-ahci")) + hpriv->flags |= AHCI_HFLAG_NO_FBS | AHCI_HFLAG_NO_NCQ; + +- port = acpi_device_get_match_data(dev); +- if (!port) +- port = &ahci_port_info; ++ if (IS_ENABLED(CONFIG_ARCH_CNS3XXX)) { ++ port = &cns3xxx_port_info; ++ } ++ else { ++ port = acpi_device_get_match_data(dev); ++ if (!port) ++ port = &ahci_port_info; ++ } + + rc = ahci_platform_init_host(pdev, hpriv, port, + &ahci_platform_sht); diff --git a/target/linux/generic/pending-4.19/640-netfilter-nf_flow_table-add-hardware-offload-support.patch b/target/linux/generic/pending-4.19/640-netfilter-nf_flow_table-add-hardware-offload-support.patch index 78b7cc9f3e..dcd9b187c3 100644 --- a/target/linux/generic/pending-4.19/640-netfilter-nf_flow_table-add-hardware-offload-support.patch +++ b/target/linux/generic/pending-4.19/640-netfilter-nf_flow_table-add-hardware-offload-support.patch @@ -506,7 +506,7 @@ Signed-off-by: Pablo Neira Ayuso +MODULE_ALIAS("nf-flow-table-hw"); --- a/net/netfilter/nf_tables_api.c +++ b/net/netfilter/nf_tables_api.c -@@ -5471,6 +5471,13 @@ static int nf_tables_flowtable_parse_hoo +@@ -5473,6 +5473,13 @@ static int nf_tables_flowtable_parse_hoo if (err < 0) return err; @@ -520,7 +520,7 @@ Signed-off-by: Pablo Neira Ayuso ops = kcalloc(n, sizeof(struct nf_hook_ops), GFP_KERNEL); if (!ops) return -ENOMEM; -@@ -5602,10 +5609,19 @@ static int nf_tables_newflowtable(struct +@@ -5604,10 +5611,19 @@ static int nf_tables_newflowtable(struct } flowtable->data.type = type; @@ -540,7 +540,7 @@ Signed-off-by: Pablo Neira Ayuso err = nf_tables_flowtable_parse_hook(&ctx, nla[NFTA_FLOWTABLE_HOOK], flowtable); if (err < 0) -@@ -5731,7 +5747,8 @@ static int nf_tables_fill_flowtable_info +@@ -5733,7 +5749,8 @@ static int nf_tables_fill_flowtable_info nla_put_string(skb, NFTA_FLOWTABLE_NAME, flowtable->name) || nla_put_be32(skb, NFTA_FLOWTABLE_USE, htonl(flowtable->use)) || nla_put_be64(skb, NFTA_FLOWTABLE_HANDLE, cpu_to_be64(flowtable->handle), diff --git a/target/linux/ipq40xx/patches-4.19/073-v4.20-ARM-dts-qcom-ipq4019-fix-cpu0-s-qcom-saw2-reg-value.patch b/target/linux/ipq40xx/patches-4.19/073-v4.20-ARM-dts-qcom-ipq4019-fix-cpu0-s-qcom-saw2-reg-value.patch deleted file mode 100644 index cd1370ea5e..0000000000 --- a/target/linux/ipq40xx/patches-4.19/073-v4.20-ARM-dts-qcom-ipq4019-fix-cpu0-s-qcom-saw2-reg-value.patch +++ /dev/null @@ -1,34 +0,0 @@ -From bd73a3dd257fb838bd456a18eeee0ef0224b7a40 Mon Sep 17 00:00:00 2001 -From: Christian Lamparter -Date: Wed, 25 Jul 2018 10:37:47 +0200 -Subject: [PATCH] ARM: dts: qcom: ipq4019: fix cpu0's qcom,saw2 reg value - -while compiling an ipq4019 target, dtc will complain: -regulator@b089000 unit address format error, expected "2089000" - -The saw0 regulator reg value seems to be -copied and pasted from qcom-ipq8064.dtsi. - -This patch fixes the reg value to match that of the -unit address which in turn silences the warning. -(There is no driver for qcom,saw2 right now. -So this went unnoticed) - -Signed-off-by: Christian Lamparter -Signed-off-by: John Crispin -Signed-off-by: Andy Gross ---- - arch/arm/boot/dts/qcom-ipq4019.dtsi | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - ---- a/arch/arm/boot/dts/qcom-ipq4019.dtsi -+++ b/arch/arm/boot/dts/qcom-ipq4019.dtsi -@@ -325,7 +325,7 @@ - - saw0: regulator@b089000 { - compatible = "qcom,saw2"; -- reg = <0x02089000 0x1000>, <0x0b009000 0x1000>; -+ reg = <0x0b089000 0x1000>, <0x0b009000 0x1000>; - regulator; - }; - diff --git a/target/linux/mediatek/patches-4.19/0101-pci-mediatek-backport-fix-pcie.patch b/target/linux/mediatek/patches-4.19/0101-pci-mediatek-backport-fix-pcie.patch index cdb53954cf..009eedb583 100644 --- a/target/linux/mediatek/patches-4.19/0101-pci-mediatek-backport-fix-pcie.patch +++ b/target/linux/mediatek/patches-4.19/0101-pci-mediatek-backport-fix-pcie.patch @@ -362,7 +362,7 @@ return err; } -@@ -1125,34 +1126,6 @@ static int mtk_pcie_request_resources(st +@@ -1127,34 +1128,6 @@ static int mtk_pcie_request_resources(st return 0; } @@ -397,7 +397,7 @@ static int mtk_pcie_probe(struct platform_device *pdev) { struct device *dev = &pdev->dev; -@@ -1179,7 +1152,14 @@ static int mtk_pcie_probe(struct platfor +@@ -1181,7 +1154,14 @@ static int mtk_pcie_probe(struct platfor if (err) goto put_resources; @@ -413,7 +413,7 @@ if (err) goto put_resources; -@@ -1192,6 +1172,80 @@ put_resources: +@@ -1194,6 +1174,80 @@ put_resources: return err; } @@ -494,7 +494,7 @@ static const struct mtk_pcie_soc mtk_pcie_soc_v1 = { .ops = &mtk_pcie_ops, .startup = mtk_pcie_startup_port, -@@ -1220,10 +1274,13 @@ static const struct of_device_id mtk_pci +@@ -1222,10 +1276,13 @@ static const struct of_device_id mtk_pci static struct platform_driver mtk_pcie_driver = { .probe = mtk_pcie_probe, From ada7322055f0bf9ddace615f97d6d40641925aea Mon Sep 17 00:00:00 2001 From: Koen Vandeputte Date: Fri, 22 Nov 2019 09:58:50 +0100 Subject: [PATCH 05/17] cns3xxx: use proper macros for defining partition regions While at it, also reorder the items for improved readability. Signed-off-by: Koen Vandeputte --- .../cns3xxx/files/arch/arm/mach-cns3xxx/laguna.c | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/target/linux/cns3xxx/files/arch/arm/mach-cns3xxx/laguna.c b/target/linux/cns3xxx/files/arch/arm/mach-cns3xxx/laguna.c index eade8f683d..bee7348266 100644 --- a/target/linux/cns3xxx/files/arch/arm/mach-cns3xxx/laguna.c +++ b/target/linux/cns3xxx/files/arch/arm/mach-cns3xxx/laguna.c @@ -114,16 +114,17 @@ static struct laguna_board_info laguna_info __initdata; static struct mtd_partition laguna_nor_partitions[] = { { .name = "uboot", - .size = SZ_256K, .offset = 0, + .size = SZ_256K, .mask_flags = MTD_WRITEABLE, }, { .name = "params", + .offset = MTDPART_OFS_APPEND, .size = SZ_128K, - .offset = SZ_256K, }, { .name = "firmware", - .offset = SZ_256K + SZ_128K, + .offset = MTDPART_OFS_APPEND, + .size = MTDPART_SIZ_FULL, }, }; @@ -155,16 +156,17 @@ static struct platform_device laguna_nor_pdev = { static struct mtd_partition laguna_spi_partitions[] = { { .name = "uboot", - .size = SZ_256K, .offset = 0, + .size = SZ_256K, .mask_flags = MTD_WRITEABLE, }, { .name = "params", + .offset = MTDPART_OFS_APPEND, .size = SZ_256K, - .offset = SZ_256K, }, { .name = "firmware", - .offset = SZ_512K, + .offset = MTDPART_OFS_APPEND, + .size = MTDPART_SIZ_FULL, }, }; From 482114d3f78df2a19904cc8edf7d9adcfdbb8625 Mon Sep 17 00:00:00 2001 From: Jo-Philipp Wich Date: Fri, 22 Nov 2019 18:53:03 +0100 Subject: [PATCH 06/17] firewall: update to latest Git HEAD 8174814 utils: persist effective extra_src and extra_dest options in state file 72a486f zones: fix emitting match rules for zones with only "extra" options Signed-off-by: Jo-Philipp Wich --- package/network/config/firewall/Makefile | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/package/network/config/firewall/Makefile b/package/network/config/firewall/Makefile index 26f8970586..bf2a1060eb 100644 --- a/package/network/config/firewall/Makefile +++ b/package/network/config/firewall/Makefile @@ -13,9 +13,9 @@ PKG_RELEASE:=1 PKG_SOURCE_PROTO:=git PKG_SOURCE_URL=$(PROJECT_GIT)/project/firewall3.git -PKG_SOURCE_DATE:=2019-09-23 -PKG_SOURCE_VERSION:=daed0cf9831c07863e5a2a572c2dd242fe757a31 -PKG_MIRROR_HASH:=363ef5da4165dc54340e311a2158bd86fd2e74cfcf8118e2f35680bd5ac556db +PKG_SOURCE_DATE:=2019-11-22 +PKG_SOURCE_VERSION:=8174814a507489ebbe8bb85c1004e1f02919ca82 +PKG_MIRROR_HASH:=84e0cca2d47470bdb1788a8ae044cc425be8ff650a1137474ba43a15040085da PKG_MAINTAINER:=Jo-Philipp Wich PKG_LICENSE:=ISC From 103e49f62e72664ee0d5285007907a75960e8645 Mon Sep 17 00:00:00 2001 From: Hauke Mehrtens Date: Fri, 22 Nov 2019 20:13:55 +0100 Subject: [PATCH 07/17] kernel: Add missing configuration option This was found by the build bot. Fixes: e29500eb849a ("kernel: bump 4.19 to 4.19.85") Fixes: db9e9e838216 ("kernel: bump 4.14 to 4.14.155") Signed-off-by: Hauke Mehrtens --- target/linux/generic/config-4.14 | 1 + target/linux/generic/config-4.19 | 1 + 2 files changed, 2 insertions(+) diff --git a/target/linux/generic/config-4.14 b/target/linux/generic/config-4.14 index 8455249e96..18f5b1a00a 100644 --- a/target/linux/generic/config-4.14 +++ b/target/linux/generic/config-4.14 @@ -1127,6 +1127,7 @@ CONFIG_DEVPORT=y # CONFIG_DMA_API_DEBUG is not set # CONFIG_DMA_ENGINE is not set # CONFIG_DMA_FENCE_TRACE is not set +# CONFIG_DMA_JZ4780 is not set # CONFIG_DMA_NOOP_OPS is not set # CONFIG_DMA_SHARED_BUFFER is not set # CONFIG_DMA_VIRT_OPS is not set diff --git a/target/linux/generic/config-4.19 b/target/linux/generic/config-4.19 index 278b969c5f..13b7fd1121 100644 --- a/target/linux/generic/config-4.19 +++ b/target/linux/generic/config-4.19 @@ -1187,6 +1187,7 @@ CONFIG_DEVPORT=y # CONFIG_DMA_API_DEBUG is not set # CONFIG_DMA_ENGINE is not set # CONFIG_DMA_FENCE_TRACE is not set +# CONFIG_DMA_JZ4780 is not set # CONFIG_DMA_NOOP_OPS is not set # CONFIG_DMA_SHARED_BUFFER is not set # CONFIG_DMA_VIRT_OPS is not set From a36c464efeffff4d4b1431cf6391dcde38c84e8b Mon Sep 17 00:00:00 2001 From: Hauke Mehrtens Date: Thu, 21 Nov 2019 22:20:20 +0100 Subject: [PATCH 08/17] mac80211: update to version 5.4-rc8 This updates mac80211 to backports based on kernel 5.4-rc8. The deleted patches were applied upstream. Signed-off-by: Hauke Mehrtens --- package/kernel/mac80211/Makefile | 8 +- ...21-ath10k_init_devices_synchronously.patch | 2 +- ...rolling-support-for-various-chipsets.patch | 6 +- ...ath10k-fix-latency-issue-for-QCA988x.patch | 42 ------- ...ckports-pci-Include-linux-pci-aspm.h.patch | 24 ---- ..._disable_link_state-wrapper-with-ret.patch | 43 ------- ...t-to-changes-to-skb_get_hash_perturb.patch | 68 ---------- .../017-rt2x00-initialize-last_reset.patch | 35 ------ ...1-rt2x00-introduce-rt2x00_platform_h.patch | 2 +- .../602-rt2x00-introduce-rt2x00eeprom.patch | 4 +- ...isabling_bands_through_platform_data.patch | 2 +- ...-rt2x00-add-rf-self-txdc-calibration.patch | 2 +- .../rt2x00/983-rt2x00-add-r-calibration.patch | 2 +- .../984-rt2x00-add-rxdcoc-calibration.patch | 2 +- .../985-rt2x00-add-rxiq-calibration.patch | 2 +- .../986-rt2x00-add-TX-LOFT-calibration.patch | 2 +- ...ting-on-DFS-channels-in-ETSI-domains.patch | 118 ------------------ ...11-accept-deauth-frames-in-IBSS-mode.patch | 39 ------ 18 files changed, 17 insertions(+), 386 deletions(-) delete mode 100644 package/kernel/mac80211/patches/ath/982-ath10k-fix-latency-issue-for-QCA988x.patch delete mode 100644 package/kernel/mac80211/patches/build/100-backports-pci-Include-linux-pci-aspm.h.patch delete mode 100644 package/kernel/mac80211/patches/build/101-backport-add-pci_disable_link_state-wrapper-with-ret.patch delete mode 100644 package/kernel/mac80211/patches/build/102-backports-Adapt-to-changes-to-skb_get_hash_perturb.patch delete mode 100644 package/kernel/mac80211/patches/rt2x00/017-rt2x00-initialize-last_reset.patch delete mode 100644 package/kernel/mac80211/patches/subsys/030-mac80211_fix-scan-when-operating-on-DFS-channels-in-ETSI-domains.patch delete mode 100644 package/kernel/mac80211/patches/subsys/363-mac80211-accept-deauth-frames-in-IBSS-mode.patch diff --git a/package/kernel/mac80211/Makefile b/package/kernel/mac80211/Makefile index 422c0436e4..9e4c362a2d 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.4-rc2-1 -PKG_RELEASE:=2 -PKG_SOURCE_URL:=@KERNEL/linux/kernel/projects/backports/stable/v5.4-rc2/ -PKG_HASH:=b3baedc135b455f09f266cb77e73276ca21bceeb0f24bac2184cc4b97d09cdbf +PKG_VERSION:=5.4-rc8-1 +PKG_RELEASE:=1 +PKG_SOURCE_URL:=@KERNEL/linux/kernel/projects/backports/stable/v5.4-rc8/ +PKG_HASH:=707ffc50d0f6fe3398bcc3a7abd44ffa088d9309255a3a71d014620c20d3bbf9 PKG_SOURCE:=backports-$(PKG_VERSION).tar.xz PKG_BUILD_DIR:=$(KERNEL_BUILD_DIR)/backports-$(PKG_VERSION) diff --git a/package/kernel/mac80211/patches/ath/921-ath10k_init_devices_synchronously.patch b/package/kernel/mac80211/patches/ath/921-ath10k_init_devices_synchronously.patch index 8221d78197..69c29f15ee 100644 --- a/package/kernel/mac80211/patches/ath/921-ath10k_init_devices_synchronously.patch +++ b/package/kernel/mac80211/patches/ath/921-ath10k_init_devices_synchronously.patch @@ -14,7 +14,7 @@ Signed-off-by: Sven Eckelmann --- a/drivers/net/wireless/ath/ath10k/core.c +++ b/drivers/net/wireless/ath/ath10k/core.c -@@ -3071,6 +3071,16 @@ int ath10k_core_register(struct ath10k * +@@ -3074,6 +3074,16 @@ int ath10k_core_register(struct ath10k * queue_work(ar->workqueue, &ar->register_work); 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/ath/974-ath10k_add-LED-and-GPIO-controlling-support-for-various-chipsets.patch index ae0f682224..3cf1957060 100644 --- a/package/kernel/mac80211/patches/ath/974-ath10k_add-LED-and-GPIO-controlling-support-for-various-chipsets.patch +++ b/package/kernel/mac80211/patches/ath/974-ath10k_add-LED-and-GPIO-controlling-support-for-various-chipsets.patch @@ -172,7 +172,7 @@ v13: .patch_load_addr = QCA9888_HW_2_0_PATCH_LOAD_ADDR, .uart_pin = 7, .cc_wraparound_type = ATH10K_HW_CC_WRAP_SHIFTED_EACH, -@@ -2788,6 +2794,10 @@ int ath10k_core_start(struct ath10k *ar, +@@ -2791,6 +2797,10 @@ int ath10k_core_start(struct ath10k *ar, goto err_hif_stop; } @@ -183,7 +183,7 @@ v13: return 0; err_hif_stop: -@@ -3044,9 +3054,18 @@ static void ath10k_core_register_work(st +@@ -3047,9 +3057,18 @@ static void ath10k_core_register_work(st goto err_spectral_destroy; } @@ -202,7 +202,7 @@ v13: err_spectral_destroy: ath10k_spectral_destroy(ar); err_debug_destroy: -@@ -3092,6 +3111,8 @@ void ath10k_core_unregister(struct ath10 +@@ -3095,6 +3114,8 @@ void ath10k_core_unregister(struct ath10 if (!test_bit(ATH10K_FLAG_CORE_REGISTERED, &ar->dev_flags)) return; diff --git a/package/kernel/mac80211/patches/ath/982-ath10k-fix-latency-issue-for-QCA988x.patch b/package/kernel/mac80211/patches/ath/982-ath10k-fix-latency-issue-for-QCA988x.patch deleted file mode 100644 index 3702abb412..0000000000 --- a/package/kernel/mac80211/patches/ath/982-ath10k-fix-latency-issue-for-QCA988x.patch +++ /dev/null @@ -1,42 +0,0 @@ -From: Miaoqing Pan -Subject: [PATCH] ath10k: fix latency issue for QCA988x -Date: Thu, 29 Aug 2019 10:45:12 +0800 - -Bad latency is found on QCA988x, the issue was introduced by -commit 4504f0e5b571 ("ath10k: sdio: workaround firmware UART -pin configuration bug"). If uart_pin_workaround is false, this -change will set uart pin even if uart_print is false. - -Tested HW: QCA9880 -Tested FW: 10.2.4-1.0-00037 - -Fixes: 4504f0e5b571 ("ath10k: sdio: workaround firmware UART pin configuration bug") -Signed-off-by: Miaoqing Pan ---- - drivers/net/wireless/ath/ath10k/core.c | 15 +++++++++------ - 1 file changed, 9 insertions(+), 6 deletions(-) - ---- a/drivers/net/wireless/ath/ath10k/core.c -+++ b/drivers/net/wireless/ath/ath10k/core.c -@@ -2124,12 +2124,15 @@ static int ath10k_init_uart(struct ath10 - return ret; - } - -- if (!uart_print && ar->hw_params.uart_pin_workaround) { -- ret = ath10k_bmi_write32(ar, hi_dbg_uart_txpin, -- ar->hw_params.uart_pin); -- if (ret) { -- ath10k_warn(ar, "failed to set UART TX pin: %d", ret); -- return ret; -+ if (!uart_print) { -+ if (ar->hw_params.uart_pin_workaround) { -+ ret = ath10k_bmi_write32(ar, hi_dbg_uart_txpin, -+ ar->hw_params.uart_pin); -+ if (ret) { -+ ath10k_warn(ar, "failed to set UART TX pin: %d", -+ ret); -+ return ret; -+ } - } - - return 0; diff --git a/package/kernel/mac80211/patches/build/100-backports-pci-Include-linux-pci-aspm.h.patch b/package/kernel/mac80211/patches/build/100-backports-pci-Include-linux-pci-aspm.h.patch deleted file mode 100644 index 91740a62b9..0000000000 --- a/package/kernel/mac80211/patches/build/100-backports-pci-Include-linux-pci-aspm.h.patch +++ /dev/null @@ -1,24 +0,0 @@ -From: Hauke Mehrtens -Date: Fri, 27 Sep 2019 23:12:08 +0200 -Subject: [PATCH] backports: pci: Include linux/pci-aspm.h - -In upstream commit 7ce2e76a0420 linux/pci-aspm.h was removed and the -content included into pci.h. Add an include to have the functions -defined in linux/pci-aspm.h available when linux/pci.h is included. - -Signed-off-by: Hauke Mehrtens ---- - ---- a/backport-include/linux/pci.h -+++ b/backport-include/linux/pci.h -@@ -7,6 +7,10 @@ - #include - #endif - -+#if LINUX_VERSION_IS_LESS(5,4,0) -+#include -+#endif -+ - #ifndef module_pci_driver - /** - * module_pci_driver() - Helper macro for registering a PCI driver diff --git a/package/kernel/mac80211/patches/build/101-backport-add-pci_disable_link_state-wrapper-with-ret.patch b/package/kernel/mac80211/patches/build/101-backport-add-pci_disable_link_state-wrapper-with-ret.patch deleted file mode 100644 index 7691522e73..0000000000 --- a/package/kernel/mac80211/patches/build/101-backport-add-pci_disable_link_state-wrapper-with-ret.patch +++ /dev/null @@ -1,43 +0,0 @@ -From: Felix Fietkau -Date: Mon, 28 Oct 2019 15:20:40 +0100 -Subject: [PATCH] backport: add pci_disable_link_state wrapper with return code - -The signature of pci_disable_link_state was changed to indicate if the state -was successfully disabled. Since the old version did not have this, add a -wrapper which checks the pcie register to determine the return code - -Signed-off-by: Felix Fietkau ---- - ---- a/backport-include/linux/pci.h -+++ b/backport-include/linux/pci.h -@@ -240,4 +240,29 @@ static inline struct pci_dev *pcie_find_ - (PCI_IRQ_LEGACY | PCI_IRQ_MSI | PCI_IRQ_MSIX) - #endif - -+#if defined(CONFIG_PCI) && LINUX_VERSION_IS_LESS(5,3,0) -+ -+static inline int -+LINUX_BACKPORT(pci_disable_link_state)(struct pci_dev *pdev, int state) -+{ -+ u16 aspmc; -+ -+ pci_disable_link_state(pdev, state); -+ -+ pcie_capability_read_word(pdev, PCI_EXP_LNKCTL, &aspmc); -+ if ((state & PCIE_LINK_STATE_L0S) && -+ (aspmc & PCI_EXP_LNKCTL_ASPM_L0S)) -+ return -EPERM; -+ -+ if ((state & PCIE_LINK_STATE_L1) && -+ (aspmc & PCI_EXP_LNKCTL_ASPM_L1)) -+ return -EPERM; -+ -+ return 0; -+} -+ -+#define pci_disable_link_state LINUX_BACKPORT(pci_disable_link_state) -+ -+#endif -+ - #endif /* _BACKPORT_LINUX_PCI_H */ diff --git a/package/kernel/mac80211/patches/build/102-backports-Adapt-to-changes-to-skb_get_hash_perturb.patch b/package/kernel/mac80211/patches/build/102-backports-Adapt-to-changes-to-skb_get_hash_perturb.patch deleted file mode 100644 index 7e40180b93..0000000000 --- a/package/kernel/mac80211/patches/build/102-backports-Adapt-to-changes-to-skb_get_hash_perturb.patch +++ /dev/null @@ -1,68 +0,0 @@ -From e3c57dd949835419cee8d3b45db38de58bf6ebd5 Mon Sep 17 00:00:00 2001 -From: Hauke Mehrtens -Date: Mon, 18 Nov 2019 01:13:37 +0100 -Subject: [PATCH] backports: Adapt to changes to skb_get_hash_perturb() - -The skb_get_hash_perturb() function now takes a siphash_key_t instead of -an u32. This was changed in commit 55667441c84f ("net/flow_dissector: -switch to siphash"). Use the correct type in the fq header file -depending on the kernel version. - -Signed-off-by: Hauke Mehrtens ---- - include/net/fq.h | 8 ++++++++ - include/net/fq_impl.h | 8 ++++++++ - 2 files changed, 16 insertions(+) - ---- a/include/net/fq.h -+++ b/include/net/fq.h -@@ -69,7 +69,15 @@ struct fq { - struct list_head backlogs; - spinlock_t lock; - u32 flows_cnt; -+#if LINUX_VERSION_IS_GEQ(5,3,10) || \ -+ LINUX_VERSION_IN_RANGE(4,19,83, 4,20,0) || \ -+ LINUX_VERSION_IN_RANGE(4,14,153, 4,15,0) || \ -+ LINUX_VERSION_IN_RANGE(4,9,200, 4,10,0) || \ -+ LINUX_VERSION_IN_RANGE(4,4,200, 4,5,0) -+ siphash_key_t perturbation; -+#else - u32 perturbation; -+#endif - u32 limit; - u32 memory_limit; - u32 memory_usage; ---- a/include/net/fq_impl.h -+++ b/include/net/fq_impl.h -@@ -108,7 +108,15 @@ begin: - - static u32 fq_flow_idx(struct fq *fq, struct sk_buff *skb) - { -+#if LINUX_VERSION_IS_GEQ(5,3,10) || \ -+ LINUX_VERSION_IN_RANGE(4,19,83, 4,20,0) || \ -+ LINUX_VERSION_IN_RANGE(4,14,153, 4,15,0) || \ -+ LINUX_VERSION_IN_RANGE(4,9,200, 4,10,0) || \ -+ LINUX_VERSION_IN_RANGE(4,4,200, 4,5,0) -+ u32 hash = skb_get_hash_perturb(skb, &fq->perturbation); -+#else - u32 hash = skb_get_hash_perturb(skb, fq->perturbation); -+#endif - - return reciprocal_scale(hash, fq->flows_cnt); - } -@@ -308,7 +316,15 @@ static int fq_init(struct fq *fq, int fl - INIT_LIST_HEAD(&fq->backlogs); - spin_lock_init(&fq->lock); - fq->flows_cnt = max_t(u32, flows_cnt, 1); -+#if LINUX_VERSION_IS_GEQ(5,3,10) || \ -+ LINUX_VERSION_IN_RANGE(4,19,83, 4,20,0) || \ -+ LINUX_VERSION_IN_RANGE(4,14,153, 4,15,0) || \ -+ LINUX_VERSION_IN_RANGE(4,9,200, 4,10,0) || \ -+ LINUX_VERSION_IN_RANGE(4,4,200, 4,5,0) -+ get_random_bytes(&fq->perturbation, sizeof(fq->perturbation)); -+#else - fq->perturbation = prandom_u32(); -+#endif - fq->quantum = 300; - fq->limit = 8192; - fq->memory_limit = 16 << 20; /* 16 MBytes */ diff --git a/package/kernel/mac80211/patches/rt2x00/017-rt2x00-initialize-last_reset.patch b/package/kernel/mac80211/patches/rt2x00/017-rt2x00-initialize-last_reset.patch deleted file mode 100644 index a362340918..0000000000 --- a/package/kernel/mac80211/patches/rt2x00/017-rt2x00-initialize-last_reset.patch +++ /dev/null @@ -1,35 +0,0 @@ -Content-Type: text/plain; charset="utf-8" -MIME-Version: 1.0 -Content-Transfer-Encoding: 7bit -X-Patchwork-Submitter: Stanislaw Gruszka -X-Patchwork-Id: 11161981 -From: Stanislaw Gruszka -To: linux-wireless@vger.kernel.org -Subject: [PATCH] rt2x00: initialize last_reset -Date: Thu, 26 Sep 2019 10:54:33 +0200 -Message-Id: <20190926085433.1300-1-sgruszka@redhat.com> -Sender: linux-wireless-owner@vger.kernel.org -List-ID: -X-Mailing-List: linux-wireless@vger.kernel.org - -Initialize last_reset variable to INITIAL_JIFFIES, otherwise it is not -possible to test H/W reset for first 5 minutes of system run. - -Fixes: e403fa31ed71 ("rt2x00: add restart hw") -Reported-and-tested-by: Jonathan Liu -Signed-off-by: Stanislaw Gruszka ---- - drivers/net/wireless/ralink/rt2x00/rt2x00debug.c | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - ---- a/drivers/net/wireless/ralink/rt2x00/rt2x00debug.c -+++ b/drivers/net/wireless/ralink/rt2x00/rt2x00debug.c -@@ -555,7 +555,7 @@ static ssize_t rt2x00debug_write_restart - { - struct rt2x00debug_intf *intf = file->private_data; - struct rt2x00_dev *rt2x00dev = intf->rt2x00dev; -- static unsigned long last_reset; -+ static unsigned long last_reset = INITIAL_JIFFIES; - - if (!rt2x00_has_cap_restart_hw(rt2x00dev)) - return -EOPNOTSUPP; diff --git a/package/kernel/mac80211/patches/rt2x00/601-rt2x00-introduce-rt2x00_platform_h.patch b/package/kernel/mac80211/patches/rt2x00/601-rt2x00-introduce-rt2x00_platform_h.patch index f9d48b2b31..1e6211a470 100644 --- a/package/kernel/mac80211/patches/rt2x00/601-rt2x00-introduce-rt2x00_platform_h.patch +++ b/package/kernel/mac80211/patches/rt2x00/601-rt2x00-introduce-rt2x00_platform_h.patch @@ -22,7 +22,7 @@ +#endif /* _RT2X00_PLATFORM_H */ --- a/drivers/net/wireless/ralink/rt2x00/rt2x00.h +++ b/drivers/net/wireless/ralink/rt2x00/rt2x00.h -@@ -29,6 +29,7 @@ +@@ -28,6 +28,7 @@ #include #include #include 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 b388fb9e5d..0c6e5a03b0 100644 --- a/package/kernel/mac80211/patches/rt2x00/602-rt2x00-introduce-rt2x00eeprom.patch +++ b/package/kernel/mac80211/patches/rt2x00/602-rt2x00-introduce-rt2x00eeprom.patch @@ -105,7 +105,7 @@ .drv_init_registers = rt2800mmio_init_registers, --- a/drivers/net/wireless/ralink/rt2x00/rt2x00.h +++ b/drivers/net/wireless/ralink/rt2x00/rt2x00.h -@@ -695,6 +695,7 @@ enum rt2x00_capability_flags { +@@ -694,6 +694,7 @@ enum rt2x00_capability_flags { REQUIRE_HT_TX_DESC, REQUIRE_PS_AUTOWAKE, REQUIRE_DELAYED_RFKILL, @@ -113,7 +113,7 @@ /* * Capabilities -@@ -971,6 +972,11 @@ struct rt2x00_dev { +@@ -970,6 +971,11 @@ struct rt2x00_dev { const struct firmware *fw; /* diff --git a/package/kernel/mac80211/patches/rt2x00/606-rt2x00-allow_disabling_bands_through_platform_data.patch b/package/kernel/mac80211/patches/rt2x00/606-rt2x00-allow_disabling_bands_through_platform_data.patch index 8a885fad86..6a8e594d5e 100644 --- a/package/kernel/mac80211/patches/rt2x00/606-rt2x00-allow_disabling_bands_through_platform_data.patch +++ b/package/kernel/mac80211/patches/rt2x00/606-rt2x00-allow_disabling_bands_through_platform_data.patch @@ -37,7 +37,7 @@ num_rates += 4; --- a/drivers/net/wireless/ralink/rt2x00/rt2x00.h +++ b/drivers/net/wireless/ralink/rt2x00/rt2x00.h -@@ -400,6 +400,7 @@ struct hw_mode_spec { +@@ -399,6 +399,7 @@ struct hw_mode_spec { unsigned int supported_bands; #define SUPPORT_BAND_2GHZ 0x00000001 #define SUPPORT_BAND_5GHZ 0x00000002 diff --git a/package/kernel/mac80211/patches/rt2x00/982-rt2x00-add-rf-self-txdc-calibration.patch b/package/kernel/mac80211/patches/rt2x00/982-rt2x00-add-rf-self-txdc-calibration.patch index ecf159d75a..3bb91ec7c5 100644 --- a/package/kernel/mac80211/patches/rt2x00/982-rt2x00-add-rf-self-txdc-calibration.patch +++ b/package/kernel/mac80211/patches/rt2x00/982-rt2x00-add-rf-self-txdc-calibration.patch @@ -79,7 +79,7 @@ void rt2800_disable_radio(struct rt2x00_dev *rt2x00dev); --- a/drivers/net/wireless/ralink/rt2x00/rt2x00.h +++ b/drivers/net/wireless/ralink/rt2x00/rt2x00.h -@@ -563,6 +563,7 @@ struct rt2x00lib_ops { +@@ -562,6 +562,7 @@ struct rt2x00lib_ops { struct link_qual *qual, const u32 count); void (*gain_calibration) (struct rt2x00_dev *rt2x00dev); void (*vco_calibration) (struct rt2x00_dev *rt2x00dev); diff --git a/package/kernel/mac80211/patches/rt2x00/983-rt2x00-add-r-calibration.patch b/package/kernel/mac80211/patches/rt2x00/983-rt2x00-add-r-calibration.patch index 5b59c95c9a..d7d07f8bb6 100644 --- a/package/kernel/mac80211/patches/rt2x00/983-rt2x00-add-r-calibration.patch +++ b/package/kernel/mac80211/patches/rt2x00/983-rt2x00-add-r-calibration.patch @@ -182,7 +182,7 @@ void rt2800_disable_radio(struct rt2x00_dev *rt2x00dev); --- a/drivers/net/wireless/ralink/rt2x00/rt2x00.h +++ b/drivers/net/wireless/ralink/rt2x00/rt2x00.h -@@ -564,6 +564,8 @@ struct rt2x00lib_ops { +@@ -563,6 +563,8 @@ struct rt2x00lib_ops { void (*gain_calibration) (struct rt2x00_dev *rt2x00dev); void (*vco_calibration) (struct rt2x00_dev *rt2x00dev); void (*rf_self_txdc_cal) (struct rt2x00_dev *rt2x00dev); diff --git a/package/kernel/mac80211/patches/rt2x00/984-rt2x00-add-rxdcoc-calibration.patch b/package/kernel/mac80211/patches/rt2x00/984-rt2x00-add-rxdcoc-calibration.patch index 7cbcc2864a..b6180efa8b 100644 --- a/package/kernel/mac80211/patches/rt2x00/984-rt2x00-add-rxdcoc-calibration.patch +++ b/package/kernel/mac80211/patches/rt2x00/984-rt2x00-add-rxdcoc-calibration.patch @@ -92,7 +92,7 @@ void rt2800_disable_radio(struct rt2x00_dev *rt2x00dev); --- a/drivers/net/wireless/ralink/rt2x00/rt2x00.h +++ b/drivers/net/wireless/ralink/rt2x00/rt2x00.h -@@ -566,6 +566,7 @@ struct rt2x00lib_ops { +@@ -565,6 +565,7 @@ struct rt2x00lib_ops { void (*rf_self_txdc_cal) (struct rt2x00_dev *rt2x00dev); int (*calcrcalibrationcode) (struct rt2x00_dev *rt2x00dev, int d1, int d2); void (*r_calibration) (struct rt2x00_dev *rt2x00dev); diff --git a/package/kernel/mac80211/patches/rt2x00/985-rt2x00-add-rxiq-calibration.patch b/package/kernel/mac80211/patches/rt2x00/985-rt2x00-add-rxiq-calibration.patch index 6d4548f469..9603d94f57 100644 --- a/package/kernel/mac80211/patches/rt2x00/985-rt2x00-add-rxiq-calibration.patch +++ b/package/kernel/mac80211/patches/rt2x00/985-rt2x00-add-rxiq-calibration.patch @@ -407,7 +407,7 @@ void rt2800_disable_radio(struct rt2x00_dev *rt2x00dev); --- a/drivers/net/wireless/ralink/rt2x00/rt2x00.h +++ b/drivers/net/wireless/ralink/rt2x00/rt2x00.h -@@ -567,6 +567,7 @@ struct rt2x00lib_ops { +@@ -566,6 +566,7 @@ struct rt2x00lib_ops { int (*calcrcalibrationcode) (struct rt2x00_dev *rt2x00dev, int d1, int d2); void (*r_calibration) (struct rt2x00_dev *rt2x00dev); void (*rxdcoc_calibration) (struct rt2x00_dev *rt2x00dev); diff --git a/package/kernel/mac80211/patches/rt2x00/986-rt2x00-add-TX-LOFT-calibration.patch b/package/kernel/mac80211/patches/rt2x00/986-rt2x00-add-TX-LOFT-calibration.patch index 111c2a42c2..e0bf00deb6 100644 --- a/package/kernel/mac80211/patches/rt2x00/986-rt2x00-add-TX-LOFT-calibration.patch +++ b/package/kernel/mac80211/patches/rt2x00/986-rt2x00-add-TX-LOFT-calibration.patch @@ -992,7 +992,7 @@ void rt2800_disable_radio(struct rt2x00_dev *rt2x00dev); --- a/drivers/net/wireless/ralink/rt2x00/rt2x00.h +++ b/drivers/net/wireless/ralink/rt2x00/rt2x00.h -@@ -568,6 +568,7 @@ struct rt2x00lib_ops { +@@ -567,6 +567,7 @@ struct rt2x00lib_ops { void (*r_calibration) (struct rt2x00_dev *rt2x00dev); void (*rxdcoc_calibration) (struct rt2x00_dev *rt2x00dev); void (*rxiq_calibration) (struct rt2x00_dev *rt2x00dev); diff --git a/package/kernel/mac80211/patches/subsys/030-mac80211_fix-scan-when-operating-on-DFS-channels-in-ETSI-domains.patch b/package/kernel/mac80211/patches/subsys/030-mac80211_fix-scan-when-operating-on-DFS-channels-in-ETSI-domains.patch deleted file mode 100644 index 560f8850df..0000000000 --- a/package/kernel/mac80211/patches/subsys/030-mac80211_fix-scan-when-operating-on-DFS-channels-in-ETSI-domains.patch +++ /dev/null @@ -1,118 +0,0 @@ -From dc0c18ed229cdcca283dd78fefa38273ec37a42c Mon Sep 17 00:00:00 2001 -From: Aaron Komisar -Date: Wed, 2 Oct 2019 13:59:07 +0000 -Subject: mac80211: fix scan when operating on DFS channels in ETSI domains - -In non-ETSI regulatory domains scan is blocked when operating channel -is a DFS channel. For ETSI, however, once DFS channel is marked as -available after the CAC, this channel will remain available (for some -time) even after leaving this channel. - -Therefore a scan can be done without any impact on the availability -of the DFS channel as no new CAC is required after the scan. - -Enable scan in mac80211 in these cases. - -Signed-off-by: Aaron Komisar -Link: https://lore.kernel.org/r/1570024728-17284-1-git-send-email-aaron.komisar@tandemg.com -Signed-off-by: Johannes Berg ---- - include/net/cfg80211.h | 8 ++++++++ - net/mac80211/scan.c | 30 ++++++++++++++++++++++++++++-- - net/wireless/reg.c | 1 + - net/wireless/reg.h | 8 -------- - 4 files changed, 37 insertions(+), 10 deletions(-) - ---- a/include/net/cfg80211.h -+++ b/include/net/cfg80211.h -@@ -5554,6 +5554,14 @@ const struct ieee80211_reg_rule *freq_re - const char *reg_initiator_name(enum nl80211_reg_initiator initiator); - - /** -+ * regulatory_pre_cac_allowed - check if pre-CAC allowed in the current regdom -+ * @wiphy: wiphy for which pre-CAC capability is checked. -+ * -+ * Pre-CAC is allowed only in some regdomains (notable ETSI). -+ */ -+bool regulatory_pre_cac_allowed(struct wiphy *wiphy); -+ -+/** - * DOC: Internal regulatory db functions - * - */ ---- a/net/mac80211/scan.c -+++ b/net/mac80211/scan.c -@@ -520,10 +520,33 @@ static int ieee80211_start_sw_scan(struc - return 0; - } - -+static bool __ieee80211_can_leave_ch(struct ieee80211_sub_if_data *sdata) -+{ -+ struct ieee80211_local *local = sdata->local; -+ struct ieee80211_sub_if_data *sdata_iter; -+ -+ if (!ieee80211_is_radar_required(local)) -+ return true; -+ -+ if (!regulatory_pre_cac_allowed(local->hw.wiphy)) -+ return false; -+ -+ mutex_lock(&local->iflist_mtx); -+ list_for_each_entry(sdata_iter, &local->interfaces, list) { -+ if (sdata_iter->wdev.cac_started) { -+ mutex_unlock(&local->iflist_mtx); -+ return false; -+ } -+ } -+ mutex_unlock(&local->iflist_mtx); -+ -+ return true; -+} -+ - static bool ieee80211_can_scan(struct ieee80211_local *local, - struct ieee80211_sub_if_data *sdata) - { -- if (ieee80211_is_radar_required(local)) -+ if (!__ieee80211_can_leave_ch(sdata)) - return false; - - if (!list_empty(&local->roc_list)) -@@ -630,7 +653,10 @@ static int __ieee80211_start_scan(struct - - lockdep_assert_held(&local->mtx); - -- if (local->scan_req || ieee80211_is_radar_required(local)) -+ if (local->scan_req) -+ return -EBUSY; -+ -+ if (!__ieee80211_can_leave_ch(sdata)) - return -EBUSY; - - if (!ieee80211_can_scan(local, sdata)) { ---- a/net/wireless/reg.c -+++ b/net/wireless/reg.c -@@ -3883,6 +3883,7 @@ bool regulatory_pre_cac_allowed(struct w - - return pre_cac_allowed; - } -+EXPORT_SYMBOL(regulatory_pre_cac_allowed); - - void regulatory_propagate_dfs_state(struct wiphy *wiphy, - struct cfg80211_chan_def *chandef, ---- a/net/wireless/reg.h -+++ b/net/wireless/reg.h -@@ -156,14 +156,6 @@ bool regulatory_indoor_allowed(void); - #define REG_PRE_CAC_EXPIRY_GRACE_MS 2000 - - /** -- * regulatory_pre_cac_allowed - if pre-CAC allowed in the current dfs domain -- * @wiphy: wiphy for which pre-CAC capability is checked. -- -- * Pre-CAC is allowed only in ETSI domain. -- */ --bool regulatory_pre_cac_allowed(struct wiphy *wiphy); -- --/** - * regulatory_propagate_dfs_state - Propagate DFS channel state to other wiphys - * @wiphy - wiphy on which radar is detected and the event will be propagated - * to other available wiphys having the same DFS domain diff --git a/package/kernel/mac80211/patches/subsys/363-mac80211-accept-deauth-frames-in-IBSS-mode.patch b/package/kernel/mac80211/patches/subsys/363-mac80211-accept-deauth-frames-in-IBSS-mode.patch deleted file mode 100644 index ad0792b4f6..0000000000 --- a/package/kernel/mac80211/patches/subsys/363-mac80211-accept-deauth-frames-in-IBSS-mode.patch +++ /dev/null @@ -1,39 +0,0 @@ -From 95697f9907bfe3eab0ef20265a766b22e27dde64 Mon Sep 17 00:00:00 2001 -From: Johannes Berg -Date: Fri, 4 Oct 2019 15:37:05 +0300 -Subject: [PATCH] mac80211: accept deauth frames in IBSS mode - -We can process deauth frames and all, but we drop them very -early in the RX path today - this could never have worked. - -Fixes: 2cc59e784b54 ("mac80211: reply to AUTH with DEAUTH if sta allocation fails in IBSS") -Signed-off-by: Johannes Berg -Signed-off-by: Luca Coelho -Link: https://lore.kernel.org/r/20191004123706.15768-2-luca@coelho.fi -Signed-off-by: Johannes Berg ---- - net/mac80211/rx.c | 11 ++++++++++- - 1 file changed, 10 insertions(+), 1 deletion(-) - ---- a/net/mac80211/rx.c -+++ b/net/mac80211/rx.c -@@ -3467,9 +3467,18 @@ ieee80211_rx_h_mgmt(struct ieee80211_rx_ - case cpu_to_le16(IEEE80211_STYPE_PROBE_RESP): - /* process for all: mesh, mlme, ibss */ - break; -+ case cpu_to_le16(IEEE80211_STYPE_DEAUTH): -+ if (is_multicast_ether_addr(mgmt->da) && -+ !is_broadcast_ether_addr(mgmt->da)) -+ return RX_DROP_MONITOR; -+ -+ /* process only for station/IBSS */ -+ if (sdata->vif.type != NL80211_IFTYPE_STATION && -+ sdata->vif.type != NL80211_IFTYPE_ADHOC) -+ return RX_DROP_MONITOR; -+ break; - case cpu_to_le16(IEEE80211_STYPE_ASSOC_RESP): - case cpu_to_le16(IEEE80211_STYPE_REASSOC_RESP): -- case cpu_to_le16(IEEE80211_STYPE_DEAUTH): - case cpu_to_le16(IEEE80211_STYPE_DISASSOC): - if (is_multicast_ether_addr(mgmt->da) && - !is_broadcast_ether_addr(mgmt->da)) From 0062aad8ecc9bbe36c55895fd78fcaf9a406b006 Mon Sep 17 00:00:00 2001 From: Hauke Mehrtens Date: Fri, 22 Nov 2019 22:43:25 +0100 Subject: [PATCH 09/17] e2fsprogs: Fix CVE-2019-5094 in libsupport This adds the following patch from debian: https://git.kernel.org/pub/scm/fs/ext2/e2fsprogs.git/commit/?h=debian/stable&id=09fe1fd2a1f9efc3091b4fc61f1876d0785956a8 libsupport: add checks to prevent buffer overrun bugs in quota code Signed-off-by: Hauke Mehrtens --- package/utils/e2fsprogs/Makefile | 2 +- .../100-CVE-2019-5094-libsupport.patch | 203 ++++++++++++++++++ 2 files changed, 204 insertions(+), 1 deletion(-) create mode 100644 package/utils/e2fsprogs/patches/100-CVE-2019-5094-libsupport.patch diff --git a/package/utils/e2fsprogs/Makefile b/package/utils/e2fsprogs/Makefile index 1ed6280eda..b2b6ea31ea 100644 --- a/package/utils/e2fsprogs/Makefile +++ b/package/utils/e2fsprogs/Makefile @@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk PKG_NAME:=e2fsprogs PKG_VERSION:=1.44.5 -PKG_RELEASE:=1 +PKG_RELEASE:=2 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz PKG_SOURCE_URL:=@KERNEL/linux/kernel/people/tytso/e2fsprogs/v$(PKG_VERSION)/ diff --git a/package/utils/e2fsprogs/patches/100-CVE-2019-5094-libsupport.patch b/package/utils/e2fsprogs/patches/100-CVE-2019-5094-libsupport.patch new file mode 100644 index 0000000000..c69f465052 --- /dev/null +++ b/package/utils/e2fsprogs/patches/100-CVE-2019-5094-libsupport.patch @@ -0,0 +1,203 @@ +From 09fe1fd2a1f9efc3091b4fc61f1876d0785956a8 Mon Sep 17 00:00:00 2001 +From: Theodore Ts'o +Date: Sun, 1 Sep 2019 00:59:16 -0400 +Subject: libsupport: add checks to prevent buffer overrun bugs in quota code + +A maliciously corrupted file systems can trigger buffer overruns in +the quota code used by e2fsck. To fix this, add sanity checks to the +quota header fields as well as to block number references in the quota +tree. + +Addresses: CVE-2019-5094 +Addresses: TALOS-2019-0887 +Signed-off-by: Theodore Ts'o +(cherry picked from commit 8dbe7b475ec5e91ed767239f0e85880f416fc384) +--- + lib/support/mkquota.c | 1 + + lib/support/quotaio_tree.c | 71 ++++++++++++++++++++++++++++++---------------- + lib/support/quotaio_v2.c | 28 ++++++++++++++++++ + 3 files changed, 76 insertions(+), 24 deletions(-) + +--- a/lib/support/mkquota.c ++++ b/lib/support/mkquota.c +@@ -671,6 +671,7 @@ errcode_t quota_compare_and_update(quota + err = qh.qh_ops->scan_dquots(&qh, scan_dquots_callback, &scan_data); + if (err) { + log_debug("Error scanning dquots"); ++ *usage_inconsistent = 1; + goto out_close_qh; + } + +--- a/lib/support/quotaio_tree.c ++++ b/lib/support/quotaio_tree.c +@@ -540,6 +540,17 @@ struct dquot *qtree_read_dquot(struct qu + return dquot; + } + ++static int check_reference(struct quota_handle *h, unsigned int blk) ++{ ++ if (blk >= h->qh_info.u.v2_mdqi.dqi_qtree.dqi_blocks) { ++ log_err("Illegal reference (%u >= %u) in %s quota file", ++ blk, h->qh_info.u.v2_mdqi.dqi_qtree.dqi_blocks, ++ quota_type2name(h->qh_type)); ++ return -1; ++ } ++ return 0; ++} ++ + /* + * Scan all dquots in file and call callback on each + */ +@@ -558,7 +569,7 @@ static int report_block(struct dquot *dq + int entries, i; + + if (!buf) +- return 0; ++ return -1; + + set_bit(bitmap, blk); + read_blk(dquot->dq_h, blk, buf); +@@ -580,23 +591,12 @@ static int report_block(struct dquot *dq + return entries; + } + +-static void check_reference(struct quota_handle *h, unsigned int blk) +-{ +- if (blk >= h->qh_info.u.v2_mdqi.dqi_qtree.dqi_blocks) +- log_err("Illegal reference (%u >= %u) in %s quota file. " +- "Quota file is probably corrupted.\n" +- "Please run e2fsck (8) to fix it.", +- blk, +- h->qh_info.u.v2_mdqi.dqi_qtree.dqi_blocks, +- quota_type2name(h->qh_type)); +-} +- + static int report_tree(struct dquot *dquot, unsigned int blk, int depth, + char *bitmap, + int (*process_dquot) (struct dquot *, void *), + void *data) + { +- int entries = 0, i; ++ int entries = 0, ret, i; + dqbuf_t buf = getdqbuf(); + __le32 *ref = (__le32 *) buf; + +@@ -607,22 +607,40 @@ static int report_tree(struct dquot *dqu + if (depth == QT_TREEDEPTH - 1) { + for (i = 0; i < QT_BLKSIZE >> 2; i++) { + blk = ext2fs_le32_to_cpu(ref[i]); +- check_reference(dquot->dq_h, blk); +- if (blk && !get_bit(bitmap, blk)) +- entries += report_block(dquot, blk, bitmap, +- process_dquot, data); ++ if (check_reference(dquot->dq_h, blk)) { ++ entries = -1; ++ goto errout; ++ } ++ if (blk && !get_bit(bitmap, blk)) { ++ ret = report_block(dquot, blk, bitmap, ++ process_dquot, data); ++ if (ret < 0) { ++ entries = ret; ++ goto errout; ++ } ++ entries += ret; ++ } + } + } else { + for (i = 0; i < QT_BLKSIZE >> 2; i++) { + blk = ext2fs_le32_to_cpu(ref[i]); + if (blk) { +- check_reference(dquot->dq_h, blk); +- entries += report_tree(dquot, blk, depth + 1, +- bitmap, process_dquot, +- data); ++ if (check_reference(dquot->dq_h, blk)) { ++ entries = -1; ++ goto errout; ++ } ++ ret = report_tree(dquot, blk, depth + 1, ++ bitmap, process_dquot, ++ data); ++ if (ret < 0) { ++ entries = ret; ++ goto errout; ++ } ++ entries += ret; + } + } + } ++errout: + freedqbuf(buf); + return entries; + } +@@ -642,6 +660,7 @@ int qtree_scan_dquots(struct quota_handl + int (*process_dquot) (struct dquot *, void *), + void *data) + { ++ int ret; + char *bitmap; + struct v2_mem_dqinfo *v2info = &h->qh_info.u.v2_mdqi; + struct qtree_mem_dqinfo *info = &v2info->dqi_qtree; +@@ -655,10 +674,14 @@ int qtree_scan_dquots(struct quota_handl + ext2fs_free_mem(&dquot); + return -1; + } +- v2info->dqi_used_entries = report_tree(dquot, QT_TREEOFF, 0, bitmap, +- process_dquot, data); ++ ret = report_tree(dquot, QT_TREEOFF, 0, bitmap, process_dquot, data); ++ if (ret < 0) ++ goto errout; ++ v2info->dqi_used_entries = ret; + v2info->dqi_data_blocks = find_set_bits(bitmap, info->dqi_blocks); ++ ret = 0; ++errout: + ext2fs_free_mem(&bitmap); + ext2fs_free_mem(&dquot); +- return 0; ++ return ret; + } +--- a/lib/support/quotaio_v2.c ++++ b/lib/support/quotaio_v2.c +@@ -175,6 +175,8 @@ static int v2_check_file(struct quota_ha + static int v2_init_io(struct quota_handle *h) + { + struct v2_disk_dqinfo ddqinfo; ++ struct v2_mem_dqinfo *info; ++ __u64 filesize; + + h->qh_info.u.v2_mdqi.dqi_qtree.dqi_entry_size = + sizeof(struct v2r1_disk_dqblk); +@@ -185,6 +187,32 @@ static int v2_init_io(struct quota_handl + sizeof(ddqinfo)) != sizeof(ddqinfo)) + return -1; + v2_disk2memdqinfo(&h->qh_info, &ddqinfo); ++ ++ /* Check to make sure quota file info is sane */ ++ info = &h->qh_info.u.v2_mdqi; ++ if (ext2fs_file_get_lsize(h->qh_qf.e2_file, &filesize)) ++ return -1; ++ if ((filesize > (1U << 31)) || ++ (info->dqi_qtree.dqi_blocks > ++ (filesize + QT_BLKSIZE - 1) >> QT_BLKSIZE_BITS)) { ++ log_err("Quota inode %u corrupted: file size %llu; " ++ "dqi_blocks %u", h->qh_qf.ino, ++ filesize, info->dqi_qtree.dqi_blocks); ++ return -1; ++ } ++ if (info->dqi_qtree.dqi_free_blk >= info->dqi_qtree.dqi_blocks) { ++ log_err("Quota inode %u corrupted: free_blk %u; dqi_blocks %u", ++ h->qh_qf.ino, info->dqi_qtree.dqi_free_blk, ++ info->dqi_qtree.dqi_blocks); ++ return -1; ++ } ++ if (info->dqi_qtree.dqi_free_entry >= info->dqi_qtree.dqi_blocks) { ++ log_err("Quota inode %u corrupted: free_entry %u; " ++ "dqi_blocks %u", h->qh_qf.ino, ++ info->dqi_qtree.dqi_free_entry, ++ info->dqi_qtree.dqi_blocks); ++ return -1; ++ } + return 0; + } + From f1ca27740595105ec7b3d7ffc4b046c038916082 Mon Sep 17 00:00:00 2001 From: Kevin Darbyshire-Bryant Date: Fri, 22 Nov 2019 14:04:02 +0000 Subject: [PATCH 10/17] dnsmasq: correct sense & usage of dnsseccheckunsigned dnsmasq v2.80 made 'dnssec-check-unsigned' the default, thus the uci option was rendered ineffectual: we checked unsigned zones no matter the setting. Disabling the checking of unsigned zones is now achieve with the "--dnssec-check-unsigned=no" dnsmasq option. Update init script to pass required option in the disabled case. Signed-off-by: Kevin Darbyshire-Bryant --- package/network/services/dnsmasq/Makefile | 2 +- package/network/services/dnsmasq/files/dnsmasq.init | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/package/network/services/dnsmasq/Makefile b/package/network/services/dnsmasq/Makefile index a1b51896a9..c57a837e9e 100644 --- a/package/network/services/dnsmasq/Makefile +++ b/package/network/services/dnsmasq/Makefile @@ -10,7 +10,7 @@ include $(TOPDIR)/rules.mk PKG_NAME:=dnsmasq PKG_UPSTREAM_VERSION:=2.80 PKG_VERSION:=$(subst test,~~test,$(subst rc,~rc,$(PKG_UPSTREAM_VERSION))) -PKG_RELEASE:=14 +PKG_RELEASE:=15 PKG_SOURCE:=$(PKG_NAME)-$(PKG_UPSTREAM_VERSION).tar.xz PKG_SOURCE_URL:=http://thekelleys.org.uk/dnsmasq diff --git a/package/network/services/dnsmasq/files/dnsmasq.init b/package/network/services/dnsmasq/files/dnsmasq.init index 1054f7a12a..94a069f1ac 100644 --- a/package/network/services/dnsmasq/files/dnsmasq.init +++ b/package/network/services/dnsmasq/files/dnsmasq.init @@ -966,7 +966,8 @@ dnsmasq_start() [ -f "$TIMEVALIDFILE" ] || xappend "--dnssec-no-timecheck" } } - append_bool "$cfg" dnsseccheckunsigned "--dnssec-check-unsigned" + config_get_bool dnsseccheckunsigned "$cfg" dnsseccheckunsigned 1 + [ "$dnsseccheckunsigned" -eq 0 ] && xappend "--dnssec-check-unsigned=no" } config_get addmac "$cfg" addmac 0 From 28d84331f4bba5923059e701f5d4878b2df3fa79 Mon Sep 17 00:00:00 2001 From: Sebastian Kemper Date: Sat, 23 Nov 2019 11:25:02 +0100 Subject: [PATCH 11/17] mac80211: add default value for noscan Commit b3d8b3a introduced a new test: [ -n "$noscan" -a "$noscan" -gt 0 ] && hostapd_noscan=1 But if length of "$noscan" is zero (noscan is not set) this doesn't stop the shell to evaluate the rest of the test. root@hank2:~# [ -n "$noscan" -a "$noscan" -gt 0 ] ash: out of range root@hank2:~# So when radios are brought up this shows in the log: Sat Nov 23 10:51:38 2019 daemon.info procd: - init complete - Sat Nov 23 10:52:24 2019 daemon.notice netifd: radio1 (1243): sh: out of range Sat Nov 23 10:52:25 2019 user.notice firewall: Reloading firewall due to ifup of wan (eth0.2) Sat Nov 23 10:52:25 2019 daemon.notice netifd: radio0 (1242): sh: out of range Sat Nov 23 10:52:26 2019 authpriv.info dropbear[1536]: Not backgrounding This commit sets noscan to 0 if unset and removes the gratuitous length check, preventing the warning. Signed-off-by: Sebastian Kemper --- package/kernel/mac80211/files/lib/netifd/wireless/mac80211.sh | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/package/kernel/mac80211/files/lib/netifd/wireless/mac80211.sh b/package/kernel/mac80211/files/lib/netifd/wireless/mac80211.sh index a04f1e3ca7..5c67ea0600 100644 --- a/package/kernel/mac80211/files/lib/netifd/wireless/mac80211.sh +++ b/package/kernel/mac80211/files/lib/netifd/wireless/mac80211.sh @@ -106,7 +106,9 @@ mac80211_hostapd_setup_base() { json_get_vars noscan ht_coex json_get_values ht_capab_list ht_capab tx_burst - [ -n "$noscan" -a "$noscan" -gt 0 ] && hostapd_noscan=1 + set_default noscan 0 + + [ "$noscan" -gt 0 ] && hostapd_noscan=1 [ "$tx_burst" = 0 ] && tx_burst= ieee80211n=1 From b7c58a1eeba5be2e1f77ec05b417be9d87e26916 Mon Sep 17 00:00:00 2001 From: Yousong Zhou Date: Wed, 13 Nov 2019 17:03:12 +0000 Subject: [PATCH 12/17] kernel: nf_conntrack_rtcache: fix cleanup on netns delete and rmmod Fixes FS#1472, FS#2353, FS#2426 Fixes: b3f95490 ("kernel: generic: Add kernel 4.14 support") Signed-off-by: Yousong Zhou Acked-by: Hauke Mehrtens --- .../020-backport_netfilter_rtcache.patch | 14 +++++++++++++- .../020-backport_netfilter_rtcache.patch | 14 +++++++++++++- 2 files changed, 26 insertions(+), 2 deletions(-) diff --git a/target/linux/generic/backport-4.14/020-backport_netfilter_rtcache.patch b/target/linux/generic/backport-4.14/020-backport_netfilter_rtcache.patch index 8a6fba4307..d745a97026 100644 --- a/target/linux/generic/backport-4.14/020-backport_netfilter_rtcache.patch +++ b/target/linux/generic/backport-4.14/020-backport_netfilter_rtcache.patch @@ -127,7 +127,7 @@ Signed-off-by: Florian Westphal # netlink interface for nf_conntrack --- /dev/null +++ b/net/netfilter/nf_conntrack_rtcache.c -@@ -0,0 +1,428 @@ +@@ -0,0 +1,440 @@ +/* route cache for netfilter. + * + * (C) 2014 Red Hat GmbH @@ -444,6 +444,11 @@ Signed-off-by: Florian Westphal + .destroy = nf_conn_rtcache_destroy, +}; + ++static int __net_init rtcache_net_init(struct net *net) ++{ ++ return nf_register_net_hooks(net, rtcache_ops, ARRAY_SIZE(rtcache_ops)); ++} ++ +static void __net_exit rtcache_net_exit(struct net *net) +{ + /* remove hooks so no new connections get rtcache extension */ @@ -451,6 +456,7 @@ Signed-off-by: Florian Westphal +} + +static struct pernet_operations rtcache_ops_net_ops = { ++ .init = rtcache_net_init, + .exit = rtcache_net_exit, +}; + @@ -531,6 +537,11 @@ Signed-off-by: Florian Westphal + synchronize_net(); + + unregister_netdevice_notifier(&nf_rtcache_notifier); ++ unregister_pernet_subsys(&rtcache_ops_net_ops); ++ for_each_net(net) ++ nf_unregister_net_hooks(net, rtcache_ops, ARRAY_SIZE(rtcache_ops)); ++ ++ synchronize_net(); + + rtnl_lock(); + @@ -547,6 +558,7 @@ Signed-off-by: Florian Westphal + } + + rtnl_unlock(); ++ + synchronize_net(); + nf_ct_extend_unregister(&rtcache_extend); +} diff --git a/target/linux/generic/backport-4.19/020-backport_netfilter_rtcache.patch b/target/linux/generic/backport-4.19/020-backport_netfilter_rtcache.patch index 3a35381ce3..2d84bc2acf 100644 --- a/target/linux/generic/backport-4.19/020-backport_netfilter_rtcache.patch +++ b/target/linux/generic/backport-4.19/020-backport_netfilter_rtcache.patch @@ -127,7 +127,7 @@ Signed-off-by: Florian Westphal # netlink interface for nf_conntrack --- /dev/null +++ b/net/netfilter/nf_conntrack_rtcache.c -@@ -0,0 +1,428 @@ +@@ -0,0 +1,440 @@ +/* route cache for netfilter. + * + * (C) 2014 Red Hat GmbH @@ -444,6 +444,11 @@ Signed-off-by: Florian Westphal + .destroy = nf_conn_rtcache_destroy, +}; + ++static int __net_init rtcache_net_init(struct net *net) ++{ ++ return nf_register_net_hooks(net, rtcache_ops, ARRAY_SIZE(rtcache_ops)); ++} ++ +static void __net_exit rtcache_net_exit(struct net *net) +{ + /* remove hooks so no new connections get rtcache extension */ @@ -451,6 +456,7 @@ Signed-off-by: Florian Westphal +} + +static struct pernet_operations rtcache_ops_net_ops = { ++ .init = rtcache_net_init, + .exit = rtcache_net_exit, +}; + @@ -531,6 +537,11 @@ Signed-off-by: Florian Westphal + synchronize_net(); + + unregister_netdevice_notifier(&nf_rtcache_notifier); ++ unregister_pernet_subsys(&rtcache_ops_net_ops); ++ for_each_net(net) ++ nf_unregister_net_hooks(net, rtcache_ops, ARRAY_SIZE(rtcache_ops)); ++ ++ synchronize_net(); + + rtnl_lock(); + @@ -547,6 +558,7 @@ Signed-off-by: Florian Westphal + } + + rtnl_unlock(); ++ + synchronize_net(); + nf_ct_extend_unregister(&rtcache_extend); +} From 640a36aafcb5c247d5347e0b03f3cc49204d7941 Mon Sep 17 00:00:00 2001 From: Adrian Schmutzler Date: Tue, 19 Nov 2019 15:47:11 +0100 Subject: [PATCH 13/17] ath79: DTS style improvement for Ubiquiti XM and BZ devices This applies minor style improvements and removes commented pll clock adjustments from ubnt_xm DTSI. The latter were introduced (already commented out) when adding ath79 target and have never been touched since then. For Unifi (BZ board), similar clock adjustments are employed and used. Signed-off-by: Adrian Schmutzler --- .../linux/ath79/dts/ar7241_ubnt_airrouter.dts | 2 +- target/linux/ath79/dts/ar7241_ubnt_unifi.dts | 10 ++++----- target/linux/ath79/dts/ar7241_ubnt_xm.dtsi | 21 ++++++------------- .../ath79/dts/ar7241_ubnt_xm_outdoor.dtsi | 1 + 4 files changed, 13 insertions(+), 21 deletions(-) diff --git a/target/linux/ath79/dts/ar7241_ubnt_airrouter.dts b/target/linux/ath79/dts/ar7241_ubnt_airrouter.dts index 03306de5d9..ad2762e20c 100644 --- a/target/linux/ath79/dts/ar7241_ubnt_airrouter.dts +++ b/target/linux/ath79/dts/ar7241_ubnt_airrouter.dts @@ -15,7 +15,7 @@ label-mac-device = &wifi; }; - airrouter-leds { + leds { compatible = "gpio-leds"; led_globe: globe { diff --git a/target/linux/ath79/dts/ar7241_ubnt_unifi.dts b/target/linux/ath79/dts/ar7241_ubnt_unifi.dts index 3e73eba9ed..5f12fd581b 100644 --- a/target/linux/ath79/dts/ar7241_ubnt_unifi.dts +++ b/target/linux/ath79/dts/ar7241_ubnt_unifi.dts @@ -78,30 +78,30 @@ read-only; }; - partition@1 { + partition@40000 { label = "u-boot-env"; reg = <0x040000 0x010000>; }; - partition@2 { + partition@50000 { compatible = "denx,uimage"; label = "firmware"; reg = <0x050000 0x750000>; }; - partition@3 { + partition@7a0000 { label = "board_config"; reg = <0x7a0000 0x010000>; read-only; }; - partition@4 { + partition@7b0000 { label = "cfg"; reg = <0x7b0000 0x040000>; read-only; }; - art: partition@5 { + art: partition@7f0000 { label = "art"; reg = <0x7f0000 0x010000>; read-only; diff --git a/target/linux/ath79/dts/ar7241_ubnt_xm.dtsi b/target/linux/ath79/dts/ar7241_ubnt_xm.dtsi index 687aef1112..e2b653b3a7 100644 --- a/target/linux/ath79/dts/ar7241_ubnt_xm.dtsi +++ b/target/linux/ath79/dts/ar7241_ubnt_xm.dtsi @@ -9,12 +9,6 @@ compatible = "ubnt,xm", "qca,ar7241"; model = "Ubiquiti Networks XM (rev 1.0) board"; -/* extosc: ref { - compatible = "fixed-clock"; - #clock-cells = <0>; - clock-frequency = <40000000>; - }; -*/ keys { compatible = "gpio-keys"; @@ -30,12 +24,9 @@ status = "okay"; }; -/*&pll { - clocks = <&extosc>; -};*/ - &spi { status = "okay"; + num-cs = <1>; flash@0 { @@ -54,30 +45,30 @@ read-only; }; - partition@1 { + partition@40000 { label = "u-boot-env"; reg = <0x040000 0x010000>; }; - partition@2 { + partition@50000 { compatible = "denx,uimage"; label = "firmware"; reg = <0x050000 0x750000>; }; - partition@3 { + partition@7a0000 { label = "board_config"; reg = <0x7a0000 0x010000>; read-only; }; - partition@4 { + partition@7b0000 { label = "cfg"; reg = <0x7b0000 0x040000>; read-only; }; - art: partition@5 { + art: partition@7f0000 { label = "art"; reg = <0x7f0000 0x010000>; read-only; diff --git a/target/linux/ath79/dts/ar7241_ubnt_xm_outdoor.dtsi b/target/linux/ath79/dts/ar7241_ubnt_xm_outdoor.dtsi index 337da5b4b7..75116edc51 100644 --- a/target/linux/ath79/dts/ar7241_ubnt_xm_outdoor.dtsi +++ b/target/linux/ath79/dts/ar7241_ubnt_xm_outdoor.dtsi @@ -11,6 +11,7 @@ leds { compatible = "gpio-leds"; + link1 { label = "ubnt:red:link1"; gpios = <&gpio 0 GPIO_ACTIVE_HIGH>; From 298814e6be7640d89328de9e7c90d4349e30683f Mon Sep 17 00:00:00 2001 From: Sungbo Eo Date: Tue, 12 Nov 2019 01:20:45 +0900 Subject: [PATCH 14/17] base-files: config_generate: split macaddr with multiple ifaces netifd does not handle network.@device[x].name properly if it contains multiple ifaces separated by spaces. Due to this, board.d lan_mac setup does not work if multiple ifaces are set to LAN by ucidef_set_interface_lan. To fix this, create a device node for each member iface when running config_generate instead. Those are named based on the member ifname: ucidef_set_interface_lan "eth0 eth1.1" ucidef_set_interface_macaddr "lan" "yy:yy:yy:yy:yy:01" will return config device 'lan_eth0_dev' option name 'eth0' option macaddr 'yy:yy:yy:yy:yy:01' config device 'lan_eth1_1_dev' option name 'eth1.1' option macaddr 'yy:yy:yy:yy:yy:01' ref: https://github.com/openwrt/openwrt/pull/2542 Signed-off-by: Sungbo Eo [always use new scheme, extend description, change commit title] Signed-off-by: Adrian Schmutzler --- package/base-files/Makefile | 2 +- package/base-files/files/bin/config_generate | 16 ++++++++++------ 2 files changed, 11 insertions(+), 7 deletions(-) diff --git a/package/base-files/Makefile b/package/base-files/Makefile index 0ca4d739f3..cf5166772d 100644 --- a/package/base-files/Makefile +++ b/package/base-files/Makefile @@ -12,7 +12,7 @@ include $(INCLUDE_DIR)/version.mk include $(INCLUDE_DIR)/feeds.mk PKG_NAME:=base-files -PKG_RELEASE:=209 +PKG_RELEASE:=210 PKG_FLAGS:=nonshared PKG_FILE_DEPENDS:=$(PLATFORM_DIR)/ $(GENERIC_PLATFORM_DIR)/base-files/ diff --git a/package/base-files/files/bin/config_generate b/package/base-files/files/bin/config_generate index 3ca035ca8b..3bf48d7216 100755 --- a/package/base-files/files/bin/config_generate +++ b/package/base-files/files/bin/config_generate @@ -85,12 +85,16 @@ generate_network() { set network.$1.proto='none' EOF - [ -n "$macaddr" ] && uci -q batch <<-EOF - delete network.$1_dev - set network.$1_dev='device' - set network.$1_dev.name='$ifname' - set network.$1_dev.macaddr='$macaddr' - EOF + if [ -n "$macaddr" ]; then + for name in $ifname; do + uci -q batch <<-EOF + delete network.$1_${name/./_}_dev + set network.$1_${name/./_}_dev='device' + set network.$1_${name/./_}_dev.name='$name' + set network.$1_${name/./_}_dev.macaddr='$macaddr' + EOF + done + fi case "$protocol" in static) From 591a06316d028c2a56642dceba105490f7f82ffa Mon Sep 17 00:00:00 2001 From: Bernhard Geier Date: Fri, 22 Nov 2019 23:11:24 +0100 Subject: [PATCH 15/17] tplink-safeloader: shorten version number of TP-Link WBS210 v2 "2.0" instead of "2.00" is sufficient and more in line with the other definitions. Signed-off-by: Bernhard Geier [commit message/title adjustments] Signed-off-by: Adrian Schmutzler --- tools/firmware-utils/src/tplink-safeloader.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/tools/firmware-utils/src/tplink-safeloader.c b/tools/firmware-utils/src/tplink-safeloader.c index 4e85bd59ca..f8b8491326 100644 --- a/tools/firmware-utils/src/tplink-safeloader.c +++ b/tools/firmware-utils/src/tplink-safeloader.c @@ -511,9 +511,9 @@ static struct device_info boards[] = { .vendor = "CPE510(TP-LINK|UN|N300-5):1.0\r\n", .support_list = "SupportList:\r\n" - "WBS210(TP-LINK|UN|N300-2|00000000):2.00\r\n" - "WBS210(TP-LINK|US|N300-2|55530000):2.00\r\n" - "WBS210(TP-LINK|EU|N300-2|45550000):2.00\r\n", + "WBS210(TP-LINK|UN|N300-2|00000000):2.0\r\n" + "WBS210(TP-LINK|US|N300-2|55530000):2.0\r\n" + "WBS210(TP-LINK|EU|N300-2|45550000):2.0\r\n", .support_trail = '\xff', .soft_ver = NULL, From 226bc91109c814b3577b1b126f4ab420c868d5a8 Mon Sep 17 00:00:00 2001 From: Adrian Schmutzler Date: Fri, 22 Nov 2019 11:50:00 +0100 Subject: [PATCH 16/17] ath79: improve TP-Link CPE DTSI names for ar9344 SOC The initial DTSI names for the TP-Link CPE devices have become quite confusing, as several non-V1 devices now use the *-v1.dtsi, the *cpe510-v1.dts does not use the cpe510.dtsi, etc. This introduces a new naming scheme based on whether devices have one or two ports, which should be easier to grasp. Signed-off-by: Adrian Schmutzler --- .../dts/{ar9344_tplink_cpexxx.dtsi => ar9344_tplink_cpe.dtsi} | 0 target/linux/ath79/dts/ar9344_tplink_cpe210-v1.dts | 2 +- target/linux/ath79/dts/ar9344_tplink_cpe220-v2.dts | 2 +- target/linux/ath79/dts/ar9344_tplink_cpe510-v1.dts | 2 +- target/linux/ath79/dts/ar9344_tplink_cpe510-v2.dts | 2 +- target/linux/ath79/dts/ar9344_tplink_cpe510-v3.dts | 2 +- target/linux/ath79/dts/ar9344_tplink_cpe610-v1.dts | 2 +- .../{ar9344_tplink_cpe510.dtsi => ar9344_tplink_cpe_1port.dtsi} | 2 +- ...r9344_tplink_cpexxx-v1.dtsi => ar9344_tplink_cpe_2port.dtsi} | 2 +- target/linux/ath79/dts/ar9344_tplink_wbs210-v2.dts | 2 +- target/linux/ath79/dts/ar9344_tplink_wbs510-v1.dts | 2 +- target/linux/ath79/dts/ar9344_tplink_wbs510-v2.dts | 2 +- 12 files changed, 11 insertions(+), 11 deletions(-) rename target/linux/ath79/dts/{ar9344_tplink_cpexxx.dtsi => ar9344_tplink_cpe.dtsi} (100%) rename target/linux/ath79/dts/{ar9344_tplink_cpe510.dtsi => ar9344_tplink_cpe_1port.dtsi} (95%) rename target/linux/ath79/dts/{ar9344_tplink_cpexxx-v1.dtsi => ar9344_tplink_cpe_2port.dtsi} (96%) diff --git a/target/linux/ath79/dts/ar9344_tplink_cpexxx.dtsi b/target/linux/ath79/dts/ar9344_tplink_cpe.dtsi similarity index 100% rename from target/linux/ath79/dts/ar9344_tplink_cpexxx.dtsi rename to target/linux/ath79/dts/ar9344_tplink_cpe.dtsi diff --git a/target/linux/ath79/dts/ar9344_tplink_cpe210-v1.dts b/target/linux/ath79/dts/ar9344_tplink_cpe210-v1.dts index e82fd4a32f..95604f07c1 100644 --- a/target/linux/ath79/dts/ar9344_tplink_cpe210-v1.dts +++ b/target/linux/ath79/dts/ar9344_tplink_cpe210-v1.dts @@ -1,7 +1,7 @@ // SPDX-License-Identifier: GPL-2.0-or-later OR MIT /dts-v1/; -#include "ar9344_tplink_cpexxx-v1.dtsi" +#include "ar9344_tplink_cpe_2port.dtsi" / { compatible = "tplink,cpe210-v1", "qca,ar9344"; diff --git a/target/linux/ath79/dts/ar9344_tplink_cpe220-v2.dts b/target/linux/ath79/dts/ar9344_tplink_cpe220-v2.dts index 7e8822710f..4a737378b0 100644 --- a/target/linux/ath79/dts/ar9344_tplink_cpe220-v2.dts +++ b/target/linux/ath79/dts/ar9344_tplink_cpe220-v2.dts @@ -1,7 +1,7 @@ // SPDX-License-Identifier: GPL-2.0-or-later OR MIT /dts-v1/; -#include "ar9344_tplink_cpexxx-v1.dtsi" +#include "ar9344_tplink_cpe_2port.dtsi" / { compatible = "tplink,cpe220-v2", "qca,ar9344"; diff --git a/target/linux/ath79/dts/ar9344_tplink_cpe510-v1.dts b/target/linux/ath79/dts/ar9344_tplink_cpe510-v1.dts index 34b83c944e..483fdf4e6c 100644 --- a/target/linux/ath79/dts/ar9344_tplink_cpe510-v1.dts +++ b/target/linux/ath79/dts/ar9344_tplink_cpe510-v1.dts @@ -1,7 +1,7 @@ // SPDX-License-Identifier: GPL-2.0-or-later OR MIT /dts-v1/; -#include "ar9344_tplink_cpexxx-v1.dtsi" +#include "ar9344_tplink_cpe_2port.dtsi" / { compatible = "tplink,cpe510-v1", "qca,ar9344"; diff --git a/target/linux/ath79/dts/ar9344_tplink_cpe510-v2.dts b/target/linux/ath79/dts/ar9344_tplink_cpe510-v2.dts index 758d0c02f0..7348bf7553 100644 --- a/target/linux/ath79/dts/ar9344_tplink_cpe510-v2.dts +++ b/target/linux/ath79/dts/ar9344_tplink_cpe510-v2.dts @@ -1,7 +1,7 @@ // SPDX-License-Identifier: GPL-2.0-or-later OR MIT /dts-v1/; -#include "ar9344_tplink_cpe510.dtsi" +#include "ar9344_tplink_cpe_1port.dtsi" / { compatible = "tplink,cpe510-v2", "qca,ar9344"; diff --git a/target/linux/ath79/dts/ar9344_tplink_cpe510-v3.dts b/target/linux/ath79/dts/ar9344_tplink_cpe510-v3.dts index 0909fcfa73..20a16c3d3e 100644 --- a/target/linux/ath79/dts/ar9344_tplink_cpe510-v3.dts +++ b/target/linux/ath79/dts/ar9344_tplink_cpe510-v3.dts @@ -1,7 +1,7 @@ // SPDX-License-Identifier: GPL-2.0-or-later OR MIT /dts-v1/; -#include "ar9344_tplink_cpe510.dtsi" +#include "ar9344_tplink_cpe_1port.dtsi" / { compatible = "tplink,cpe510-v3", "qca,ar9344"; diff --git a/target/linux/ath79/dts/ar9344_tplink_cpe610-v1.dts b/target/linux/ath79/dts/ar9344_tplink_cpe610-v1.dts index cb614a9dfb..54ea399b74 100644 --- a/target/linux/ath79/dts/ar9344_tplink_cpe610-v1.dts +++ b/target/linux/ath79/dts/ar9344_tplink_cpe610-v1.dts @@ -1,7 +1,7 @@ // SPDX-License-Identifier: GPL-2.0-or-later OR MIT /dts-v1/; -#include "ar9344_tplink_cpexxx.dtsi" +#include "ar9344_tplink_cpe.dtsi" / { model = "TP-Link CPE610 v1"; diff --git a/target/linux/ath79/dts/ar9344_tplink_cpe510.dtsi b/target/linux/ath79/dts/ar9344_tplink_cpe_1port.dtsi similarity index 95% rename from target/linux/ath79/dts/ar9344_tplink_cpe510.dtsi rename to target/linux/ath79/dts/ar9344_tplink_cpe_1port.dtsi index 41a9443740..653efdee17 100644 --- a/target/linux/ath79/dts/ar9344_tplink_cpe510.dtsi +++ b/target/linux/ath79/dts/ar9344_tplink_cpe_1port.dtsi @@ -1,7 +1,7 @@ // SPDX-License-Identifier: GPL-2.0-or-later OR MIT /dts-v1/; -#include "ar9344_tplink_cpexxx.dtsi" +#include "ar9344_tplink_cpe.dtsi" / { aliases { diff --git a/target/linux/ath79/dts/ar9344_tplink_cpexxx-v1.dtsi b/target/linux/ath79/dts/ar9344_tplink_cpe_2port.dtsi similarity index 96% rename from target/linux/ath79/dts/ar9344_tplink_cpexxx-v1.dtsi rename to target/linux/ath79/dts/ar9344_tplink_cpe_2port.dtsi index 440ba8a8b3..e97e49d718 100644 --- a/target/linux/ath79/dts/ar9344_tplink_cpexxx-v1.dtsi +++ b/target/linux/ath79/dts/ar9344_tplink_cpe_2port.dtsi @@ -1,7 +1,7 @@ // SPDX-License-Identifier: GPL-2.0-or-later OR MIT /dts-v1/; -#include "ar9344_tplink_cpexxx.dtsi" +#include "ar9344_tplink_cpe.dtsi" / { aliases { diff --git a/target/linux/ath79/dts/ar9344_tplink_wbs210-v2.dts b/target/linux/ath79/dts/ar9344_tplink_wbs210-v2.dts index dddf4aebda..8c5535754a 100644 --- a/target/linux/ath79/dts/ar9344_tplink_wbs210-v2.dts +++ b/target/linux/ath79/dts/ar9344_tplink_wbs210-v2.dts @@ -1,7 +1,7 @@ // SPDX-License-Identifier: GPL-2.0-or-later OR MIT /dts-v1/; -#include "ar9344_tplink_cpexxx-v1.dtsi" +#include "ar9344_tplink_cpe_2port.dtsi" / { compatible = "tplink,wbs210-v2", "qca,ar9344"; diff --git a/target/linux/ath79/dts/ar9344_tplink_wbs510-v1.dts b/target/linux/ath79/dts/ar9344_tplink_wbs510-v1.dts index ba6fab2c1a..28ea727b3d 100644 --- a/target/linux/ath79/dts/ar9344_tplink_wbs510-v1.dts +++ b/target/linux/ath79/dts/ar9344_tplink_wbs510-v1.dts @@ -1,7 +1,7 @@ // SPDX-License-Identifier: GPL-2.0-or-later OR MIT /dts-v1/; -#include "ar9344_tplink_cpexxx-v1.dtsi" +#include "ar9344_tplink_cpe_2port.dtsi" / { compatible = "tplink,wbs510-v1", "qca,ar9344"; diff --git a/target/linux/ath79/dts/ar9344_tplink_wbs510-v2.dts b/target/linux/ath79/dts/ar9344_tplink_wbs510-v2.dts index 5c55d78904..8ce47a5134 100644 --- a/target/linux/ath79/dts/ar9344_tplink_wbs510-v2.dts +++ b/target/linux/ath79/dts/ar9344_tplink_wbs510-v2.dts @@ -1,7 +1,7 @@ // SPDX-License-Identifier: GPL-2.0-or-later OR MIT /dts-v1/; -#include "ar9344_tplink_cpexxx-v1.dtsi" +#include "ar9344_tplink_cpe_2port.dtsi" / { compatible = "tplink,wbs510-v2", "qca,ar9344"; From 09c428ec6bca27bdb31e2f6fef85b07787cead30 Mon Sep 17 00:00:00 2001 From: Kamil Wcislo Date: Thu, 5 Jul 2018 21:40:19 +0200 Subject: [PATCH 17/17] build: add PKG_SOURCE_URL_FILE support It seems that there is a missing PKG_SOURCE_URL_FILE support. This little fix adds the support for packages to change the name of the downloaded file. Sometimes it is desirable to change the downloaded archive file name, like for mitigating name conflicts for different packages (some files on the server could be named like, e.g. 2018-01-01.tar.gz) or for the cases that there is no name for the file in the URL (e.g. http://someserver.com/download). Signed-off-by: Kamil Wcislo Signed-off-by: Matthias Schiffer --- include/download.mk | 1 + 1 file changed, 1 insertion(+) diff --git a/include/download.mk b/include/download.mk index 09794e155e..14d68bf8f5 100644 --- a/include/download.mk +++ b/include/download.mk @@ -289,6 +289,7 @@ endef define Download/default FILE:=$(PKG_SOURCE) URL:=$(PKG_SOURCE_URL) + URL_FILE:=$(PKG_SOURCE_URL_FILE) SUBDIR:=$(PKG_SOURCE_SUBDIR) PROTO:=$(PKG_SOURCE_PROTO) $(if $(PKG_SOURCE_MIRROR),MIRROR:=$(filter 1,$(PKG_MIRROR)))