From patchwork Fri Feb 2 16:06:59 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Paolo Abeni X-Patchwork-Id: 13543124 X-Patchwork-Delegate: kuba@kernel.org Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.129.124]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id C44D6148301 for ; Fri, 2 Feb 2024 16:07:16 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=170.10.129.124 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1706890038; cv=none; b=flRya0V97Vwzr9So2mTHepk54OJxgPHs8ZIyLg/6mHoquF1Q+FazeTJYjy2e1/pmxfERgDB/BG+4OfTZr+0B5tqqkbNR5vEJDsHPyTvVGqgQVTUZ2dMB+Tp4H3A2OIz+BuoVhGiALZuoSBhwcT8bVqRW/VQ7OEIyECAhNhZMGHI= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1706890038; c=relaxed/simple; bh=dWqDluAGebC9iUHazZC6G1amxNpPOt/EUwg+LbLuE9U=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version; b=gfdbTJqn0wSvNUQEZXieaZsn5akZNMoiOLbbbkwLI7pvfrrhEyNM7Q8K6z3CTmEM2mCPKr1VXuXD3Si2eijIqVQtrlUSI0RALJ2YnIOlYz7UTqt3ah7RHWPPXhm8u1iNgpC2mEBB7/MLjYlweDykyMUo2ZxQ3CKiRBICr9xvsys= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=redhat.com; spf=pass smtp.mailfrom=redhat.com; dkim=pass (1024-bit key) header.d=redhat.com header.i=@redhat.com header.b=UwuTtjLU; arc=none smtp.client-ip=170.10.129.124 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=redhat.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=redhat.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=redhat.com header.i=@redhat.com header.b="UwuTtjLU" DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1706890035; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding; bh=TeQN/mgjI+NOMRyCt7BGpixz6liM9dhqEGJXdte70KM=; b=UwuTtjLUmjFzColfSd9+ZY4ps8C53bLKERd+wQJiEMuFtjTMpdpYxSTj2GSVt0Ud2UI6HX qbqSWGO3Huxf8iKB5SRTN2Jnw68BNEO5NgBlLzUVkhqz84DKYX30o42khe0FO0tm/Q95z6 zfLkdg/Yod4v+8v8XuIOiaHP78x/BUo= Received: from mimecast-mx02.redhat.com (mx-ext.redhat.com [66.187.233.73]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-237-y4sGsZFIMTuYSlqJTZ9amQ-1; Fri, 02 Feb 2024 11:07:14 -0500 X-MC-Unique: y4sGsZFIMTuYSlqJTZ9amQ-1 Received: from smtp.corp.redhat.com (int-mx09.intmail.prod.int.rdu2.redhat.com [10.11.54.9]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id 8D2893C23FC3; Fri, 2 Feb 2024 16:07:13 +0000 (UTC) Received: from gerbillo.redhat.com (unknown [10.45.224.216]) by smtp.corp.redhat.com (Postfix) with ESMTP id EBA7F492BC6; Fri, 2 Feb 2024 16:07:11 +0000 (UTC) From: Paolo Abeni To: netdev@vger.kernel.org Cc: "David S. Miller" , Eric Dumazet , Jakub Kicinski , Shuah Khan , Xin Long , linux-kselftest@vger.kernel.org Subject: [PATCH net] selftests: net: let big_tcp test cope with slow env Date: Fri, 2 Feb 2024 17:06:59 +0100 Message-ID: Precedence: bulk X-Mailing-List: netdev@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-Scanned-By: MIMEDefang 3.4.1 on 10.11.54.9 X-Patchwork-Delegate: kuba@kernel.org In very slow environments, most big TCP cases including segmentation and reassembly of big TCP packets have a good chance to fail: by default the TCP client uses write size well below 64K. If the host is low enough autocorking is unable to build real big TCP packets. Address the issue using much larger write operations. Note that is hard to observe the issue without an extremely slow and/or overloaded environment; reduce the TCP transfer time to allow for much easier/faster reproducibility. Fixes: 6bb382bcf742 ("selftests: add a selftest for big tcp") Signed-off-by: Paolo Abeni Reviewed-by: Eric Dumazet Acked-by: Xin Long --- tools/testing/selftests/net/big_tcp.sh | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/tools/testing/selftests/net/big_tcp.sh b/tools/testing/selftests/net/big_tcp.sh index cde9a91c4797..2db9d15cd45f 100755 --- a/tools/testing/selftests/net/big_tcp.sh +++ b/tools/testing/selftests/net/big_tcp.sh @@ -122,7 +122,9 @@ do_netperf() { local netns=$1 [ "$NF" = "6" ] && serip=$SERVER_IP6 - ip net exec $netns netperf -$NF -t TCP_STREAM -H $serip 2>&1 >/dev/null + + # use large write to be sure to generate big tcp packets + ip net exec $netns netperf -$NF -t TCP_STREAM -l 1 -H $serip -- -m 262144 2>&1 >/dev/null } do_test() {