DPDK patches and discussions
 help / color / mirror / Atom feed
* [PATCH] app/testpmd: check starting port is not in bonding
@ 2022-02-17 11:36 Min Hu (Connor)
  2022-02-17 12:48 ` Ferruh Yigit
  0 siblings, 1 reply; 2+ messages in thread
From: Min Hu (Connor) @ 2022-02-17 11:36 UTC (permalink / raw)
  To: dev; +Cc: ferruh.yigit, thomas, bernard.iremonger, xiaoyun.li

In bond, start or stop slave port should be operated by bonding port.
This patch add port_is_bonding_slave in start_port function.

Fixes: 0e545d3047fe ("app/testpmd: check stopping port is not in bonding")
Cc: stable@dpdk.org

Signed-off-by: Min Hu (Connor) <humin29@huawei.com>
---
 app/test-pmd/testpmd.c | 7 +++++++
 1 file changed, 7 insertions(+)

diff --git a/app/test-pmd/testpmd.c b/app/test-pmd/testpmd.c
index 6d2e52c790..fe2ce19f99 100644
--- a/app/test-pmd/testpmd.c
+++ b/app/test-pmd/testpmd.c
@@ -2726,6 +2726,13 @@ start_port(portid_t pid)
 		if (pid != pi && pid != (portid_t)RTE_PORT_ALL)
 			continue;
 
+		if (port_is_bonding_slave(pi)) {
+			fprintf(stderr,
+				"Please remove port %d from bonded device.\n",
+				pi);
+			continue;
+		}
+
 		need_check_link_status = 0;
 		port = &ports[pi];
 		if (port->port_status == RTE_PORT_STOPPED)
-- 
2.33.0


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

* Re: [PATCH] app/testpmd: check starting port is not in bonding
  2022-02-17 11:36 [PATCH] app/testpmd: check starting port is not in bonding Min Hu (Connor)
@ 2022-02-17 12:48 ` Ferruh Yigit
  0 siblings, 0 replies; 2+ messages in thread
From: Ferruh Yigit @ 2022-02-17 12:48 UTC (permalink / raw)
  To: Min Hu (Connor), dev; +Cc: thomas, bernard.iremonger, xiaoyun.li

On 2/17/2022 11:36 AM, Min Hu (Connor) wrote:
> In bond, start or stop slave port should be operated by bonding port.
> This patch add port_is_bonding_slave in start_port function.
> 
> Fixes: 0e545d3047fe ("app/testpmd: check stopping port is not in bonding")
> Cc: stable@dpdk.org
> 
> Signed-off-by: Min Hu (Connor) <humin29@huawei.com>

Reviewed-by: Ferruh Yigit <ferruh.yigit@intel.com>

Applied to dpdk-next-net/main, thanks.

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

end of thread, other threads:[~2022-02-17 12:48 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-02-17 11:36 [PATCH] app/testpmd: check starting port is not in bonding Min Hu (Connor)
2022-02-17 12:48 ` Ferruh Yigit

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).