Refreshed all patches.
Altered patches:
- 402-mtd-support-layerscape.patch
Fixes:
- CVE-2019-18660
Compile-tested on: ar71xx
Runtime-tested on: ar71xx
Signed-off-by: Koen Vandeputte <koen.vandeputte@ncentric.com>
LINUX_RELEASE?=1
-LINUX_VERSION-4.9 = .202
+LINUX_VERSION-4.9 = .205
LINUX_VERSION-4.14 = .156
-LINUX_KERNEL_HASH-4.9.202 = 8108ec1cd10fc40821c84e9f087dba10b1767aad66596f4a36925faef55e4ebf
+LINUX_KERNEL_HASH-4.9.205 = 98b9e8644706acc0cf51022372bb263b59a1d2bbe3ccd7ce6bd9bc7378c78b05
LINUX_KERNEL_HASH-4.14.156 = f8889feb0cbd7df36ff35bd4c72c1e2010567621bfcb218fcfa501bc5c7787c0
remove_uri_prefix=$(subst git://,,$(subst http://,,$(subst https://,,$(1))))
--- a/drivers/net/ethernet/broadcom/bcm63xx_enet.c
+++ b/drivers/net/ethernet/broadcom/bcm63xx_enet.c
-@@ -1739,10 +1739,8 @@ static int bcm_enet_probe(struct platfor
+@@ -1740,10 +1740,8 @@ static int bcm_enet_probe(struct platfor
const char *clk_name;
int i, ret;
res_irq = platform_get_resource(pdev, IORESOURCE_IRQ, 0);
res_irq_rx = platform_get_resource(pdev, IORESOURCE_IRQ, 1);
-@@ -2714,11 +2712,8 @@ static int bcm_enetsw_probe(struct platf
+@@ -2715,11 +2713,8 @@ static int bcm_enetsw_probe(struct platf
struct resource *res_mem;
int ret, irq_rx, irq_tx;
--- a/drivers/net/ethernet/broadcom/bcm63xx_enet.c
+++ b/drivers/net/ethernet/broadcom/bcm63xx_enet.c
-@@ -1784,14 +1784,14 @@ static int bcm_enet_probe(struct platfor
+@@ -1785,14 +1785,14 @@ static int bcm_enet_probe(struct platfor
clk_name = "enet1";
}
/* initialize default and fetch platform data */
priv->rx_ring_size = BCMENET_DEF_RX_DESC;
-@@ -1819,7 +1819,7 @@ static int bcm_enet_probe(struct platfor
+@@ -1820,7 +1820,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 */
if (IS_ERR(priv->phy_clk)) {
ret = PTR_ERR(priv->phy_clk);
priv->phy_clk = NULL;
-@@ -1827,7 +1827,7 @@ static int bcm_enet_probe(struct platfor
+@@ -1828,7 +1828,7 @@ static int bcm_enet_probe(struct platfor
}
ret = clk_prepare_enable(priv->phy_clk);
if (ret)
}
/* do minimal hardware init to be able to probe mii bus */
-@@ -1921,14 +1921,8 @@ out_uninit_hw:
+@@ -1922,14 +1922,8 @@ out_uninit_hw:
if (priv->phy_clk)
clk_disable_unprepare(priv->phy_clk);
out:
free_netdev(dev);
return ret;
-@@ -1964,12 +1958,10 @@ static int bcm_enet_remove(struct platfo
+@@ -1965,12 +1959,10 @@ static int bcm_enet_remove(struct platfo
}
/* disable hw block clocks */
free_netdev(dev);
return 0;
-@@ -2752,26 +2744,20 @@ static int bcm_enetsw_probe(struct platf
+@@ -2753,26 +2745,20 @@ static int bcm_enetsw_probe(struct platf
if (ret)
goto out;
priv->rx_chan = 0;
priv->tx_chan = 1;
-@@ -2803,15 +2789,6 @@ static int bcm_enetsw_probe(struct platf
+@@ -2804,15 +2790,6 @@ static int bcm_enetsw_probe(struct platf
out_disable_clk:
clk_disable_unprepare(priv->mac_clk);
out:
free_netdev(dev);
return ret;
-@@ -2823,20 +2800,13 @@ static int bcm_enetsw_remove(struct plat
+@@ -2824,20 +2801,13 @@ static int bcm_enetsw_remove(struct plat
{
struct bcm_enet_priv *priv;
struct net_device *dev;
--- a/drivers/net/ethernet/broadcom/bcm63xx_enet.c
+++ b/drivers/net/ethernet/broadcom/bcm63xx_enet.c
-@@ -1918,8 +1918,7 @@ out_free_mdio:
+@@ -1919,8 +1919,7 @@ out_free_mdio:
out_uninit_hw:
/* turn off mdc clock */
enet_writel(priv, 0, ENET_MIISC_REG);
out_disable_clk_mac:
clk_disable_unprepare(priv->mac_clk);
-@@ -1958,9 +1957,7 @@ static int bcm_enet_remove(struct platfo
+@@ -1959,9 +1958,7 @@ static int bcm_enet_remove(struct platfo
}
/* disable hw block clocks */
--- a/drivers/net/ethernet/broadcom/bcm63xx_enet.c
+++ b/drivers/net/ethernet/broadcom/bcm63xx_enet.c
-@@ -1736,7 +1736,6 @@ static int bcm_enet_probe(struct platfor
+@@ -1737,7 +1737,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;
int i, ret;
if (!bcm_enet_shared_base[0])
-@@ -1777,14 +1776,12 @@ static int bcm_enet_probe(struct platfor
+@@ -1778,14 +1777,12 @@ static int bcm_enet_probe(struct platfor
if (priv->mac_id == 0) {
priv->rx_chan = 0;
priv->tx_chan = 1;
/*
--- a/drivers/net/ethernet/broadcom/bcm63xx_enet.c
+++ b/drivers/net/ethernet/broadcom/bcm63xx_enet.c
-@@ -1772,15 +1772,6 @@ static int bcm_enet_probe(struct platfor
+@@ -1773,15 +1773,6 @@ static int bcm_enet_probe(struct platfor
priv->irq_tx = res_irq_tx->start;
priv->mac_id = pdev->id;
priv->mac_clk = devm_clk_get(&pdev->dev, "enet");
if (IS_ERR(priv->mac_clk)) {
ret = PTR_ERR(priv->mac_clk);
-@@ -1812,6 +1803,8 @@ static int bcm_enet_probe(struct platfor
+@@ -1813,6 +1804,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;
--- a/drivers/net/ethernet/broadcom/bcm63xx_enet.c
+++ b/drivers/net/ethernet/broadcom/bcm63xx_enet.c
-@@ -1807,7 +1807,7 @@ static int bcm_enet_probe(struct platfor
+@@ -1808,7 +1808,7 @@ static int bcm_enet_probe(struct platfor
priv->tx_chan = pd->tx_chan;
}
--- a/drivers/net/ethernet/broadcom/bcm63xx_enet.c
+++ b/drivers/net/ethernet/broadcom/bcm63xx_enet.c
-@@ -1770,7 +1770,6 @@ static int bcm_enet_probe(struct platfor
+@@ -1771,7 +1771,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;
priv->mac_clk = devm_clk_get(&pdev->dev, "enet");
if (IS_ERR(priv->mac_clk)) {
-@@ -1838,7 +1837,7 @@ static int bcm_enet_probe(struct platfor
+@@ -1839,7 +1838,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;
--- a/drivers/net/ethernet/broadcom/bcm63xx_enet.c
+++ b/drivers/net/ethernet/broadcom/bcm63xx_enet.c
-@@ -1635,7 +1635,7 @@ static int compute_hw_mtu(struct bcm_ene
+@@ -1636,7 +1636,7 @@ static int compute_hw_mtu(struct bcm_ene
actual_mtu = mtu;
/* add ethernet header + vlan tag size */
--- a/drivers/net/ethernet/broadcom/bcm63xx_enet.c
+++ b/drivers/net/ethernet/broadcom/bcm63xx_enet.c
-@@ -870,10 +870,8 @@ static int bcm_enet_open(struct net_devi
+@@ -871,10 +871,8 @@ static int bcm_enet_open(struct net_devi
struct bcm_enet_priv *priv;
struct sockaddr addr;
struct device *kdev;
void *p;
u32 val;
-@@ -881,40 +879,10 @@ static int bcm_enet_open(struct net_devi
+@@ -882,40 +880,10 @@ static int bcm_enet_open(struct net_devi
kdev = &priv->pdev->dev;
if (priv->has_phy) {
}
/* mask all interrupts and request them */
-@@ -924,7 +892,7 @@ static int bcm_enet_open(struct net_devi
+@@ -925,7 +893,7 @@ static int bcm_enet_open(struct net_devi
ret = request_irq(dev->irq, bcm_enet_isr_mac, 0, dev->name, dev);
if (ret)
ret = request_irq(priv->irq_rx, bcm_enet_isr_dma, 0,
dev->name, dev);
-@@ -1086,8 +1054,8 @@ static int bcm_enet_open(struct net_devi
+@@ -1087,8 +1055,8 @@ static int bcm_enet_open(struct net_devi
enet_dmac_writel(priv, priv->dma_chan_int_mask,
ENETDMAC_IRMASK, priv->tx_chan);
else
bcm_enet_adjust_link(dev);
-@@ -1128,10 +1096,6 @@ out_freeirq_rx:
+@@ -1129,10 +1097,6 @@ out_freeirq_rx:
out_freeirq:
free_irq(dev->irq, dev);
return ret;
}
-@@ -1236,10 +1200,6 @@ static int bcm_enet_stop(struct net_devi
+@@ -1237,10 +1201,6 @@ static int bcm_enet_stop(struct net_devi
free_irq(priv->irq_rx, dev);
free_irq(dev->irq, dev);
return 0;
}
-@@ -1821,14 +1781,46 @@ static int bcm_enet_probe(struct platfor
+@@ -1822,14 +1782,46 @@ static int bcm_enet_probe(struct platfor
/* do minimal hardware init to be able to probe mii bus */
bcm_enet_hw_preinit(priv);
}
bus = priv->mii_bus;
-@@ -1852,6 +1844,35 @@ static int bcm_enet_probe(struct platfor
+@@ -1853,6 +1845,35 @@ static int bcm_enet_probe(struct platfor
dev_err(&pdev->dev, "unable to register mdio bus\n");
goto out_free_mdio;
}
} else {
/* run platform code to initialize PHY device */
-@@ -1859,44 +1880,16 @@ static int bcm_enet_probe(struct platfor
+@@ -1860,44 +1881,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");
if (priv->mii_bus)
mdiobus_unregister(priv->mii_bus);
-@@ -1904,6 +1897,9 @@ out_free_mdio:
+@@ -1905,6 +1898,9 @@ out_free_mdio:
if (priv->mii_bus)
mdiobus_free(priv->mii_bus);
out_uninit_hw:
/* turn off mdc clock */
enet_writel(priv, 0, ENET_MIISC_REG);
-@@ -1934,6 +1930,7 @@ static int bcm_enet_remove(struct platfo
+@@ -1935,6 +1931,7 @@ static int bcm_enet_remove(struct platfo
enet_writel(priv, 0, ENET_MIISC_REG);
if (priv->has_phy) {
#define ENETSW_MDIOC_EXT_MASK (1 << 16)
--- a/drivers/net/ethernet/broadcom/bcm63xx_enet.c
+++ b/drivers/net/ethernet/broadcom/bcm63xx_enet.c
-@@ -2205,6 +2205,18 @@ static int bcm_enetsw_open(struct net_de
+@@ -2206,6 +2206,18 @@ static int bcm_enetsw_open(struct net_de
priv->sw_port_link[i] = 0;
}
#include <bcm63xx_dev_enet.h>
#include "bcm63xx_enet.h"
-@@ -1950,7 +1951,8 @@ static int bcm_enet_remove(struct platfo
+@@ -1951,7 +1952,8 @@ static int bcm_enet_remove(struct platfo
return 0;
}
.probe = bcm_enet_probe,
.remove = bcm_enet_remove,
.driver = {
-@@ -1959,6 +1961,42 @@ struct platform_driver bcm63xx_enet_driv
+@@ -1960,6 +1962,42 @@ struct platform_driver bcm63xx_enet_driv
},
};
/*
* switch mii access callbacks
*/
-@@ -2217,29 +2255,6 @@ static int bcm_enetsw_open(struct net_de
+@@ -2218,29 +2256,6 @@ static int bcm_enetsw_open(struct net_de
enetsw_writeb(priv, rgmii_ctrl, ENETSW_RGMII_CTRL_REG(i));
}
/* initialize flow control buffer allocation */
enet_dma_writel(priv, ENETDMA_BUFALLOC_FORCE_MASK | 0,
ENETDMA_BUFALLOC_REG(priv->rx_chan));
-@@ -2698,6 +2713,9 @@ static int bcm_enetsw_probe(struct platf
+@@ -2699,6 +2714,9 @@ static int bcm_enetsw_probe(struct platf
struct bcm63xx_enetsw_platform_data *pd;
struct resource *res_mem;
int ret, irq_rx, irq_tx;
if (!bcm_enet_shared_base[0])
return -EPROBE_DEFER;
-@@ -2780,6 +2798,43 @@ static int bcm_enetsw_probe(struct platf
+@@ -2781,6 +2799,43 @@ static int bcm_enetsw_probe(struct platf
priv->pdev = pdev;
priv->net_dev = dev;
return 0;
out_disable_clk:
-@@ -2801,6 +2856,9 @@ static int bcm_enetsw_remove(struct plat
+@@ -2802,6 +2857,9 @@ static int bcm_enetsw_remove(struct plat
priv = netdev_priv(dev);
unregister_netdev(dev);
--- a/drivers/net/ethernet/broadcom/bcm63xx_enet.c
+++ b/drivers/net/ethernet/broadcom/bcm63xx_enet.c
-@@ -2757,9 +2757,9 @@ static int bcm_enetsw_probe(struct platf
+@@ -2758,9 +2758,9 @@ static int bcm_enetsw_probe(struct platf
if (ret)
goto out;
--- a/drivers/net/ethernet/broadcom/bcm63xx_enet.c
+++ b/drivers/net/ethernet/broadcom/bcm63xx_enet.c
-@@ -2252,6 +2252,10 @@ static int bcm_enetsw_open(struct net_de
+@@ -2253,6 +2253,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;
return work_done;
--- a/drivers/net/ethernet/ti/cpsw.c
+++ b/drivers/net/ethernet/ti/cpsw.c
-@@ -843,7 +843,7 @@ static int cpsw_rx_poll(struct napi_stru
+@@ -844,7 +844,7 @@ static int cpsw_rx_poll(struct napi_stru
}
if (num_rx < budget) {
}
--- a/drivers/net/ethernet/toshiba/tc35815.c
+++ b/drivers/net/ethernet/toshiba/tc35815.c
-@@ -1639,7 +1639,7 @@ static int tc35815_poll(struct napi_stru
+@@ -1641,7 +1641,7 @@ static int tc35815_poll(struct napi_stru
spin_unlock(&lp->rx_lock);
if (received < budget) {
--- a/drivers/net/wireless/ath/ath10k/pci.c
+++ b/drivers/net/wireless/ath/ath10k/pci.c
-@@ -2804,7 +2804,7 @@ static int ath10k_pci_napi_poll(struct n
+@@ -2803,7 +2803,7 @@ static int ath10k_pci_napi_poll(struct n
done = ath10k_htt_txrx_compl_task(ar, budget);
if (done < budget) {
errors per {size} bytes".
--- a/drivers/mtd/maps/physmap_of.c
+++ b/drivers/mtd/maps/physmap_of.c
-@@ -113,47 +113,9 @@ static struct mtd_info *obsolete_probe(s
+@@ -104,47 +104,9 @@ static struct mtd_info *obsolete_probe(s
static const char * const part_probe_types_def[] = {
"cmdlinepart", "RedBoot", "ofpart", "ofoldpart", NULL };
const struct of_device_id *match;
struct device_node *dp = dev->dev.of_node;
struct resource res;
-@@ -317,14 +279,8 @@ static int of_flash_probe(struct platfor
+@@ -300,14 +262,8 @@ static int of_flash_probe(struct platfor
info->cmtd->dev.parent = &dev->dev;
mtd_set_of_node(info->cmtd, dp);
--- a/drivers/i2c/busses/Kconfig
+++ b/drivers/i2c/busses/Kconfig
-@@ -643,6 +643,16 @@ config I2C_MESON
+@@ -644,6 +644,16 @@ config I2C_MESON
If you say yes to this option, support will be included for the
I2C interface on the Amlogic Meson family of SoCs.
#include <linux/of.h>
#include <linux/of_address.h>
#include <linux/of_platform.h>
-@@ -209,6 +210,9 @@ static int of_flash_probe(struct platfor
+@@ -201,6 +202,9 @@ static int of_flash_probe(struct platfor
return err;
}
+ if (of_property_read_bool(dp->parent, "big-endian"))
+ info->list[i].map.swap = CFI_BIG_ENDIAN;
+
- err = -ENOMEM;
- info->list[i].map.virt = ioremap(info->list[i].map.phys,
- info->list[i].map.size);
+ simple_map_init(&info->list[i].map);
+
+ /*
--- a/drivers/mtd/nand/Kconfig
+++ b/drivers/mtd/nand/Kconfig
@@ -438,7 +438,7 @@ config MTD_NAND_FSL_ELBC