]> git.ipfire.org Git - thirdparty/kernel/stable-queue.git/commitdiff
drop cortina patch from older kernels
authorGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Mon, 14 Oct 2024 13:05:06 +0000 (15:05 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Mon, 14 Oct 2024 13:05:06 +0000 (15:05 +0200)
queue-4.19/net-ethernet-cortina-restore-tso-support.patch [deleted file]
queue-4.19/series
queue-5.10/net-ethernet-cortina-restore-tso-support.patch [deleted file]
queue-5.10/series
queue-5.15/net-ethernet-cortina-restore-tso-support.patch [deleted file]
queue-5.15/series
queue-5.4/net-ethernet-cortina-restore-tso-support.patch [deleted file]
queue-5.4/series

diff --git a/queue-4.19/net-ethernet-cortina-restore-tso-support.patch b/queue-4.19/net-ethernet-cortina-restore-tso-support.patch
deleted file mode 100644 (file)
index c19ae40..0000000
+++ /dev/null
@@ -1,130 +0,0 @@
-From 2942dfab630444d46aaa37fb7d629b620abbf6ba Mon Sep 17 00:00:00 2001
-From: Linus Walleij <linus.walleij@linaro.org>
-Date: Mon, 27 May 2024 21:26:44 +0200
-Subject: net: ethernet: cortina: Restore TSO support
-
-From: Linus Walleij <linus.walleij@linaro.org>
-
-commit 2942dfab630444d46aaa37fb7d629b620abbf6ba upstream.
-
-An earlier commit deleted the TSO support in the Cortina Gemini
-driver because the driver was confusing gso_size and MTU,
-probably because what the Linux kernel calls "gso_size" was
-called "MTU" in the datasheet.
-
-Restore the functionality properly reading the gso_size from
-the skbuff.
-
-Tested with iperf3, running a server on a different machine
-and client on the device with the cortina gemini ethernet:
-
-Connecting to host 192.168.1.2, port 5201
-60008000.ethernet-port eth0: segment offloading mss = 05ea len=1c8a
-60008000.ethernet-port eth0: segment offloading mss = 05ea len=1c8a
-60008000.ethernet-port eth0: segment offloading mss = 05ea len=27da
-60008000.ethernet-port eth0: segment offloading mss = 05ea len=0b92
-60008000.ethernet-port eth0: segment offloading mss = 05ea len=2bda
-(...)
-
-(The hardware MSS 0x05ea here includes the ethernet headers.)
-
-If I disable all segment offloading on the receiving host and
-dump packets using tcpdump -xx like this:
-
-ethtool -K enp2s0 gro off gso off tso off
-tcpdump -xx -i enp2s0 host 192.168.1.136
-
-I get segmented packages such as this when running iperf3:
-
-23:16:54.024139 IP OpenWrt.lan.59168 > Fecusia.targus-getdata1:
-Flags [.], seq 1486:2934, ack 1, win 4198,
-options [nop,nop,TS val 3886192908 ecr 3601341877], length 1448
-0x0000:  fc34 9701 a0c6 14d6 4da8 3c4f 0800 4500
-0x0010:  05dc 16a0 4000 4006 9aa1 c0a8 0188 c0a8
-0x0020:  0102 e720 1451 ff25 9822 4c52 29cf 8010
-0x0030:  1066 ac8c 0000 0101 080a e7a2 990c d6a8
-(...)
-0x05c0:  5e49 e109 fe8c 4617 5e18 7a82 7eae d647
-0x05d0:  e8ee ae64 dc88 c897 3f8a 07a4 3a33 6b1b
-0x05e0:  3501 a30f 2758 cc44 4b4a
-
-Several such packets often follow after each other verifying
-the segmentation into 0x05a8 (1448) byte packages also on the
-reveiving end. As can be seen, the ethernet frames are
-0x05ea (1514) in size.
-
-Performance with iperf3 before this patch: ~15.5 Mbit/s
-Performance with iperf3 after this patch: ~175 Mbit/s
-
-This was running a 60 second test (twice) the best measurement
-was 179 Mbit/s.
-
-For comparison if I run iperf3 with UDP I get around 1.05 Mbit/s
-both before and after this patch.
-
-While this is a gigabit ethernet interface, the CPU is a cheap
-D-Link DIR-685 router (based on the ARMv5 Faraday FA526 at
-~50 MHz), and the software is not supposed to drive traffic,
-as the device has a DSA chip, so this kind of numbers can be
-expected.
-
-Fixes: ac631873c9e7 ("net: ethernet: cortina: Drop TSO support")
-Reviewed-by: Eric Dumazet <edumazet@google.com>
-Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
-Signed-off-by: David S. Miller <davem@davemloft.net>
-Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
----
- drivers/net/ethernet/cortina/gemini.c |   23 +++++++++++++++++++----
- 1 file changed, 19 insertions(+), 4 deletions(-)
-
---- a/drivers/net/ethernet/cortina/gemini.c
-+++ b/drivers/net/ethernet/cortina/gemini.c
-@@ -81,7 +81,8 @@ MODULE_PARM_DESC(debug, "Debug level (0=
- #define GMAC0_IRQ4_8 (GMAC0_MIB_INT_BIT | GMAC0_RX_OVERRUN_INT_BIT)
- #define GMAC_OFFLOAD_FEATURES (NETIF_F_SG | NETIF_F_IP_CSUM | \
--                             NETIF_F_IPV6_CSUM | NETIF_F_RXCSUM)
-+                             NETIF_F_IPV6_CSUM | NETIF_F_RXCSUM | \
-+                             NETIF_F_TSO | NETIF_F_TSO_ECN | NETIF_F_TSO6)
- /**
-  * struct gmac_queue_page - page buffer per-page info
-@@ -1156,13 +1157,25 @@ static int gmac_map_tx_bufs(struct net_d
-       skb_frag_t *skb_frag;
-       dma_addr_t mapping;
-       void *buffer;
-+      u16 mss;
-       int ret;
--      /* TODO: implement proper TSO using MTU in word3 */
-       word1 = skb->len;
-       word3 = SOF_BIT;
--      if (skb->len >= ETH_FRAME_LEN) {
-+      mss = skb_shinfo(skb)->gso_size;
-+      if (mss) {
-+              /* This means we are dealing with TCP and skb->len is the
-+               * sum total of all the segments. The TSO will deal with
-+               * chopping this up for us.
-+               */
-+              /* The accelerator needs the full frame size here */
-+              mss += skb_tcp_all_headers(skb);
-+              netdev_dbg(netdev, "segment offloading mss = %04x len=%04x\n",
-+                         mss, skb->len);
-+              word1 |= TSS_MTU_ENABLE_BIT;
-+              word3 |= mss;
-+      } else if (skb->len >= ETH_FRAME_LEN) {
-               /* Hardware offloaded checksumming isn't working on frames
-                * bigger than 1514 bytes. A hypothesis about this is that the
-                * checksum buffer is only 1518 bytes, so when the frames get
-@@ -1177,7 +1190,9 @@ static int gmac_map_tx_bufs(struct net_d
-                               return ret;
-               }
-               word1 |= TSS_BYPASS_BIT;
--      } else if (skb->ip_summed == CHECKSUM_PARTIAL) {
-+      }
-+
-+      if (skb->ip_summed == CHECKSUM_PARTIAL) {
-               int tcp = 0;
-               /* We do not switch off the checksumming on non TCP/UDP
index 21ae1194aa3004e81fea42eed64732ab3b2be242..d2482fdfd8932d1ba6b1aef41cfec87cfb96aef8 100644 (file)
@@ -266,4 +266,3 @@ revert-usb-yurex-replace-snprintf-with-the-safer-scnprintf-variant.patch
 usb-xhci-fix-problem-with-xhci-resume-from-suspend.patch
 usb-storage-ignore-bogus-device-raised-by-jieli-br21-usb-sound-chip.patch
 net-fix-an-unsafe-loop-on-the-list.patch
-net-ethernet-cortina-restore-tso-support.patch
diff --git a/queue-5.10/net-ethernet-cortina-restore-tso-support.patch b/queue-5.10/net-ethernet-cortina-restore-tso-support.patch
deleted file mode 100644 (file)
index 5c7adb6..0000000
+++ /dev/null
@@ -1,130 +0,0 @@
-From 2942dfab630444d46aaa37fb7d629b620abbf6ba Mon Sep 17 00:00:00 2001
-From: Linus Walleij <linus.walleij@linaro.org>
-Date: Mon, 27 May 2024 21:26:44 +0200
-Subject: net: ethernet: cortina: Restore TSO support
-
-From: Linus Walleij <linus.walleij@linaro.org>
-
-commit 2942dfab630444d46aaa37fb7d629b620abbf6ba upstream.
-
-An earlier commit deleted the TSO support in the Cortina Gemini
-driver because the driver was confusing gso_size and MTU,
-probably because what the Linux kernel calls "gso_size" was
-called "MTU" in the datasheet.
-
-Restore the functionality properly reading the gso_size from
-the skbuff.
-
-Tested with iperf3, running a server on a different machine
-and client on the device with the cortina gemini ethernet:
-
-Connecting to host 192.168.1.2, port 5201
-60008000.ethernet-port eth0: segment offloading mss = 05ea len=1c8a
-60008000.ethernet-port eth0: segment offloading mss = 05ea len=1c8a
-60008000.ethernet-port eth0: segment offloading mss = 05ea len=27da
-60008000.ethernet-port eth0: segment offloading mss = 05ea len=0b92
-60008000.ethernet-port eth0: segment offloading mss = 05ea len=2bda
-(...)
-
-(The hardware MSS 0x05ea here includes the ethernet headers.)
-
-If I disable all segment offloading on the receiving host and
-dump packets using tcpdump -xx like this:
-
-ethtool -K enp2s0 gro off gso off tso off
-tcpdump -xx -i enp2s0 host 192.168.1.136
-
-I get segmented packages such as this when running iperf3:
-
-23:16:54.024139 IP OpenWrt.lan.59168 > Fecusia.targus-getdata1:
-Flags [.], seq 1486:2934, ack 1, win 4198,
-options [nop,nop,TS val 3886192908 ecr 3601341877], length 1448
-0x0000:  fc34 9701 a0c6 14d6 4da8 3c4f 0800 4500
-0x0010:  05dc 16a0 4000 4006 9aa1 c0a8 0188 c0a8
-0x0020:  0102 e720 1451 ff25 9822 4c52 29cf 8010
-0x0030:  1066 ac8c 0000 0101 080a e7a2 990c d6a8
-(...)
-0x05c0:  5e49 e109 fe8c 4617 5e18 7a82 7eae d647
-0x05d0:  e8ee ae64 dc88 c897 3f8a 07a4 3a33 6b1b
-0x05e0:  3501 a30f 2758 cc44 4b4a
-
-Several such packets often follow after each other verifying
-the segmentation into 0x05a8 (1448) byte packages also on the
-reveiving end. As can be seen, the ethernet frames are
-0x05ea (1514) in size.
-
-Performance with iperf3 before this patch: ~15.5 Mbit/s
-Performance with iperf3 after this patch: ~175 Mbit/s
-
-This was running a 60 second test (twice) the best measurement
-was 179 Mbit/s.
-
-For comparison if I run iperf3 with UDP I get around 1.05 Mbit/s
-both before and after this patch.
-
-While this is a gigabit ethernet interface, the CPU is a cheap
-D-Link DIR-685 router (based on the ARMv5 Faraday FA526 at
-~50 MHz), and the software is not supposed to drive traffic,
-as the device has a DSA chip, so this kind of numbers can be
-expected.
-
-Fixes: ac631873c9e7 ("net: ethernet: cortina: Drop TSO support")
-Reviewed-by: Eric Dumazet <edumazet@google.com>
-Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
-Signed-off-by: David S. Miller <davem@davemloft.net>
-Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
----
- drivers/net/ethernet/cortina/gemini.c |   23 +++++++++++++++++++----
- 1 file changed, 19 insertions(+), 4 deletions(-)
-
---- a/drivers/net/ethernet/cortina/gemini.c
-+++ b/drivers/net/ethernet/cortina/gemini.c
-@@ -80,7 +80,8 @@ MODULE_PARM_DESC(debug, "Debug level (0=
- #define GMAC0_IRQ4_8 (GMAC0_MIB_INT_BIT | GMAC0_RX_OVERRUN_INT_BIT)
- #define GMAC_OFFLOAD_FEATURES (NETIF_F_SG | NETIF_F_IP_CSUM | \
--                             NETIF_F_IPV6_CSUM | NETIF_F_RXCSUM)
-+                             NETIF_F_IPV6_CSUM | NETIF_F_RXCSUM | \
-+                             NETIF_F_TSO | NETIF_F_TSO_ECN | NETIF_F_TSO6)
- /**
-  * struct gmac_queue_page - page buffer per-page info
-@@ -1149,13 +1150,25 @@ static int gmac_map_tx_bufs(struct net_d
-       skb_frag_t *skb_frag;
-       dma_addr_t mapping;
-       void *buffer;
-+      u16 mss;
-       int ret;
--      /* TODO: implement proper TSO using MTU in word3 */
-       word1 = skb->len;
-       word3 = SOF_BIT;
--      if (skb->len >= ETH_FRAME_LEN) {
-+      mss = skb_shinfo(skb)->gso_size;
-+      if (mss) {
-+              /* This means we are dealing with TCP and skb->len is the
-+               * sum total of all the segments. The TSO will deal with
-+               * chopping this up for us.
-+               */
-+              /* The accelerator needs the full frame size here */
-+              mss += skb_tcp_all_headers(skb);
-+              netdev_dbg(netdev, "segment offloading mss = %04x len=%04x\n",
-+                         mss, skb->len);
-+              word1 |= TSS_MTU_ENABLE_BIT;
-+              word3 |= mss;
-+      } else if (skb->len >= ETH_FRAME_LEN) {
-               /* Hardware offloaded checksumming isn't working on frames
-                * bigger than 1514 bytes. A hypothesis about this is that the
-                * checksum buffer is only 1518 bytes, so when the frames get
-@@ -1170,7 +1183,9 @@ static int gmac_map_tx_bufs(struct net_d
-                               return ret;
-               }
-               word1 |= TSS_BYPASS_BIT;
--      } else if (skb->ip_summed == CHECKSUM_PARTIAL) {
-+      }
-+
-+      if (skb->ip_summed == CHECKSUM_PARTIAL) {
-               int tcp = 0;
-               /* We do not switch off the checksumming on non TCP/UDP
index f06a3ea80423745baba8c7126218934ba28d3633..d2beeb70856b6b90ba4c734a52ac86ad74b012b8 100644 (file)
@@ -515,4 +515,3 @@ hid-intel-ish-hid-fix-uninitialized-variable-rv-in-ish_fw_xfer_direct_dma.patch
 net-fix-an-unsafe-loop-on-the-list.patch
 net-dsa-lan9303-ensure-chip-reset-and-wait-for-ready-status.patch
 nouveau-dmem-fix-vulnerability-in-migrate_to_ram-upon-copy-error.patch
-net-ethernet-cortina-restore-tso-support.patch
diff --git a/queue-5.15/net-ethernet-cortina-restore-tso-support.patch b/queue-5.15/net-ethernet-cortina-restore-tso-support.patch
deleted file mode 100644 (file)
index 4f058bb..0000000
+++ /dev/null
@@ -1,130 +0,0 @@
-From 2942dfab630444d46aaa37fb7d629b620abbf6ba Mon Sep 17 00:00:00 2001
-From: Linus Walleij <linus.walleij@linaro.org>
-Date: Mon, 27 May 2024 21:26:44 +0200
-Subject: net: ethernet: cortina: Restore TSO support
-
-From: Linus Walleij <linus.walleij@linaro.org>
-
-commit 2942dfab630444d46aaa37fb7d629b620abbf6ba upstream.
-
-An earlier commit deleted the TSO support in the Cortina Gemini
-driver because the driver was confusing gso_size and MTU,
-probably because what the Linux kernel calls "gso_size" was
-called "MTU" in the datasheet.
-
-Restore the functionality properly reading the gso_size from
-the skbuff.
-
-Tested with iperf3, running a server on a different machine
-and client on the device with the cortina gemini ethernet:
-
-Connecting to host 192.168.1.2, port 5201
-60008000.ethernet-port eth0: segment offloading mss = 05ea len=1c8a
-60008000.ethernet-port eth0: segment offloading mss = 05ea len=1c8a
-60008000.ethernet-port eth0: segment offloading mss = 05ea len=27da
-60008000.ethernet-port eth0: segment offloading mss = 05ea len=0b92
-60008000.ethernet-port eth0: segment offloading mss = 05ea len=2bda
-(...)
-
-(The hardware MSS 0x05ea here includes the ethernet headers.)
-
-If I disable all segment offloading on the receiving host and
-dump packets using tcpdump -xx like this:
-
-ethtool -K enp2s0 gro off gso off tso off
-tcpdump -xx -i enp2s0 host 192.168.1.136
-
-I get segmented packages such as this when running iperf3:
-
-23:16:54.024139 IP OpenWrt.lan.59168 > Fecusia.targus-getdata1:
-Flags [.], seq 1486:2934, ack 1, win 4198,
-options [nop,nop,TS val 3886192908 ecr 3601341877], length 1448
-0x0000:  fc34 9701 a0c6 14d6 4da8 3c4f 0800 4500
-0x0010:  05dc 16a0 4000 4006 9aa1 c0a8 0188 c0a8
-0x0020:  0102 e720 1451 ff25 9822 4c52 29cf 8010
-0x0030:  1066 ac8c 0000 0101 080a e7a2 990c d6a8
-(...)
-0x05c0:  5e49 e109 fe8c 4617 5e18 7a82 7eae d647
-0x05d0:  e8ee ae64 dc88 c897 3f8a 07a4 3a33 6b1b
-0x05e0:  3501 a30f 2758 cc44 4b4a
-
-Several such packets often follow after each other verifying
-the segmentation into 0x05a8 (1448) byte packages also on the
-reveiving end. As can be seen, the ethernet frames are
-0x05ea (1514) in size.
-
-Performance with iperf3 before this patch: ~15.5 Mbit/s
-Performance with iperf3 after this patch: ~175 Mbit/s
-
-This was running a 60 second test (twice) the best measurement
-was 179 Mbit/s.
-
-For comparison if I run iperf3 with UDP I get around 1.05 Mbit/s
-both before and after this patch.
-
-While this is a gigabit ethernet interface, the CPU is a cheap
-D-Link DIR-685 router (based on the ARMv5 Faraday FA526 at
-~50 MHz), and the software is not supposed to drive traffic,
-as the device has a DSA chip, so this kind of numbers can be
-expected.
-
-Fixes: ac631873c9e7 ("net: ethernet: cortina: Drop TSO support")
-Reviewed-by: Eric Dumazet <edumazet@google.com>
-Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
-Signed-off-by: David S. Miller <davem@davemloft.net>
-Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
----
- drivers/net/ethernet/cortina/gemini.c |   23 +++++++++++++++++++----
- 1 file changed, 19 insertions(+), 4 deletions(-)
-
---- a/drivers/net/ethernet/cortina/gemini.c
-+++ b/drivers/net/ethernet/cortina/gemini.c
-@@ -79,7 +79,8 @@ MODULE_PARM_DESC(debug, "Debug level (0=
- #define GMAC0_IRQ4_8 (GMAC0_MIB_INT_BIT | GMAC0_RX_OVERRUN_INT_BIT)
- #define GMAC_OFFLOAD_FEATURES (NETIF_F_SG | NETIF_F_IP_CSUM | \
--                             NETIF_F_IPV6_CSUM | NETIF_F_RXCSUM)
-+                             NETIF_F_IPV6_CSUM | NETIF_F_RXCSUM | \
-+                             NETIF_F_TSO | NETIF_F_TSO_ECN | NETIF_F_TSO6)
- /**
-  * struct gmac_queue_page - page buffer per-page info
-@@ -1148,13 +1149,25 @@ static int gmac_map_tx_bufs(struct net_d
-       skb_frag_t *skb_frag;
-       dma_addr_t mapping;
-       void *buffer;
-+      u16 mss;
-       int ret;
--      /* TODO: implement proper TSO using MTU in word3 */
-       word1 = skb->len;
-       word3 = SOF_BIT;
--      if (skb->len >= ETH_FRAME_LEN) {
-+      mss = skb_shinfo(skb)->gso_size;
-+      if (mss) {
-+              /* This means we are dealing with TCP and skb->len is the
-+               * sum total of all the segments. The TSO will deal with
-+               * chopping this up for us.
-+               */
-+              /* The accelerator needs the full frame size here */
-+              mss += skb_tcp_all_headers(skb);
-+              netdev_dbg(netdev, "segment offloading mss = %04x len=%04x\n",
-+                         mss, skb->len);
-+              word1 |= TSS_MTU_ENABLE_BIT;
-+              word3 |= mss;
-+      } else if (skb->len >= ETH_FRAME_LEN) {
-               /* Hardware offloaded checksumming isn't working on frames
-                * bigger than 1514 bytes. A hypothesis about this is that the
-                * checksum buffer is only 1518 bytes, so when the frames get
-@@ -1169,7 +1182,9 @@ static int gmac_map_tx_bufs(struct net_d
-                               return ret;
-               }
-               word1 |= TSS_BYPASS_BIT;
--      } else if (skb->ip_summed == CHECKSUM_PARTIAL) {
-+      }
-+
-+      if (skb->ip_summed == CHECKSUM_PARTIAL) {
-               int tcp = 0;
-               /* We do not switch off the checksumming on non TCP/UDP
index 7bf838d5645de6f920e4a210e65a0438c65089af..a1ae9879344e9a82ea30f6d550a51fbab63874ba 100644 (file)
@@ -683,4 +683,3 @@ net-dsa-lan9303-ensure-chip-reset-and-wait-for-ready-status.patch
 mptcp-pm-do-not-remove-closing-subflows.patch
 nouveau-dmem-fix-vulnerability-in-migrate_to_ram-upon-copy-error.patch
 kthread-unpark-only-parked-kthread.patch
-net-ethernet-cortina-restore-tso-support.patch
diff --git a/queue-5.4/net-ethernet-cortina-restore-tso-support.patch b/queue-5.4/net-ethernet-cortina-restore-tso-support.patch
deleted file mode 100644 (file)
index a82ad6e..0000000
+++ /dev/null
@@ -1,130 +0,0 @@
-From 2942dfab630444d46aaa37fb7d629b620abbf6ba Mon Sep 17 00:00:00 2001
-From: Linus Walleij <linus.walleij@linaro.org>
-Date: Mon, 27 May 2024 21:26:44 +0200
-Subject: net: ethernet: cortina: Restore TSO support
-
-From: Linus Walleij <linus.walleij@linaro.org>
-
-commit 2942dfab630444d46aaa37fb7d629b620abbf6ba upstream.
-
-An earlier commit deleted the TSO support in the Cortina Gemini
-driver because the driver was confusing gso_size and MTU,
-probably because what the Linux kernel calls "gso_size" was
-called "MTU" in the datasheet.
-
-Restore the functionality properly reading the gso_size from
-the skbuff.
-
-Tested with iperf3, running a server on a different machine
-and client on the device with the cortina gemini ethernet:
-
-Connecting to host 192.168.1.2, port 5201
-60008000.ethernet-port eth0: segment offloading mss = 05ea len=1c8a
-60008000.ethernet-port eth0: segment offloading mss = 05ea len=1c8a
-60008000.ethernet-port eth0: segment offloading mss = 05ea len=27da
-60008000.ethernet-port eth0: segment offloading mss = 05ea len=0b92
-60008000.ethernet-port eth0: segment offloading mss = 05ea len=2bda
-(...)
-
-(The hardware MSS 0x05ea here includes the ethernet headers.)
-
-If I disable all segment offloading on the receiving host and
-dump packets using tcpdump -xx like this:
-
-ethtool -K enp2s0 gro off gso off tso off
-tcpdump -xx -i enp2s0 host 192.168.1.136
-
-I get segmented packages such as this when running iperf3:
-
-23:16:54.024139 IP OpenWrt.lan.59168 > Fecusia.targus-getdata1:
-Flags [.], seq 1486:2934, ack 1, win 4198,
-options [nop,nop,TS val 3886192908 ecr 3601341877], length 1448
-0x0000:  fc34 9701 a0c6 14d6 4da8 3c4f 0800 4500
-0x0010:  05dc 16a0 4000 4006 9aa1 c0a8 0188 c0a8
-0x0020:  0102 e720 1451 ff25 9822 4c52 29cf 8010
-0x0030:  1066 ac8c 0000 0101 080a e7a2 990c d6a8
-(...)
-0x05c0:  5e49 e109 fe8c 4617 5e18 7a82 7eae d647
-0x05d0:  e8ee ae64 dc88 c897 3f8a 07a4 3a33 6b1b
-0x05e0:  3501 a30f 2758 cc44 4b4a
-
-Several such packets often follow after each other verifying
-the segmentation into 0x05a8 (1448) byte packages also on the
-reveiving end. As can be seen, the ethernet frames are
-0x05ea (1514) in size.
-
-Performance with iperf3 before this patch: ~15.5 Mbit/s
-Performance with iperf3 after this patch: ~175 Mbit/s
-
-This was running a 60 second test (twice) the best measurement
-was 179 Mbit/s.
-
-For comparison if I run iperf3 with UDP I get around 1.05 Mbit/s
-both before and after this patch.
-
-While this is a gigabit ethernet interface, the CPU is a cheap
-D-Link DIR-685 router (based on the ARMv5 Faraday FA526 at
-~50 MHz), and the software is not supposed to drive traffic,
-as the device has a DSA chip, so this kind of numbers can be
-expected.
-
-Fixes: ac631873c9e7 ("net: ethernet: cortina: Drop TSO support")
-Reviewed-by: Eric Dumazet <edumazet@google.com>
-Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
-Signed-off-by: David S. Miller <davem@davemloft.net>
-Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
----
- drivers/net/ethernet/cortina/gemini.c |   23 +++++++++++++++++++----
- 1 file changed, 19 insertions(+), 4 deletions(-)
-
---- a/drivers/net/ethernet/cortina/gemini.c
-+++ b/drivers/net/ethernet/cortina/gemini.c
-@@ -81,7 +81,8 @@ MODULE_PARM_DESC(debug, "Debug level (0=
- #define GMAC0_IRQ4_8 (GMAC0_MIB_INT_BIT | GMAC0_RX_OVERRUN_INT_BIT)
- #define GMAC_OFFLOAD_FEATURES (NETIF_F_SG | NETIF_F_IP_CSUM | \
--                             NETIF_F_IPV6_CSUM | NETIF_F_RXCSUM)
-+                             NETIF_F_IPV6_CSUM | NETIF_F_RXCSUM | \
-+                             NETIF_F_TSO | NETIF_F_TSO_ECN | NETIF_F_TSO6)
- /**
-  * struct gmac_queue_page - page buffer per-page info
-@@ -1155,13 +1156,25 @@ static int gmac_map_tx_bufs(struct net_d
-       skb_frag_t *skb_frag;
-       dma_addr_t mapping;
-       void *buffer;
-+      u16 mss;
-       int ret;
--      /* TODO: implement proper TSO using MTU in word3 */
-       word1 = skb->len;
-       word3 = SOF_BIT;
--      if (skb->len >= ETH_FRAME_LEN) {
-+      mss = skb_shinfo(skb)->gso_size;
-+      if (mss) {
-+              /* This means we are dealing with TCP and skb->len is the
-+               * sum total of all the segments. The TSO will deal with
-+               * chopping this up for us.
-+               */
-+              /* The accelerator needs the full frame size here */
-+              mss += skb_tcp_all_headers(skb);
-+              netdev_dbg(netdev, "segment offloading mss = %04x len=%04x\n",
-+                         mss, skb->len);
-+              word1 |= TSS_MTU_ENABLE_BIT;
-+              word3 |= mss;
-+      } else if (skb->len >= ETH_FRAME_LEN) {
-               /* Hardware offloaded checksumming isn't working on frames
-                * bigger than 1514 bytes. A hypothesis about this is that the
-                * checksum buffer is only 1518 bytes, so when the frames get
-@@ -1176,7 +1189,9 @@ static int gmac_map_tx_bufs(struct net_d
-                               return ret;
-               }
-               word1 |= TSS_BYPASS_BIT;
--      } else if (skb->ip_summed == CHECKSUM_PARTIAL) {
-+      }
-+
-+      if (skb->ip_summed == CHECKSUM_PARTIAL) {
-               int tcp = 0;
-               /* We do not switch off the checksumming on non TCP/UDP
index 42ded92e86a45256f4919ae9e7705745fab8193b..466ae56bff6744b831867fdb24191c88e379525f 100644 (file)
@@ -356,4 +356,3 @@ usb-storage-ignore-bogus-device-raised-by-jieli-br21-usb-sound-chip.patch
 hid-intel-ish-hid-fix-uninitialized-variable-rv-in-ish_fw_xfer_direct_dma.patch
 net-fix-an-unsafe-loop-on-the-list.patch
 nouveau-dmem-fix-vulnerability-in-migrate_to_ram-upon-copy-error.patch
-net-ethernet-cortina-restore-tso-support.patch