From: Paul Szczepanek <paul.szczepanek@arm.com>
To: Dean Marx <dmarx@iol.unh.edu>,
probb@iol.unh.edu, npratte@iol.unh.edu, luca.vizzarro@arm.com,
yoan.picchi@foss.arm.com, Honnappa.Nagarahalli@arm.com
Cc: nd@arm.com, dev@dpdk.org
Subject: Re: [PATCH v1] dts: fix multicast set function in testpmd shell
Date: Fri, 24 Jan 2025 12:00:11 +0000 [thread overview]
Message-ID: <c322d000-3d2d-4c86-95a8-a55c913f2872@arm.com> (raw)
In-Reply-To: <20250116193307.23213-1-dmarx@iol.unh.edu>
On 16/01/2025 19:33, Dean Marx wrote:
> Fixes verification method in multicast set function by changing
> the stats capture to use show_port_info_all(). This way, the
> method will continue to work even after DTS lifts the restriction
> on port topologies.
>
> Fixes: abf8a3bc793b ("dts: add multicast set function to shell")
>
> Signed-off-by: Dean Marx <dmarx@iol.unh.edu>
> ---
> dts/framework/remote_session/testpmd_shell.py | 7 +++----
> 1 file changed, 3 insertions(+), 4 deletions(-)
>
> diff --git a/dts/framework/remote_session/testpmd_shell.py b/dts/framework/remote_session/testpmd_shell.py
> index d25952e2fa..37cd981264 100644
> --- a/dts/framework/remote_session/testpmd_shell.py
> +++ b/dts/framework/remote_session/testpmd_shell.py
> @@ -1795,7 +1795,7 @@ def show_port_stats(self, port_id: int) -> TestPmdPortStats:
>
> return TestPmdPortStats.parse(output)
>
> - def set_multicast_all(self, on: bool, verify: bool = True):
> + def set_multicast_all(self, on: bool, verify: bool = True) -> None:
> """Turns multicast mode on/off for the specified port.
>
> Args:
> @@ -1809,9 +1809,8 @@ def set_multicast_all(self, on: bool, verify: bool = True):
> """
> multicast_cmd_output = self.send_command(f"set allmulti all {'on' if on else 'off'}")
> if verify:
> - stats0 = self.show_port_info(port_id=0)
> - stats1 = self.show_port_info(port_id=1)
> - if on ^ (stats0.is_allmulticast_mode_enabled and stats1.is_allmulticast_mode_enabled):
> + port_stats = self.show_port_info_all()
> + if on ^ all(stats.is_allmulticast_mode_enabled for stats in port_stats):
> self._logger.debug(
> f"Failed to set multicast mode on all ports.: \n{multicast_cmd_output}"
> )
Reviewed-by: Paul Szczepanek <paul.szczepanek@arm.com>
prev parent reply other threads:[~2025-01-24 12:00 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-01-16 19:33 Dean Marx
2025-01-24 12:00 ` Paul Szczepanek [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=c322d000-3d2d-4c86-95a8-a55c913f2872@arm.com \
--to=paul.szczepanek@arm.com \
--cc=Honnappa.Nagarahalli@arm.com \
--cc=dev@dpdk.org \
--cc=dmarx@iol.unh.edu \
--cc=luca.vizzarro@arm.com \
--cc=nd@arm.com \
--cc=npratte@iol.unh.edu \
--cc=probb@iol.unh.edu \
--cc=yoan.picchi@foss.arm.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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).