From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 1E22343F1B; Fri, 26 Apr 2024 20:06:16 +0200 (CEST) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 9931E4026C; Fri, 26 Apr 2024 20:06:15 +0200 (CEST) Received: from mail-pg1-f174.google.com (mail-pg1-f174.google.com [209.85.215.174]) by mails.dpdk.org (Postfix) with ESMTP id 3F8BA40144 for ; Fri, 26 Apr 2024 20:06:14 +0200 (CEST) Received: by mail-pg1-f174.google.com with SMTP id 41be03b00d2f7-60c49bdbcd3so872363a12.0 for ; Fri, 26 Apr 2024 11:06:14 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=iol.unh.edu; s=unh-iol; t=1714154773; x=1714759573; darn=dpdk.org; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:from:to:cc:subject:date :message-id:reply-to; bh=RLBK40iVdjSxLgeFN1FV02wngb0w+kjdif95QDRryEE=; b=dcZPR67THEsnEvP26TZye2nx1h/wK7r6l2YBS1OXk55Uib5dUFpgDEabkZJrwEuNvf h/Y1Zl9fW31Ch1AUvzIfcPAdnE1dVnBUwmf9FZOdSwzgyEXVZjoVQN6r0UabYgxyjbUO I0EQNGPBvGMTgVoVMBgXbrlHnHNqdxmBuffqQ= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1714154773; x=1714759573; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=RLBK40iVdjSxLgeFN1FV02wngb0w+kjdif95QDRryEE=; b=kXB2ml06WjPOfXKZRBwjcvTP3a+LR6bGW8w7SNq8k2zbP+lWB0sDgVLg/r5RmZrk58 k96W1MTjoECn/DdkyuurDH74fGcOY4ERHVe9yxEp/bubPDEJMgdAIfsn4o6DSMIVJzI6 RqLSIk1bHgXl4B2xZy9hJb4j7J+u9d2Wk4qw5fyBhupPnXkpvYF4rLRI0ubk0FPfDB4F ftvUMGt7NYjkrOFk3qaqpDw5z2EscBf8Uj+h7ZWik6vXZ06w1kYCSvAFGjQlNWny7eAz UQdGrUVueu6H0u9BA4GWW/JK7YP3FY0umudpEVVGsax0oWcbHi+gZuPP1NNcsb+uSsKj WOMA== X-Forwarded-Encrypted: i=1; AJvYcCVPZkqpRJctzNKdz3rY8RhHOIGyANehPVmLK5EPPPV4YTA3w3jC89Kd0Kh6T7iAOLrBYk50utDqM7ksJOU= X-Gm-Message-State: AOJu0YxVtFKRoEEhG95n/Rb53sjr1S8IoMg5dun9Gk1r8m51wTJrVYMw FHem4DV9eQQqbW86BE5VlWWhSoizzylLL/JLvnzxWoAl5njE1VUJDOTmqdLE9AOwjglTNDMGCUq 8zkmdi7ZM3s3/zvTwOXm/K1VyluU5xwZ289xnIw== X-Google-Smtp-Source: AGHT+IGAzS/sbkrrJ5ssYVnlq6wKwOaG64ve1gW7XWwA1Cc7O4ajxxGGcPY0b3PcZyetF8onEh2/ZpdTuxVEcMxAkII= X-Received: by 2002:a17:90a:ad88:b0:2a5:5a2c:6066 with SMTP id s8-20020a17090aad8800b002a55a2c6066mr306821pjq.37.1714154773266; Fri, 26 Apr 2024 11:06:13 -0700 (PDT) MIME-Version: 1.0 References: <20240326190422.577028-1-luca.vizzarro@arm.com> <20240326190422.577028-5-luca.vizzarro@arm.com> In-Reply-To: From: Jeremy Spewock Date: Fri, 26 Apr 2024 14:06:02 -0400 Message-ID: Subject: Re: [PATCH 4/6] dts: use testpmd params for scatter test suite To: =?UTF-8?Q?Juraj_Linke=C5=A1?= Cc: Luca Vizzarro , dev@dpdk.org, Jack Bond-Preston , Honnappa Nagarahalli Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org On Wed, Apr 10, 2024 at 9:19=E2=80=AFAM Juraj Linke=C5=A1 wrote: > > On Wed, Apr 10, 2024 at 12:53=E2=80=AFPM Luca Vizzarro wrote: > > > > On 09/04/2024 20:12, Juraj Linke=C5=A1 wrote: > > >> @@ -104,16 +108,15 @@ def pmd_scatter(self, mbsize: int) -> None: > > >> """ > > >> testpmd =3D self.sut_node.create_interactive_shell( > > >> TestPmdShell, > > >> - app_parameters=3DStrParams( > > >> - "--mbcache=3D200 " > > >> - f"--mbuf-size=3D{mbsize} " > > >> - "--max-pkt-len=3D9000 " > > >> - "--port-topology=3Dpaired " > > >> - "--tx-offloads=3D0x00008000" > > >> + app_parameters=3DTestPmdParameters( > > >> + forward_mode=3DTestPmdForwardingModes.mac, > > >> + mbcache=3D200, > > >> + mbuf_size=3D[mbsize], > > >> + max_pkt_len=3D9000, > > >> + tx_offloads=3D0x00008000, > > >> ), > > >> privileged=3DTrue, > > >> ) > > >> - testpmd.set_forward_mode(TestPmdForwardingModes.mac) > > > > > > Jeremy, does this change the test? Instead of configuring the fw mode > > > after starting testpmd, we're starting testpmd with fw mode > > > configured. To my knowledge, as Luca mentions below, this does not functionally change anything about the test, scatter should just need the MAC forwarding mode to be set at some point before forwarding starts, it doesn't technically matter when. One thing to note that this does change, however, is that we lose the verification step that the method within testpmd provides. I'm not sure off the top of my head if testpmd just completely fails to start if the forwarding mode flag is set and it fails to change modes or if it still starts and then just goes back to default (io) which would make the test operate in an invalid state without anyway of knowing. As another note however, I've never seen a mode change fail and I don't know what could even make it fail, so this would be a rare thing anyway, but still just something to consider. > > > > I am not Jeremy (please Jeremy still reply), but we discussed this on > > Slack. Reading through the testpmd source code, setting arguments like > > forward-mode in the command line, is the exact equivalent of calling > > `set forward mode` right after start-up. So it is equivalent in theory. > > > > > If not, we should remove the testpmd.set_forward_mode method, as it's > > > not used anymore. > > > > Could there be test cases that change the forward mode multiple times i= n > > the same shell, though? As this could still be needed to cover this. > > Yes, but we don't have such a test now. It's good practice to remove > unused code. We can still bring it back anytime, it'll be in git > history.