[LEDE-DEV] [PATCH] kernel: update kernel 4.4 to 4.4.78
Baptiste Jonglez
baptiste at bitsofnetworks.org
Sun Jul 23 14:57:14 PDT 2017
From: Baptiste Jonglez <git at bitsofnetworks.org>
All patches have been refreshed, and upstream patches have been dropped.
Compile tested: ar71xx, at91, bcm53xx, brcm47xx, brcm63xx, gemini, ixp4xx,
lantiq, layerscape, malta, mvebu
Run tested: ar71xx
Signed-off-by: Baptiste Jonglez <git at bitsofnetworks.org>
---
include/kernel-version.mk | 4 +-
...fix-regression-in-PCI-window-initializati.patch | 37 ---------
...ARM-dts-enable-clock-support-for-BCM5301X.patch | 4 +-
...-BCM5301X-Correct-GIC_PPI-interrupt-flags.patch | 41 ----------
...y-Initialize-mdio-clock-at-probe-function.patch | 48 -----------
....5-03-mtd-nand-spi-nor-assign-MTD-of_node.patch | 2 +-
...r-convert-to-spi_nor_-get-set-_flash_node.patch | 2 +-
...-4.5-08-mtd-spi-nor-drop-flash_node-field.patch | 2 +-
.../patches-4.4/002-phy_drivers_backport.patch | 16 ++--
...part-limit-scanned-flash-area-on-BCM47XX-.patch | 35 --------
...m47xxpart-don-t-fail-because-of-bit-flips.patch | 93 ----------------------
...td-spi-nor-backport-SPI_NOR_HAS_LOCK-flag.patch | 4 +-
...1-bgmac-fix-a-missing-check-for-build_skb.patch | 28 -------
...x-reversed-test-of-build_skb-return-value.patch | 22 -----
...elper-checking-for-BCM4707-BCM53018-chip-.patch | 12 +--
...c-support-Ethernet-device-on-BCM47094-SoC.patch | 2 +-
...eset-enable-Ethernet-core-before-using-it.patch | 31 --------
...-net_device-with-backing-device-structure.patch | 2 +-
...-bgmac-Add-support-for-ethtool-statistics.patch | 4 +-
...003-bgmac-Maintain-some-netdev-statistics.patch | 10 +--
...t-bgmac-use-phydev-from-struct-net_device.patch | 20 ++---
...-v4.7-0001-net-bgmac-Fix-SOF-bit-checking.patch | 37 ---------
...-bgmac-Start-transmit-queue-in-bgmac_open.patch | 28 -------
...-bgmac-Remove-superflous-netif_carrier_on.patch | 28 -------
...k-to-of_scan_flat_dt-before-accessing-ini.patch | 30 -------
...465-m25p80-mx-disable-software-protection.patch | 2 +-
.../patches-4.4/662-use_fq_codel_by_default.patch | 8 +-
...jecting-with-source-address-failed-policy.patch | 14 ++--
...80-NET-skip-GRO-for-foreign-MAC-addresses.patch | 10 +--
.../generic/patches-4.4/721-phy_packets.patch | 2 +-
.../1074-mtd-nand-spi-nor-assign-MTD-of_node.patch | 2 +-
...r-convert-to-spi_nor_-get-set-_flash_node.patch | 2 +-
.../1078-mtd-spi-nor-drop-flash_node-field.patch | 2 +-
...-provide-default-erase_sector-implementat.patch | 4 +-
...-mtd-spi-nor-Add-SPI-NOR-layer-PM-support.patch | 6 +-
...pi_nor-Disable-Micron-flash-HW-protection.patch | 2 +-
...-nor-Support-R-W-for-S25FS-S-family-flash.patch | 2 +-
...105-mtd-spi-nor-add-DDR-quad-read-support.patch | 10 +--
...or-fsl-quad-add-flash-S25FS-extra-support.patch | 2 +-
.../7018-devres-add-devm_alloc_percpu.patch | 2 +-
...-pci-layerscape-add-MSI-interrupt-support.patch | 2 +-
.../030-mvneta-consolidate-autoneg-enabling.patch | 2 +-
...implement-ethtool-autonegotiation-control.patch | 2 +-
...Make-the-default-queue-related-for-each-p.patch | 2 +-
.../034-net-mvneta-Add-naive-RSS-support.patch | 6 +-
...fix-trivial-cut-off-issue-in-mvneta_ethto.patch | 2 +-
...net-mvneta-Fix-for_each_present_cpu-usage.patch | 55 -------------
...-marvell-88E1512-add-flow-control-support.patch | 2 +-
...mtd-backport-v4.7-0day-patches-from-Boris.patch | 10 +--
.../patches-4.4/100-korina_fix_napi_disable.patch | 51 ------------
50 files changed, 91 insertions(+), 655 deletions(-)
delete mode 100644 target/linux/ar71xx/patches-4.4/102-MIPS-ath79-fix-regression-in-PCI-window-initializati.patch
delete mode 100644 target/linux/bcm53xx/patches-4.4/047-0013-ARM-dts-BCM5301X-Correct-GIC_PPI-interrupt-flags.patch
delete mode 100644 target/linux/bcm53xx/patches-4.4/060-0001-net-phy-Initialize-mdio-clock-at-probe-function.patch
delete mode 100644 target/linux/generic/patches-4.4/040-0001-mtd-bcm47xxpart-limit-scanned-flash-area-on-BCM47XX-.patch
delete mode 100644 target/linux/generic/patches-4.4/040-0002-mtd-bcm47xxpart-don-t-fail-because-of-bit-flips.patch
delete mode 100644 target/linux/generic/patches-4.4/070-v4.5-0001-bgmac-fix-a-missing-check-for-build_skb.patch
delete mode 100644 target/linux/generic/patches-4.4/070-v4.5-0002-bgmac-Fix-reversed-test-of-build_skb-return-value.patch
delete mode 100644 target/linux/generic/patches-4.4/070-v4.6-0003-bgmac-reset-enable-Ethernet-core-before-using-it.patch
delete mode 100644 target/linux/generic/patches-4.4/071-v4.7-0001-net-bgmac-Fix-SOF-bit-checking.patch
delete mode 100644 target/linux/generic/patches-4.4/071-v4.7-0002-net-bgmac-Start-transmit-queue-in-bgmac_open.patch
delete mode 100644 target/linux/generic/patches-4.4/071-v4.7-0003-net-bgmac-Remove-superflous-netif_carrier_on.patch
delete mode 100644 target/linux/generic/patches-4.4/104-of-Add-check-to-of_scan_flat_dt-before-accessing-ini.patch
delete mode 100644 target/linux/mvebu/patches-4.4/037-net-mvneta-Fix-for_each_present_cpu-usage.patch
delete mode 100644 target/linux/rb532/patches-4.4/100-korina_fix_napi_disable.patch
diff --git a/include/kernel-version.mk b/include/kernel-version.mk
index 3033060383..c6c4c52891 100644
--- a/include/kernel-version.mk
+++ b/include/kernel-version.mk
@@ -3,11 +3,11 @@
LINUX_RELEASE?=1
LINUX_VERSION-3.18 = .43
-LINUX_VERSION-4.4 = .74
+LINUX_VERSION-4.4 = .78
LINUX_VERSION-4.9 = .37
LINUX_KERNEL_HASH-3.18.43 = 1236e8123a6ce537d5029232560966feed054ae31776fe8481dd7d18cdd5492c
-LINUX_KERNEL_HASH-4.4.74 = c319ad6150d112bd4f8c9d1427868eeafd3ab461becf9457f814e4ba7c57808e
+LINUX_KERNEL_HASH-4.4.78 = 7c3fdbf4d7ef7b61586155a04c1f0483799f44e20f526fda8fca090738abb693
LINUX_KERNEL_HASH-4.9.37 = f61ecf083b690d97cfdeec2b4457992e98882250c4f41ade36fd7cdfda066090
ifdef KERNEL_PATCHVER
diff --git a/target/linux/ar71xx/patches-4.4/102-MIPS-ath79-fix-regression-in-PCI-window-initializati.patch b/target/linux/ar71xx/patches-4.4/102-MIPS-ath79-fix-regression-in-PCI-window-initializati.patch
deleted file mode 100644
index e5226a5dc3..0000000000
--- a/target/linux/ar71xx/patches-4.4/102-MIPS-ath79-fix-regression-in-PCI-window-initializati.patch
+++ /dev/null
@@ -1,37 +0,0 @@
-From: Felix Fietkau <nbd at nbd.name>
-Date: Sun, 15 May 2016 13:09:20 +0200
-Subject: [PATCH] MIPS: ath79: fix regression in PCI window initialization
-
-ath79_ddr_pci_win_base has the type void __iomem *, so register offsets
-need to be a multiple of 4.
-
-Cc: Alban Bedel <albeu at free.fr>
-Fixes: 24b0e3e84fbf ("MIPS: ath79: Improve the DDR controller interface")
-Signed-off-by: Felix Fietkau <nbd at nbd.name>
----
-
---- a/arch/mips/ath79/common.c
-+++ b/arch/mips/ath79/common.c
-@@ -76,14 +76,14 @@ void ath79_ddr_set_pci_windows(void)
- {
- BUG_ON(!ath79_ddr_pci_win_base);
-
-- __raw_writel(AR71XX_PCI_WIN0_OFFS, ath79_ddr_pci_win_base + 0);
-- __raw_writel(AR71XX_PCI_WIN1_OFFS, ath79_ddr_pci_win_base + 1);
-- __raw_writel(AR71XX_PCI_WIN2_OFFS, ath79_ddr_pci_win_base + 2);
-- __raw_writel(AR71XX_PCI_WIN3_OFFS, ath79_ddr_pci_win_base + 3);
-- __raw_writel(AR71XX_PCI_WIN4_OFFS, ath79_ddr_pci_win_base + 4);
-- __raw_writel(AR71XX_PCI_WIN5_OFFS, ath79_ddr_pci_win_base + 5);
-- __raw_writel(AR71XX_PCI_WIN6_OFFS, ath79_ddr_pci_win_base + 6);
-- __raw_writel(AR71XX_PCI_WIN7_OFFS, ath79_ddr_pci_win_base + 7);
-+ __raw_writel(AR71XX_PCI_WIN0_OFFS, ath79_ddr_pci_win_base + 0x0);
-+ __raw_writel(AR71XX_PCI_WIN1_OFFS, ath79_ddr_pci_win_base + 0x4);
-+ __raw_writel(AR71XX_PCI_WIN2_OFFS, ath79_ddr_pci_win_base + 0x8);
-+ __raw_writel(AR71XX_PCI_WIN3_OFFS, ath79_ddr_pci_win_base + 0xc);
-+ __raw_writel(AR71XX_PCI_WIN4_OFFS, ath79_ddr_pci_win_base + 0x10);
-+ __raw_writel(AR71XX_PCI_WIN5_OFFS, ath79_ddr_pci_win_base + 0x14);
-+ __raw_writel(AR71XX_PCI_WIN6_OFFS, ath79_ddr_pci_win_base + 0x18);
-+ __raw_writel(AR71XX_PCI_WIN7_OFFS, ath79_ddr_pci_win_base + 0x1c);
- }
- EXPORT_SYMBOL_GPL(ath79_ddr_set_pci_windows);
-
diff --git a/target/linux/bcm53xx/patches-4.4/031-ARM-dts-enable-clock-support-for-BCM5301X.patch b/target/linux/bcm53xx/patches-4.4/031-ARM-dts-enable-clock-support-for-BCM5301X.patch
index db47006218..165fe7c5cb 100644
--- a/target/linux/bcm53xx/patches-4.4/031-ARM-dts-enable-clock-support-for-BCM5301X.patch
+++ b/target/linux/bcm53xx/patches-4.4/031-ARM-dts-enable-clock-support-for-BCM5301X.patch
@@ -68,7 +68,7 @@ Signed-off-by: Florian Fainelli <f.fainelli at gmail.com>
compatible = "arm,cortex-a9-global-timer";
- reg = <0x0200 0x100>;
+ reg = <0x20200 0x100>;
- interrupts = <GIC_PPI 11 IRQ_TYPE_LEVEL_HIGH>;
+ interrupts = <GIC_PPI 11 IRQ_TYPE_EDGE_RISING>;
- clocks = <&clk_periph>;
+ clocks = <&periph_clk>;
};
@@ -78,7 +78,7 @@ Signed-off-by: Florian Fainelli <f.fainelli at gmail.com>
compatible = "arm,cortex-a9-twd-timer";
- reg = <0x0600 0x100>;
+ reg = <0x20600 0x100>;
- interrupts = <GIC_PPI 13 IRQ_TYPE_LEVEL_HIGH>;
+ interrupts = <GIC_PPI 13 IRQ_TYPE_EDGE_RISING>;
- clocks = <&clk_periph>;
+ clocks = <&periph_clk>;
};
diff --git a/target/linux/bcm53xx/patches-4.4/047-0013-ARM-dts-BCM5301X-Correct-GIC_PPI-interrupt-flags.patch b/target/linux/bcm53xx/patches-4.4/047-0013-ARM-dts-BCM5301X-Correct-GIC_PPI-interrupt-flags.patch
deleted file mode 100644
index 70df2013cc..0000000000
--- a/target/linux/bcm53xx/patches-4.4/047-0013-ARM-dts-BCM5301X-Correct-GIC_PPI-interrupt-flags.patch
+++ /dev/null
@@ -1,41 +0,0 @@
-From 0e34079cd1f674449749aafe4be07336177de90d Mon Sep 17 00:00:00 2001
-From: Jon Mason <jon.mason at broadcom.com>
-Date: Thu, 2 Mar 2017 19:21:32 -0500
-Subject: [PATCH] ARM: dts: BCM5301X: Correct GIC_PPI interrupt flags
-MIME-Version: 1.0
-Content-Type: text/plain; charset=UTF-8
-Content-Transfer-Encoding: 8bit
-
-GIC_PPI flags were misconfigured for the timers, resulting in errors
-like:
-[ 0.000000] GIC: PPI11 is secure or misconfigured
-
-Changing them to being edge triggered corrects the issue
-
-Suggested-by: Rafał Miłecki <rafal at milecki.pl>
-Signed-off-by: Jon Mason <jon.mason at broadcom.com>
-Fixes: d27509f1 ("ARM: BCM5301X: add dts files for BCM4708 SoC")
-Signed-off-by: Florian Fainelli <f.fainelli at gmail.com>
----
- arch/arm/boot/dts/bcm5301x.dtsi | 4 ++--
- 1 file changed, 2 insertions(+), 2 deletions(-)
-
---- a/arch/arm/boot/dts/bcm5301x.dtsi
-+++ b/arch/arm/boot/dts/bcm5301x.dtsi
-@@ -66,14 +66,14 @@
- timer at 20200 {
- compatible = "arm,cortex-a9-global-timer";
- reg = <0x20200 0x100>;
-- interrupts = <GIC_PPI 11 IRQ_TYPE_LEVEL_HIGH>;
-+ interrupts = <GIC_PPI 11 IRQ_TYPE_EDGE_RISING>;
- clocks = <&periph_clk>;
- };
-
- local-timer at 20600 {
- compatible = "arm,cortex-a9-twd-timer";
- reg = <0x20600 0x100>;
-- interrupts = <GIC_PPI 13 IRQ_TYPE_LEVEL_HIGH>;
-+ interrupts = <GIC_PPI 13 IRQ_TYPE_EDGE_RISING>;
- clocks = <&periph_clk>;
- };
-
diff --git a/target/linux/bcm53xx/patches-4.4/060-0001-net-phy-Initialize-mdio-clock-at-probe-function.patch b/target/linux/bcm53xx/patches-4.4/060-0001-net-phy-Initialize-mdio-clock-at-probe-function.patch
deleted file mode 100644
index 7678a70a32..0000000000
--- a/target/linux/bcm53xx/patches-4.4/060-0001-net-phy-Initialize-mdio-clock-at-probe-function.patch
+++ /dev/null
@@ -1,48 +0,0 @@
-From bb1a619735b4660f21bce3e728b937640024b4ad Mon Sep 17 00:00:00 2001
-From: Yendapally Reddy Dhananjaya Reddy <yendapally.reddy at broadcom.com>
-Date: Wed, 8 Feb 2017 17:14:26 -0500
-Subject: [PATCH] net: phy: Initialize mdio clock at probe function
-
-USB PHYs need the MDIO clock divisor enabled earlier to work.
-Initialize mdio clock divisor in probe function. The ext bus
-bit available in the same register will be used by mdio mux
-to enable external mdio.
-
-Signed-off-by: Yendapally Reddy Dhananjaya Reddy <yendapally.reddy at broadcom.com>
-Fixes: ddc24ae1 ("net: phy: Broadcom iProc MDIO bus driver")
-Reviewed-by: Florian Fainelli <f.fainelli at gmail.com>
-Signed-off-by: Jon Mason <jon.mason at broadcom.com>
-Signed-off-by: David S. Miller <davem at davemloft.net>
----
- drivers/net/phy/mdio-bcm-iproc.c | 6 ++----
- 1 file changed, 2 insertions(+), 4 deletions(-)
-
---- a/drivers/net/phy/mdio-bcm-iproc.c
-+++ b/drivers/net/phy/mdio-bcm-iproc.c
-@@ -81,8 +81,6 @@ static int iproc_mdio_read(struct mii_bu
- if (rc)
- return rc;
-
-- iproc_mdio_config_clk(priv->base);
--
- /* Prepare the read operation */
- cmd = (MII_DATA_TA_VAL << MII_DATA_TA_SHIFT) |
- (reg << MII_DATA_RA_SHIFT) |
-@@ -112,8 +110,6 @@ static int iproc_mdio_write(struct mii_b
- if (rc)
- return rc;
-
-- iproc_mdio_config_clk(priv->base);
--
- /* Prepare the write operation */
- cmd = (MII_DATA_TA_VAL << MII_DATA_TA_SHIFT) |
- (reg << MII_DATA_RA_SHIFT) |
-@@ -163,6 +159,8 @@ static int iproc_mdio_probe(struct platf
- bus->read = iproc_mdio_read;
- bus->write = iproc_mdio_write;
-
-+ iproc_mdio_config_clk(priv->base);
-+
- rc = of_mdiobus_register(bus, pdev->dev.of_node);
- if (rc) {
- dev_err(&pdev->dev, "MDIO bus registration failed\n");
diff --git a/target/linux/brcm63xx/patches-4.4/000-4.5-03-mtd-nand-spi-nor-assign-MTD-of_node.patch b/target/linux/brcm63xx/patches-4.4/000-4.5-03-mtd-nand-spi-nor-assign-MTD-of_node.patch
index 93bacea83b..14eaca3546 100644
--- a/target/linux/brcm63xx/patches-4.4/000-4.5-03-mtd-nand-spi-nor-assign-MTD-of_node.patch
+++ b/target/linux/brcm63xx/patches-4.4/000-4.5-03-mtd-nand-spi-nor-assign-MTD-of_node.patch
@@ -27,7 +27,7 @@ Reviewed-by: Boris Brezillon <boris.brezillon at free-electrons.com>
return ret;
--- a/drivers/mtd/spi-nor/spi-nor.c
+++ b/drivers/mtd/spi-nor/spi-nor.c
-@@ -1221,6 +1221,7 @@ int spi_nor_scan(struct spi_nor *nor, co
+@@ -1228,6 +1228,7 @@ int spi_nor_scan(struct spi_nor *nor, co
mtd->flags |= MTD_NO_ERASE;
mtd->dev.parent = dev;
diff --git a/target/linux/brcm63xx/patches-4.4/000-4.5-05-spi-nor-convert-to-spi_nor_-get-set-_flash_node.patch b/target/linux/brcm63xx/patches-4.4/000-4.5-05-spi-nor-convert-to-spi_nor_-get-set-_flash_node.patch
index 74af24bbad..4056bafcff 100644
--- a/target/linux/brcm63xx/patches-4.4/000-4.5-05-spi-nor-convert-to-spi_nor_-get-set-_flash_node.patch
+++ b/target/linux/brcm63xx/patches-4.4/000-4.5-05-spi-nor-convert-to-spi_nor_-get-set-_flash_node.patch
@@ -68,7 +68,7 @@ Reviewed-by: Boris Brezillon <boris.brezillon at free-electrons.com>
spifi->nor.write = nxp_spifi_write;
--- a/drivers/mtd/spi-nor/spi-nor.c
+++ b/drivers/mtd/spi-nor/spi-nor.c
-@@ -1113,7 +1113,7 @@ int spi_nor_scan(struct spi_nor *nor, co
+@@ -1120,7 +1120,7 @@ int spi_nor_scan(struct spi_nor *nor, co
const struct flash_info *info = NULL;
struct device *dev = nor->dev;
struct mtd_info *mtd = &nor->mtd;
diff --git a/target/linux/brcm63xx/patches-4.4/000-4.5-08-mtd-spi-nor-drop-flash_node-field.patch b/target/linux/brcm63xx/patches-4.4/000-4.5-08-mtd-spi-nor-drop-flash_node-field.patch
index e8bf8dc119..1dd32257df 100644
--- a/target/linux/brcm63xx/patches-4.4/000-4.5-08-mtd-spi-nor-drop-flash_node-field.patch
+++ b/target/linux/brcm63xx/patches-4.4/000-4.5-08-mtd-spi-nor-drop-flash_node-field.patch
@@ -14,7 +14,7 @@ Reviewed-by: Boris Brezillon <boris.brezillon at free-electrons.com>
--- a/drivers/mtd/spi-nor/spi-nor.c
+++ b/drivers/mtd/spi-nor/spi-nor.c
-@@ -1221,7 +1221,6 @@ int spi_nor_scan(struct spi_nor *nor, co
+@@ -1228,7 +1228,6 @@ int spi_nor_scan(struct spi_nor *nor, co
mtd->flags |= MTD_NO_ERASE;
mtd->dev.parent = dev;
diff --git a/target/linux/generic/patches-4.4/002-phy_drivers_backport.patch b/target/linux/generic/patches-4.4/002-phy_drivers_backport.patch
index b752b4d6a4..fe0c059371 100644
--- a/target/linux/generic/patches-4.4/002-phy_drivers_backport.patch
+++ b/target/linux/generic/patches-4.4/002-phy_drivers_backport.patch
@@ -1,6 +1,6 @@
--- a/drivers/net/phy/adm6996.c
+++ b/drivers/net/phy/adm6996.c
-@@ -287,7 +287,7 @@ static u16
+@@ -286,7 +286,7 @@ static u16
adm6996_read_mii_reg(struct adm6996_priv *priv, enum admreg reg)
{
struct phy_device *phydev = priv->priv;
@@ -9,7 +9,7 @@
return bus->read(bus, PHYADDR(reg));
}
-@@ -296,7 +296,7 @@ static void
+@@ -295,7 +295,7 @@ static void
adm6996_write_mii_reg(struct adm6996_priv *priv, enum admreg reg, u16 val)
{
struct phy_device *phydev = priv->priv;
@@ -18,7 +18,7 @@
bus->write(bus, PHYADDR(reg), val);
}
-@@ -1019,13 +1019,13 @@ static int adm6996_config_init(struct ph
+@@ -1018,13 +1018,13 @@ static int adm6996_config_init(struct ph
pdev->supported = ADVERTISED_100baseT_Full;
pdev->advertising = ADVERTISED_100baseT_Full;
@@ -35,7 +35,7 @@
if (!priv)
return -ENOMEM;
-@@ -1045,7 +1045,7 @@ static int adm6996_config_init(struct ph
+@@ -1044,7 +1044,7 @@ static int adm6996_config_init(struct ph
}
/*
@@ -44,7 +44,7 @@
*/
static int adm6996_read_status(struct phy_device *phydev)
{
-@@ -1061,7 +1061,7 @@ static int adm6996_read_status(struct ph
+@@ -1060,7 +1060,7 @@ static int adm6996_read_status(struct ph
}
/*
@@ -53,7 +53,7 @@
*/
static int adm6996_config_aneg(struct phy_device *phydev)
{
-@@ -1070,11 +1070,11 @@ static int adm6996_config_aneg(struct ph
+@@ -1069,11 +1069,11 @@ static int adm6996_config_aneg(struct ph
static int adm6996_fixup(struct phy_device *dev)
{
@@ -67,7 +67,7 @@
return 0;
/* look for the switch on the bus */
-@@ -1121,6 +1121,7 @@ static struct phy_driver adm6996_phy_dri
+@@ -1120,6 +1120,7 @@ static struct phy_driver adm6996_phy_dri
.config_aneg = &adm6996_config_aneg,
.read_status = &adm6996_read_status,
.soft_reset = adm6996_soft_reset,
@@ -75,7 +75,7 @@
};
static int adm6996_gpio_probe(struct platform_device *pdev)
-@@ -1193,7 +1194,7 @@ static int __init adm6996_init(void)
+@@ -1188,7 +1189,7 @@ static int __init adm6996_init(void)
int err;
phy_register_fixup_for_id(PHY_ANY_ID, adm6996_fixup);
diff --git a/target/linux/generic/patches-4.4/040-0001-mtd-bcm47xxpart-limit-scanned-flash-area-on-BCM47XX-.patch b/target/linux/generic/patches-4.4/040-0001-mtd-bcm47xxpart-limit-scanned-flash-area-on-BCM47XX-.patch
deleted file mode 100644
index 2429b113d0..0000000000
--- a/target/linux/generic/patches-4.4/040-0001-mtd-bcm47xxpart-limit-scanned-flash-area-on-BCM47XX-.patch
+++ /dev/null
@@ -1,35 +0,0 @@
-From 2a36a5c30eab9cd1c9d2d08bd27cd763325d70c5 Mon Sep 17 00:00:00 2001
-From: =?UTF-8?q?Rafa=C5=82=20Mi=C5=82ecki?= <zajec5 at gmail.com>
-Date: Sat, 5 Dec 2015 02:09:43 +0100
-Subject: [PATCH] mtd: bcm47xxpart: limit scanned flash area on BCM47XX (MIPS)
- only
-MIME-Version: 1.0
-Content-Type: text/plain; charset=UTF-8
-Content-Transfer-Encoding: 8bit
-
-We allowed using bcm47xxpart on BCM5301X arch with commit:
-9e3afa5f5c7 ("mtd: bcm47xxpart: allow enabling on ARCH_BCM_5301X")
-
-BCM5301X devices may contain some partitions in higher memory, e.g.
-Netgear R8000 has board_data at 0x2600000. To detect them we should
-use size limit on MIPS only.
-
-Signed-off-by: Rafał Miłecki <zajec5 at gmail.com>
-Signed-off-by: Brian Norris <computersforpeace at gmail.com>
----
- drivers/mtd/bcm47xxpart.c | 4 ++--
- 1 file changed, 2 insertions(+), 2 deletions(-)
-
---- a/drivers/mtd/bcm47xxpart.c
-+++ b/drivers/mtd/bcm47xxpart.c
-@@ -118,8 +118,8 @@ static int bcm47xxpart_parse(struct mtd_
- /* Parse block by block looking for magics */
- for (offset = 0; offset <= master->size - blocksize;
- offset += blocksize) {
-- /* Nothing more in higher memory */
-- if (offset >= 0x2000000)
-+ /* Nothing more in higher memory on BCM47XX (MIPS) */
-+ if (config_enabled(CONFIG_BCM47XX) && offset >= 0x2000000)
- break;
-
- if (curr_part >= BCM47XXPART_MAX_PARTS) {
diff --git a/target/linux/generic/patches-4.4/040-0002-mtd-bcm47xxpart-don-t-fail-because-of-bit-flips.patch b/target/linux/generic/patches-4.4/040-0002-mtd-bcm47xxpart-don-t-fail-because-of-bit-flips.patch
deleted file mode 100644
index 4155a2a95e..0000000000
--- a/target/linux/generic/patches-4.4/040-0002-mtd-bcm47xxpart-don-t-fail-because-of-bit-flips.patch
+++ /dev/null
@@ -1,93 +0,0 @@
-From 36bcc0c9c2bc8f56569cd735ba531a51358d7c2b Mon Sep 17 00:00:00 2001
-From: =?UTF-8?q?Rafa=C5=82=20Mi=C5=82ecki?= <zajec5 at gmail.com>
-Date: Sun, 6 Dec 2015 11:31:38 +0100
-Subject: [PATCH] mtd: bcm47xxpart: don't fail because of bit-flips
-MIME-Version: 1.0
-Content-Type: text/plain; charset=UTF-8
-Content-Transfer-Encoding: 8bit
-
-Bit-flip errors may occur on NAND flashes and are harmless. Handle them
-gracefully as read content is still reliable and can be parsed.
-
-Signed-off-by: Rafał Miłecki <zajec5 at gmail.com>
-Signed-off-by: Brian Norris <computersforpeace at gmail.com>
----
- drivers/mtd/bcm47xxpart.c | 38 ++++++++++++++++++++++----------------
- 1 file changed, 22 insertions(+), 16 deletions(-)
-
---- a/drivers/mtd/bcm47xxpart.c
-+++ b/drivers/mtd/bcm47xxpart.c
-@@ -66,11 +66,13 @@ static const char *bcm47xxpart_trx_data_
- {
- uint32_t buf;
- size_t bytes_read;
-+ int err;
-
-- if (mtd_read(master, offset, sizeof(buf), &bytes_read,
-- (uint8_t *)&buf) < 0) {
-- pr_err("mtd_read error while parsing (offset: 0x%X)!\n",
-- offset);
-+ err = mtd_read(master, offset, sizeof(buf), &bytes_read,
-+ (uint8_t *)&buf);
-+ if (err && !mtd_is_bitflip(err)) {
-+ pr_err("mtd_read error while parsing (offset: 0x%X): %d\n",
-+ offset, err);
- goto out_default;
- }
-
-@@ -95,6 +97,7 @@ static int bcm47xxpart_parse(struct mtd_
- int trx_part = -1;
- int last_trx_part = -1;
- int possible_nvram_sizes[] = { 0x8000, 0xF000, 0x10000, };
-+ int err;
-
- /*
- * Some really old flashes (like AT45DB*) had smaller erasesize-s, but
-@@ -128,10 +131,11 @@ static int bcm47xxpart_parse(struct mtd_
- }
-
- /* Read beginning of the block */
-- if (mtd_read(master, offset, BCM47XXPART_BYTES_TO_READ,
-- &bytes_read, (uint8_t *)buf) < 0) {
-- pr_err("mtd_read error while parsing (offset: 0x%X)!\n",
-- offset);
-+ err = mtd_read(master, offset, BCM47XXPART_BYTES_TO_READ,
-+ &bytes_read, (uint8_t *)buf);
-+ if (err && !mtd_is_bitflip(err)) {
-+ pr_err("mtd_read error while parsing (offset: 0x%X): %d\n",
-+ offset, err);
- continue;
- }
-
-@@ -252,10 +256,11 @@ static int bcm47xxpart_parse(struct mtd_
- }
-
- /* Read middle of the block */
-- if (mtd_read(master, offset + 0x8000, 0x4,
-- &bytes_read, (uint8_t *)buf) < 0) {
-- pr_err("mtd_read error while parsing (offset: 0x%X)!\n",
-- offset);
-+ err = mtd_read(master, offset + 0x8000, 0x4, &bytes_read,
-+ (uint8_t *)buf);
-+ if (err && !mtd_is_bitflip(err)) {
-+ pr_err("mtd_read error while parsing (offset: 0x%X): %d\n",
-+ offset, err);
- continue;
- }
-
-@@ -275,10 +280,11 @@ static int bcm47xxpart_parse(struct mtd_
- }
-
- offset = master->size - possible_nvram_sizes[i];
-- if (mtd_read(master, offset, 0x4, &bytes_read,
-- (uint8_t *)buf) < 0) {
-- pr_err("mtd_read error while reading at offset 0x%X!\n",
-- offset);
-+ err = mtd_read(master, offset, 0x4, &bytes_read,
-+ (uint8_t *)buf);
-+ if (err && !mtd_is_bitflip(err)) {
-+ pr_err("mtd_read error while reading (offset 0x%X): %d\n",
-+ offset, err);
- continue;
- }
-
diff --git a/target/linux/generic/patches-4.4/048-mtd-spi-nor-backport-SPI_NOR_HAS_LOCK-flag.patch b/target/linux/generic/patches-4.4/048-mtd-spi-nor-backport-SPI_NOR_HAS_LOCK-flag.patch
index 5048bcca7d..69a5432fa7 100644
--- a/target/linux/generic/patches-4.4/048-mtd-spi-nor-backport-SPI_NOR_HAS_LOCK-flag.patch
+++ b/target/linux/generic/patches-4.4/048-mtd-spi-nor-backport-SPI_NOR_HAS_LOCK-flag.patch
@@ -25,7 +25,7 @@ Tested-by: Ezequiel Garcia <ezequiel at vanguardiasur.com.ar>
};
#define JEDEC_MFR(info) ((info)->id[0])
-@@ -1156,7 +1157,8 @@ int spi_nor_scan(struct spi_nor *nor, co
+@@ -1163,7 +1164,8 @@ int spi_nor_scan(struct spi_nor *nor, co
if (JEDEC_MFR(info) == SNOR_MFR_ATMEL ||
JEDEC_MFR(info) == SNOR_MFR_INTEL ||
@@ -35,7 +35,7 @@ Tested-by: Ezequiel Garcia <ezequiel at vanguardiasur.com.ar>
write_enable(nor);
write_sr(nor, 0);
}
-@@ -1172,7 +1174,8 @@ int spi_nor_scan(struct spi_nor *nor, co
+@@ -1179,7 +1181,8 @@ int spi_nor_scan(struct spi_nor *nor, co
mtd->_read = spi_nor_read;
/* NOR protection support for STmicro/Micron chips and similar */
diff --git a/target/linux/generic/patches-4.4/070-v4.5-0001-bgmac-fix-a-missing-check-for-build_skb.patch b/target/linux/generic/patches-4.4/070-v4.5-0001-bgmac-fix-a-missing-check-for-build_skb.patch
deleted file mode 100644
index 99f9de65a7..0000000000
--- a/target/linux/generic/patches-4.4/070-v4.5-0001-bgmac-fix-a-missing-check-for-build_skb.patch
+++ /dev/null
@@ -1,28 +0,0 @@
-From f1640c3ddeec12804bc9a21feee85fc15aca95f6 Mon Sep 17 00:00:00 2001
-From: wangweidong <wangweidong1 at huawei.com>
-Date: Wed, 13 Jan 2016 11:06:41 +0800
-Subject: [PATCH] bgmac: fix a missing check for build_skb
-
-when build_skb failed, it may occure a NULL pointer.
-So add a 'NULL check' for it.
-
-Signed-off-by: Weidong Wang <wangweidong1 at huawei.com>
-Signed-off-by: David S. Miller <davem at davemloft.net>
----
- drivers/net/ethernet/broadcom/bgmac.c | 5 +++++
- 1 file changed, 5 insertions(+)
-
---- a/drivers/net/ethernet/broadcom/bgmac.c
-+++ b/drivers/net/ethernet/broadcom/bgmac.c
-@@ -469,6 +469,11 @@ static int bgmac_dma_rx_read(struct bgma
- len -= ETH_FCS_LEN;
-
- skb = build_skb(buf, BGMAC_RX_ALLOC_SIZE);
-+ if (unlikely(skb)) {
-+ bgmac_err(bgmac, "build_skb failed\n");
-+ put_page(virt_to_head_page(buf));
-+ break;
-+ }
- skb_put(skb, BGMAC_RX_FRAME_OFFSET +
- BGMAC_RX_BUF_OFFSET + len);
- skb_pull(skb, BGMAC_RX_FRAME_OFFSET +
diff --git a/target/linux/generic/patches-4.4/070-v4.5-0002-bgmac-Fix-reversed-test-of-build_skb-return-value.patch b/target/linux/generic/patches-4.4/070-v4.5-0002-bgmac-Fix-reversed-test-of-build_skb-return-value.patch
deleted file mode 100644
index eebcded6fa..0000000000
--- a/target/linux/generic/patches-4.4/070-v4.5-0002-bgmac-Fix-reversed-test-of-build_skb-return-value.patch
+++ /dev/null
@@ -1,22 +0,0 @@
-From 750afbf8ee9c6a1c74a1fe5fc9852146b1d72687 Mon Sep 17 00:00:00 2001
-From: "David S. Miller" <davem at davemloft.net>
-Date: Fri, 15 Jan 2016 16:07:13 -0500
-Subject: [PATCH] bgmac: Fix reversed test of build_skb() return value.
-
-Fixes: f1640c3ddeec ("bgmac: fix a missing check for build_skb")
-Signed-off-by: David S. Miller <davem at davemloft.net>
----
- drivers/net/ethernet/broadcom/bgmac.c | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
---- a/drivers/net/ethernet/broadcom/bgmac.c
-+++ b/drivers/net/ethernet/broadcom/bgmac.c
-@@ -469,7 +469,7 @@ static int bgmac_dma_rx_read(struct bgma
- len -= ETH_FCS_LEN;
-
- skb = build_skb(buf, BGMAC_RX_ALLOC_SIZE);
-- if (unlikely(skb)) {
-+ if (unlikely(!skb)) {
- bgmac_err(bgmac, "build_skb failed\n");
- put_page(virt_to_head_page(buf));
- break;
diff --git a/target/linux/generic/patches-4.4/070-v4.6-0001-bgmac-add-helper-checking-for-BCM4707-BCM53018-chip-.patch b/target/linux/generic/patches-4.4/070-v4.6-0001-bgmac-add-helper-checking-for-BCM4707-BCM53018-chip-.patch
index 0c007569fb..94a37d4437 100644
--- a/target/linux/generic/patches-4.4/070-v4.6-0001-bgmac-add-helper-checking-for-BCM4707-BCM53018-chip-.patch
+++ b/target/linux/generic/patches-4.4/070-v4.6-0001-bgmac-add-helper-checking-for-BCM4707-BCM53018-chip-.patch
@@ -36,7 +36,7 @@ Signed-off-by: David S. Miller <davem at davemloft.net>
static bool bgmac_wait_value(struct bcma_device *core, u16 reg, u32 mask,
u32 value, int timeout)
{
-@@ -990,11 +1001,9 @@ static void bgmac_mac_speed(struct bgmac
+@@ -991,11 +1002,9 @@ static void bgmac_mac_speed(struct bgmac
static void bgmac_miiconfig(struct bgmac *bgmac)
{
struct bcma_device *core = bgmac->core;
@@ -49,7 +49,7 @@ Signed-off-by: David S. Miller <davem at davemloft.net>
bcma_awrite32(core, BCMA_IOCTL,
bcma_aread32(core, BCMA_IOCTL) | 0x40 |
BGMAC_BCMA_IOCTL_SW_CLKEN);
-@@ -1058,9 +1067,7 @@ static void bgmac_chip_reset(struct bgma
+@@ -1059,9 +1068,7 @@ static void bgmac_chip_reset(struct bgma
}
/* Request Misc PLL for corerev > 2 */
@@ -60,7 +60,7 @@ Signed-off-by: David S. Miller <davem at davemloft.net>
bgmac_set(bgmac, BCMA_CLKCTLST,
BGMAC_BCMA_CLKCTLST_MISC_PLL_REQ);
bgmac_wait_value(bgmac->core, BCMA_CLKCTLST,
-@@ -1196,8 +1203,7 @@ static void bgmac_enable(struct bgmac *b
+@@ -1197,8 +1204,7 @@ static void bgmac_enable(struct bgmac *b
break;
}
@@ -70,7 +70,7 @@ Signed-off-by: David S. Miller <davem at davemloft.net>
rxq_ctl = bgmac_read(bgmac, BGMAC_RXQ_CTL);
rxq_ctl &= ~BGMAC_RXQ_CTL_MDP_MASK;
bp_clk = bcma_pmu_get_bus_clock(&bgmac->core->bus->drv_cc) /
-@@ -1475,14 +1481,12 @@ static int bgmac_fixed_phy_register(stru
+@@ -1477,14 +1483,12 @@ static int bgmac_fixed_phy_register(stru
static int bgmac_mii_register(struct bgmac *bgmac)
{
@@ -86,7 +86,7 @@ Signed-off-by: David S. Miller <davem at davemloft.net>
return bgmac_fixed_phy_register(bgmac);
mii_bus = mdiobus_alloc();
-@@ -1553,7 +1557,6 @@ static void bgmac_mii_unregister(struct
+@@ -1555,7 +1559,6 @@ static void bgmac_mii_unregister(struct
/* http://bcm-v4.sipsolutions.net/mac-gbit/gmac/chipattach */
static int bgmac_probe(struct bcma_device *core)
{
@@ -94,7 +94,7 @@ Signed-off-by: David S. Miller <davem at davemloft.net>
struct net_device *net_dev;
struct bgmac *bgmac;
struct ssb_sprom *sprom = &core->bus->sprom;
-@@ -1634,8 +1637,7 @@ static int bgmac_probe(struct bcma_devic
+@@ -1641,8 +1644,7 @@ static int bgmac_probe(struct bcma_devic
bgmac_chip_reset(bgmac);
/* For Northstar, we have to take all GMAC core out of reset */
diff --git a/target/linux/generic/patches-4.4/070-v4.6-0002-bgmac-support-Ethernet-device-on-BCM47094-SoC.patch b/target/linux/generic/patches-4.4/070-v4.6-0002-bgmac-support-Ethernet-device-on-BCM47094-SoC.patch
index d00c2bd551..41e470b314 100644
--- a/target/linux/generic/patches-4.4/070-v4.6-0002-bgmac-support-Ethernet-device-on-BCM47094-SoC.patch
+++ b/target/linux/generic/patches-4.4/070-v4.6-0002-bgmac-support-Ethernet-device-on-BCM47094-SoC.patch
@@ -25,7 +25,7 @@ Signed-off-by: David S. Miller <davem at davemloft.net>
case BCMA_CHIP_ID_BCM53018:
return true;
default:
-@@ -1055,8 +1056,9 @@ static void bgmac_chip_reset(struct bgma
+@@ -1056,8 +1057,9 @@ static void bgmac_chip_reset(struct bgma
(ci->id == BCMA_CHIP_ID_BCM53572 && ci->pkg == BCMA_PKG_ID_BCM47188))
iost &= ~BGMAC_BCMA_IOST_ATTACHED;
diff --git a/target/linux/generic/patches-4.4/070-v4.6-0003-bgmac-reset-enable-Ethernet-core-before-using-it.patch b/target/linux/generic/patches-4.4/070-v4.6-0003-bgmac-reset-enable-Ethernet-core-before-using-it.patch
deleted file mode 100644
index 021a5913aa..0000000000
--- a/target/linux/generic/patches-4.4/070-v4.6-0003-bgmac-reset-enable-Ethernet-core-before-using-it.patch
+++ /dev/null
@@ -1,31 +0,0 @@
-From b4dfd8e92956b396d3438212bc9a0be6267b8b34 Mon Sep 17 00:00:00 2001
-From: =?UTF-8?q?Rafa=C5=82=20Mi=C5=82ecki?= <zajec5 at gmail.com>
-Date: Tue, 12 Apr 2016 13:30:45 +0200
-Subject: [PATCH] bgmac: reset & enable Ethernet core before using it
-MIME-Version: 1.0
-Content-Type: text/plain; charset=UTF-8
-Content-Transfer-Encoding: 8bit
-
-This fixes Ethernet on D-Link DIR-885L with BCM47094 SoC. Felix reported
-similar fix was needed for his BCM4709 device (Buffalo WXR-1900DHP?).
-I tested this for regressions on BCM4706, BCM4708A0 and BCM47081A0.
-
-Cc: Felix Fietkau <nbd at nbd.name>
-Signed-off-by: Rafał Miłecki <zajec5 at gmail.com>
-Signed-off-by: David S. Miller <davem at davemloft.net>
----
-
---- a/drivers/net/ethernet/broadcom/bgmac.c
-+++ b/drivers/net/ethernet/broadcom/bgmac.c
-@@ -1586,6 +1586,11 @@ static int bgmac_probe(struct bcma_devic
- dev_warn(&core->dev, "Using random MAC: %pM\n", mac);
- }
-
-+ /* This (reset &) enable is not preset in specs or reference driver but
-+ * Broadcom does it in arch PCI code when enabling fake PCI device.
-+ */
-+ bcma_core_enable(core, 0);
-+
- /* Allocation and references */
- net_dev = alloc_etherdev(sizeof(*bgmac));
- if (!net_dev)
diff --git a/target/linux/generic/patches-4.4/070-v4.8-0001-bgmac-Bind-net_device-with-backing-device-structure.patch b/target/linux/generic/patches-4.4/070-v4.8-0001-bgmac-Bind-net_device-with-backing-device-structure.patch
index 4d00094aa8..8f6d9a9ee7 100644
--- a/target/linux/generic/patches-4.4/070-v4.8-0001-bgmac-Bind-net_device-with-backing-device-structure.patch
+++ b/target/linux/generic/patches-4.4/070-v4.8-0001-bgmac-Bind-net_device-with-backing-device-structure.patch
@@ -15,7 +15,7 @@ Signed-off-by: David S. Miller <davem at davemloft.net>
--- a/drivers/net/ethernet/broadcom/bgmac.c
+++ b/drivers/net/ethernet/broadcom/bgmac.c
-@@ -1602,6 +1602,7 @@ static int bgmac_probe(struct bcma_devic
+@@ -1604,6 +1604,7 @@ static int bgmac_probe(struct bcma_devic
bgmac->net_dev = net_dev;
bgmac->core = core;
bcma_set_drvdata(core, bgmac);
diff --git a/target/linux/generic/patches-4.4/070-v4.8-0002-bgmac-Add-support-for-ethtool-statistics.patch b/target/linux/generic/patches-4.4/070-v4.8-0002-bgmac-Add-support-for-ethtool-statistics.patch
index cff70802d2..585282b0aa 100644
--- a/target/linux/generic/patches-4.4/070-v4.8-0002-bgmac-Add-support-for-ethtool-statistics.patch
+++ b/target/linux/generic/patches-4.4/070-v4.8-0002-bgmac-Add-support-for-ethtool-statistics.patch
@@ -15,7 +15,7 @@ Signed-off-by: David S. Miller <davem at davemloft.net>
--- a/drivers/net/ethernet/broadcom/bgmac.c
+++ b/drivers/net/ethernet/broadcom/bgmac.c
-@@ -1385,6 +1385,127 @@ static const struct net_device_ops bgmac
+@@ -1387,6 +1387,127 @@ static const struct net_device_ops bgmac
* ethtool_ops
**************************************************/
@@ -143,7 +143,7 @@ Signed-off-by: David S. Miller <davem at davemloft.net>
static int bgmac_get_settings(struct net_device *net_dev,
struct ethtool_cmd *cmd)
{
-@@ -1409,6 +1530,9 @@ static void bgmac_get_drvinfo(struct net
+@@ -1411,6 +1532,9 @@ static void bgmac_get_drvinfo(struct net
}
static const struct ethtool_ops bgmac_ethtool_ops = {
diff --git a/target/linux/generic/patches-4.4/070-v4.8-0003-bgmac-Maintain-some-netdev-statistics.patch b/target/linux/generic/patches-4.4/070-v4.8-0003-bgmac-Maintain-some-netdev-statistics.patch
index 322851d026..1dbe1743df 100644
--- a/target/linux/generic/patches-4.4/070-v4.8-0003-bgmac-Maintain-some-netdev-statistics.patch
+++ b/target/linux/generic/patches-4.4/070-v4.8-0003-bgmac-Maintain-some-netdev-statistics.patch
@@ -23,7 +23,7 @@ Signed-off-by: David S. Miller <davem at davemloft.net>
return NETDEV_TX_OK;
}
-@@ -284,6 +286,8 @@ static void bgmac_dma_tx_free(struct bgm
+@@ -285,6 +287,8 @@ static void bgmac_dma_tx_free(struct bgm
DMA_TO_DEVICE);
if (slot->skb) {
@@ -32,7 +32,7 @@ Signed-off-by: David S. Miller <davem at davemloft.net>
bytes_compl += slot->skb->len;
pkts_compl++;
-@@ -467,6 +471,7 @@ static int bgmac_dma_rx_read(struct bgma
+@@ -468,6 +472,7 @@ static int bgmac_dma_rx_read(struct bgma
bgmac_err(bgmac, "Found poisoned packet at slot %d, DMA issue!\n",
ring->start);
put_page(virt_to_head_page(buf));
@@ -40,7 +40,7 @@ Signed-off-by: David S. Miller <davem at davemloft.net>
break;
}
-@@ -474,6 +479,8 @@ static int bgmac_dma_rx_read(struct bgma
+@@ -475,6 +480,8 @@ static int bgmac_dma_rx_read(struct bgma
bgmac_err(bgmac, "Found oversized packet at slot %d, DMA issue!\n",
ring->start);
put_page(virt_to_head_page(buf));
@@ -49,7 +49,7 @@ Signed-off-by: David S. Miller <davem at davemloft.net>
break;
}
-@@ -484,6 +491,7 @@ static int bgmac_dma_rx_read(struct bgma
+@@ -485,6 +492,7 @@ static int bgmac_dma_rx_read(struct bgma
if (unlikely(!skb)) {
bgmac_err(bgmac, "build_skb failed\n");
put_page(virt_to_head_page(buf));
@@ -57,7 +57,7 @@ Signed-off-by: David S. Miller <davem at davemloft.net>
break;
}
skb_put(skb, BGMAC_RX_FRAME_OFFSET +
-@@ -493,6 +501,8 @@ static int bgmac_dma_rx_read(struct bgma
+@@ -494,6 +502,8 @@ static int bgmac_dma_rx_read(struct bgma
skb_checksum_none_assert(skb);
skb->protocol = eth_type_trans(skb, bgmac->net_dev);
diff --git a/target/linux/generic/patches-4.4/070-v4.8-0004-net-ethernet-bgmac-use-phydev-from-struct-net_device.patch b/target/linux/generic/patches-4.4/070-v4.8-0004-net-ethernet-bgmac-use-phydev-from-struct-net_device.patch
index 8c97b09970..7ce6a09ec3 100644
--- a/target/linux/generic/patches-4.4/070-v4.8-0004-net-ethernet-bgmac-use-phydev-from-struct-net_device.patch
+++ b/target/linux/generic/patches-4.4/070-v4.8-0004-net-ethernet-bgmac-use-phydev-from-struct-net_device.patch
@@ -17,16 +17,16 @@ Signed-off-by: David S. Miller <davem at davemloft.net>
--- a/drivers/net/ethernet/broadcom/bgmac.c
+++ b/drivers/net/ethernet/broadcom/bgmac.c
-@@ -1323,7 +1323,7 @@ static int bgmac_open(struct net_device
+@@ -1324,7 +1324,7 @@ static int bgmac_open(struct net_device
}
napi_enable(&bgmac->napi);
- phy_start(bgmac->phy_dev);
+ phy_start(net_dev->phydev);
- netif_carrier_on(net_dev);
- return 0;
-@@ -1335,7 +1335,7 @@ static int bgmac_stop(struct net_device
+ netif_start_queue(net_dev);
+
+@@ -1337,7 +1337,7 @@ static int bgmac_stop(struct net_device
netif_carrier_off(net_dev);
@@ -35,7 +35,7 @@ Signed-off-by: David S. Miller <davem at davemloft.net>
napi_disable(&bgmac->napi);
bgmac_chip_intrs_off(bgmac);
-@@ -1373,12 +1373,10 @@ static int bgmac_set_mac_address(struct
+@@ -1375,12 +1375,10 @@ static int bgmac_set_mac_address(struct
static int bgmac_ioctl(struct net_device *net_dev, struct ifreq *ifr, int cmd)
{
@@ -49,7 +49,7 @@ Signed-off-by: David S. Miller <davem at davemloft.net>
}
static const struct net_device_ops bgmac_netdev_ops = {
-@@ -1521,7 +1519,7 @@ static int bgmac_get_settings(struct net
+@@ -1523,7 +1521,7 @@ static int bgmac_get_settings(struct net
{
struct bgmac *bgmac = netdev_priv(net_dev);
@@ -58,7 +58,7 @@ Signed-off-by: David S. Miller <davem at davemloft.net>
}
static int bgmac_set_settings(struct net_device *net_dev,
-@@ -1529,7 +1527,7 @@ static int bgmac_set_settings(struct net
+@@ -1531,7 +1529,7 @@ static int bgmac_set_settings(struct net
{
struct bgmac *bgmac = netdev_priv(net_dev);
@@ -67,7 +67,7 @@ Signed-off-by: David S. Miller <davem at davemloft.net>
}
static void bgmac_get_drvinfo(struct net_device *net_dev,
-@@ -1566,7 +1564,7 @@ static int bgmac_mii_write(struct mii_bu
+@@ -1568,7 +1566,7 @@ static int bgmac_mii_write(struct mii_bu
static void bgmac_adjust_link(struct net_device *net_dev)
{
struct bgmac *bgmac = netdev_priv(net_dev);
@@ -76,7 +76,7 @@ Signed-off-by: David S. Miller <davem at davemloft.net>
bool update = false;
if (phy_dev->link) {
-@@ -1610,8 +1608,6 @@ static int bgmac_fixed_phy_register(stru
+@@ -1612,8 +1610,6 @@ static int bgmac_fixed_phy_register(stru
return err;
}
@@ -85,7 +85,7 @@ Signed-off-by: David S. Miller <davem at davemloft.net>
return err;
}
-@@ -1664,7 +1660,6 @@ static int bgmac_mii_register(struct bgm
+@@ -1666,7 +1662,6 @@ static int bgmac_mii_register(struct bgm
err = PTR_ERR(phy_dev);
goto err_unregister_bus;
}
diff --git a/target/linux/generic/patches-4.4/071-v4.7-0001-net-bgmac-Fix-SOF-bit-checking.patch b/target/linux/generic/patches-4.4/071-v4.7-0001-net-bgmac-Fix-SOF-bit-checking.patch
deleted file mode 100644
index ea73fda6ff..0000000000
--- a/target/linux/generic/patches-4.4/071-v4.7-0001-net-bgmac-Fix-SOF-bit-checking.patch
+++ /dev/null
@@ -1,37 +0,0 @@
-From d2b13233879ca1268a1c027d4573109e5a777811 Mon Sep 17 00:00:00 2001
-From: Florian Fainelli <f.fainelli at gmail.com>
-Date: Thu, 23 Jun 2016 14:23:12 -0700
-Subject: [PATCH 1/3] net: bgmac: Fix SOF bit checking
-
-We are checking for the Start of Frame bit in the ctl1 word, while this
-bit is set in the ctl0 word instead. Read the ctl0 word and update the
-check to verify that.
-
-Fixes: 9cde94506eac ("bgmac: implement scatter/gather support")
-Signed-off-by: Florian Fainelli <f.fainelli at gmail.com>
-Signed-off-by: David S. Miller <davem at davemloft.net>
----
- drivers/net/ethernet/broadcom/bgmac.c | 5 +++--
- 1 file changed, 3 insertions(+), 2 deletions(-)
-
---- a/drivers/net/ethernet/broadcom/bgmac.c
-+++ b/drivers/net/ethernet/broadcom/bgmac.c
-@@ -269,15 +269,16 @@ static void bgmac_dma_tx_free(struct bgm
- while (ring->start != ring->end) {
- int slot_idx = ring->start % BGMAC_TX_RING_SLOTS;
- struct bgmac_slot_info *slot = &ring->slots[slot_idx];
-- u32 ctl1;
-+ u32 ctl0, ctl1;
- int len;
-
- if (slot_idx == empty_slot)
- break;
-
-+ ctl0 = le32_to_cpu(ring->cpu_base[slot_idx].ctl0);
- ctl1 = le32_to_cpu(ring->cpu_base[slot_idx].ctl1);
- len = ctl1 & BGMAC_DESC_CTL1_LEN;
-- if (ctl1 & BGMAC_DESC_CTL0_SOF)
-+ if (ctl0 & BGMAC_DESC_CTL0_SOF)
- /* Unmap no longer used buffer */
- dma_unmap_single(dma_dev, slot->dma_addr, len,
- DMA_TO_DEVICE);
diff --git a/target/linux/generic/patches-4.4/071-v4.7-0002-net-bgmac-Start-transmit-queue-in-bgmac_open.patch b/target/linux/generic/patches-4.4/071-v4.7-0002-net-bgmac-Start-transmit-queue-in-bgmac_open.patch
deleted file mode 100644
index 6a866bccdb..0000000000
--- a/target/linux/generic/patches-4.4/071-v4.7-0002-net-bgmac-Start-transmit-queue-in-bgmac_open.patch
+++ /dev/null
@@ -1,28 +0,0 @@
-From c3897f2a69e54dd113fc9abd2daf872e5b495798 Mon Sep 17 00:00:00 2001
-From: Florian Fainelli <f.fainelli at gmail.com>
-Date: Thu, 23 Jun 2016 14:25:32 -0700
-Subject: [PATCH 2/3] net: bgmac: Start transmit queue in bgmac_open
-
-The driver does not start the transmit queue in bgmac_open(). If the
-queue was stopped prior to closing then re-opening the interface, we
-would never be able to wake-up again.
-
-Fixes: dd4544f05469 ("bgmac: driver for GBit MAC core on BCMA bus")
-Signed-off-by: Florian Fainelli <f.fainelli at gmail.com>
-Signed-off-by: David S. Miller <davem at davemloft.net>
----
- drivers/net/ethernet/broadcom/bgmac.c | 3 +++
- 1 file changed, 3 insertions(+)
-
---- a/drivers/net/ethernet/broadcom/bgmac.c
-+++ b/drivers/net/ethernet/broadcom/bgmac.c
-@@ -1327,6 +1327,9 @@ static int bgmac_open(struct net_device
- phy_start(net_dev->phydev);
-
- netif_carrier_on(net_dev);
-+
-+ netif_start_queue(net_dev);
-+
- return 0;
- }
-
diff --git a/target/linux/generic/patches-4.4/071-v4.7-0003-net-bgmac-Remove-superflous-netif_carrier_on.patch b/target/linux/generic/patches-4.4/071-v4.7-0003-net-bgmac-Remove-superflous-netif_carrier_on.patch
deleted file mode 100644
index 0edf9ee9fa..0000000000
--- a/target/linux/generic/patches-4.4/071-v4.7-0003-net-bgmac-Remove-superflous-netif_carrier_on.patch
+++ /dev/null
@@ -1,28 +0,0 @@
-From 3894396e64994f31c3ef5c7e6f63dded0593e567 Mon Sep 17 00:00:00 2001
-From: Florian Fainelli <f.fainelli at gmail.com>
-Date: Thu, 23 Jun 2016 14:25:33 -0700
-Subject: [PATCH 3/3] net: bgmac: Remove superflous netif_carrier_on()
-
-bgmac_open() calls phy_start() to initialize the PHY state machine,
-which will set the interface's carrier state accordingly, no need to
-force that as this could be conflicting with the PHY state determined by
-PHYLIB.
-
-Fixes: dd4544f05469 ("bgmac: driver for GBit MAC core on BCMA bus")
-Signed-off-by: Florian Fainelli <f.fainelli at gmail.com>
-Signed-off-by: David S. Miller <davem at davemloft.net>
----
- drivers/net/ethernet/broadcom/bgmac.c | 2 --
- 1 file changed, 2 deletions(-)
-
---- a/drivers/net/ethernet/broadcom/bgmac.c
-+++ b/drivers/net/ethernet/broadcom/bgmac.c
-@@ -1326,8 +1326,6 @@ static int bgmac_open(struct net_device
-
- phy_start(net_dev->phydev);
-
-- netif_carrier_on(net_dev);
--
- netif_start_queue(net_dev);
-
- return 0;
diff --git a/target/linux/generic/patches-4.4/104-of-Add-check-to-of_scan_flat_dt-before-accessing-ini.patch b/target/linux/generic/patches-4.4/104-of-Add-check-to-of_scan_flat_dt-before-accessing-ini.patch
deleted file mode 100644
index e7c125d8ec..0000000000
--- a/target/linux/generic/patches-4.4/104-of-Add-check-to-of_scan_flat_dt-before-accessing-ini.patch
+++ /dev/null
@@ -1,30 +0,0 @@
-From: Tobias Wolf <dev-NTEO at vplace.de>
-Date: Wed, 23 Nov 2016 10:40:07 +0100
-Subject: [PATCH] of: Add check to of_scan_flat_dt() before accessing
- initial_boot_params
-
-An empty __dtb_start to __dtb_end section might result in initial_boot_params
-being null for arch/mips/ralink. This showed that the boot process hangs
-indefinitely in of_scan_flat_dt().
-
-Signed-off-by: Tobias Wolf <dev-NTEO at vplace.de>
----
-
---- a/drivers/of/fdt.c
-+++ b/drivers/of/fdt.c
-@@ -632,9 +632,12 @@ int __init of_scan_flat_dt(int (*it)(uns
- const char *pathp;
- int offset, rc = 0, depth = -1;
-
-- for (offset = fdt_next_node(blob, -1, &depth);
-- offset >= 0 && depth >= 0 && !rc;
-- offset = fdt_next_node(blob, offset, &depth)) {
-+ if (!blob)
-+ return 0;
-+
-+ for (offset = fdt_next_node(blob, -1, &depth);
-+ offset >= 0 && depth >= 0 && !rc;
-+ offset = fdt_next_node(blob, offset, &depth)) {
-
- pathp = fdt_get_name(blob, offset, NULL);
- if (*pathp == '/')
diff --git a/target/linux/generic/patches-4.4/465-m25p80-mx-disable-software-protection.patch b/target/linux/generic/patches-4.4/465-m25p80-mx-disable-software-protection.patch
index 89bafa8387..e81ebbb3fa 100644
--- a/target/linux/generic/patches-4.4/465-m25p80-mx-disable-software-protection.patch
+++ b/target/linux/generic/patches-4.4/465-m25p80-mx-disable-software-protection.patch
@@ -4,7 +4,7 @@ Signed-off-by: Felix Fietkau <nbd at nbd.name>
--- a/drivers/mtd/spi-nor/spi-nor.c
+++ b/drivers/mtd/spi-nor/spi-nor.c
-@@ -1159,6 +1159,7 @@ int spi_nor_scan(struct spi_nor *nor, co
+@@ -1166,6 +1166,7 @@ int spi_nor_scan(struct spi_nor *nor, co
if (JEDEC_MFR(info) == SNOR_MFR_ATMEL ||
JEDEC_MFR(info) == SNOR_MFR_INTEL ||
diff --git a/target/linux/generic/patches-4.4/662-use_fq_codel_by_default.patch b/target/linux/generic/patches-4.4/662-use_fq_codel_by_default.patch
index 8952ab4e20..9d1962caa9 100644
--- a/target/linux/generic/patches-4.4/662-use_fq_codel_by_default.patch
+++ b/target/linux/generic/patches-4.4/662-use_fq_codel_by_default.patch
@@ -70,10 +70,10 @@
+ qdisc = qdisc_create_dflt(dev_queue, &fq_codel_qdisc_ops,
TC_H_MAKE(TC_H_MAJ(sch->handle),
TC_H_MIN(ntx + 1)));
- if (qdisc == NULL)
+ if (!qdisc)
--- a/net/sched/sch_mqprio.c
+++ b/net/sched/sch_mqprio.c
-@@ -124,7 +124,7 @@ static int mqprio_init(struct Qdisc *sch
+@@ -122,7 +122,7 @@ static int mqprio_init(struct Qdisc *sch
for (i = 0; i < dev->num_tx_queues; i++) {
dev_queue = netdev_get_tx_queue(dev, i);
@@ -81,10 +81,10 @@
+ qdisc = qdisc_create_dflt(dev_queue, &fq_codel_qdisc_ops,
TC_H_MAKE(TC_H_MAJ(sch->handle),
TC_H_MIN(i + 1)));
- if (qdisc == NULL) {
+ if (!qdisc)
--- a/net/sched/sch_api.c
+++ b/net/sched/sch_api.c
-@@ -1948,7 +1948,7 @@ static int __init pktsched_init(void)
+@@ -1951,7 +1951,7 @@ static int __init pktsched_init(void)
return err;
}
diff --git a/target/linux/generic/patches-4.4/670-ipv6-allow-rejecting-with-source-address-failed-policy.patch b/target/linux/generic/patches-4.4/670-ipv6-allow-rejecting-with-source-address-failed-policy.patch
index 1ec2b81e1a..c6c65d9f39 100644
--- a/target/linux/generic/patches-4.4/670-ipv6-allow-rejecting-with-source-address-failed-policy.patch
+++ b/target/linux/generic/patches-4.4/670-ipv6-allow-rejecting-with-source-address-failed-policy.patch
@@ -88,7 +88,7 @@ Signed-off-by: Jonas Gorski <jogo at openwrt.org>
default:
--- a/net/ipv6/fib6_rules.c
+++ b/net/ipv6/fib6_rules.c
-@@ -84,6 +84,10 @@ static int fib6_rule_action(struct fib_r
+@@ -73,6 +73,10 @@ static int fib6_rule_action(struct fib_r
err = -EACCES;
rt = net->ipv6.ip6_prohibit_entry;
goto discard_pkt;
@@ -183,7 +183,7 @@ Signed-off-by: Jonas Gorski <jogo at openwrt.org>
cfg->fc_flags |= RTF_REJECT;
if (rtm->rtm_type == RTN_LOCAL)
-@@ -3093,6 +3127,9 @@ static int rt6_fill_node(struct net *net
+@@ -3087,6 +3121,9 @@ static int rt6_fill_node(struct net *net
case -EACCES:
rtm->rtm_type = RTN_PROHIBIT;
break;
@@ -193,7 +193,7 @@ Signed-off-by: Jonas Gorski <jogo at openwrt.org>
case -EAGAIN:
rtm->rtm_type = RTN_THROW;
break;
-@@ -3372,6 +3409,8 @@ static int ip6_route_dev_notify(struct n
+@@ -3366,6 +3403,8 @@ static int ip6_route_dev_notify(struct n
#ifdef CONFIG_IPV6_MULTIPLE_TABLES
net->ipv6.ip6_prohibit_entry->dst.dev = dev;
net->ipv6.ip6_prohibit_entry->rt6i_idev = in6_dev_get(dev);
@@ -202,7 +202,7 @@ Signed-off-by: Jonas Gorski <jogo at openwrt.org>
net->ipv6.ip6_blk_hole_entry->dst.dev = dev;
net->ipv6.ip6_blk_hole_entry->rt6i_idev = in6_dev_get(dev);
#endif
-@@ -3594,6 +3633,17 @@ static int __net_init ip6_route_net_init
+@@ -3588,6 +3627,17 @@ static int __net_init ip6_route_net_init
net->ipv6.ip6_blk_hole_entry->dst.ops = &net->ipv6.ip6_dst_ops;
dst_init_metrics(&net->ipv6.ip6_blk_hole_entry->dst,
ip6_template_metrics, true);
@@ -220,7 +220,7 @@ Signed-off-by: Jonas Gorski <jogo at openwrt.org>
#endif
net->ipv6.sysctl.flush_delay = 0;
-@@ -3612,6 +3662,8 @@ out:
+@@ -3606,6 +3656,8 @@ out:
return ret;
#ifdef CONFIG_IPV6_MULTIPLE_TABLES
@@ -229,7 +229,7 @@ Signed-off-by: Jonas Gorski <jogo at openwrt.org>
out_ip6_prohibit_entry:
kfree(net->ipv6.ip6_prohibit_entry);
out_ip6_null_entry:
-@@ -3629,6 +3681,7 @@ static void __net_exit ip6_route_net_exi
+@@ -3623,6 +3675,7 @@ static void __net_exit ip6_route_net_exi
#ifdef CONFIG_IPV6_MULTIPLE_TABLES
kfree(net->ipv6.ip6_prohibit_entry);
kfree(net->ipv6.ip6_blk_hole_entry);
@@ -237,7 +237,7 @@ Signed-off-by: Jonas Gorski <jogo at openwrt.org>
#endif
dst_entries_destroy(&net->ipv6.ip6_dst_ops);
}
-@@ -3702,6 +3755,9 @@ void __init ip6_route_init_special_entri
+@@ -3696,6 +3749,9 @@ void __init ip6_route_init_special_entri
init_net.ipv6.ip6_prohibit_entry->rt6i_idev = in6_dev_get(init_net.loopback_dev);
init_net.ipv6.ip6_blk_hole_entry->dst.dev = init_net.loopback_dev;
init_net.ipv6.ip6_blk_hole_entry->rt6i_idev = in6_dev_get(init_net.loopback_dev);
diff --git a/target/linux/generic/patches-4.4/680-NET-skip-GRO-for-foreign-MAC-addresses.patch b/target/linux/generic/patches-4.4/680-NET-skip-GRO-for-foreign-MAC-addresses.patch
index 4ef11ed17e..0c5871048b 100644
--- a/target/linux/generic/patches-4.4/680-NET-skip-GRO-for-foreign-MAC-addresses.patch
+++ b/target/linux/generic/patches-4.4/680-NET-skip-GRO-for-foreign-MAC-addresses.patch
@@ -17,7 +17,7 @@ Signed-off-by: Felix Fietkau <nbd at nbd.name>
--- a/net/core/dev.c
+++ b/net/core/dev.c
-@@ -4248,6 +4248,9 @@ static enum gro_result dev_gro_receive(s
+@@ -4249,6 +4249,9 @@ static enum gro_result dev_gro_receive(s
enum gro_result ret;
int grow;
@@ -27,7 +27,7 @@ Signed-off-by: Felix Fietkau <nbd at nbd.name>
if (!(skb->dev->features & NETIF_F_GRO))
goto normal;
-@@ -5404,6 +5407,48 @@ static void __netdev_adjacent_dev_unlink
+@@ -5415,6 +5418,48 @@ static void __netdev_adjacent_dev_unlink
&upper_dev->adj_list.lower);
}
@@ -76,7 +76,7 @@ Signed-off-by: Felix Fietkau <nbd at nbd.name>
static int __netdev_upper_dev_link(struct net_device *dev,
struct net_device *upper_dev, bool master,
void *private)
-@@ -5475,6 +5520,7 @@ static int __netdev_upper_dev_link(struc
+@@ -5486,6 +5531,7 @@ static int __netdev_upper_dev_link(struc
goto rollback_lower_mesh;
}
@@ -84,7 +84,7 @@ Signed-off-by: Felix Fietkau <nbd at nbd.name>
call_netdevice_notifiers_info(NETDEV_CHANGEUPPER, dev,
&changeupper_info.info);
return 0;
-@@ -5601,6 +5647,7 @@ void netdev_upper_dev_unlink(struct net_
+@@ -5612,6 +5658,7 @@ void netdev_upper_dev_unlink(struct net_
list_for_each_entry(i, &upper_dev->all_adj_list.upper, list)
__netdev_adjacent_dev_unlink(dev, i->dev, i->ref_nr);
@@ -92,7 +92,7 @@ Signed-off-by: Felix Fietkau <nbd at nbd.name>
call_netdevice_notifiers_info(NETDEV_CHANGEUPPER, dev,
&changeupper_info.info);
}
-@@ -6141,6 +6188,7 @@ int dev_set_mac_address(struct net_devic
+@@ -6152,6 +6199,7 @@ int dev_set_mac_address(struct net_devic
if (err)
return err;
dev->addr_assign_type = NET_ADDR_SET;
diff --git a/target/linux/generic/patches-4.4/721-phy_packets.patch b/target/linux/generic/patches-4.4/721-phy_packets.patch
index 7dac46a4db..b163684c69 100644
--- a/target/linux/generic/patches-4.4/721-phy_packets.patch
+++ b/target/linux/generic/patches-4.4/721-phy_packets.patch
@@ -86,7 +86,7 @@
help
--- a/net/core/dev.c
+++ b/net/core/dev.c
-@@ -2735,10 +2735,20 @@ static int xmit_one(struct sk_buff *skb,
+@@ -2736,10 +2736,20 @@ static int xmit_one(struct sk_buff *skb,
if (!list_empty(&ptype_all) || !list_empty(&dev->ptype_all))
dev_queue_xmit_nit(skb, dev);
diff --git a/target/linux/layerscape/patches-4.4/1074-mtd-nand-spi-nor-assign-MTD-of_node.patch b/target/linux/layerscape/patches-4.4/1074-mtd-nand-spi-nor-assign-MTD-of_node.patch
index e383347895..358b51245f 100644
--- a/target/linux/layerscape/patches-4.4/1074-mtd-nand-spi-nor-assign-MTD-of_node.patch
+++ b/target/linux/layerscape/patches-4.4/1074-mtd-nand-spi-nor-assign-MTD-of_node.patch
@@ -21,7 +21,7 @@ Signed-off-by: Yuan Yao <yao.yuan at nxp.com>
--- a/drivers/mtd/spi-nor/spi-nor.c
+++ b/drivers/mtd/spi-nor/spi-nor.c
-@@ -1221,6 +1221,7 @@ int spi_nor_scan(struct spi_nor *nor, co
+@@ -1228,6 +1228,7 @@ int spi_nor_scan(struct spi_nor *nor, co
mtd->flags |= MTD_NO_ERASE;
mtd->dev.parent = dev;
diff --git a/target/linux/layerscape/patches-4.4/1075-mtd-spi-nor-convert-to-spi_nor_-get-set-_flash_node.patch b/target/linux/layerscape/patches-4.4/1075-mtd-spi-nor-convert-to-spi_nor_-get-set-_flash_node.patch
index 596cc6fcb7..bbe29b612a 100644
--- a/target/linux/layerscape/patches-4.4/1075-mtd-spi-nor-convert-to-spi_nor_-get-set-_flash_node.patch
+++ b/target/linux/layerscape/patches-4.4/1075-mtd-spi-nor-convert-to-spi_nor_-get-set-_flash_node.patch
@@ -69,7 +69,7 @@ Reviewed-by: Boris Brezillon <boris.brezillon at free-electrons.com>
spifi->nor.write = nxp_spifi_write;
--- a/drivers/mtd/spi-nor/spi-nor.c
+++ b/drivers/mtd/spi-nor/spi-nor.c
-@@ -1113,7 +1113,7 @@ int spi_nor_scan(struct spi_nor *nor, co
+@@ -1120,7 +1120,7 @@ int spi_nor_scan(struct spi_nor *nor, co
const struct flash_info *info = NULL;
struct device *dev = nor->dev;
struct mtd_info *mtd = &nor->mtd;
diff --git a/target/linux/layerscape/patches-4.4/1078-mtd-spi-nor-drop-flash_node-field.patch b/target/linux/layerscape/patches-4.4/1078-mtd-spi-nor-drop-flash_node-field.patch
index 45c69a85cd..dc551dfabb 100644
--- a/target/linux/layerscape/patches-4.4/1078-mtd-spi-nor-drop-flash_node-field.patch
+++ b/target/linux/layerscape/patches-4.4/1078-mtd-spi-nor-drop-flash_node-field.patch
@@ -14,7 +14,7 @@ Reviewed-by: Boris Brezillon <boris.brezillon at free-electrons.com>
--- a/drivers/mtd/spi-nor/spi-nor.c
+++ b/drivers/mtd/spi-nor/spi-nor.c
-@@ -1221,7 +1221,6 @@ int spi_nor_scan(struct spi_nor *nor, co
+@@ -1228,7 +1228,6 @@ int spi_nor_scan(struct spi_nor *nor, co
mtd->flags |= MTD_NO_ERASE;
mtd->dev.parent = dev;
diff --git a/target/linux/layerscape/patches-4.4/1081-mtd-spi-nor-provide-default-erase_sector-implementat.patch b/target/linux/layerscape/patches-4.4/1081-mtd-spi-nor-provide-default-erase_sector-implementat.patch
index c5029b87a2..e966cafce6 100644
--- a/target/linux/layerscape/patches-4.4/1081-mtd-spi-nor-provide-default-erase_sector-implementat.patch
+++ b/target/linux/layerscape/patches-4.4/1081-mtd-spi-nor-provide-default-erase_sector-implementat.patch
@@ -69,7 +69,7 @@ Signed-off-by: Brian Norris <computersforpeace at gmail.com>
addr += mtd->erasesize;
len -= mtd->erasesize;
-@@ -1100,7 +1123,7 @@ static int set_quad_mode(struct spi_nor
+@@ -1107,7 +1130,7 @@ static int set_quad_mode(struct spi_nor
static int spi_nor_check(struct spi_nor *nor)
{
if (!nor->dev || !nor->read || !nor->write ||
@@ -78,7 +78,7 @@ Signed-off-by: Brian Norris <computersforpeace at gmail.com>
pr_err("spi-nor: please fill all the necessary fields!\n");
return -EINVAL;
}
-@@ -1303,6 +1326,12 @@ int spi_nor_scan(struct spi_nor *nor, co
+@@ -1310,6 +1333,12 @@ int spi_nor_scan(struct spi_nor *nor, co
nor->addr_width = 3;
}
diff --git a/target/linux/layerscape/patches-4.4/1090-mtd-spi-nor-Add-SPI-NOR-layer-PM-support.patch b/target/linux/layerscape/patches-4.4/1090-mtd-spi-nor-Add-SPI-NOR-layer-PM-support.patch
index 65a6633453..de3d2d5456 100644
--- a/target/linux/layerscape/patches-4.4/1090-mtd-spi-nor-Add-SPI-NOR-layer-PM-support.patch
+++ b/target/linux/layerscape/patches-4.4/1090-mtd-spi-nor-Add-SPI-NOR-layer-PM-support.patch
@@ -24,7 +24,7 @@ Integrated-by: Jiang Yutang <yutang.jiang at nxp.com>
--- a/drivers/mtd/spi-nor/spi-nor.c
+++ b/drivers/mtd/spi-nor/spi-nor.c
-@@ -1141,6 +1141,26 @@ static int spi_nor_check(struct spi_nor
+@@ -1148,6 +1148,26 @@ static int spi_nor_check(struct spi_nor
return 0;
}
@@ -51,7 +51,7 @@ Integrated-by: Jiang Yutang <yutang.jiang at nxp.com>
int spi_nor_scan(struct spi_nor *nor, const char *name, enum read_mode mode)
{
const struct flash_info *info = NULL;
-@@ -1188,19 +1208,9 @@ int spi_nor_scan(struct spi_nor *nor, co
+@@ -1195,19 +1215,9 @@ int spi_nor_scan(struct spi_nor *nor, co
mutex_init(&nor->lock);
@@ -74,7 +74,7 @@ Integrated-by: Jiang Yutang <yutang.jiang at nxp.com>
if (!mtd->name)
mtd->name = dev_name(dev);
-@@ -1367,6 +1377,45 @@ int spi_nor_scan(struct spi_nor *nor, co
+@@ -1374,6 +1384,45 @@ int spi_nor_scan(struct spi_nor *nor, co
}
EXPORT_SYMBOL_GPL(spi_nor_scan);
diff --git a/target/linux/layerscape/patches-4.4/1100-mtd-spi_nor-Disable-Micron-flash-HW-protection.patch b/target/linux/layerscape/patches-4.4/1100-mtd-spi_nor-Disable-Micron-flash-HW-protection.patch
index a5495616e9..47fef5cd0c 100644
--- a/target/linux/layerscape/patches-4.4/1100-mtd-spi_nor-Disable-Micron-flash-HW-protection.patch
+++ b/target/linux/layerscape/patches-4.4/1100-mtd-spi_nor-Disable-Micron-flash-HW-protection.patch
@@ -24,7 +24,7 @@ Signed-off-by: Yunhui Cui <B56489 at freescale.com>
struct flash_info {
char *name;
-@@ -1239,6 +1240,14 @@ int spi_nor_scan(struct spi_nor *nor, co
+@@ -1246,6 +1247,14 @@ int spi_nor_scan(struct spi_nor *nor, co
if (ret)
return ret;
diff --git a/target/linux/layerscape/patches-4.4/1103-mtd-spi-nor-Support-R-W-for-S25FS-S-family-flash.patch b/target/linux/layerscape/patches-4.4/1103-mtd-spi-nor-Support-R-W-for-S25FS-S-family-flash.patch
index 9cfa2697a8..7b954dd5c8 100644
--- a/target/linux/layerscape/patches-4.4/1103-mtd-spi-nor-Support-R-W-for-S25FS-S-family-flash.patch
+++ b/target/linux/layerscape/patches-4.4/1103-mtd-spi-nor-Support-R-W-for-S25FS-S-family-flash.patch
@@ -95,7 +95,7 @@ Signed-off-by: Yunhui Cui <yunhui.cui at nxp.com>
static int spi_nor_read(struct mtd_info *mtd, loff_t from, size_t len,
size_t *retlen, u_char *buf)
{
-@@ -1248,6 +1302,12 @@ int spi_nor_scan(struct spi_nor *nor, co
+@@ -1255,6 +1309,12 @@ int spi_nor_scan(struct spi_nor *nor, co
write_sr(nor, ret);
}
diff --git a/target/linux/layerscape/patches-4.4/1105-mtd-spi-nor-add-DDR-quad-read-support.patch b/target/linux/layerscape/patches-4.4/1105-mtd-spi-nor-add-DDR-quad-read-support.patch
index bad120e7be..df7e0d82f8 100644
--- a/target/linux/layerscape/patches-4.4/1105-mtd-spi-nor-add-DDR-quad-read-support.patch
+++ b/target/linux/layerscape/patches-4.4/1105-mtd-spi-nor-add-DDR-quad-read-support.patch
@@ -63,7 +63,7 @@ Signed-off-by: Yunhui Cui <yunhui.cui at nxp.com>
{ "s25fl129p0", INFO(0x012018, 0x4d00, 256 * 1024, 64, SPI_NOR_DUAL_READ | SPI_NOR_QUAD_READ) },
{ "s25fl129p1", INFO(0x012018, 0x4d01, 64 * 1024, 256, SPI_NOR_DUAL_READ | SPI_NOR_QUAD_READ) },
{ "s25sl004a", INFO(0x010212, 0, 64 * 1024, 8, 0) },
-@@ -1188,6 +1194,23 @@ static int spansion_quad_enable(struct s
+@@ -1195,6 +1201,23 @@ static int spansion_quad_enable(struct s
return 0;
}
@@ -87,7 +87,7 @@ Signed-off-by: Yunhui Cui <yunhui.cui at nxp.com>
static int set_quad_mode(struct spi_nor *nor, const struct flash_info *info)
{
int status;
-@@ -1378,8 +1401,15 @@ int spi_nor_scan(struct spi_nor *nor, co
+@@ -1385,8 +1408,15 @@ int spi_nor_scan(struct spi_nor *nor, co
if (info->flags & SPI_NOR_NO_FR)
nor->flash_read = SPI_NOR_NORMAL;
@@ -105,7 +105,7 @@ Signed-off-by: Yunhui Cui <yunhui.cui at nxp.com>
ret = set_quad_mode(nor, info);
if (ret) {
dev_err(dev, "quad mode not supported\n");
-@@ -1392,6 +1422,14 @@ int spi_nor_scan(struct spi_nor *nor, co
+@@ -1399,6 +1429,14 @@ int spi_nor_scan(struct spi_nor *nor, co
/* Default commands */
switch (nor->flash_read) {
@@ -120,7 +120,7 @@ Signed-off-by: Yunhui Cui <yunhui.cui at nxp.com>
case SPI_NOR_QUAD:
nor->read_opcode = SPINOR_OP_READ_1_1_4;
break;
-@@ -1419,6 +1457,9 @@ int spi_nor_scan(struct spi_nor *nor, co
+@@ -1426,6 +1464,9 @@ int spi_nor_scan(struct spi_nor *nor, co
if (JEDEC_MFR(info) == SNOR_MFR_SPANSION) {
/* Dedicated 4-byte command set */
switch (nor->flash_read) {
@@ -130,7 +130,7 @@ Signed-off-by: Yunhui Cui <yunhui.cui at nxp.com>
case SPI_NOR_QUAD:
nor->read_opcode = SPINOR_OP_READ4_1_1_4;
break;
-@@ -1448,7 +1489,7 @@ int spi_nor_scan(struct spi_nor *nor, co
+@@ -1455,7 +1496,7 @@ int spi_nor_scan(struct spi_nor *nor, co
return -EINVAL;
}
diff --git a/target/linux/layerscape/patches-4.4/1110-mtd-spi-nor-fsl-quad-add-flash-S25FS-extra-support.patch b/target/linux/layerscape/patches-4.4/1110-mtd-spi-nor-fsl-quad-add-flash-S25FS-extra-support.patch
index 8dab548550..c018a33fb0 100644
--- a/target/linux/layerscape/patches-4.4/1110-mtd-spi-nor-fsl-quad-add-flash-S25FS-extra-support.patch
+++ b/target/linux/layerscape/patches-4.4/1110-mtd-spi-nor-fsl-quad-add-flash-S25FS-extra-support.patch
@@ -136,7 +136,7 @@ Integrated-by: Jiang Yutang <yutang.jiang at nxp.com>
return 0;
}
-@@ -1336,6 +1333,8 @@ int spi_nor_scan(struct spi_nor *nor, co
+@@ -1343,6 +1340,8 @@ int spi_nor_scan(struct spi_nor *nor, co
if (!mtd->name)
mtd->name = dev_name(dev);
diff --git a/target/linux/layerscape/patches-4.4/7018-devres-add-devm_alloc_percpu.patch b/target/linux/layerscape/patches-4.4/7018-devres-add-devm_alloc_percpu.patch
index 4962d4bada..835403e582 100644
--- a/target/linux/layerscape/patches-4.4/7018-devres-add-devm_alloc_percpu.patch
+++ b/target/linux/layerscape/patches-4.4/7018-devres-add-devm_alloc_percpu.patch
@@ -110,7 +110,7 @@ Conflicts:
+EXPORT_SYMBOL_GPL(devm_free_percpu);
--- a/include/linux/device.h
+++ b/include/linux/device.h
-@@ -681,6 +681,25 @@ void __iomem *devm_ioremap_resource(stru
+@@ -683,6 +683,25 @@ void __iomem *devm_ioremap_resource(stru
int devm_add_action(struct device *dev, void (*action)(void *), void *data);
void devm_remove_action(struct device *dev, void (*action)(void *), void *data);
diff --git a/target/linux/layerscape/patches-4.4/8138-pci-layerscape-add-MSI-interrupt-support.patch b/target/linux/layerscape/patches-4.4/8138-pci-layerscape-add-MSI-interrupt-support.patch
index 0db0a6b6d3..cbfa86c1e2 100644
--- a/target/linux/layerscape/patches-4.4/8138-pci-layerscape-add-MSI-interrupt-support.patch
+++ b/target/linux/layerscape/patches-4.4/8138-pci-layerscape-add-MSI-interrupt-support.patch
@@ -69,7 +69,7 @@ Signed-off-by: Zhao Qiang <qiang.zhao at nxp.com>
if (IS_ERR(group))
--- a/drivers/iommu/iommu.c
+++ b/drivers/iommu/iommu.c
-@@ -686,10 +686,10 @@ static struct iommu_group *get_pci_alias
+@@ -697,10 +697,10 @@ static struct iommu_group *get_pci_alias
continue;
/* We alias them or they alias us */
diff --git a/target/linux/mvebu/patches-4.4/030-mvneta-consolidate-autoneg-enabling.patch b/target/linux/mvebu/patches-4.4/030-mvneta-consolidate-autoneg-enabling.patch
index 1d98c7decc..c398a47341 100644
--- a/target/linux/mvebu/patches-4.4/030-mvneta-consolidate-autoneg-enabling.patch
+++ b/target/linux/mvebu/patches-4.4/030-mvneta-consolidate-autoneg-enabling.patch
@@ -43,7 +43,7 @@ Signed-off-by: David S. Miller <davem at davemloft.net>
}
mvneta_set_ucast_table(pp, -1);
-@@ -3230,9 +3243,6 @@ static int mvneta_port_power_up(struct m
+@@ -3228,9 +3241,6 @@ static int mvneta_port_power_up(struct m
return -EINVAL;
}
diff --git a/target/linux/mvebu/patches-4.4/031-mvneta-implement-ethtool-autonegotiation-control.patch b/target/linux/mvebu/patches-4.4/031-mvneta-implement-ethtool-autonegotiation-control.patch
index 626b511c45..dc4a224b74 100644
--- a/target/linux/mvebu/patches-4.4/031-mvneta-implement-ethtool-autonegotiation-control.patch
+++ b/target/linux/mvebu/patches-4.4/031-mvneta-implement-ethtool-autonegotiation-control.patch
@@ -118,7 +118,7 @@ Signed-off-by: David S. Miller <davem at davemloft.net>
mvneta_set_ucast_table(pp, -1);
mvneta_set_special_mcast_table(pp, -1);
mvneta_set_other_mcast_table(pp, -1);
-@@ -2956,10 +2962,43 @@ int mvneta_ethtool_get_settings(struct n
+@@ -2954,10 +2960,43 @@ int mvneta_ethtool_get_settings(struct n
int mvneta_ethtool_set_settings(struct net_device *dev, struct ethtool_cmd *cmd)
{
struct mvneta_port *pp = netdev_priv(dev);
diff --git a/target/linux/mvebu/patches-4.4/032-net-mvneta-Make-the-default-queue-related-for-each-p.patch b/target/linux/mvebu/patches-4.4/032-net-mvneta-Make-the-default-queue-related-for-each-p.patch
index 54c93998f6..83782a0b4f 100644
--- a/target/linux/mvebu/patches-4.4/032-net-mvneta-Make-the-default-queue-related-for-each-p.patch
+++ b/target/linux/mvebu/patches-4.4/032-net-mvneta-Make-the-default-queue-related-for-each-p.patch
@@ -120,7 +120,7 @@ Signed-off-by: David S. Miller <davem at davemloft.net>
for_each_online_cpu(cpu) {
if (i == online_cpu_idx)
-@@ -3363,6 +3364,8 @@ static int mvneta_probe(struct platform_
+@@ -3361,6 +3362,8 @@ static int mvneta_probe(struct platform_
strcmp(managed, "in-band-status") == 0);
pp->cpu_notifier.notifier_call = mvneta_percpu_notifier;
diff --git a/target/linux/mvebu/patches-4.4/034-net-mvneta-Add-naive-RSS-support.patch b/target/linux/mvebu/patches-4.4/034-net-mvneta-Add-naive-RSS-support.patch
index 629c44c8a1..9d729b50bb 100644
--- a/target/linux/mvebu/patches-4.4/034-net-mvneta-Add-naive-RSS-support.patch
+++ b/target/linux/mvebu/patches-4.4/034-net-mvneta-Add-naive-RSS-support.patch
@@ -62,7 +62,7 @@ Signed-off-by: David S. Miller <davem at davemloft.net>
static void mvneta_start_dev(struct mvneta_port *pp)
{
unsigned int cpu;
-@@ -3231,6 +3250,106 @@ static int mvneta_ethtool_get_sset_count
+@@ -3229,6 +3248,106 @@ static int mvneta_ethtool_get_sset_count
return -EOPNOTSUPP;
}
@@ -169,7 +169,7 @@ Signed-off-by: David S. Miller <davem at davemloft.net>
static const struct net_device_ops mvneta_netdev_ops = {
.ndo_open = mvneta_open,
.ndo_stop = mvneta_stop,
-@@ -3255,6 +3374,10 @@ const struct ethtool_ops mvneta_eth_tool
+@@ -3253,6 +3372,10 @@ const struct ethtool_ops mvneta_eth_tool
.get_strings = mvneta_ethtool_get_strings,
.get_ethtool_stats = mvneta_ethtool_get_stats,
.get_sset_count = mvneta_ethtool_get_sset_count,
@@ -180,7 +180,7 @@ Signed-off-by: David S. Miller <davem at davemloft.net>
};
/* Initialize hw */
-@@ -3446,6 +3569,8 @@ static int mvneta_probe(struct platform_
+@@ -3444,6 +3567,8 @@ static int mvneta_probe(struct platform_
pp->rxq_def = rxq_def;
diff --git a/target/linux/mvebu/patches-4.4/036-net-mvneta-fix-trivial-cut-off-issue-in-mvneta_ethto.patch b/target/linux/mvebu/patches-4.4/036-net-mvneta-fix-trivial-cut-off-issue-in-mvneta_ethto.patch
index 2bd7a88032..d88336701d 100644
--- a/target/linux/mvebu/patches-4.4/036-net-mvneta-fix-trivial-cut-off-issue-in-mvneta_ethto.patch
+++ b/target/linux/mvebu/patches-4.4/036-net-mvneta-fix-trivial-cut-off-issue-in-mvneta_ethto.patch
@@ -13,7 +13,7 @@ Signed-off-by: David S. Miller <davem at davemloft.net>
--- a/drivers/net/ethernet/marvell/mvneta.c
+++ b/drivers/net/ethernet/marvell/mvneta.c
-@@ -3242,26 +3242,25 @@ static void mvneta_ethtool_update_stats(
+@@ -3240,26 +3240,25 @@ static void mvneta_ethtool_update_stats(
const struct mvneta_statistic *s;
void __iomem *base = pp->base;
u32 high, low, val;
diff --git a/target/linux/mvebu/patches-4.4/037-net-mvneta-Fix-for_each_present_cpu-usage.patch b/target/linux/mvebu/patches-4.4/037-net-mvneta-Fix-for_each_present_cpu-usage.patch
deleted file mode 100644
index 9ded5b71fe..0000000000
--- a/target/linux/mvebu/patches-4.4/037-net-mvneta-Fix-for_each_present_cpu-usage.patch
+++ /dev/null
@@ -1,55 +0,0 @@
-From: Gregory CLEMENT <gregory.clement at free-electrons.com>
-Date: Thu, 4 Feb 2016 22:09:23 +0100
-Subject: [PATCH] net: mvneta: Fix for_each_present_cpu usage
-
-This patch convert the for_each_present in on_each_cpu, instead of
-applying on the present cpus it will be applied only on the online cpus.
-This fix a bug reported on
-http://thread.gmane.org/gmane.linux.ports.arm.kernel/468173.
-
-Using the macro on_each_cpu (instead of a for_each_* loop) also ensures
-that all the calls will be done all at once.
-
-Fixes: f86428854480 ("net: mvneta: Statically assign queues to CPUs")
-Reported-by: Stefan Roese <stefan.roese at gmail.com>
-Suggested-by: Jisheng Zhang <jszhang at marvell.com>
-Suggested-by: Russell King <rmk+kernel at arm.linux.org.uk>
-Signed-off-by: Gregory CLEMENT <gregory.clement at free-electrons.com>
-Signed-off-by: David S. Miller <davem at davemloft.net>
----
-
---- a/drivers/net/ethernet/marvell/mvneta.c
-+++ b/drivers/net/ethernet/marvell/mvneta.c
-@@ -2562,7 +2562,7 @@ static void mvneta_start_dev(struct mvne
- mvneta_port_enable(pp);
-
- /* Enable polling on the port */
-- for_each_present_cpu(cpu) {
-+ for_each_online_cpu(cpu) {
- struct mvneta_pcpu_port *port = per_cpu_ptr(pp->ports, cpu);
-
- napi_enable(&port->napi);
-@@ -2587,7 +2587,7 @@ static void mvneta_stop_dev(struct mvnet
-
- phy_stop(pp->phy_dev);
-
-- for_each_present_cpu(cpu) {
-+ for_each_online_cpu(cpu) {
- struct mvneta_pcpu_port *port = per_cpu_ptr(pp->ports, cpu);
-
- napi_disable(&port->napi);
-@@ -3055,13 +3055,11 @@ err_cleanup_rxqs:
- static int mvneta_stop(struct net_device *dev)
- {
- struct mvneta_port *pp = netdev_priv(dev);
-- int cpu;
-
- mvneta_stop_dev(pp);
- mvneta_mdio_remove(pp);
- unregister_cpu_notifier(&pp->cpu_notifier);
-- for_each_present_cpu(cpu)
-- smp_call_function_single(cpu, mvneta_percpu_disable, pp, true);
-+ on_each_cpu(mvneta_percpu_disable, pp, true);
- free_percpu_irq(dev->irq, pp->ports);
- mvneta_cleanup_rxqs(pp);
- mvneta_cleanup_txqs(pp);
diff --git a/target/linux/mvebu/patches-4.4/126-phy-marvell-88E1512-add-flow-control-support.patch b/target/linux/mvebu/patches-4.4/126-phy-marvell-88E1512-add-flow-control-support.patch
index c8f372b409..cfb0202196 100644
--- a/target/linux/mvebu/patches-4.4/126-phy-marvell-88E1512-add-flow-control-support.patch
+++ b/target/linux/mvebu/patches-4.4/126-phy-marvell-88E1512-add-flow-control-support.patch
@@ -15,7 +15,7 @@ Signed-off-by: Russell King <rmk+kernel at arm.linux.org.uk>
--- a/drivers/net/phy/marvell.c
+++ b/drivers/net/phy/marvell.c
-@@ -1150,7 +1150,7 @@ static struct phy_driver marvell_drivers
+@@ -1148,7 +1148,7 @@ static struct phy_driver marvell_drivers
.phy_id = MARVELL_PHY_ID_88E1510,
.phy_id_mask = MARVELL_PHY_ID_MASK,
.name = "Marvell 88E1510",
diff --git a/target/linux/oxnas/patches-4.4/0072-mtd-backport-v4.7-0day-patches-from-Boris.patch b/target/linux/oxnas/patches-4.4/0072-mtd-backport-v4.7-0day-patches-from-Boris.patch
index 4b25d18f96..48fda9b020 100644
--- a/target/linux/oxnas/patches-4.4/0072-mtd-backport-v4.7-0day-patches-from-Boris.patch
+++ b/target/linux/oxnas/patches-4.4/0072-mtd-backport-v4.7-0day-patches-from-Boris.patch
@@ -4370,7 +4370,7 @@ Signed-off-by: John Crispin <blogic at openwrt.org>
write_enable(nor);
write_sr(nor, val | SR_QUAD_EN_MX);
-@@ -1100,7 +1247,7 @@ static int set_quad_mode(struct spi_nor
+@@ -1107,7 +1254,7 @@ static int set_quad_mode(struct spi_nor
static int spi_nor_check(struct spi_nor *nor)
{
if (!nor->dev || !nor->read || !nor->write ||
@@ -4379,7 +4379,7 @@ Signed-off-by: John Crispin <blogic at openwrt.org>
pr_err("spi-nor: please fill all the necessary fields!\n");
return -EINVAL;
}
-@@ -1113,7 +1260,7 @@ int spi_nor_scan(struct spi_nor *nor, co
+@@ -1120,7 +1267,7 @@ int spi_nor_scan(struct spi_nor *nor, co
const struct flash_info *info = NULL;
struct device *dev = nor->dev;
struct mtd_info *mtd = &nor->mtd;
@@ -4388,7 +4388,7 @@ Signed-off-by: John Crispin <blogic at openwrt.org>
int ret;
int i;
-@@ -1167,6 +1314,7 @@ int spi_nor_scan(struct spi_nor *nor, co
+@@ -1174,6 +1321,7 @@ int spi_nor_scan(struct spi_nor *nor, co
info->flags & SPI_NOR_HAS_LOCK) {
write_enable(nor);
write_sr(nor, 0);
@@ -4396,7 +4396,7 @@ Signed-off-by: John Crispin <blogic at openwrt.org>
}
if (!mtd->name)
-@@ -1201,6 +1349,8 @@ int spi_nor_scan(struct spi_nor *nor, co
+@@ -1208,6 +1356,8 @@ int spi_nor_scan(struct spi_nor *nor, co
if (info->flags & USE_FSR)
nor->flags |= SNOR_F_USE_FSR;
@@ -4405,7 +4405,7 @@ Signed-off-by: John Crispin <blogic at openwrt.org>
#ifdef CONFIG_MTD_SPI_NOR_USE_4K_SECTORS
/* prefer "small sector" erase if possible */
-@@ -1303,6 +1453,12 @@ int spi_nor_scan(struct spi_nor *nor, co
+@@ -1310,6 +1460,12 @@ int spi_nor_scan(struct spi_nor *nor, co
nor->addr_width = 3;
}
diff --git a/target/linux/rb532/patches-4.4/100-korina_fix_napi_disable.patch b/target/linux/rb532/patches-4.4/100-korina_fix_napi_disable.patch
deleted file mode 100644
index 3a67297df0..0000000000
--- a/target/linux/rb532/patches-4.4/100-korina_fix_napi_disable.patch
+++ /dev/null
@@ -1,51 +0,0 @@
-From 5833532b49820aa221248f296c207cc50d20ca2d Mon Sep 17 00:00:00 2001
-From: Florian Fainelli <f.fainelli at gmail.com>
-Date: Fri, 23 Dec 2016 19:36:31 -0800
-Subject: [PATCH net] net: korina: Fix NAPI versus resources freeing
-
-Commit beb0babfb77e ("korina: disable napi on close and restart")
-introduced calls to napi_disable() that were missing before,
-unfortunately this leaves a small window during which NAPI has a chance
-to run, yet we just freed resources since korina_free_ring() has been
-called:
-
-Fix this by disabling NAPI first then freeing resource, and make sure
-that we also cancel the restart taks before doing the resource freeing.
-
-Fixes: beb0babfb77e ("korina: disable napi on close and restart")
-Reported-by: Alexandros C. Couloumbis <alex at ozo.com>
-Signed-off-by: Florian Fainelli <f.fainelli at gmail.com>
----
- drivers/net/ethernet/korina.c | 8 ++++----
- 1 file changed, 4 insertions(+), 4 deletions(-)
-
---- a/drivers/net/ethernet/korina.c
-+++ b/drivers/net/ethernet/korina.c
-@@ -900,10 +900,10 @@ static void korina_restart_task(struct w
- DMA_STAT_DONE | DMA_STAT_HALT | DMA_STAT_ERR,
- &lp->rx_dma_regs->dmasm);
-
-- korina_free_ring(dev);
--
- napi_disable(&lp->napi);
-
-+ korina_free_ring(dev);
-+
- if (korina_init(dev) < 0) {
- printk(KERN_ERR "%s: cannot restart device\n", dev->name);
- return;
-@@ -1064,12 +1064,12 @@ static int korina_close(struct net_devic
- tmp = tmp | DMA_STAT_DONE | DMA_STAT_HALT | DMA_STAT_ERR;
- writel(tmp, &lp->rx_dma_regs->dmasm);
-
-- korina_free_ring(dev);
--
- napi_disable(&lp->napi);
-
- cancel_work_sync(&lp->restart_task);
-
-+ korina_free_ring(dev);
-+
- free_irq(lp->rx_irq, dev);
- free_irq(lp->tx_irq, dev);
- free_irq(lp->ovr_irq, dev);
--
2.13.3
More information about the Lede-dev
mailing list