mirror of
https://github.com/coolsnowwolf/lede.git
synced 2025-04-16 04:13:31 +00:00
kernel: bump 5.10 to 5.10.157 (#10561)
Manually rebased: backport-5.10/610-v5.13-32-net-ethernet-mtk_eth_soc-add-support-for-initializin.patch hack-5.10/645-netfilter-connmark-introduce-set-dscpmark.patch[1] All other patches automatically rebased 1. Rebase by Kevin 'ldir' Darbyshire-Bryant<ldir@darbyshire-bryant.me.uk> Signed-off-by: Linhui Liu <liulinhui36@gmail.com> Signed-off-by: Linhui Liu <liulinhui36@gmail.com>
This commit is contained in:
parent
944341aaf2
commit
7468945d5b
@ -1,2 +1,2 @@
|
|||||||
LINUX_VERSION-5.10 = .156
|
LINUX_VERSION-5.10 = .157
|
||||||
LINUX_KERNEL_HASH-5.10.156 = 679e9964ca720027967391b61db990ceb7868e93e203f87724f18310f4955923
|
LINUX_KERNEL_HASH-5.10.157 = fc4cd7c0777ed53f1350e73877e9918df3c40d8e8abe93c6e1a0eb21556d327f
|
||||||
|
@ -258,7 +258,7 @@ SVN-Revision: 35130
|
|||||||
#include <linux/uaccess.h>
|
#include <linux/uaccess.h>
|
||||||
#include <linux/ipv6.h>
|
#include <linux/ipv6.h>
|
||||||
#include <linux/icmpv6.h>
|
#include <linux/icmpv6.h>
|
||||||
@@ -924,10 +925,10 @@ static void tcp_v6_send_response(const s
|
@@ -926,10 +927,10 @@ static void tcp_v6_send_response(const s
|
||||||
topt = (__be32 *)(t1 + 1);
|
topt = (__be32 *)(t1 + 1);
|
||||||
|
|
||||||
if (tsecr) {
|
if (tsecr) {
|
||||||
|
@ -58,7 +58,7 @@ Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
|
|||||||
}
|
}
|
||||||
|
|
||||||
static int nf_flow_table_block_setup(struct nf_flowtable *flowtable,
|
static int nf_flow_table_block_setup(struct nf_flowtable *flowtable,
|
||||||
@@ -1013,15 +1023,33 @@ EXPORT_SYMBOL_GPL(nf_flow_table_offload_
|
@@ -1017,15 +1027,33 @@ EXPORT_SYMBOL_GPL(nf_flow_table_offload_
|
||||||
|
|
||||||
int nf_flow_table_offload_init(void)
|
int nf_flow_table_offload_init(void)
|
||||||
{
|
{
|
||||||
|
@ -145,7 +145,7 @@ Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
|
|||||||
const struct net_bridge *br)
|
const struct net_bridge *br)
|
||||||
--- a/net/bridge/br_vlan.c
|
--- a/net/bridge/br_vlan.c
|
||||||
+++ b/net/bridge/br_vlan.c
|
+++ b/net/bridge/br_vlan.c
|
||||||
@@ -1327,6 +1327,59 @@ int br_vlan_get_pvid_rcu(const struct ne
|
@@ -1350,6 +1350,59 @@ int br_vlan_get_pvid_rcu(const struct ne
|
||||||
}
|
}
|
||||||
EXPORT_SYMBOL_GPL(br_vlan_get_pvid_rcu);
|
EXPORT_SYMBOL_GPL(br_vlan_get_pvid_rcu);
|
||||||
|
|
||||||
|
@ -57,7 +57,7 @@ Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
|
|||||||
break;
|
break;
|
||||||
--- a/net/bridge/br_vlan.c
|
--- a/net/bridge/br_vlan.c
|
||||||
+++ b/net/bridge/br_vlan.c
|
+++ b/net/bridge/br_vlan.c
|
||||||
@@ -1374,6 +1374,8 @@ int br_vlan_fill_forward_path_mode(struc
|
@@ -1397,6 +1397,8 @@ int br_vlan_fill_forward_path_mode(struc
|
||||||
|
|
||||||
if (path->bridge.vlan_mode == DEV_PATH_BR_VLAN_TAG)
|
if (path->bridge.vlan_mode == DEV_PATH_BR_VLAN_TAG)
|
||||||
path->bridge.vlan_mode = DEV_PATH_BR_VLAN_KEEP;
|
path->bridge.vlan_mode = DEV_PATH_BR_VLAN_KEEP;
|
||||||
|
@ -27,7 +27,7 @@ Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
|
|||||||
obj-$(CONFIG_NET_MEDIATEK_STAR_EMAC) += mtk_star_emac.o
|
obj-$(CONFIG_NET_MEDIATEK_STAR_EMAC) += mtk_star_emac.o
|
||||||
--- a/drivers/net/ethernet/mediatek/mtk_eth_soc.c
|
--- a/drivers/net/ethernet/mediatek/mtk_eth_soc.c
|
||||||
+++ b/drivers/net/ethernet/mediatek/mtk_eth_soc.c
|
+++ b/drivers/net/ethernet/mediatek/mtk_eth_soc.c
|
||||||
@@ -2299,12 +2299,17 @@ static int mtk_open(struct net_device *d
|
@@ -2299,15 +2299,20 @@ static int mtk_open(struct net_device *d
|
||||||
|
|
||||||
/* we run 2 netdevs on the same dma ring so we only bring it up once */
|
/* we run 2 netdevs on the same dma ring so we only bring it up once */
|
||||||
if (!refcount_read(ð->dma_refcnt)) {
|
if (!refcount_read(ð->dma_refcnt)) {
|
||||||
@ -37,7 +37,10 @@ Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
|
|||||||
|
|
||||||
+ err = mtk_start_dma(eth);
|
+ err = mtk_start_dma(eth);
|
||||||
if (err)
|
if (err)
|
||||||
|
if (err) {
|
||||||
|
phylink_disconnect_phy(mac->phylink);
|
||||||
return err;
|
return err;
|
||||||
|
}
|
||||||
|
|
||||||
- mtk_gdm_config(eth, MTK_GDMA_TO_PDMA);
|
- mtk_gdm_config(eth, MTK_GDMA_TO_PDMA);
|
||||||
+ if (eth->soc->offload_version && mtk_ppe_start(ð->ppe) == 0)
|
+ if (eth->soc->offload_version && mtk_ppe_start(ð->ppe) == 0)
|
||||||
@ -47,7 +50,7 @@ Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
|
|||||||
|
|
||||||
napi_enable(ð->tx_napi);
|
napi_enable(ð->tx_napi);
|
||||||
napi_enable(ð->rx_napi);
|
napi_enable(ð->rx_napi);
|
||||||
@@ -2371,6 +2376,9 @@ static int mtk_stop(struct net_device *d
|
@@ -2374,6 +2379,9 @@ static int mtk_stop(struct net_device *d
|
||||||
|
|
||||||
mtk_dma_free(eth);
|
mtk_dma_free(eth);
|
||||||
|
|
||||||
@ -57,7 +60,7 @@ Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
|
|||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -3099,6 +3107,13 @@ static int mtk_probe(struct platform_dev
|
@@ -3102,6 +3110,13 @@ static int mtk_probe(struct platform_dev
|
||||||
goto err_free_dev;
|
goto err_free_dev;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -71,7 +74,7 @@ Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
|
|||||||
for (i = 0; i < MTK_MAX_DEVS; i++) {
|
for (i = 0; i < MTK_MAX_DEVS; i++) {
|
||||||
if (!eth->netdev[i])
|
if (!eth->netdev[i])
|
||||||
continue;
|
continue;
|
||||||
@@ -3173,6 +3188,7 @@ static const struct mtk_soc_data mt7621_
|
@@ -3176,6 +3191,7 @@ static const struct mtk_soc_data mt7621_
|
||||||
.hw_features = MTK_HW_FEATURES,
|
.hw_features = MTK_HW_FEATURES,
|
||||||
.required_clks = MT7621_CLKS_BITMAP,
|
.required_clks = MT7621_CLKS_BITMAP,
|
||||||
.required_pctl = false,
|
.required_pctl = false,
|
||||||
@ -79,7 +82,7 @@ Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
|
|||||||
};
|
};
|
||||||
|
|
||||||
static const struct mtk_soc_data mt7622_data = {
|
static const struct mtk_soc_data mt7622_data = {
|
||||||
@@ -3181,6 +3197,7 @@ static const struct mtk_soc_data mt7622_
|
@@ -3184,6 +3200,7 @@ static const struct mtk_soc_data mt7622_
|
||||||
.hw_features = MTK_HW_FEATURES,
|
.hw_features = MTK_HW_FEATURES,
|
||||||
.required_clks = MT7622_CLKS_BITMAP,
|
.required_clks = MT7622_CLKS_BITMAP,
|
||||||
.required_pctl = false,
|
.required_pctl = false,
|
||||||
|
@ -21,7 +21,7 @@ Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
|
|||||||
obj-$(CONFIG_NET_MEDIATEK_STAR_EMAC) += mtk_star_emac.o
|
obj-$(CONFIG_NET_MEDIATEK_STAR_EMAC) += mtk_star_emac.o
|
||||||
--- a/drivers/net/ethernet/mediatek/mtk_eth_soc.c
|
--- a/drivers/net/ethernet/mediatek/mtk_eth_soc.c
|
||||||
+++ b/drivers/net/ethernet/mediatek/mtk_eth_soc.c
|
+++ b/drivers/net/ethernet/mediatek/mtk_eth_soc.c
|
||||||
@@ -2854,6 +2854,7 @@ static const struct net_device_ops mtk_n
|
@@ -2857,6 +2857,7 @@ static const struct net_device_ops mtk_n
|
||||||
#ifdef CONFIG_NET_POLL_CONTROLLER
|
#ifdef CONFIG_NET_POLL_CONTROLLER
|
||||||
.ndo_poll_controller = mtk_poll_controller,
|
.ndo_poll_controller = mtk_poll_controller,
|
||||||
#endif
|
#endif
|
||||||
@ -29,7 +29,7 @@ Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
|
|||||||
};
|
};
|
||||||
|
|
||||||
static int mtk_add_mac(struct mtk_eth *eth, struct device_node *np)
|
static int mtk_add_mac(struct mtk_eth *eth, struct device_node *np)
|
||||||
@@ -3112,6 +3113,10 @@ static int mtk_probe(struct platform_dev
|
@@ -3115,6 +3116,10 @@ static int mtk_probe(struct platform_dev
|
||||||
eth->base + MTK_ETH_PPE_BASE, 2);
|
eth->base + MTK_ETH_PPE_BASE, 2);
|
||||||
if (err)
|
if (err)
|
||||||
goto err_free_dev;
|
goto err_free_dev;
|
||||||
|
@ -103,7 +103,7 @@ Signed-off-by: David S. Miller <davem@davemloft.net>
|
|||||||
if (likely(napi_schedule_prep(ð->tx_napi))) {
|
if (likely(napi_schedule_prep(ð->tx_napi))) {
|
||||||
__napi_schedule(ð->tx_napi);
|
__napi_schedule(ð->tx_napi);
|
||||||
mtk_tx_irq_disable(eth, MTK_TX_DONE_INT);
|
mtk_tx_irq_disable(eth, MTK_TX_DONE_INT);
|
||||||
@@ -2366,6 +2383,9 @@ static int mtk_stop(struct net_device *d
|
@@ -2369,6 +2386,9 @@ static int mtk_stop(struct net_device *d
|
||||||
napi_disable(ð->tx_napi);
|
napi_disable(ð->tx_napi);
|
||||||
napi_disable(ð->rx_napi);
|
napi_disable(ð->rx_napi);
|
||||||
|
|
||||||
@ -113,7 +113,7 @@ Signed-off-by: David S. Miller <davem@davemloft.net>
|
|||||||
if (MTK_HAS_CAPS(eth->soc->caps, MTK_QDMA))
|
if (MTK_HAS_CAPS(eth->soc->caps, MTK_QDMA))
|
||||||
mtk_stop_dma(eth, MTK_QDMA_GLO_CFG);
|
mtk_stop_dma(eth, MTK_QDMA_GLO_CFG);
|
||||||
mtk_stop_dma(eth, MTK_PDMA_GLO_CFG);
|
mtk_stop_dma(eth, MTK_PDMA_GLO_CFG);
|
||||||
@@ -2418,6 +2438,64 @@ err_disable_clks:
|
@@ -2421,6 +2441,64 @@ err_disable_clks:
|
||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -178,7 +178,7 @@ Signed-off-by: David S. Miller <davem@davemloft.net>
|
|||||||
static int mtk_hw_init(struct mtk_eth *eth)
|
static int mtk_hw_init(struct mtk_eth *eth)
|
||||||
{
|
{
|
||||||
int i, val, ret;
|
int i, val, ret;
|
||||||
@@ -2439,9 +2517,6 @@ static int mtk_hw_init(struct mtk_eth *e
|
@@ -2442,9 +2520,6 @@ static int mtk_hw_init(struct mtk_eth *e
|
||||||
goto err_disable_pm;
|
goto err_disable_pm;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -188,7 +188,7 @@ Signed-off-by: David S. Miller <davem@davemloft.net>
|
|||||||
/* disable delay and normal interrupt */
|
/* disable delay and normal interrupt */
|
||||||
mtk_tx_irq_disable(eth, ~0);
|
mtk_tx_irq_disable(eth, ~0);
|
||||||
mtk_rx_irq_disable(eth, ~0);
|
mtk_rx_irq_disable(eth, ~0);
|
||||||
@@ -2480,11 +2555,11 @@ static int mtk_hw_init(struct mtk_eth *e
|
@@ -2483,11 +2558,11 @@ static int mtk_hw_init(struct mtk_eth *e
|
||||||
/* Enable RX VLan Offloading */
|
/* Enable RX VLan Offloading */
|
||||||
mtk_w32(eth, 1, MTK_CDMP_EG_CTRL);
|
mtk_w32(eth, 1, MTK_CDMP_EG_CTRL);
|
||||||
|
|
||||||
@ -203,7 +203,7 @@ Signed-off-by: David S. Miller <davem@davemloft.net>
|
|||||||
mtk_tx_irq_disable(eth, ~0);
|
mtk_tx_irq_disable(eth, ~0);
|
||||||
mtk_rx_irq_disable(eth, ~0);
|
mtk_rx_irq_disable(eth, ~0);
|
||||||
|
|
||||||
@@ -2989,6 +3064,13 @@ static int mtk_probe(struct platform_dev
|
@@ -2992,6 +3067,13 @@ static int mtk_probe(struct platform_dev
|
||||||
spin_lock_init(ð->page_lock);
|
spin_lock_init(ð->page_lock);
|
||||||
spin_lock_init(ð->tx_irq_lock);
|
spin_lock_init(ð->tx_irq_lock);
|
||||||
spin_lock_init(ð->rx_irq_lock);
|
spin_lock_init(ð->rx_irq_lock);
|
||||||
|
@ -48,7 +48,7 @@ Signed-off-by: Jakub Kicinski <kuba@kernel.org>
|
|||||||
|
|
||||||
return buf_size;
|
return buf_size;
|
||||||
}
|
}
|
||||||
@@ -2626,6 +2626,35 @@ static void mtk_uninit(struct net_device
|
@@ -2629,6 +2629,35 @@ static void mtk_uninit(struct net_device
|
||||||
mtk_rx_irq_disable(eth, ~0);
|
mtk_rx_irq_disable(eth, ~0);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -84,7 +84,7 @@ Signed-off-by: Jakub Kicinski <kuba@kernel.org>
|
|||||||
static int mtk_do_ioctl(struct net_device *dev, struct ifreq *ifr, int cmd)
|
static int mtk_do_ioctl(struct net_device *dev, struct ifreq *ifr, int cmd)
|
||||||
{
|
{
|
||||||
struct mtk_mac *mac = netdev_priv(dev);
|
struct mtk_mac *mac = netdev_priv(dev);
|
||||||
@@ -2922,6 +2951,7 @@ static const struct net_device_ops mtk_n
|
@@ -2925,6 +2954,7 @@ static const struct net_device_ops mtk_n
|
||||||
.ndo_set_mac_address = mtk_set_mac_address,
|
.ndo_set_mac_address = mtk_set_mac_address,
|
||||||
.ndo_validate_addr = eth_validate_addr,
|
.ndo_validate_addr = eth_validate_addr,
|
||||||
.ndo_do_ioctl = mtk_do_ioctl,
|
.ndo_do_ioctl = mtk_do_ioctl,
|
||||||
@ -92,7 +92,7 @@ Signed-off-by: Jakub Kicinski <kuba@kernel.org>
|
|||||||
.ndo_tx_timeout = mtk_tx_timeout,
|
.ndo_tx_timeout = mtk_tx_timeout,
|
||||||
.ndo_get_stats64 = mtk_get_stats64,
|
.ndo_get_stats64 = mtk_get_stats64,
|
||||||
.ndo_fix_features = mtk_fix_features,
|
.ndo_fix_features = mtk_fix_features,
|
||||||
@@ -3024,7 +3054,10 @@ static int mtk_add_mac(struct mtk_eth *e
|
@@ -3027,7 +3057,10 @@ static int mtk_add_mac(struct mtk_eth *e
|
||||||
eth->netdev[id]->irq = eth->irq[0];
|
eth->netdev[id]->irq = eth->irq[0];
|
||||||
eth->netdev[id]->dev.of_node = np;
|
eth->netdev[id]->dev.of_node = np;
|
||||||
|
|
||||||
|
@ -476,7 +476,7 @@ Signed-off-by: David S. Miller <davem@davemloft.net>
|
|||||||
p->phy_np = of_parse_phandle(pdev->dev.of_node, "phy-handle", 0);
|
p->phy_np = of_parse_phandle(pdev->dev.of_node, "phy-handle", 0);
|
||||||
--- a/drivers/net/ethernet/cavium/thunder/thunder_bgx.c
|
--- a/drivers/net/ethernet/cavium/thunder/thunder_bgx.c
|
||||||
+++ b/drivers/net/ethernet/cavium/thunder/thunder_bgx.c
|
+++ b/drivers/net/ethernet/cavium/thunder/thunder_bgx.c
|
||||||
@@ -1474,7 +1474,6 @@ static int bgx_init_of_phy(struct bgx *b
|
@@ -1476,7 +1476,6 @@ static int bgx_init_of_phy(struct bgx *b
|
||||||
device_for_each_child_node(&bgx->pdev->dev, fwn) {
|
device_for_each_child_node(&bgx->pdev->dev, fwn) {
|
||||||
struct phy_device *pd;
|
struct phy_device *pd;
|
||||||
struct device_node *phy_np;
|
struct device_node *phy_np;
|
||||||
@ -484,7 +484,7 @@ Signed-off-by: David S. Miller <davem@davemloft.net>
|
|||||||
|
|
||||||
/* Should always be an OF node. But if it is not, we
|
/* Should always be an OF node. But if it is not, we
|
||||||
* cannot handle it, so exit the loop.
|
* cannot handle it, so exit the loop.
|
||||||
@@ -1483,9 +1482,7 @@ static int bgx_init_of_phy(struct bgx *b
|
@@ -1485,9 +1484,7 @@ static int bgx_init_of_phy(struct bgx *b
|
||||||
if (!node)
|
if (!node)
|
||||||
break;
|
break;
|
||||||
|
|
||||||
@ -895,7 +895,7 @@ Signed-off-by: David S. Miller <davem@davemloft.net>
|
|||||||
|
|
||||||
--- a/drivers/net/ethernet/mediatek/mtk_eth_soc.c
|
--- a/drivers/net/ethernet/mediatek/mtk_eth_soc.c
|
||||||
+++ b/drivers/net/ethernet/mediatek/mtk_eth_soc.c
|
+++ b/drivers/net/ethernet/mediatek/mtk_eth_soc.c
|
||||||
@@ -2600,14 +2600,11 @@ static int __init mtk_init(struct net_de
|
@@ -2603,14 +2603,11 @@ static int __init mtk_init(struct net_de
|
||||||
{
|
{
|
||||||
struct mtk_mac *mac = netdev_priv(dev);
|
struct mtk_mac *mac = netdev_priv(dev);
|
||||||
struct mtk_eth *eth = mac->hw;
|
struct mtk_eth *eth = mac->hw;
|
||||||
|
@ -109,7 +109,7 @@ Signed-off-by: Kevin Darbyshire-Bryant <ldir@darbyshire-bryant.me.uk>
|
|||||||
__u8 invert;
|
__u8 invert;
|
||||||
--- a/net/netfilter/xt_connmark.c
|
--- a/net/netfilter/xt_connmark.c
|
||||||
+++ b/net/netfilter/xt_connmark.c
|
+++ b/net/netfilter/xt_connmark.c
|
||||||
@@ -24,12 +24,13 @@ MODULE_ALIAS("ipt_connmark");
|
@@ -24,13 +24,13 @@ MODULE_ALIAS("ipt_connmark");
|
||||||
MODULE_ALIAS("ip6t_connmark");
|
MODULE_ALIAS("ip6t_connmark");
|
||||||
|
|
||||||
static unsigned int
|
static unsigned int
|
||||||
@ -120,20 +120,22 @@ Signed-off-by: Kevin Darbyshire-Bryant <ldir@darbyshire-bryant.me.uk>
|
|||||||
u_int32_t new_targetmark;
|
u_int32_t new_targetmark;
|
||||||
struct nf_conn *ct;
|
struct nf_conn *ct;
|
||||||
u_int32_t newmark;
|
u_int32_t newmark;
|
||||||
|
- u_int32_t oldmark;
|
||||||
+ u_int8_t dscp;
|
+ u_int8_t dscp;
|
||||||
|
|
||||||
ct = nf_ct_get(skb, &ctinfo);
|
ct = nf_ct_get(skb, &ctinfo);
|
||||||
if (ct == NULL)
|
if (ct == NULL)
|
||||||
@@ -37,12 +38,24 @@ connmark_tg_shift(struct sk_buff *skb, c
|
@@ -38,13 +38,24 @@ connmark_tg_shift(struct sk_buff *skb, c
|
||||||
|
|
||||||
switch (info->mode) {
|
switch (info->mode) {
|
||||||
case XT_CONNMARK_SET:
|
case XT_CONNMARK_SET:
|
||||||
- newmark = (ct->mark & ~info->ctmask) ^ info->ctmark;
|
- oldmark = READ_ONCE(ct->mark);
|
||||||
|
- newmark = (oldmark & ~info->ctmask) ^ info->ctmark;
|
||||||
- if (info->shift_dir == D_SHIFT_RIGHT)
|
- if (info->shift_dir == D_SHIFT_RIGHT)
|
||||||
- newmark >>= info->shift_bits;
|
- newmark >>= info->shift_bits;
|
||||||
- else
|
- else
|
||||||
- newmark <<= info->shift_bits;
|
- newmark <<= info->shift_bits;
|
||||||
+ newmark = ct->mark;
|
+ newmark = READ_ONCE(ct->mark);
|
||||||
+ if (info->func & XT_CONNMARK_VALUE) {
|
+ if (info->func & XT_CONNMARK_VALUE) {
|
||||||
+ newmark = (newmark & ~info->ctmask) ^ info->ctmark;
|
+ newmark = (newmark & ~info->ctmask) ^ info->ctmark;
|
||||||
+ if (info->shift_dir == D_SHIFT_RIGHT)
|
+ if (info->shift_dir == D_SHIFT_RIGHT)
|
||||||
@ -151,10 +153,10 @@ Signed-off-by: Kevin Darbyshire-Bryant <ldir@darbyshire-bryant.me.uk>
|
|||||||
+ newmark = (newmark & ~info->ctmark) |
|
+ newmark = (newmark & ~info->ctmark) |
|
||||||
+ (info->ctmask | (dscp << info->shift_bits));
|
+ (info->ctmask | (dscp << info->shift_bits));
|
||||||
+ }
|
+ }
|
||||||
if (ct->mark != newmark) {
|
if (READ_ONCE(ct->mark) != newmark) {
|
||||||
ct->mark = newmark;
|
WRITE_ONCE(ct->mark, newmark);
|
||||||
nf_conntrack_event_cache(IPCT_MARK, ct);
|
nf_conntrack_event_cache(IPCT_MARK, ct);
|
||||||
@@ -81,20 +94,36 @@ static unsigned int
|
@@ -83,20 +94,36 @@ static unsigned int
|
||||||
connmark_tg(struct sk_buff *skb, const struct xt_action_param *par)
|
connmark_tg(struct sk_buff *skb, const struct xt_action_param *par)
|
||||||
{
|
{
|
||||||
const struct xt_connmark_tginfo1 *info = par->targinfo;
|
const struct xt_connmark_tginfo1 *info = par->targinfo;
|
||||||
@ -193,7 +195,7 @@ Signed-off-by: Kevin Darbyshire-Bryant <ldir@darbyshire-bryant.me.uk>
|
|||||||
|
|
||||||
return connmark_tg_shift(skb, info);
|
return connmark_tg_shift(skb, info);
|
||||||
}
|
}
|
||||||
@@ -165,6 +194,16 @@ static struct xt_target connmark_tg_reg[
|
@@ -167,6 +194,16 @@ static struct xt_target connmark_tg_reg[
|
||||||
.targetsize = sizeof(struct xt_connmark_tginfo2),
|
.targetsize = sizeof(struct xt_connmark_tginfo2),
|
||||||
.destroy = connmark_tg_destroy,
|
.destroy = connmark_tg_destroy,
|
||||||
.me = THIS_MODULE,
|
.me = THIS_MODULE,
|
||||||
|
@ -122,7 +122,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
|
|||||||
u64 res;
|
u64 res;
|
||||||
--- a/net/ipv4/Kconfig
|
--- a/net/ipv4/Kconfig
|
||||||
+++ b/net/ipv4/Kconfig
|
+++ b/net/ipv4/Kconfig
|
||||||
@@ -414,6 +414,7 @@ config INET_TUNNEL
|
@@ -424,6 +424,7 @@ config INET_TUNNEL
|
||||||
|
|
||||||
config INET_DIAG
|
config INET_DIAG
|
||||||
tristate "INET: socket monitoring interface"
|
tristate "INET: socket monitoring interface"
|
||||||
|
@ -341,7 +341,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
|
|||||||
|
|
||||||
--- a/net/ipv4/fib_trie.c
|
--- a/net/ipv4/fib_trie.c
|
||||||
+++ b/net/ipv4/fib_trie.c
|
+++ b/net/ipv4/fib_trie.c
|
||||||
@@ -2986,11 +2986,13 @@ static const struct seq_operations fib_r
|
@@ -2988,11 +2988,13 @@ static const struct seq_operations fib_r
|
||||||
|
|
||||||
int __net_init fib_proc_init(struct net *net)
|
int __net_init fib_proc_init(struct net *net)
|
||||||
{
|
{
|
||||||
@ -357,7 +357,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
|
|||||||
fib_triestat_seq_show, NULL))
|
fib_triestat_seq_show, NULL))
|
||||||
goto out2;
|
goto out2;
|
||||||
|
|
||||||
@@ -3001,17 +3003,21 @@ int __net_init fib_proc_init(struct net
|
@@ -3003,17 +3005,21 @@ int __net_init fib_proc_init(struct net
|
||||||
return 0;
|
return 0;
|
||||||
|
|
||||||
out3:
|
out3:
|
||||||
|
@ -294,7 +294,7 @@ Signed-off-by: Zhi Chen <zhichen@codeaurora.org>
|
|||||||
struct nf_conn *ct = item->ct;
|
struct nf_conn *ct = item->ct;
|
||||||
struct sk_buff *skb;
|
struct sk_buff *skb;
|
||||||
unsigned int type;
|
unsigned int type;
|
||||||
@@ -3752,9 +3759,15 @@ static int ctnetlink_stat_exp_cpu(struct
|
@@ -3756,9 +3763,15 @@ static int ctnetlink_stat_exp_cpu(struct
|
||||||
}
|
}
|
||||||
|
|
||||||
#ifdef CONFIG_NF_CONNTRACK_EVENTS
|
#ifdef CONFIG_NF_CONNTRACK_EVENTS
|
||||||
|
@ -66,7 +66,7 @@ Signed-off-by: Jonas Gorski <jogo@openwrt.org>
|
|||||||
static void rt_fibinfo_free(struct rtable __rcu **rtp)
|
static void rt_fibinfo_free(struct rtable __rcu **rtp)
|
||||||
--- a/net/ipv4/fib_trie.c
|
--- a/net/ipv4/fib_trie.c
|
||||||
+++ b/net/ipv4/fib_trie.c
|
+++ b/net/ipv4/fib_trie.c
|
||||||
@@ -2734,6 +2734,7 @@ static const char *const rtn_type_names[
|
@@ -2736,6 +2736,7 @@ static const char *const rtn_type_names[
|
||||||
[RTN_THROW] = "THROW",
|
[RTN_THROW] = "THROW",
|
||||||
[RTN_NAT] = "NAT",
|
[RTN_NAT] = "NAT",
|
||||||
[RTN_XRESOLVE] = "XRESOLVE",
|
[RTN_XRESOLVE] = "XRESOLVE",
|
||||||
|
@ -205,7 +205,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
|
|||||||
MTK_DMA_SIZE * sizeof(struct mtk_tx_dma),
|
MTK_DMA_SIZE * sizeof(struct mtk_tx_dma),
|
||||||
eth->scratch_ring,
|
eth->scratch_ring,
|
||||||
eth->phy_scratch_ring);
|
eth->phy_scratch_ring);
|
||||||
@@ -2502,6 +2503,8 @@ static void mtk_dim_tx(struct work_struc
|
@@ -2505,6 +2506,8 @@ static void mtk_dim_tx(struct work_struc
|
||||||
|
|
||||||
static int mtk_hw_init(struct mtk_eth *eth)
|
static int mtk_hw_init(struct mtk_eth *eth)
|
||||||
{
|
{
|
||||||
@ -214,7 +214,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
|
|||||||
int i, val, ret;
|
int i, val, ret;
|
||||||
|
|
||||||
if (test_and_set_bit(MTK_HW_INIT, ð->state))
|
if (test_and_set_bit(MTK_HW_INIT, ð->state))
|
||||||
@@ -2514,6 +2517,10 @@ static int mtk_hw_init(struct mtk_eth *e
|
@@ -2517,6 +2520,10 @@ static int mtk_hw_init(struct mtk_eth *e
|
||||||
if (ret)
|
if (ret)
|
||||||
goto err_disable_pm;
|
goto err_disable_pm;
|
||||||
|
|
||||||
@ -225,7 +225,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
|
|||||||
if (MTK_HAS_CAPS(eth->soc->caps, MTK_SOC_MT7628)) {
|
if (MTK_HAS_CAPS(eth->soc->caps, MTK_SOC_MT7628)) {
|
||||||
ret = device_reset(eth->dev);
|
ret = device_reset(eth->dev);
|
||||||
if (ret) {
|
if (ret) {
|
||||||
@@ -3063,6 +3070,35 @@ free_netdev:
|
@@ -3066,6 +3073,35 @@ free_netdev:
|
||||||
return err;
|
return err;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -261,7 +261,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
|
|||||||
static int mtk_probe(struct platform_device *pdev)
|
static int mtk_probe(struct platform_device *pdev)
|
||||||
{
|
{
|
||||||
struct device_node *mac_np;
|
struct device_node *mac_np;
|
||||||
@@ -3076,6 +3112,7 @@ static int mtk_probe(struct platform_dev
|
@@ -3079,6 +3115,7 @@ static int mtk_probe(struct platform_dev
|
||||||
eth->soc = of_device_get_match_data(&pdev->dev);
|
eth->soc = of_device_get_match_data(&pdev->dev);
|
||||||
|
|
||||||
eth->dev = &pdev->dev;
|
eth->dev = &pdev->dev;
|
||||||
@ -269,7 +269,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
|
|||||||
eth->base = devm_platform_ioremap_resource(pdev, 0);
|
eth->base = devm_platform_ioremap_resource(pdev, 0);
|
||||||
if (IS_ERR(eth->base))
|
if (IS_ERR(eth->base))
|
||||||
return PTR_ERR(eth->base);
|
return PTR_ERR(eth->base);
|
||||||
@@ -3124,6 +3161,16 @@ static int mtk_probe(struct platform_dev
|
@@ -3127,6 +3164,16 @@ static int mtk_probe(struct platform_dev
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -56,7 +56,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
|
|||||||
|
|
||||||
static int mtk_msg_level = -1;
|
static int mtk_msg_level = -1;
|
||||||
module_param_named(msg_level, mtk_msg_level, int, 0);
|
module_param_named(msg_level, mtk_msg_level, int, 0);
|
||||||
@@ -3193,6 +3194,22 @@ static int mtk_probe(struct platform_dev
|
@@ -3196,6 +3197,22 @@ static int mtk_probe(struct platform_dev
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -10,16 +10,16 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
|
|||||||
|
|
||||||
--- a/drivers/net/ethernet/mediatek/mtk_eth_soc.c
|
--- a/drivers/net/ethernet/mediatek/mtk_eth_soc.c
|
||||||
+++ b/drivers/net/ethernet/mediatek/mtk_eth_soc.c
|
+++ b/drivers/net/ethernet/mediatek/mtk_eth_soc.c
|
||||||
@@ -2325,7 +2325,7 @@ static int mtk_open(struct net_device *d
|
@@ -2328,7 +2328,7 @@ static int mtk_open(struct net_device *d
|
||||||
if (err)
|
|
||||||
return err;
|
return err;
|
||||||
|
}
|
||||||
|
|
||||||
- if (eth->soc->offload_version && mtk_ppe_start(ð->ppe) == 0)
|
- if (eth->soc->offload_version && mtk_ppe_start(ð->ppe) == 0)
|
||||||
+ if (eth->soc->offload_version && mtk_ppe_start(eth->ppe) == 0)
|
+ if (eth->soc->offload_version && mtk_ppe_start(eth->ppe) == 0)
|
||||||
gdm_config = MTK_GDMA_TO_PPE;
|
gdm_config = MTK_GDMA_TO_PPE;
|
||||||
|
|
||||||
mtk_gdm_config(eth, gdm_config);
|
mtk_gdm_config(eth, gdm_config);
|
||||||
@@ -2399,7 +2399,7 @@ static int mtk_stop(struct net_device *d
|
@@ -2402,7 +2402,7 @@ static int mtk_stop(struct net_device *d
|
||||||
mtk_dma_free(eth);
|
mtk_dma_free(eth);
|
||||||
|
|
||||||
if (eth->soc->offload_version)
|
if (eth->soc->offload_version)
|
||||||
@ -28,7 +28,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
|
|||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
@@ -3285,10 +3285,11 @@ static int mtk_probe(struct platform_dev
|
@@ -3288,10 +3288,11 @@ static int mtk_probe(struct platform_dev
|
||||||
}
|
}
|
||||||
|
|
||||||
if (eth->soc->offload_version) {
|
if (eth->soc->offload_version) {
|
||||||
|
@ -54,7 +54,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
|
|||||||
if (netdev->features & NETIF_F_HW_VLAN_CTAG_RX &&
|
if (netdev->features & NETIF_F_HW_VLAN_CTAG_RX &&
|
||||||
(trxd.rxd2 & RX_DMA_VTAG))
|
(trxd.rxd2 & RX_DMA_VTAG))
|
||||||
__vlan_hwaccel_put_tag(skb, htons(ETH_P_8021Q),
|
__vlan_hwaccel_put_tag(skb, htons(ETH_P_8021Q),
|
||||||
@@ -3285,7 +3291,7 @@ static int mtk_probe(struct platform_dev
|
@@ -3288,7 +3294,7 @@ static int mtk_probe(struct platform_dev
|
||||||
}
|
}
|
||||||
|
|
||||||
if (eth->soc->offload_version) {
|
if (eth->soc->offload_version) {
|
||||||
|
@ -30,7 +30,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
|
|||||||
}
|
}
|
||||||
|
|
||||||
return IRQ_HANDLED;
|
return IRQ_HANDLED;
|
||||||
@@ -3320,6 +3320,8 @@ static int mtk_probe(struct platform_dev
|
@@ -3323,6 +3323,8 @@ static int mtk_probe(struct platform_dev
|
||||||
* for NAPI to work
|
* for NAPI to work
|
||||||
*/
|
*/
|
||||||
init_dummy_netdev(ð->dummy_dev);
|
init_dummy_netdev(ð->dummy_dev);
|
||||||
|
@ -22,7 +22,7 @@ Signed-off-by: Tobias Waldekranz <tobias@waldekranz.com>
|
|||||||
|
|
||||||
--- a/include/net/switchdev.h
|
--- a/include/net/switchdev.h
|
||||||
+++ b/include/net/switchdev.h
|
+++ b/include/net/switchdev.h
|
||||||
@@ -224,6 +224,7 @@ struct switchdev_notifier_fdb_info {
|
@@ -226,6 +226,7 @@ struct switchdev_notifier_fdb_info {
|
||||||
const unsigned char *addr;
|
const unsigned char *addr;
|
||||||
u16 vid;
|
u16 vid;
|
||||||
u8 added_by_user:1,
|
u8 added_by_user:1,
|
||||||
|
@ -584,7 +584,7 @@
|
|||||||
/* Caller must hold RTNL. */
|
/* Caller must hold RTNL. */
|
||||||
int fib_table_insert(struct net *net, struct fib_table *tb,
|
int fib_table_insert(struct net *net, struct fib_table *tb,
|
||||||
struct fib_config *cfg, struct netlink_ext_ack *extack)
|
struct fib_config *cfg, struct netlink_ext_ack *extack)
|
||||||
@@ -1352,6 +1355,9 @@ int fib_table_insert(struct net *net, st
|
@@ -1354,6 +1357,9 @@ int fib_table_insert(struct net *net, st
|
||||||
rtmsg_fib(RTM_NEWROUTE, htonl(key), new_fa, plen, new_fa->tb_id,
|
rtmsg_fib(RTM_NEWROUTE, htonl(key), new_fa, plen, new_fa->tb_id,
|
||||||
&cfg->fc_nlinfo, nlflags);
|
&cfg->fc_nlinfo, nlflags);
|
||||||
succeeded:
|
succeeded:
|
||||||
@ -594,7 +594,7 @@
|
|||||||
return 0;
|
return 0;
|
||||||
|
|
||||||
out_remove_new_fa:
|
out_remove_new_fa:
|
||||||
@@ -1722,6 +1728,9 @@ int fib_table_delete(struct net *net, st
|
@@ -1724,6 +1730,9 @@ int fib_table_delete(struct net *net, st
|
||||||
if (fa_to_delete->fa_state & FA_S_ACCESSED)
|
if (fa_to_delete->fa_state & FA_S_ACCESSED)
|
||||||
rt_cache_flush(cfg->fc_nlinfo.nl_net);
|
rt_cache_flush(cfg->fc_nlinfo.nl_net);
|
||||||
|
|
||||||
@ -604,7 +604,7 @@
|
|||||||
fib_release_info(fa_to_delete->fa_info);
|
fib_release_info(fa_to_delete->fa_info);
|
||||||
alias_free_mem_rcu(fa_to_delete);
|
alias_free_mem_rcu(fa_to_delete);
|
||||||
return 0;
|
return 0;
|
||||||
@@ -2358,6 +2367,20 @@ void __init fib_trie_init(void)
|
@@ -2360,6 +2369,20 @@ void __init fib_trie_init(void)
|
||||||
0, SLAB_PANIC, NULL);
|
0, SLAB_PANIC, NULL);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -14,7 +14,7 @@ Signed-off-by: Frank Wunderlich <frank-w@public-files.de>
|
|||||||
|
|
||||||
--- a/drivers/net/ethernet/mediatek/mtk_eth_soc.c
|
--- a/drivers/net/ethernet/mediatek/mtk_eth_soc.c
|
||||||
+++ b/drivers/net/ethernet/mediatek/mtk_eth_soc.c
|
+++ b/drivers/net/ethernet/mediatek/mtk_eth_soc.c
|
||||||
@@ -3395,6 +3395,7 @@ static const struct mtk_soc_data mt7623_
|
@@ -3398,6 +3398,7 @@ static const struct mtk_soc_data mt7623_
|
||||||
.hw_features = MTK_HW_FEATURES,
|
.hw_features = MTK_HW_FEATURES,
|
||||||
.required_clks = MT7623_CLKS_BITMAP,
|
.required_clks = MT7623_CLKS_BITMAP,
|
||||||
.required_pctl = true,
|
.required_pctl = true,
|
||||||
|
@ -14,7 +14,7 @@ Signed-off-by: René van Dorst <opensource@vdorst.com>
|
|||||||
|
|
||||||
--- a/drivers/net/ethernet/mediatek/mtk_eth_soc.c
|
--- a/drivers/net/ethernet/mediatek/mtk_eth_soc.c
|
||||||
+++ b/drivers/net/ethernet/mediatek/mtk_eth_soc.c
|
+++ b/drivers/net/ethernet/mediatek/mtk_eth_soc.c
|
||||||
@@ -2975,6 +2975,7 @@ static const struct net_device_ops mtk_n
|
@@ -2978,6 +2978,7 @@ static const struct net_device_ops mtk_n
|
||||||
|
|
||||||
static int mtk_add_mac(struct mtk_eth *eth, struct device_node *np)
|
static int mtk_add_mac(struct mtk_eth *eth, struct device_node *np)
|
||||||
{
|
{
|
||||||
@ -22,7 +22,7 @@ Signed-off-by: René van Dorst <opensource@vdorst.com>
|
|||||||
const __be32 *_id = of_get_property(np, "reg", NULL);
|
const __be32 *_id = of_get_property(np, "reg", NULL);
|
||||||
phy_interface_t phy_mode;
|
phy_interface_t phy_mode;
|
||||||
struct phylink *phylink;
|
struct phylink *phylink;
|
||||||
@@ -3070,6 +3071,9 @@ static int mtk_add_mac(struct mtk_eth *e
|
@@ -3073,6 +3074,9 @@ static int mtk_add_mac(struct mtk_eth *e
|
||||||
else
|
else
|
||||||
eth->netdev[id]->max_mtu = MTK_MAX_RX_LENGTH_2K - MTK_RX_ETH_HLEN;
|
eth->netdev[id]->max_mtu = MTK_MAX_RX_LENGTH_2K - MTK_RX_ETH_HLEN;
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user