* net/mlx:mlx5 mlx_flow_create failed when set bond_mode_8023
@ 2023-06-20 15:25 =?gb18030?B?Y29tcGlsZV9zdWNjZXNz?=
2023-07-12 11:29 ` Slava Ovsiienko
0 siblings, 1 reply; 2+ messages in thread
From: =?gb18030?B?Y29tcGlsZV9zdWNjZXNz?= @ 2023-06-20 15:25 UTC (permalink / raw)
To: =?gb18030?B?dXNlcnM=?=, =?gb18030?B?ZGV2?=,
=?gb18030?B?bWF0YW4=?=, =?gb18030?B?c2hhaGFmcw==?=,
=?gb18030?B?dmlhY2hlc2xhdm8=?=
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1.1: Type: text/plain; charset="gb18030", Size: 1568 bytes --]
Hi,
When I create bond4 with ConnectX-4 , mlx_flow_create return error;
When bond_port is opened, slave_port will be closed to sync bond_port config
£¨bond_ethdev_start -> slave_configure->rte_eth_dev_stop£©
6¤7slave_configure(struct rte_eth_dev *bonded_eth_dev,
struct rte_eth_dev *slave_eth_dev)
{
uint16_t nb_rx_queues;
uint16_t nb_tx_queues;
int errval;
struct bond_dev_private *internals = bonded_eth_dev->data->dev_private;
/* Stop slave */
errval = rte_eth_dev_stop(slave_eth_dev->data->port_id);
if (errval != 0)
RTE_BOND_LOG(ERR, "rte_eth_dev_stop: port %u, err (%d)",
slave_eth_dev->data->port_id, errval);
However, If the device is not started yetm it is not allowed to created a flow from application.
£¨slave_configure -> bond_ethdev_8023ad_flow_set -> rte_flow_create -> mlx5_flow_create£©
I want to add rte_eth_dev_start before bond_ethdev_8023ad_flow_set. This can solve my problem.
compile_success
980965867@qq.com
[-- Attachment #1.2: Type: text/html, Size: 12702 bytes --]
[-- Attachment #2: 03349B68@BCE9222C.01C59164.png.jpg --]
[-- Type: image/jpeg, Size: 47269 bytes --]
[-- Attachment #3: fix-mlx4-bond-flow-create-failed.patch --]
[-- Type: application/octet-stream, Size: 797 bytes --]
diff -Nur dpdk-21.11.org/drivers/net/bonding/rte_eth_bond_pmd.c dpdk-21.11/drivers/net/bonding/rte_eth_bond_pmd.c
--- dpdk-21.11.org/drivers/net/bonding/rte_eth_bond_pmd.c 2023-06-20 15:21:19.860000000 +0000
+++ dpdk-21.11/drivers/net/bonding/rte_eth_bond_pmd.c 2023-06-20 15:23:39.468000000 +0000
@@ -1848,6 +1848,15 @@
internals->mode4.dedicated_queues.flow[slave_eth_dev->data->port_id],
&flow_error);
+ errval = rte_eth_dev_start(slave_eth_dev->data->port_id);
+ if (errval != 0){
+ RTE_BOND_LOG(ERR, "rte_eth_dev_start: port %u, err (%d)",
+ slave_eth_dev->data->port_id, errval);
+ return errval;
+
+ }
+
+
errval = bond_ethdev_8023ad_flow_set(bonded_eth_dev,
slave_eth_dev->data->port_id);
if (errval != 0) {
^ permalink raw reply [flat|nested] 2+ messages in thread
* RE: net/mlx:mlx5 mlx_flow_create failed when set bond_mode_8023
2023-06-20 15:25 net/mlx:mlx5 mlx_flow_create failed when set bond_mode_8023 =?gb18030?B?Y29tcGlsZV9zdWNjZXNz?=
@ 2023-07-12 11:29 ` Slava Ovsiienko
0 siblings, 0 replies; 2+ messages in thread
From: Slava Ovsiienko @ 2023-07-12 11:29 UTC (permalink / raw)
To: compile_success, users, dev, Matan Azrad, Shahaf Shuler
[-- Attachment #1.1: Type: text/plain, Size: 1684 bytes --]
Hi, Yan
Sorry, I do not follow the letter?
Are you proposing the patch for bonding PMD?
If so, could you, please send your patch in plain text, according to ML rules?
It is application responsibility to start bonding virtual device (and it will start its slaves)
before flow creation.
With best regards,
Slava
From: compile_success <980965867@qq.com>
Sent: Tuesday, June 20, 2023 6:26 PM
To: users <users@dpdk.org>; dev <dev@dpdk.org>; Matan Azrad <matan@mellanox.com>; Shahaf Shuler <shahafs@mellanox.com>; Slava Ovsiienko <viacheslavo@mellanox.com>
Subject: net/mlx:mlx5 mlx_flow_create failed when set bond_mode_8023
Hi,
When I create bond4 with ConnectX-4 , mlx_flow_create return error;
When bond_port is opened, slave_port will be closed to sync bond_port config
(bond_ethdev_start -> slave_configure->rte_eth_dev_stop)
slave_configure(struct rte_eth_dev *bonded_eth_dev,
struct rte_eth_dev *slave_eth_dev)
{
uint16_t nb_rx_queues;
uint16_t nb_tx_queues;
int errval;
struct bond_dev_private *internals = bonded_eth_dev->data->dev_private;
/* Stop slave */
errval = rte_eth_dev_stop(slave_eth_dev->data->port_id);
if (errval != 0)
RTE_BOND_LOG(ERR, "rte_eth_dev_stop: port %u, err (%d)",
slave_eth_dev->data->port_id, errval);
However, If the device is not started yetm it is not allowed to created a flow from application.
(slave_configure -> bond_ethdev_8023ad_flow_set -> rte_flow_create -> mlx5_flow_create)
I want to add rte_eth_dev_start before bond_ethdev_8023ad_flow_set. This can solve my problem.
[cid:image001.png@01D9B4CB.A5D91B50]
________________________________
[-- Attachment #1.2: Type: text/html, Size: 12494 bytes --]
[-- Attachment #2: image001.png --]
[-- Type: image/png, Size: 47269 bytes --]
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2023-07-20 5:19 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-06-20 15:25 net/mlx:mlx5 mlx_flow_create failed when set bond_mode_8023 =?gb18030?B?Y29tcGlsZV9zdWNjZXNz?=
2023-07-12 11:29 ` Slava Ovsiienko
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).