diff options
author | Marek BehĂșn <kabel@kernel.org> | 2023-04-12 13:01:25 +0200 |
---|---|---|
committer | Christian Lamparter <chunkeey@gmail.com> | 2023-06-08 15:33:14 +0200 |
commit | 76cabb95da1994b84a373346c46e52ec836edfc7 (patch) | |
tree | 292892222b3d112739adc67e238e4ea85f84ccd0 /target/linux/mvebu | |
parent | 47437563aafcd7158584cbfc991f754f27aebeba (diff) | |
download | upstream-76cabb95da1994b84a373346c46e52ec836edfc7.tar.gz upstream-76cabb95da1994b84a373346c46e52ec836edfc7.tar.bz2 upstream-76cabb95da1994b84a373346c46e52ec836edfc7.zip |
kernel: Backport mvneta crash fix to 5.15
Backport Russell King's series [1]
net: mvneta: reduce size of TSO header allocation
to pending-5.15 to fix random crashes on Turris Omnia.
This also backports two patches that are dependencies to this series:
net: mvneta: Delete unused variable
net: mvneta: fix potential double-frees in mvneta_txq_sw_deinit()
[1] https://lore.kernel.org/netdev/ZCsbJ4nG+So%2Fn9qY@shell.armlinux.org.uk/
Signed-off-by: Marek BehĂșn <kabel@kernel.org>
Signed-off-by: Christian Lamparter <chunkeey@gmail.com> (squashed)
(cherry picked from commit 7b31c2e9ed4da7bfeecbd393c17c249eca870717)
Diffstat (limited to 'target/linux/mvebu')
5 files changed, 12 insertions, 12 deletions
diff --git a/target/linux/mvebu/patches-5.15/700-mvneta-tx-queue-workaround.patch b/target/linux/mvebu/patches-5.15/700-mvneta-tx-queue-workaround.patch index 826f95d1c2..32e8ef4b7d 100644 --- a/target/linux/mvebu/patches-5.15/700-mvneta-tx-queue-workaround.patch +++ b/target/linux/mvebu/patches-5.15/700-mvneta-tx-queue-workaround.patch @@ -9,7 +9,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name> --- --- a/drivers/net/ethernet/marvell/mvneta.c +++ b/drivers/net/ethernet/marvell/mvneta.c -@@ -4943,6 +4943,16 @@ static int mvneta_setup_tc(struct net_de +@@ -5006,6 +5006,16 @@ static int mvneta_setup_tc(struct net_de } } @@ -26,7 +26,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name> static const struct net_device_ops mvneta_netdev_ops = { .ndo_open = mvneta_open, .ndo_stop = mvneta_stop, -@@ -4953,6 +4963,9 @@ static const struct net_device_ops mvnet +@@ -5016,6 +5026,9 @@ static const struct net_device_ops mvnet .ndo_fix_features = mvneta_fix_features, .ndo_get_stats64 = mvneta_get_stats64, .ndo_eth_ioctl = mvneta_ioctl, diff --git a/target/linux/mvebu/patches-5.15/702-net-next-ethernet-marvell-mvnetaMQPrioOffload.patch b/target/linux/mvebu/patches-5.15/702-net-next-ethernet-marvell-mvnetaMQPrioOffload.patch index c3a6d9f4d0..019b9528c3 100644 --- a/target/linux/mvebu/patches-5.15/702-net-next-ethernet-marvell-mvnetaMQPrioOffload.patch +++ b/target/linux/mvebu/patches-5.15/702-net-next-ethernet-marvell-mvnetaMQPrioOffload.patch @@ -26,7 +26,7 @@ Signed-off-by: David S. Miller <davem@davemloft.net> #include <linux/bpf_trace.h> /* Registers */ -@@ -4903,14 +4904,14 @@ static void mvneta_setup_rx_prio_map(str +@@ -4966,14 +4967,14 @@ static void mvneta_setup_rx_prio_map(str } static int mvneta_setup_mqprio(struct net_device *dev, @@ -44,7 +44,7 @@ Signed-off-by: David S. Miller <davem@davemloft.net> if (num_tc > rxq_number) return -EINVAL; -@@ -4921,13 +4922,15 @@ static int mvneta_setup_mqprio(struct ne +@@ -4984,13 +4985,15 @@ static int mvneta_setup_mqprio(struct ne return 0; } diff --git a/target/linux/mvebu/patches-5.15/703-net-next-ethernet-marvell-mvnetaMQPrioFlag.patch b/target/linux/mvebu/patches-5.15/703-net-next-ethernet-marvell-mvnetaMQPrioFlag.patch index 8ef585be9a..c878a28843 100644 --- a/target/linux/mvebu/patches-5.15/703-net-next-ethernet-marvell-mvnetaMQPrioFlag.patch +++ b/target/linux/mvebu/patches-5.15/703-net-next-ethernet-marvell-mvnetaMQPrioFlag.patch @@ -17,7 +17,7 @@ Signed-off-by: David S. Miller <davem@davemloft.net> --- a/drivers/net/ethernet/marvell/mvneta.c +++ b/drivers/net/ethernet/marvell/mvneta.c -@@ -4910,7 +4910,9 @@ static int mvneta_setup_mqprio(struct ne +@@ -4973,7 +4973,9 @@ static int mvneta_setup_mqprio(struct ne u8 num_tc; int i; diff --git a/target/linux/mvebu/patches-5.15/704-net-next-ethernet-marvell-mvnetaMQPrioQueue.patch b/target/linux/mvebu/patches-5.15/704-net-next-ethernet-marvell-mvnetaMQPrioQueue.patch index 196b986541..546a8486ef 100644 --- a/target/linux/mvebu/patches-5.15/704-net-next-ethernet-marvell-mvnetaMQPrioQueue.patch +++ b/target/linux/mvebu/patches-5.15/704-net-next-ethernet-marvell-mvnetaMQPrioQueue.patch @@ -22,7 +22,7 @@ Signed-off-by: David S. Miller <davem@davemloft.net> --- a/drivers/net/ethernet/marvell/mvneta.c +++ b/drivers/net/ethernet/marvell/mvneta.c -@@ -493,7 +493,6 @@ struct mvneta_port { +@@ -498,7 +498,6 @@ struct mvneta_port { u8 mcast_count[256]; u16 tx_ring_size; u16 rx_ring_size; @@ -30,7 +30,7 @@ Signed-off-by: David S. Miller <davem@davemloft.net> phy_interface_t phy_interface; struct device_node *dn; -@@ -4892,13 +4891,12 @@ static void mvneta_clear_rx_prio_map(str +@@ -4955,13 +4954,12 @@ static void mvneta_clear_rx_prio_map(str mvreg_write(pp, MVNETA_VLAN_PRIO_TO_RXQ, 0); } @@ -48,7 +48,7 @@ Signed-off-by: David S. Miller <davem@davemloft.net> mvreg_write(pp, MVNETA_VLAN_PRIO_TO_RXQ, val); } -@@ -4907,8 +4905,8 @@ static int mvneta_setup_mqprio(struct ne +@@ -4970,8 +4968,8 @@ static int mvneta_setup_mqprio(struct ne struct tc_mqprio_qopt_offload *mqprio) { struct mvneta_port *pp = netdev_priv(dev); @@ -58,7 +58,7 @@ Signed-off-by: David S. Miller <davem@davemloft.net> if (mqprio->qopt.hw != TC_MQPRIO_HW_OFFLOAD_TCS) return 0; -@@ -4918,21 +4916,28 @@ static int mvneta_setup_mqprio(struct ne +@@ -4981,21 +4979,28 @@ static int mvneta_setup_mqprio(struct ne if (num_tc > rxq_number) return -EINVAL; diff --git a/target/linux/mvebu/patches-5.15/705-net-next-ethernet-marvell-mvnetaMQPrioTCOffload.patch b/target/linux/mvebu/patches-5.15/705-net-next-ethernet-marvell-mvnetaMQPrioTCOffload.patch index d640da4d44..1d4a055a71 100644 --- a/target/linux/mvebu/patches-5.15/705-net-next-ethernet-marvell-mvnetaMQPrioTCOffload.patch +++ b/target/linux/mvebu/patches-5.15/705-net-next-ethernet-marvell-mvnetaMQPrioTCOffload.patch @@ -62,7 +62,7 @@ Signed-off-by: David S. Miller <davem@davemloft.net> #define MVNETA_LPI_CTRL_0 0x2cc0 #define MVNETA_LPI_CTRL_1 0x2cc4 #define MVNETA_LPI_REQUEST_ENABLE BIT(0) -@@ -4901,11 +4928,74 @@ static void mvneta_map_vlan_prio_to_rxq( +@@ -4964,11 +4991,74 @@ static void mvneta_map_vlan_prio_to_rxq( mvreg_write(pp, MVNETA_VLAN_PRIO_TO_RXQ, val); } @@ -138,7 +138,7 @@ Signed-off-by: David S. Miller <davem@davemloft.net> u8 num_tc; if (mqprio->qopt.hw != TC_MQPRIO_HW_OFFLOAD_TCS) -@@ -4919,6 +5009,7 @@ static int mvneta_setup_mqprio(struct ne +@@ -4982,6 +5072,7 @@ static int mvneta_setup_mqprio(struct ne mvneta_clear_rx_prio_map(pp); if (!num_tc) { @@ -146,7 +146,7 @@ Signed-off-by: David S. Miller <davem@davemloft.net> netdev_reset_tc(dev); return 0; } -@@ -4939,6 +5030,33 @@ static int mvneta_setup_mqprio(struct ne +@@ -5002,6 +5093,33 @@ static int mvneta_setup_mqprio(struct ne } } |