netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH net-next] selftests/net: packetdrill: add --mss option to three tests
@ 2025-07-10 15:56 Eric Dumazet
  2025-07-10 19:39 ` Willem de Bruijn
  2025-07-12  0:40 ` patchwork-bot+netdevbpf
  0 siblings, 2 replies; 3+ messages in thread
From: Eric Dumazet @ 2025-07-10 15:56 UTC (permalink / raw)
  To: David S . Miller, Jakub Kicinski, Paolo Abeni, Neal Cardwell
  Cc: Simon Horman, Kuniyuki Iwashima, Willem de Bruijn, netdev,
	eric.dumazet, Eric Dumazet

Three tests are cooking GSO packets but do not provide
gso_size information to the kernel, triggering this message:

TCP: tun0: Driver has suspect GRO implementation, TCP performance may be compromised.

Add --mss option to avoid this warning.

Signed-off-by: Eric Dumazet <edumazet@google.com>
---
 .../selftests/net/packetdrill/tcp_blocking_blocking-read.pkt   | 2 ++
 tools/testing/selftests/net/packetdrill/tcp_inq_client.pkt     | 3 +++
 tools/testing/selftests/net/packetdrill/tcp_inq_server.pkt     | 3 +++
 3 files changed, 8 insertions(+)

diff --git a/tools/testing/selftests/net/packetdrill/tcp_blocking_blocking-read.pkt b/tools/testing/selftests/net/packetdrill/tcp_blocking_blocking-read.pkt
index 914eabab367aeb765a85e311513c3ca35ec27946..657e42ca65b5d4280875af49ba8775688172799d 100644
--- a/tools/testing/selftests/net/packetdrill/tcp_blocking_blocking-read.pkt
+++ b/tools/testing/selftests/net/packetdrill/tcp_blocking_blocking-read.pkt
@@ -1,6 +1,8 @@
 // SPDX-License-Identifier: GPL-2.0
 // Test for blocking read.
+
 --tolerance_usecs=10000
+--mss=1000
 
 `./defaults.sh`
 
diff --git a/tools/testing/selftests/net/packetdrill/tcp_inq_client.pkt b/tools/testing/selftests/net/packetdrill/tcp_inq_client.pkt
index df49c67645ac8f8bdef485f03af6e84d2b883ae9..e13f0eee97952a39a3b67cf276d01d0b9eee16cb 100644
--- a/tools/testing/selftests/net/packetdrill/tcp_inq_client.pkt
+++ b/tools/testing/selftests/net/packetdrill/tcp_inq_client.pkt
@@ -1,5 +1,8 @@
 // SPDX-License-Identifier: GPL-2.0
 // Test TCP_INQ and TCP_CM_INQ on the client side.
+
+--mss=1000
+
 `./defaults.sh
 `
 
diff --git a/tools/testing/selftests/net/packetdrill/tcp_inq_server.pkt b/tools/testing/selftests/net/packetdrill/tcp_inq_server.pkt
index 04a5e2590c62cf725e92f137470b0bcae309eaba..14dd5f813d50eb6425bb58a72e63d47433a29cb4 100644
--- a/tools/testing/selftests/net/packetdrill/tcp_inq_server.pkt
+++ b/tools/testing/selftests/net/packetdrill/tcp_inq_server.pkt
@@ -1,5 +1,8 @@
 // SPDX-License-Identifier: GPL-2.0
 // Test TCP_INQ and TCP_CM_INQ on the server side.
+
+--mss=1000
+
 `./defaults.sh
 `
 
-- 
2.50.0.727.gbf7dc18ff4-goog


^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [PATCH net-next] selftests/net: packetdrill: add --mss option to three tests
  2025-07-10 15:56 [PATCH net-next] selftests/net: packetdrill: add --mss option to three tests Eric Dumazet
@ 2025-07-10 19:39 ` Willem de Bruijn
  2025-07-12  0:40 ` patchwork-bot+netdevbpf
  1 sibling, 0 replies; 3+ messages in thread
From: Willem de Bruijn @ 2025-07-10 19:39 UTC (permalink / raw)
  To: Eric Dumazet, David S . Miller, Jakub Kicinski, Paolo Abeni,
	Neal Cardwell
  Cc: Simon Horman, Kuniyuki Iwashima, Willem de Bruijn, netdev,
	eric.dumazet, Eric Dumazet

Eric Dumazet wrote:
> Three tests are cooking GSO packets but do not provide
> gso_size information to the kernel, triggering this message:
> 
> TCP: tun0: Driver has suspect GRO implementation, TCP performance may be compromised.
> 
> Add --mss option to avoid this warning.
> 
> Signed-off-by: Eric Dumazet <edumazet@google.com>

Reviewed-by: Willem de Bruijn <willemb@google.com>

This is because of this in packetdrill linux_tun_write, I suppose:

        if (packet->tcp && packet->mss) {
                if (packet->ipv4)
                        gso.gso_type = VIRTIO_NET_HDR_GSO_TCPV4;
                else
                        gso.gso_type = VIRTIO_NET_HDR_GSO_TCPV6;
                gso.gso_size = packet->mss;
        }

Which seems to imply that setting mss means that all generated packets
use GRO. Which tracks with the commit that introduced it: commit
58a7865c47e3 ("net-test: packetdrill: add GRO support to packetdrill").
Which includes

	+++ b/gtests/net/packetdrill/config.h
	@@ -73,6 +73,7 @@ struct config {
		u32 speed;                      /* speed reported by tun driver;
						 * may require special tun driver
						 */
	+       int mss;                        /* gso_size for GRO packets to tun device */

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH net-next] selftests/net: packetdrill: add --mss option to three tests
  2025-07-10 15:56 [PATCH net-next] selftests/net: packetdrill: add --mss option to three tests Eric Dumazet
  2025-07-10 19:39 ` Willem de Bruijn
@ 2025-07-12  0:40 ` patchwork-bot+netdevbpf
  1 sibling, 0 replies; 3+ messages in thread
From: patchwork-bot+netdevbpf @ 2025-07-12  0:40 UTC (permalink / raw)
  To: Eric Dumazet
  Cc: davem, kuba, pabeni, ncardwell, horms, kuniyu, willemb, netdev,
	eric.dumazet

Hello:

This patch was applied to netdev/net-next.git (main)
by Jakub Kicinski <kuba@kernel.org>:

On Thu, 10 Jul 2025 15:56:41 +0000 you wrote:
> Three tests are cooking GSO packets but do not provide
> gso_size information to the kernel, triggering this message:
> 
> TCP: tun0: Driver has suspect GRO implementation, TCP performance may be compromised.
> 
> Add --mss option to avoid this warning.
> 
> [...]

Here is the summary with links:
  - [net-next] selftests/net: packetdrill: add --mss option to three tests
    https://git.kernel.org/netdev/net-next/c/f0600fe94986

You are awesome, thank you!
-- 
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/patchwork/pwbot.html



^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2025-07-12  0:39 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-07-10 15:56 [PATCH net-next] selftests/net: packetdrill: add --mss option to three tests Eric Dumazet
2025-07-10 19:39 ` Willem de Bruijn
2025-07-12  0:40 ` patchwork-bot+netdevbpf

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).