--- a/drivers/net/ethernet/airoha/airoha_eth.c
+++ b/drivers/net/ethernet/airoha/airoha_eth.c
-@@ -2160,8 +2160,12 @@ static void airoha_ethtool_get_mac_stats
+@@ -2163,8 +2163,12 @@ static void airoha_ethtool_get_mac_stats
airoha_update_hw_stats(port);
do {
start = u64_stats_fetch_begin(&port->stats.syncp);
--- a/drivers/net/ethernet/airoha/airoha_eth.c
+++ b/drivers/net/ethernet/airoha/airoha_eth.c
-@@ -2908,6 +2908,7 @@ static const struct ethtool_ops airoha_e
+@@ -2911,6 +2911,7 @@ static const struct ethtool_ops airoha_e
.get_drvinfo = airoha_ethtool_get_drvinfo,
.get_eth_mac_stats = airoha_ethtool_get_mac_stats,
.get_rmon_stats = airoha_ethtool_get_rmon_stats,
/* enable 1:N vlan action, init vlan table */
airoha_fe_set(eth, REG_MC_VLAN_EN, MC_VLAN_EN_MASK);
-@@ -1853,8 +1834,10 @@ static int airhoha_set_gdm2_loopback(str
+@@ -1856,8 +1837,10 @@ static int airhoha_set_gdm2_loopback(str
static int airoha_dev_init(struct net_device *dev)
{
struct airoha_gdm_port *port = netdev_priv(dev);
airoha_set_macaddr(port, dev->dev_addr);
-@@ -1872,16 +1855,27 @@ static int airoha_dev_init(struct net_de
+@@ -1875,16 +1858,27 @@ static int airoha_dev_init(struct net_de
fallthrough;
case AIROHA_GDM2_IDX:
if (airoha_ppe_is_enabled(eth, 1)) {
--- a/drivers/net/ethernet/airoha/airoha_eth.c
+++ b/drivers/net/ethernet/airoha/airoha_eth.c
-@@ -2902,6 +2902,7 @@ static const struct ethtool_ops airoha_e
+@@ -2905,6 +2905,7 @@ static const struct ethtool_ops airoha_e
.get_drvinfo = airoha_ethtool_get_drvinfo,
.get_eth_mac_stats = airoha_ethtool_get_mac_stats,
.get_rmon_stats = airoha_ethtool_get_rmon_stats,
--- a/drivers/net/ethernet/airoha/airoha_eth.c
+++ b/drivers/net/ethernet/airoha/airoha_eth.c
-@@ -1821,7 +1821,7 @@ static int airhoha_set_gdm2_loopback(str
+@@ -1824,7 +1824,7 @@ static int airhoha_set_gdm2_loopback(str
airoha_fe_rmw(eth,
REG_SP_DFT_CPORT(src_port >> fls(SP_CPORT_DFT_MASK)),
SP_CPORT_MASK(val),
if (port->id != AIROHA_GDM3_IDX && airoha_is_7581(eth))
airoha_fe_rmw(eth, REG_SRC_PORT_FC_MAP6,
-@@ -1875,7 +1875,7 @@ static int airoha_dev_init(struct net_de
+@@ -1878,7 +1878,7 @@ static int airoha_dev_init(struct net_de
ppe_id = pse_port == FE_PSE_PORT_PPE2 ? 1 : 0;
airoha_fe_rmw(eth, REG_PPE_DFT_CPORT0(ppe_id),
DFT_CPORT_MASK(port->id),
return 0;
}
-@@ -2235,7 +2235,7 @@ static int airoha_qdma_set_chan_tx_sched
+@@ -2238,7 +2238,7 @@ static int airoha_qdma_set_chan_tx_sched
airoha_qdma_rmw(port->qdma, REG_CHAN_QOS_MODE(channel >> 3),
CHAN_QOS_MODE_MASK(channel),
--- a/drivers/net/ethernet/airoha/airoha_eth.c
+++ b/drivers/net/ethernet/airoha/airoha_eth.c
-@@ -1823,10 +1823,12 @@ static int airhoha_set_gdm2_loopback(str
+@@ -1826,10 +1826,12 @@ static int airhoha_set_gdm2_loopback(str
SP_CPORT_MASK(val),
__field_prep(SP_CPORT_MASK(val), FE_PSE_PORT_CDM2));
--- a/drivers/net/ethernet/airoha/airoha_eth.c
+++ b/drivers/net/ethernet/airoha/airoha_eth.c
-@@ -1708,6 +1708,7 @@ static int airoha_dev_open(struct net_de
+@@ -1711,6 +1711,7 @@ static int airoha_dev_open(struct net_de
int err, len = ETH_HLEN + dev->mtu + ETH_FCS_LEN;
struct airoha_gdm_port *port = netdev_priv(dev);
struct airoha_qdma *qdma = port->qdma;
netif_tx_start_all_queues(dev);
err = airoha_set_vip_for_gdm_port(port, true);
-@@ -1731,6 +1732,14 @@ static int airoha_dev_open(struct net_de
+@@ -1734,6 +1735,14 @@ static int airoha_dev_open(struct net_de
GLOBAL_CFG_RX_DMA_EN_MASK);
atomic_inc(&qdma->users);
return 0;
}
-@@ -1745,6 +1754,9 @@ static int airoha_dev_stop(struct net_de
+@@ -1748,6 +1757,9 @@ static int airoha_dev_stop(struct net_de
for (i = 0; i < dev->num_tx_queues; i++)
netdev_tx_reset_subqueue(dev, i);
if (atomic_dec_and_test(&qdma->users)) {
airoha_qdma_clear(qdma, REG_QDMA_GLOBAL_CFG,
GLOBAL_CFG_TX_DMA_EN_MASK |
-@@ -1838,7 +1850,7 @@ static int airoha_dev_init(struct net_de
+@@ -1841,7 +1853,7 @@ static int airoha_dev_init(struct net_de
struct airoha_gdm_port *port = netdev_priv(dev);
struct airoha_qdma *qdma = port->qdma;
struct airoha_eth *eth = qdma->eth;
u8 ppe_id;
airoha_set_macaddr(port, dev->dev_addr);
-@@ -1859,7 +1871,7 @@ static int airoha_dev_init(struct net_de
+@@ -1862,7 +1874,7 @@ static int airoha_dev_init(struct net_de
if (airoha_ppe_is_enabled(eth, 1)) {
/* For PPE2 always use secondary cpu port. */
fe_cpu_port = FE_PSE_PORT_CDM2;
break;
}
fallthrough;
-@@ -1868,13 +1880,11 @@ static int airoha_dev_init(struct net_de
+@@ -1871,13 +1883,11 @@ static int airoha_dev_init(struct net_de
/* For PPE1 select cpu port according to the running QDMA. */
fe_cpu_port = qdma_id ? FE_PSE_PORT_CDM2 : FE_PSE_PORT_CDM1;
--- a/drivers/net/ethernet/airoha/airoha_eth.c
+++ b/drivers/net/ethernet/airoha/airoha_eth.c
-@@ -1848,11 +1848,13 @@ static int airhoha_set_gdm2_loopback(str
+@@ -1851,11 +1851,13 @@ static int airhoha_set_gdm2_loopback(str
static int airoha_dev_init(struct net_device *dev)
{
struct airoha_gdm_port *port = netdev_priv(dev);
airoha_set_macaddr(port, dev->dev_addr);
switch (port->id) {
-@@ -1876,7 +1878,7 @@ static int airoha_dev_init(struct net_de
+@@ -1879,7 +1881,7 @@ static int airoha_dev_init(struct net_de
}
fallthrough;
default: {
/* For PPE1 select cpu port according to the running QDMA. */
fe_cpu_port = qdma_id ? FE_PSE_PORT_CDM2 : FE_PSE_PORT_CDM1;
-@@ -2963,11 +2965,10 @@ bool airoha_is_valid_gdm_port(struct air
+@@ -2966,11 +2968,10 @@ bool airoha_is_valid_gdm_port(struct air
}
static int airoha_alloc_gdm_port(struct airoha_eth *eth,
struct net_device *dev;
int err, p;
u32 id;
-@@ -2998,7 +2999,6 @@ static int airoha_alloc_gdm_port(struct
+@@ -3001,7 +3002,6 @@ static int airoha_alloc_gdm_port(struct
return -ENOMEM;
}
dev->netdev_ops = &airoha_netdev_ops;
dev->ethtool_ops = &airoha_ethtool_ops;
dev->max_mtu = AIROHA_MAX_MTU;
-@@ -3010,7 +3010,6 @@ static int airoha_alloc_gdm_port(struct
+@@ -3013,7 +3013,6 @@ static int airoha_alloc_gdm_port(struct
dev->features |= dev->hw_features;
dev->vlan_features = dev->hw_features;
dev->dev.of_node = np;
SET_NETDEV_DEV(dev, eth->dev);
/* reserve hw queues for HTB offloading */
-@@ -3031,7 +3030,7 @@ static int airoha_alloc_gdm_port(struct
+@@ -3034,7 +3033,7 @@ static int airoha_alloc_gdm_port(struct
port = netdev_priv(dev);
u64_stats_init(&port->stats.syncp);
spin_lock_init(&port->stats.lock);
port->dev = dev;
port->id = id;
/* XXX: Read nbq from DTS */
-@@ -3133,7 +3132,6 @@ static int airoha_probe(struct platform_
+@@ -3136,7 +3135,6 @@ static int airoha_probe(struct platform_
for (i = 0; i < ARRAY_SIZE(eth->qdma); i++)
airoha_qdma_start_napi(ð->qdma[i]);
for_each_child_of_node(pdev->dev.of_node, np) {
if (!of_device_is_compatible(np, "airoha,eth-mac"))
continue;
-@@ -3141,7 +3139,7 @@ static int airoha_probe(struct platform_
+@@ -3144,7 +3142,7 @@ static int airoha_probe(struct platform_
if (!of_device_is_available(np))
continue;
--- a/drivers/net/ethernet/airoha/airoha_eth.c
+++ b/drivers/net/ethernet/airoha/airoha_eth.c
-@@ -1849,8 +1849,7 @@ static int airoha_dev_init(struct net_de
+@@ -1852,8 +1852,7 @@ static int airoha_dev_init(struct net_de
{
struct airoha_gdm_port *port = netdev_priv(dev);
struct airoha_eth *eth = port->eth;
/* QDMA0 is used for lan ports while QDMA1 is used for WAN ports */
port->qdma = ð->qdma[!airoha_is_lan_gdm_port(port)];
-@@ -1868,28 +1867,13 @@ static int airoha_dev_init(struct net_de
+@@ -1871,28 +1870,13 @@ static int airoha_dev_init(struct net_de
if (err)
return err;
}
return 0;
}
-@@ -1992,7 +1976,7 @@ static u32 airoha_get_dsa_tag(struct sk_
+@@ -1995,7 +1979,7 @@ static u32 airoha_get_dsa_tag(struct sk_
#endif
}
--- a/drivers/net/ethernet/airoha/airoha_eth.c
+++ b/drivers/net/ethernet/airoha/airoha_eth.c
-@@ -3040,6 +3040,8 @@ static int airoha_register_gdm_devices(s
+@@ -3043,6 +3043,8 @@ static int airoha_register_gdm_devices(s
return err;
}
--- a/drivers/net/ethernet/airoha/airoha_eth.c
+++ b/drivers/net/ethernet/airoha/airoha_eth.c
-@@ -2752,7 +2752,7 @@ static int airoha_dev_setup_tc_block_cb(
+@@ -2755,7 +2755,7 @@ static int airoha_dev_setup_tc_block_cb(
}
}
struct flow_block_offload *f)
{
flow_setup_cb_t *cb = airoha_dev_setup_tc_block_cb;
-@@ -2765,12 +2765,12 @@ static int airoha_dev_setup_tc_block(str
+@@ -2768,12 +2768,12 @@ static int airoha_dev_setup_tc_block(str
f->driver_block_list = &block_cb_list;
switch (f->command) {
case FLOW_BLOCK_BIND:
if (IS_ERR(block_cb))
return PTR_ERR(block_cb);
-@@ -2779,7 +2779,7 @@ static int airoha_dev_setup_tc_block(str
+@@ -2782,7 +2782,7 @@ static int airoha_dev_setup_tc_block(str
list_add_tail(&block_cb->driver_list, &block_cb_list);
return 0;
case FLOW_BLOCK_UNBIND:
if (!block_cb)
return -ENOENT;
-@@ -2878,7 +2878,7 @@ static int airoha_dev_tc_setup(struct ne
+@@ -2881,7 +2881,7 @@ static int airoha_dev_tc_setup(struct ne
return airoha_tc_setup_qdisc_htb(port, type_data);
case TC_SETUP_BLOCK:
case TC_SETUP_FT:
--- a/drivers/net/ethernet/airoha/airoha_eth.c
+++ b/drivers/net/ethernet/airoha/airoha_eth.c
-@@ -2557,10 +2557,11 @@ static int airoha_qdma_set_trtcm_token_b
+@@ -2560,10 +2560,11 @@ static int airoha_qdma_set_trtcm_token_b
mode, val);
}
int i, err;
for (i = 0; i <= TRTCM_PEAK_MODE; i++) {
-@@ -2580,21 +2581,20 @@ static int airoha_qdma_set_tx_rate_limit
+@@ -2583,21 +2584,20 @@ static int airoha_qdma_set_tx_rate_limit
return 0;
}
if (err) {
NL_SET_ERR_MSG_MOD(opt->extack,
"failed configuring htb offload");
-@@ -2606,7 +2606,7 @@ static int airoha_tc_htb_alloc_leaf_queu
+@@ -2609,7 +2609,7 @@ static int airoha_tc_htb_alloc_leaf_queu
err = netif_set_real_num_tx_queues(dev, num_tx_queues + 1);
if (err) {
NL_SET_ERR_MSG_MOD(opt->extack,
"failed setting real_num_tx_queues");
return err;
-@@ -2793,44 +2793,47 @@ static int airoha_dev_setup_tc_block(str
+@@ -2796,44 +2796,47 @@ static int airoha_dev_setup_tc_block(str
}
}
if (!test_bit(channel, port->qos_sq_bmap)) {
NL_SET_ERR_MSG_MOD(opt->extack, "invalid queue id");
-@@ -2842,23 +2845,23 @@ static int airoha_tc_get_htb_get_leaf_qu
+@@ -2845,23 +2848,23 @@ static int airoha_tc_get_htb_get_leaf_qu
return 0;
}
default:
return -EOPNOTSUPP;
}
-@@ -2875,7 +2878,7 @@ static int airoha_dev_tc_setup(struct ne
+@@ -2878,7 +2881,7 @@ static int airoha_dev_tc_setup(struct ne
case TC_SETUP_QDISC_ETS:
return airoha_tc_setup_qdisc_ets(port, type_data);
case TC_SETUP_QDISC_HTB:
--- a/drivers/net/ethernet/airoha/airoha_eth.c
+++ b/drivers/net/ethernet/airoha/airoha_eth.c
-@@ -2203,10 +2203,11 @@ airoha_ethtool_get_rmon_stats(struct net
+@@ -2206,10 +2206,11 @@ airoha_ethtool_get_rmon_stats(struct net
} while (u64_stats_fetch_retry(&port->stats.syncp, start));
}
int i;
for (i = 0; i < AIROHA_NUM_TX_RING; i++)
-@@ -2238,17 +2239,15 @@ static int airoha_qdma_set_chan_tx_sched
+@@ -2241,17 +2242,15 @@ static int airoha_qdma_set_chan_tx_sched
return 0;
}
struct tc_ets_qopt_offload *opt)
{
struct tc_ets_qopt_offload_replace_params *p = &opt->replace_params;
-@@ -2289,20 +2288,21 @@ static int airoha_qdma_set_tx_ets_sched(
+@@ -2292,20 +2291,21 @@ static int airoha_qdma_set_tx_ets_sched(
else if (nstrict < AIROHA_NUM_QOS_QUEUES - 1)
mode = nstrict + 1;
_bstats_update(opt->stats.bstats, 0, tx_packets);
port->cpu_tx_packets = cpu_tx_packets;
-@@ -2311,7 +2311,7 @@ static int airoha_qdma_get_tx_ets_stats(
+@@ -2314,7 +2314,7 @@ static int airoha_qdma_get_tx_ets_stats(
return 0;
}
struct tc_ets_qopt_offload *opt)
{
int channel;
-@@ -2324,12 +2324,12 @@ static int airoha_tc_setup_qdisc_ets(str
+@@ -2327,12 +2327,12 @@ static int airoha_tc_setup_qdisc_ets(str
switch (opt->command) {
case TC_ETS_REPLACE:
default:
return -EOPNOTSUPP;
}
-@@ -2872,11 +2872,9 @@ static int airoha_tc_setup_qdisc_htb(str
+@@ -2875,11 +2875,9 @@ static int airoha_tc_setup_qdisc_htb(str
static int airoha_dev_tc_setup(struct net_device *dev, enum tc_setup_type type,
void *type_data)
{
--- a/drivers/net/ethernet/airoha/airoha_eth.c
+++ b/drivers/net/ethernet/airoha/airoha_eth.c
-@@ -1786,7 +1786,7 @@ static int airoha_dev_set_macaddr(struct
+@@ -1789,7 +1789,7 @@ static int airoha_dev_set_macaddr(struct
return 0;
}
{
struct airoha_eth *eth = port->qdma->eth;
u32 val, pse_port, chan;
-@@ -1862,7 +1862,7 @@ static int airoha_dev_init(struct net_de
+@@ -1865,7 +1865,7 @@ static int airoha_dev_init(struct net_de
if (!eth->ports[1]) {
int err;
--- a/drivers/net/ethernet/airoha/airoha_eth.c
+++ b/drivers/net/ethernet/airoha/airoha_eth.c
-@@ -1791,7 +1791,7 @@ static int airoha_set_gdm2_loopback(stru
+@@ -1794,7 +1794,7 @@ static int airoha_set_gdm2_loopback(stru
{
struct airoha_eth *eth = port->qdma->eth;
u32 val, pse_port, chan;
airoha_set_gdm_port_fwd_cfg(eth, REG_GDM_FWD_CFG(AIROHA_GDM2_IDX),
FE_PSE_PORT_DROP);
-@@ -1835,6 +1835,9 @@ static int airoha_set_gdm2_loopback(stru
+@@ -1838,6 +1838,9 @@ static int airoha_set_gdm2_loopback(stru
SP_CPORT_MASK(val),
__field_prep(SP_CPORT_MASK(val), FE_PSE_PORT_CDM2));
if (port->id == AIROHA_GDM4_IDX && airoha_is_7581(eth)) {
u32 mask = FC_ID_OF_SRC_PORT_MASK(port->nbq);
-@@ -1873,7 +1876,8 @@ static int airoha_dev_init(struct net_de
+@@ -1876,7 +1879,8 @@ static int airoha_dev_init(struct net_de
}
for (i = 0; i < eth->soc->num_ppe; i++)
--- a/drivers/net/ethernet/airoha/airoha_eth.c
+++ b/drivers/net/ethernet/airoha/airoha_eth.c
-@@ -1822,7 +1822,7 @@ static int airoha_set_gdm2_loopback(stru
+@@ -1825,7 +1825,7 @@ static int airoha_set_gdm2_loopback(stru
airoha_fe_clear(eth, REG_FE_VIP_PORT_EN, BIT(AIROHA_GDM2_IDX));
airoha_fe_clear(eth, REG_FE_IFC_PORT_EN, BIT(AIROHA_GDM2_IDX));
if (src_port < 0)
return src_port;
-@@ -3196,7 +3196,7 @@ static const char * const en7581_xsi_rst
+@@ -3199,7 +3199,7 @@ static const char * const en7581_xsi_rst
"xfp-mac",
};
{
switch (port->id) {
case AIROHA_GDM3_IDX:
-@@ -3249,7 +3249,7 @@ static const char * const an7583_xsi_rst
+@@ -3252,7 +3252,7 @@ static const char * const an7583_xsi_rst
"xfp-mac",
};
{
switch (port->id) {
case AIROHA_GDM3_IDX:
-@@ -3297,7 +3297,7 @@ static const struct airoha_eth_soc_data
+@@ -3300,7 +3300,7 @@ static const struct airoha_eth_soc_data
.num_xsi_rsts = ARRAY_SIZE(en7581_xsi_rsts_names),
.num_ppe = 2,
.ops = {
.get_vip_port = airoha_en7581_get_vip_port,
},
};
-@@ -3308,7 +3308,7 @@ static const struct airoha_eth_soc_data
+@@ -3311,7 +3311,7 @@ static const struct airoha_eth_soc_data
.num_xsi_rsts = ARRAY_SIZE(an7583_xsi_rsts_names),
.num_ppe = 1,
.ops = {
}
}
q->txq_stopped = false;
-@@ -1700,19 +1707,20 @@ static void airoha_update_hw_stats(struc
+@@ -1703,19 +1710,20 @@ static void airoha_update_hw_stats(struc
spin_unlock(&port->stats.lock);
}
airoha_fe_set(qdma->eth, REG_GDM_INGRESS_CFG(port->id),
GDM_STAG_EN_MASK);
else
-@@ -1740,16 +1748,17 @@ static int airoha_dev_open(struct net_de
+@@ -1743,16 +1751,17 @@ static int airoha_dev_open(struct net_de
return 0;
}
airoha_set_gdm_port_fwd_cfg(qdma->eth, REG_GDM_FWD_CFG(port->id),
FE_PSE_PORT_DROP);
-@@ -1770,16 +1779,17 @@ static int airoha_dev_stop(struct net_de
+@@ -1773,16 +1782,17 @@ static int airoha_dev_stop(struct net_de
return 0;
}
return 0;
}
-@@ -1845,16 +1855,17 @@ static int airoha_set_gdm2_loopback(stru
+@@ -1848,16 +1858,17 @@ static int airoha_set_gdm2_loopback(stru
return 0;
}
switch (port->id) {
case AIROHA_GDM3_IDX:
-@@ -1879,10 +1890,11 @@ static int airoha_dev_init(struct net_de
+@@ -1882,10 +1893,11 @@ static int airoha_dev_init(struct net_de
return 0;
}
unsigned int start;
airoha_update_hw_stats(port);
-@@ -1901,36 +1913,39 @@ static void airoha_dev_get_stats64(struc
+@@ -1904,36 +1916,39 @@ static void airoha_dev_get_stats64(struc
} while (u64_stats_fetch_retry(&port->stats.syncp, start));
}
}
static u32 airoha_get_dsa_tag(struct sk_buff *skb, struct net_device *dev)
-@@ -1994,9 +2009,10 @@ int airoha_get_fe_port(struct airoha_gdm
+@@ -1997,9 +2012,10 @@ int airoha_get_fe_port(struct airoha_gdm
}
static netdev_tx_t airoha_dev_xmit(struct sk_buff *skb,
struct airoha_qdma *qdma = port->qdma;
u32 nr_frags, tag, msg0, msg1, len;
struct airoha_queue_entry *e;
-@@ -2009,7 +2025,7 @@ static netdev_tx_t airoha_dev_xmit(struc
+@@ -2012,7 +2028,7 @@ static netdev_tx_t airoha_dev_xmit(struc
u8 fport;
qid = airoha_qdma_get_txq(qdma, skb_get_queue_mapping(skb));
msg0 = FIELD_PREP(QDMA_ETH_TXMSG_CHAN_MASK,
qid / AIROHA_NUM_QOS_QUEUES) |
-@@ -2045,7 +2061,7 @@ static netdev_tx_t airoha_dev_xmit(struc
+@@ -2048,7 +2064,7 @@ static netdev_tx_t airoha_dev_xmit(struc
spin_lock_bh(&q->lock);
nr_frags = 1 + skb_shinfo(skb)->nr_frags;
if (q->queued + nr_frags >= q->ndesc) {
-@@ -2069,9 +2085,9 @@ static netdev_tx_t airoha_dev_xmit(struc
+@@ -2072,9 +2088,9 @@ static netdev_tx_t airoha_dev_xmit(struc
dma_addr_t addr;
u32 val;
goto error_unmap;
list_move_tail(&e->list, &tx_list);
-@@ -2120,7 +2136,7 @@ static netdev_tx_t airoha_dev_xmit(struc
+@@ -2123,7 +2139,7 @@ static netdev_tx_t airoha_dev_xmit(struc
error_unmap:
list_for_each_entry(e, &tx_list, list) {
DMA_TO_DEVICE);
e->dma_addr = 0;
}
-@@ -2129,25 +2145,27 @@ error_unmap:
+@@ -2132,25 +2148,27 @@ error_unmap:
spin_unlock_bh(&q->lock);
error:
dev_kfree_skb_any(skb);
unsigned int start;
airoha_update_hw_stats(port);
-@@ -2175,11 +2193,12 @@ static const struct ethtool_rmon_hist_ra
+@@ -2178,11 +2196,12 @@ static const struct ethtool_rmon_hist_ra
};
static void
struct airoha_hw_stats *hw_stats = &port->stats;
unsigned int start;
-@@ -2204,11 +2223,12 @@ airoha_ethtool_get_rmon_stats(struct net
+@@ -2207,11 +2226,12 @@ airoha_ethtool_get_rmon_stats(struct net
} while (u64_stats_fetch_retry(&port->stats.syncp, start));
}
int i;
for (i = 0; i < AIROHA_NUM_TX_RING; i++)
-@@ -2293,10 +2313,12 @@ static int airoha_qdma_set_tx_ets_sched(
+@@ -2296,10 +2316,12 @@ static int airoha_qdma_set_tx_ets_sched(
ARRAY_SIZE(w));
}
u64 cpu_tx_packets = airoha_qdma_rr(port->qdma,
REG_CNTR_VAL(channel << 1));
u64 fwd_tx_packets = airoha_qdma_rr(port->qdma,
-@@ -2558,11 +2580,12 @@ static int airoha_qdma_set_trtcm_token_b
+@@ -2561,11 +2583,12 @@ static int airoha_qdma_set_trtcm_token_b
mode, val);
}
int i, err;
for (i = 0; i <= TRTCM_PEAK_MODE; i++) {
-@@ -2582,20 +2605,22 @@ static int airoha_qdma_set_tx_rate_limit
+@@ -2585,20 +2608,22 @@ static int airoha_qdma_set_tx_rate_limit
return 0;
}
if (err) {
NL_SET_ERR_MSG_MOD(opt->extack,
"failed configuring htb offload");
-@@ -2605,9 +2630,10 @@ static int airoha_tc_htb_alloc_leaf_queu
+@@ -2608,9 +2633,10 @@ static int airoha_tc_htb_alloc_leaf_queu
if (opt->command == TC_HTB_NODE_MODIFY)
return 0;
NL_SET_ERR_MSG_MOD(opt->extack,
"failed setting real_num_tx_queues");
return err;
-@@ -2697,11 +2723,12 @@ static int airoha_tc_matchall_act_valida
+@@ -2700,11 +2726,12 @@ static int airoha_tc_matchall_act_valida
return 0;
}
u32 rate = 0, bucket_size = 0;
switch (f->command) {
-@@ -2736,18 +2763,19 @@ static int airoha_dev_tc_matchall(struct
+@@ -2739,18 +2766,19 @@ static int airoha_dev_tc_matchall(struct
static int airoha_dev_setup_tc_block_cb(enum tc_setup_type type,
void *type_data, void *cb_priv)
{
default:
return -EOPNOTSUPP;
}
-@@ -2794,47 +2822,51 @@ static int airoha_dev_setup_tc_block(str
+@@ -2797,47 +2825,51 @@ static int airoha_dev_setup_tc_block(str
}
}
if (!test_bit(channel, port->qos_sq_bmap)) {
NL_SET_ERR_MSG_MOD(opt->extack, "invalid queue id");
-@@ -2870,8 +2902,8 @@ static int airoha_tc_setup_qdisc_htb(str
+@@ -2873,8 +2905,8 @@ static int airoha_tc_setup_qdisc_htb(str
return 0;
}
{
switch (type) {
case TC_SETUP_QDISC_ETS:
-@@ -2937,25 +2969,81 @@ static void airoha_metadata_dst_free(str
+@@ -2940,25 +2972,81 @@ static void airoha_metadata_dst_free(str
}
}
int err, p;
u32 id;
-@@ -2977,53 +3065,22 @@ static int airoha_alloc_gdm_port(struct
+@@ -2980,53 +3068,22 @@ static int airoha_alloc_gdm_port(struct
return -EINVAL;
}
}
static int airoha_register_gdm_devices(struct airoha_eth *eth)
-@@ -3037,7 +3094,7 @@ static int airoha_register_gdm_devices(s
+@@ -3040,7 +3097,7 @@ static int airoha_register_gdm_devices(s
if (!port)
continue;
if (err)
return err;
}
-@@ -3146,12 +3203,14 @@ error_napi_stop:
+@@ -3149,12 +3206,14 @@ error_napi_stop:
for (i = 0; i < ARRAY_SIZE(eth->ports); i++) {
struct airoha_gdm_port *port = eth->ports[i];
airoha_metadata_dst_free(port);
}
airoha_hw_cleanup(eth);
-@@ -3172,11 +3231,14 @@ static void airoha_remove(struct platfor
+@@ -3175,11 +3234,14 @@ static void airoha_remove(struct platfor
for (i = 0; i < ARRAY_SIZE(eth->ports); i++) {
struct airoha_gdm_port *port = eth->ports[i];
for (j = 0; j < dev->dev->num_tx_queues; j++) {
if (airoha_qdma_get_txq(qdma, j) != qid)
continue;
-@@ -1563,9 +1567,10 @@ static void airoha_qdma_stop_napi(struct
+@@ -1566,9 +1570,10 @@ static void airoha_qdma_stop_napi(struct
}
}
u32 val, i = 0;
spin_lock(&port->stats.lock);
-@@ -1712,11 +1717,11 @@ static int airoha_dev_open(struct net_de
+@@ -1715,11 +1720,11 @@ static int airoha_dev_open(struct net_de
int err, len = ETH_HLEN + netdev->mtu + ETH_FCS_LEN;
struct airoha_gdm_dev *dev = netdev_priv(netdev);
struct airoha_gdm_port *port = dev->port;
if (err)
return err;
-@@ -1752,11 +1757,11 @@ static int airoha_dev_stop(struct net_de
+@@ -1755,11 +1760,11 @@ static int airoha_dev_stop(struct net_de
{
struct airoha_gdm_dev *dev = netdev_priv(netdev);
struct airoha_gdm_port *port = dev->port;
for (i = 0; i < netdev->num_tx_queues; i++)
netdev_tx_reset_subqueue(netdev, i);
-@@ -1782,21 +1787,21 @@ static int airoha_dev_stop(struct net_de
+@@ -1785,21 +1790,21 @@ static int airoha_dev_stop(struct net_de
static int airoha_dev_set_macaddr(struct net_device *netdev, void *p)
{
struct airoha_gdm_dev *dev = netdev_priv(netdev);
u32 val, pse_port, chan;
int i, src_port;
-@@ -1843,7 +1848,7 @@ static int airoha_set_gdm2_loopback(stru
+@@ -1846,7 +1851,7 @@ static int airoha_set_gdm2_loopback(stru
__field_prep(SP_CPORT_MASK(val), FE_PSE_PORT_CDM2));
for (i = 0; i < eth->soc->num_ppe; i++)
if (port->id == AIROHA_GDM4_IDX && airoha_is_7581(eth)) {
u32 mask = FC_ID_OF_SRC_PORT_MASK(port->nbq);
-@@ -1863,9 +1868,9 @@ static int airoha_dev_init(struct net_de
+@@ -1866,9 +1871,9 @@ static int airoha_dev_init(struct net_de
int i;
/* QDMA0 is used for lan ports while QDMA1 is used for WAN ports */
switch (port->id) {
case AIROHA_GDM3_IDX:
-@@ -1874,7 +1879,7 @@ static int airoha_dev_init(struct net_de
+@@ -1877,7 +1882,7 @@ static int airoha_dev_init(struct net_de
if (!eth->ports[1]) {
int err;
if (err)
return err;
}
-@@ -1884,8 +1889,7 @@ static int airoha_dev_init(struct net_de
+@@ -1887,8 +1892,7 @@ static int airoha_dev_init(struct net_de
}
for (i = 0; i < eth->soc->num_ppe; i++)
return 0;
}
-@@ -1897,7 +1901,7 @@ static void airoha_dev_get_stats64(struc
+@@ -1900,7 +1904,7 @@ static void airoha_dev_get_stats64(struc
struct airoha_gdm_port *port = dev->port;
unsigned int start;
do {
start = u64_stats_fetch_begin(&port->stats.syncp);
storage->rx_packets = port->stats.rx_ok_pkts;
-@@ -1917,8 +1921,8 @@ static int airoha_dev_change_mtu(struct
+@@ -1920,8 +1924,8 @@ static int airoha_dev_change_mtu(struct
{
struct airoha_gdm_dev *dev = netdev_priv(netdev);
struct airoha_gdm_port *port = dev->port;
airoha_fe_rmw(eth, REG_GDM_LEN_CFG(port->id),
GDM_LONG_LEN_MASK,
-@@ -1992,10 +1996,10 @@ static u32 airoha_get_dsa_tag(struct sk_
+@@ -1995,10 +1999,10 @@ static u32 airoha_get_dsa_tag(struct sk_
#endif
}
switch (eth->soc->version) {
case 0x7583:
-@@ -2012,8 +2016,7 @@ static netdev_tx_t airoha_dev_xmit(struc
+@@ -2015,8 +2019,7 @@ static netdev_tx_t airoha_dev_xmit(struc
struct net_device *netdev)
{
struct airoha_gdm_dev *dev = netdev_priv(netdev);
u32 nr_frags, tag, msg0, msg1, len;
struct airoha_queue_entry *e;
struct netdev_queue *txq;
-@@ -2051,7 +2054,7 @@ static netdev_tx_t airoha_dev_xmit(struc
+@@ -2054,7 +2057,7 @@ static netdev_tx_t airoha_dev_xmit(struc
}
}
msg1 = FIELD_PREP(QDMA_ETH_TXMSG_FPORT_MASK, fport) |
FIELD_PREP(QDMA_ETH_TXMSG_METER_MASK, 0x7f);
-@@ -2154,8 +2157,7 @@ static void airoha_ethtool_get_drvinfo(s
+@@ -2157,8 +2160,7 @@ static void airoha_ethtool_get_drvinfo(s
struct ethtool_drvinfo *info)
{
struct airoha_gdm_dev *dev = netdev_priv(netdev);
strscpy(info->driver, eth->dev->driver->name, sizeof(info->driver));
strscpy(info->bus_info, dev_name(eth->dev), sizeof(info->bus_info));
-@@ -2168,7 +2170,7 @@ static void airoha_ethtool_get_mac_stats
+@@ -2171,7 +2173,7 @@ static void airoha_ethtool_get_mac_stats
struct airoha_gdm_port *port = dev->port;
unsigned int start;
do {
start = u64_stats_fetch_begin(&port->stats.syncp);
stats->FramesTransmittedOK = port->stats.tx_ok_pkts;
-@@ -2208,7 +2210,7 @@ airoha_ethtool_get_rmon_stats(struct net
+@@ -2211,7 +2213,7 @@ airoha_ethtool_get_rmon_stats(struct net
ARRAY_SIZE(hw_stats->rx_len) + 1);
*ranges = airoha_ethtool_rmon_ranges;
do {
int i;
-@@ -2228,18 +2230,17 @@ static int airoha_qdma_set_chan_tx_sched
+@@ -2231,18 +2233,17 @@ static int airoha_qdma_set_chan_tx_sched
const u16 *weights, u8 n_weights)
{
struct airoha_gdm_dev *dev = netdev_priv(netdev);
TWRR_RW_CMD_MASK |
FIELD_PREP(TWRR_CHAN_IDX_MASK, channel) |
FIELD_PREP(TWRR_QUEUE_IDX_MASK, i) |
-@@ -2247,13 +2248,12 @@ static int airoha_qdma_set_chan_tx_sched
+@@ -2250,13 +2251,12 @@ static int airoha_qdma_set_chan_tx_sched
err = read_poll_timeout(airoha_qdma_rr, status,
status & TWRR_RW_CMD_DONE,
USEC_PER_MSEC, 10 * USEC_PER_MSEC,
CHAN_QOS_MODE_MASK(channel),
__field_prep(CHAN_QOS_MODE_MASK(channel), mode));
-@@ -2319,9 +2319,9 @@ static int airoha_qdma_get_tx_ets_stats(
+@@ -2322,9 +2322,9 @@ static int airoha_qdma_get_tx_ets_stats(
struct airoha_gdm_dev *dev = netdev_priv(netdev);
struct airoha_gdm_port *port = dev->port;
REG_CNTR_VAL((channel << 1) + 1));
u64 tx_packets = (cpu_tx_packets - port->cpu_tx_packets) +
(fwd_tx_packets - port->fwd_tx_packets);
-@@ -2585,17 +2585,16 @@ static int airoha_qdma_set_tx_rate_limit
+@@ -2588,17 +2588,16 @@ static int airoha_qdma_set_tx_rate_limit
u32 bucket_size)
{
struct airoha_gdm_dev *dev = netdev_priv(netdev);
REG_EGRESS_TRTCM_CFG,
i, rate, bucket_size);
if (err)
-@@ -2645,11 +2644,11 @@ static int airoha_tc_htb_alloc_leaf_queu
+@@ -2648,11 +2647,11 @@ static int airoha_tc_htb_alloc_leaf_queu
return 0;
}
int i;
for (i = 0; i < ARRAY_SIZE(qdma->q_rx); i++) {
-@@ -2728,7 +2727,6 @@ static int airoha_dev_tc_matchall(struct
+@@ -2731,7 +2730,6 @@ static int airoha_dev_tc_matchall(struct
{
enum trtcm_unit_type unit_type = TRTCM_BYTE_UNIT;
struct airoha_gdm_dev *dev = netdev_priv(netdev);
u32 rate = 0, bucket_size = 0;
switch (f->command) {
-@@ -2753,7 +2751,7 @@ static int airoha_dev_tc_matchall(struct
+@@ -2756,7 +2754,7 @@ static int airoha_dev_tc_matchall(struct
fallthrough;
}
case TC_CLSMATCHALL_DESTROY:
unit_type);
default:
return -EOPNOTSUPP;
-@@ -2765,8 +2763,7 @@ static int airoha_dev_setup_tc_block_cb(
+@@ -2768,8 +2766,7 @@ static int airoha_dev_setup_tc_block_cb(
{
struct net_device *netdev = cb_priv;
struct airoha_gdm_dev *dev = netdev_priv(netdev);
val = (addr[0] << 16) | (addr[1] << 8) | addr[2];
airoha_fe_wr(eth, reg, val);
-@@ -1868,7 +1866,7 @@ static int airoha_dev_init(struct net_de
+@@ -1871,7 +1869,7 @@ static int airoha_dev_init(struct net_de
int i;
/* QDMA0 is used for lan ports while QDMA1 is used for WAN ports */
--- a/drivers/net/ethernet/airoha/airoha_eth.c
+++ b/drivers/net/ethernet/airoha/airoha_eth.c
-@@ -2602,30 +2602,40 @@ static int airoha_qdma_set_tx_rate_limit
+@@ -2605,30 +2605,40 @@ static int airoha_qdma_set_tx_rate_limit
return 0;
}
err = netif_set_real_num_tx_queues(netdev, num_tx_queues + 1);
if (err) {
-@@ -2633,13 +2643,17 @@ static int airoha_tc_htb_alloc_leaf_queu
+@@ -2636,13 +2646,17 @@ static int airoha_tc_htb_alloc_leaf_queu
opt->quantum);
NL_SET_ERR_MSG_MOD(opt->extack,
"failed setting real_num_tx_queues");
}
static int airoha_qdma_set_rx_meter(struct airoha_gdm_dev *dev,
-@@ -2820,11 +2834,13 @@ static int airoha_dev_setup_tc_block(str
+@@ -2823,11 +2837,13 @@ static int airoha_dev_setup_tc_block(str
static void airoha_tc_remove_htb_queue(struct net_device *netdev, int queue)
{
struct airoha_gdm_dev *dev = netdev_priv(netdev);
}
static int airoha_tc_htb_delete_leaf_queue(struct net_device *netdev,
-@@ -2832,9 +2848,8 @@ static int airoha_tc_htb_delete_leaf_que
+@@ -2835,9 +2851,8 @@ static int airoha_tc_htb_delete_leaf_que
{
u32 channel = TC_H_MIN(opt->classid) % AIROHA_NUM_QOS_CHANNELS;
struct airoha_gdm_dev *dev = netdev_priv(netdev);
NL_SET_ERR_MSG_MOD(opt->extack, "invalid queue id");
return -EINVAL;
}
-@@ -2847,10 +2862,9 @@ static int airoha_tc_htb_delete_leaf_que
+@@ -2850,10 +2865,9 @@ static int airoha_tc_htb_delete_leaf_que
static int airoha_tc_htb_destroy(struct net_device *netdev)
{
struct airoha_gdm_dev *dev = netdev_priv(netdev);
airoha_tc_remove_htb_queue(netdev, q);
return 0;
-@@ -2861,9 +2875,8 @@ static int airoha_tc_get_htb_get_leaf_qu
+@@ -2864,9 +2878,8 @@ static int airoha_tc_get_htb_get_leaf_qu
{
u32 channel = TC_H_MIN(opt->classid) % AIROHA_NUM_QOS_CHANNELS;
struct airoha_gdm_dev *dev = netdev_priv(netdev);
NL_SET_ERR_MSG_MOD(opt->extack, "invalid queue id");
return -EINVAL;
}
-@@ -2882,6 +2895,7 @@ static int airoha_tc_setup_qdisc_htb(str
+@@ -2885,6 +2898,7 @@ static int airoha_tc_setup_qdisc_htb(str
case TC_HTB_DESTROY:
return airoha_tc_htb_destroy(dev);
case TC_HTB_NODE_MODIFY:
--- a/drivers/net/ethernet/airoha/airoha_eth.c
+++ b/drivers/net/ethernet/airoha/airoha_eth.c
-@@ -2315,19 +2315,17 @@ static int airoha_qdma_get_tx_ets_stats(
+@@ -2318,19 +2318,17 @@ static int airoha_qdma_get_tx_ets_stats(
struct tc_ets_qopt_offload *opt)
{
struct airoha_gdm_dev *dev = netdev_priv(netdev);
--- a/drivers/net/ethernet/airoha/airoha_eth.c
+++ b/drivers/net/ethernet/airoha/airoha_eth.c
-@@ -1796,7 +1796,7 @@ static int airoha_dev_set_macaddr(struct
+@@ -1799,7 +1799,7 @@ static int airoha_dev_set_macaddr(struct
return 0;
}
{
struct airoha_gdm_port *port = dev->port;
struct airoha_eth *eth = dev->eth;
-@@ -1877,7 +1877,7 @@ static int airoha_dev_init(struct net_de
+@@ -1880,7 +1880,7 @@ static int airoha_dev_init(struct net_de
if (!eth->ports[1]) {
int err;
+++ /dev/null
-From b38cae85d1c45ff189d7ecb6ac36f41cdc3d84d0 Mon Sep 17 00:00:00 2001
-From: Lorenzo Bianconi <lorenzo@kernel.org>
-Date: Tue, 2 Jun 2026 11:21:04 +0200
-Subject: [PATCH] net: airoha: Fix use-after-free in metadata dst teardown
-
-airoha_metadata_dst_free() runs metadata_dst_free() which frees the
-metadata_dst with kfree() immediately, bypassing the RCU grace period.
-In the RX path, skb_dst_set_noref() sets a non-refcounted pointer from
-the skb to the metadata_dst. This function requires RCU read-side
-protection and the dst must remain valid until all RCU readers complete.
-Since metadata_dst_free() calls kfree() directly, an use-after-free can
-occur if any skb still holds a noref pointer to the dst when the driver
-tears it down.
-Replace metadata_dst_free() with dst_release() which properly goes
-through the refcount path: when the refcount drops to zero, it schedules
-the actual free via call_rcu_hurry(), ensuring all RCU readers have
-completed before the memory is freed.
-
-Fixes: af3cf757d5c9 ("net: airoha: Move DSA tag in DMA descriptor")
-Signed-off-by: Lorenzo Bianconi <lorenzo@kernel.org>
-Link: https://patch.msgid.link/20260602-airoha-mtk-metadata-uaf-fix-v1-1-3aaa99d83351@kernel.org
-Signed-off-by: Jakub Kicinski <kuba@kernel.org>
----
- drivers/net/ethernet/airoha/airoha_eth.c | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
---- a/drivers/net/ethernet/airoha/airoha_eth.c
-+++ b/drivers/net/ethernet/airoha/airoha_eth.c
-@@ -2972,7 +2972,7 @@ static void airoha_metadata_dst_free(str
- if (!port->dsa_meta[i])
- continue;
-
-- metadata_dst_free(port->dsa_meta[i]);
-+ dst_release(&port->dsa_meta[i]->dst);
- }
- }
-
--- a/drivers/net/ethernet/airoha/airoha_eth.c
+++ b/drivers/net/ethernet/airoha/airoha_eth.c
-@@ -2605,13 +2605,19 @@ static int airoha_tc_htb_modify_queue(st
+@@ -2608,13 +2608,19 @@ static int airoha_tc_htb_modify_queue(st
{
u32 channel = TC_H_MIN(opt->classid) % AIROHA_NUM_QOS_CHANNELS;
u32 rate = div_u64(opt->rate, 1000) << 3; /* kbps */
+++ /dev/null
-From f9f25118faa4dd2b6e3d14a03d123bbdbd59925d Mon Sep 17 00:00:00 2001
-From: ZhaoJinming <zhaojinming@uniontech.com>
-Date: Thu, 4 Jun 2026 15:03:52 +0800
-Subject: [PATCH] net: airoha: Add NULL check for of_reserved_mem_lookup() in
- airoha_qdma_init_hfwd_queues()
-
-of_reserved_mem_lookup() may return NULL if the reserved memory region
-referenced by the "memory-region" phandle is not found in the reserved
-memory table (e.g. due to a misconfigured DTS or a removed
-memory-region node). The current code dereferences the returned
-pointer without checking for NULL, leading to a kernel NULL pointer
-dereference at the following lines:
-
- dma_addr = rmem->base; // line 1156
- num_desc = div_u64(rmem->size, buf_size); // line 1160
-
-Add a NULL check after of_reserved_mem_lookup() and return -ENODEV if
-the lookup fails, which is consistent with the existing error handling
-for of_parse_phandle() failure in the same code block.
-
-Fixes: 3a1ce9e3d01b ("net: airoha: Add the capability to allocate hwfd buffers via reserved-memory")
-Cc: stable@vger.kernel.org
-Signed-off-by: ZhaoJinming <zhaojinming@uniontech.com>
-Acked-by: Lorenzo Bianconi <lorenzo@kernel.org>
-Signed-off-by: Jakub Kicinski <kuba@kernel.org>
----
- drivers/net/ethernet/airoha/airoha_eth.c | 3 +++
- 1 file changed, 3 insertions(+)
-
---- a/drivers/net/ethernet/airoha/airoha_eth.c
-+++ b/drivers/net/ethernet/airoha/airoha_eth.c
-@@ -1159,6 +1159,9 @@ static int airoha_qdma_init_hfwd_queues(
-
- rmem = of_reserved_mem_lookup(np);
- of_node_put(np);
-+ if (!rmem)
-+ return -ENODEV;
-+
- dma_addr = rmem->base;
- /* Compute the number of hw descriptors according to the
- * reserved memory size and the payload buffer size
module_phy_driver(as21xxx_drivers);
--- a/drivers/net/phy/phy_device.c
+++ b/drivers/net/phy/phy_device.c
-@@ -1882,7 +1882,8 @@ void phy_detach(struct phy_device *phyde
+@@ -1885,7 +1885,8 @@ void phy_detach(struct phy_device *phyde
}
/* Assert the reset signal */
CONFIG_ARM64_ERRATUM_2441009=y
CONFIG_ARM64_ERRATUM_2457168=y
CONFIG_ARM64_ERRATUM_2658417=y
+CONFIG_ARM64_ERRATUM_4118414=y
CONFIG_ARM64_ERRATUM_4193714=y
CONFIG_ARM64_ERRATUM_819472=y
CONFIG_ARM64_ERRATUM_824069=y
/* Access rules:
* state_hw_drive: st_mutex held
* state_hw_mask: st_mutex held
-@@ -860,6 +877,45 @@ static int sfp_read(struct sfp *sfp, boo
+@@ -861,6 +878,45 @@ static int sfp_read(struct sfp *sfp, boo
return sfp->read(sfp, a2, addr, buf, len);
}
static int sfp_write(struct sfp *sfp, bool a2, u8 addr, void *buf, size_t len)
{
return sfp->write(sfp, a2, addr, buf, len);
-@@ -3158,9 +3214,30 @@ static int sfp_probe(struct platform_dev
+@@ -3159,9 +3215,30 @@ static int sfp_probe(struct platform_dev
sfp->get_state = sfp_gpio_get_state;
sfp->set_state = sfp_gpio_set_state;
eee->eee_enabled = tp->eee_en;
if (speed & _1000bps)
-@@ -9381,6 +9440,11 @@ static int rtl8152_probe_once(struct usb
+@@ -9386,6 +9445,11 @@ static int rtl8152_probe_once(struct usb
} else {
tp->speed = SPEED_1000;
}
default:
version = RTL_VER_UNKNOWN;
dev_info(&udev->dev, "Unknown version 0x%04x\n", ocp_data);
-@@ -9411,6 +9954,7 @@ static int rtl8152_probe_once(struct usb
+@@ -9416,6 +9959,7 @@ static int rtl8152_probe_once(struct usb
case RTL_VER_12:
case RTL_VER_13:
case RTL_VER_15:
netdev->max_mtu = size_to_mtu(16 * 1024);
break;
case RTL_VER_01:
-@@ -9571,6 +10115,7 @@ static const struct usb_device_id rtl815
+@@ -9576,6 +10120,7 @@ static const struct usb_device_id rtl815
{ USB_DEVICE(VENDOR_ID_REALTEK, 0x8153) },
{ USB_DEVICE(VENDOR_ID_REALTEK, 0x8155) },
{ USB_DEVICE(VENDOR_ID_REALTEK, 0x8156) },
# CONFIG_ARM64_ERRATUM_2966298 is not set
# CONFIG_ARM64_ERRATUM_3117295 is not set
# CONFIG_ARM64_ERRATUM_3194386 is not set
+# CONFIG_ARM64_ERRATUM_4118414 is not set
# CONFIG_ARM64_ERRATUM_819472 is not set
# CONFIG_ARM64_ERRATUM_824069 is not set
# CONFIG_ARM64_ERRATUM_826319 is not set
{QMI_FIXED_INTF(0x0408, 0xea42, 4)}, /* Yota / Megafon M100-1 */
--- a/drivers/usb/serial/option.c
+++ b/drivers/usb/serial/option.c
-@@ -247,6 +247,11 @@ static void option_instat_callback(struc
+@@ -248,6 +248,11 @@ static void option_instat_callback(struc
#define UBLOX_PRODUCT_R410M 0x90b2
/* These Yuga products use Qualcomm's vendor ID */
#define YUGA_PRODUCT_CLM920_NC5 0x9625
#define QUECTEL_VENDOR_ID 0x2c7c
/* These Quectel products use Quectel's vendor ID */
-@@ -1156,6 +1161,11 @@ static const struct usb_device_id option
+@@ -1159,6 +1164,11 @@ static const struct usb_device_id option
{ USB_DEVICE(QUALCOMM_VENDOR_ID, 0x0023)}, /* ONYX 3G device */
{ USB_DEVICE(QUALCOMM_VENDOR_ID, 0x9000), /* SIMCom SIM5218 */
.driver_info = NCTRL(0) | NCTRL(1) | NCTRL(2) | NCTRL(3) | RSVD(4) },
/* Quectel products using Qualcomm vendor ID */
{ USB_DEVICE(QUALCOMM_VENDOR_ID, QUECTEL_PRODUCT_UC15)},
{ USB_DEVICE(QUALCOMM_VENDOR_ID, QUECTEL_PRODUCT_UC20),
-@@ -1197,6 +1207,11 @@ static const struct usb_device_id option
+@@ -1200,6 +1210,11 @@ static const struct usb_device_id option
.driver_info = ZLP },
{ USB_DEVICE(QUECTEL_VENDOR_ID, QUECTEL_PRODUCT_BG96),
.driver_info = RSVD(4) },
INDIRECT_CALLABLE_DECLARE(struct dst_entry *ip6_dst_check(struct dst_entry *,
u32));
INDIRECT_CALLABLE_DECLARE(struct dst_entry *ipv4_dst_check(struct dst_entry *,
-@@ -2406,9 +2423,11 @@ static void __sk_free(struct sock *sk)
+@@ -2411,9 +2428,11 @@ static void __sk_free(struct sock *sk)
if (likely(sk->sk_net_refcnt))
sock_inuse_add(sock_net(sk), -1);
--- a/net/core/sock.c
+++ b/net/core/sock.c
-@@ -4349,6 +4349,8 @@ static __net_initdata struct pernet_oper
+@@ -4358,6 +4358,8 @@ static __net_initdata struct pernet_oper
static int __init proto_init(void)
{
-LINUX_VERSION-6.18 = .35
-LINUX_KERNEL_HASH-6.18.35 = f78602932219125e211c5f5bfd84edcfd4ec5ce88fc944f8248413f665bef236
+LINUX_VERSION-6.18 = .36
+LINUX_KERNEL_HASH-6.18.36 = fbab86c9f471c81075b280cca30bd85d790c060063a1245859b6344b07c9c44e
--- a/Makefile
+++ b/Makefile
-@@ -628,7 +628,7 @@ export RUSTC_BOOTSTRAP := 1
+@@ -629,7 +629,7 @@ export RUSTC_BOOTSTRAP := 1
# Allows finding `.clippy.toml` in out-of-srctree builds.
export CLIPPY_CONF_DIR := $(srctree)
}
--- a/net/core/sock.c
+++ b/net/core/sock.c
-@@ -2620,7 +2620,7 @@ void sk_setup_caps(struct sock *sk, stru
+@@ -2625,7 +2625,7 @@ void sk_setup_caps(struct sock *sk, stru
icsk->icsk_ack.dst_quick_ack = dst_metric(dst, RTAX_QUICKACK);
}
if (sk->sk_route_caps & NETIF_F_GSO)
--- a/drivers/net/phy/phy_device.c
+++ b/drivers/net/phy/phy_device.c
-@@ -1836,6 +1836,9 @@ void phy_detach(struct phy_device *phyde
+@@ -1839,6 +1839,9 @@ void phy_detach(struct phy_device *phyde
phydev->devlink = NULL;
}
* CONFIG_CMDLINE is meant to be a default in case nothing else
--- a/arch/arm64/Kconfig
+++ b/arch/arm64/Kconfig
-@@ -2398,6 +2398,14 @@ config CMDLINE_FORCE
+@@ -2436,6 +2436,14 @@ config CMDLINE_FORCE
endchoice
--- a/drivers/net/phy/sfp.c
+++ b/drivers/net/phy/sfp.c
-@@ -841,6 +841,7 @@ static int sfp_i2c_configure(struct sfp
- return -EINVAL;
+@@ -1815,6 +1815,7 @@ static int sfp_hwmon_insert(struct sfp *
+ sfp->hwmon_tries = R_PROBE_RETRY_SLOW;
}
+ sfp->i2c_block_size = sfp->i2c_max_block_size;
static void sfp_i2c_mdiobus_destroy(struct sfp *sfp)
{
mdiobus_unregister(sfp->i2c_mii);
-@@ -2172,9 +2195,15 @@ static void sfp_sm_fault(struct sfp *sfp
+@@ -2173,9 +2196,15 @@ static void sfp_sm_fault(struct sfp *sfp
static int sfp_sm_add_mdio_bus(struct sfp *sfp)
{
CONFIG_ARM64_ERRATUM_2441009=y
CONFIG_ARM64_ERRATUM_2658417=y
CONFIG_ARM64_ERRATUM_3117295=y
+CONFIG_ARM64_ERRATUM_4118414=y
CONFIG_ARM64_ERRATUM_819472=y
CONFIG_ARM64_ERRATUM_824069=y
CONFIG_ARM64_ERRATUM_826319=y