Re: [ovs-dev] [PATCH 0/6] Add support for DPDK meter HW offload

2023-01-07 Thread Eli Britstein via dev


>-Original Message-
>From: Nole Zhang 
>Sent: Friday, 6 January 2023 11:28
>To: Eli Britstein ; d...@openvswitch.org
>Cc: Eelco Chaudron ; Ilya Maximets
>; Chaoyong He ; oss-
>drivers ; Nole Zhang 
>Subject: RE: [PATCH 0/6] Add support for DPDK meter HW offload
>
>External email: Use caution opening links or attachments
>
>
>> -Original Message-
>> From: Eli Britstein 
>> Sent: 2022年12月26日 18:04
>> To: Simon Horman ; d...@openvswitch.org
>> Cc: Eelco Chaudron ; Ilya Maximets
>> ; Chaoyong He ; oss-
>> drivers ; Nole Zhang
>> 
>> Subject: RE: [PATCH 0/6] Add support for DPDK meter HW offload
>>
>> Dpif-netdev should not implement internal HW offload details. If need
>> to "apply on all ports", it needs to be done in offload layer.
>> However, in arch level, there is a problem with the proposed series.
>> It will create a meter object per port, while in SW it is one object,
>> that can be shared between multiple flows, on different ports.
>
>In dpif-netdev, it doesn't relate with implement internal HW offload details, I
>just try to add the meter to the PMD if the PMD support the meter offload.
[Eli Britstein] your loops over ports, not over PMDs. See in [1], for example 
in dpif_netdev_offload_meter_set():
+HMAP_FOR_EACH (port, node, &dp->ports) {
+dev = port->netdev;
Am I wrong?

Other than that, there is already a convenient API to traverse ports for 
offload - netdev_ports_traverse().
>
>No, it will create a meter object per PMD not per port, so the meter can share
>the same NIC different vf,  different NIC can't share  the meter, it is same 
>with
>ovs-tc meter offload
[Eli Britstein] no, it will create an object per port, as this is your code.
To create a shared object for all the VFs in the same NIC, need to use the 
"proxy" port. Such work has started in [2].

[1] 
http://patchwork.ozlabs.org/project/openvswitch/patch/20221216155054.986464-3-simon.hor...@corigine.com/
[2] 
http://patchwork.ozlabs.org/project/openvswitch/patch/20220720121823.2497727-4-ivan.ma...@oktetlabs.ru/

>>
>> >-Original Message-
>> >From: Simon Horman 
>> >Sent: Friday, 16 December 2022 17:51
>> >To: d...@openvswitch.org
>> >Cc: Eelco Chaudron ; Ilya Maximets
>> >; Eli Britstein ; Chaoyong He
>> >; oss-driv...@corigine.com; Peng Zhang
>> >; Simon Horman
>> 
>> >Subject: [PATCH 0/6] Add support for DPDK meter HW offload
>> >
>> >External email: Use caution opening links or attachments
>> >
>> >
>> >Hi,
>> >
>> >this series adds support for DPDK meter HW offload
>> >
>> >* Patch 1/6: Add netdev provider API for HW offload of DPDK meters
>> >* Patch 2/6: Add DPIF API to offload OpenFlow meters to DPDK
>> >* Patch 3/6: Implement netdev provider API for HW offload of DPDK
>> >meters
>> >* Patch 4/6: Add more DPDK meter algorithms
>> >* Patch 4/6: Add support for meter action ti DPDK HW offload
>> >* Patch 4/6: Add CI builds with ALLOW_EXPERIMENTAL_API
>> >
>> >Peng Zhang (6):
>> >  netdev-offload: Add DPDK meter offload API
>> >  dpif-netdev: Offloading meter with DPDK
>> >  netdev-offload-dpdk: Implement meter offload API for DPDK
>> >  netdev-dpdk: add meter algorithms
>> >  netdev-dpdk-offload: Add support for meter action
>> >  ci: add the opts about ALLOW_EXPERIMENTAL_API
>> >
>> > .ci/linux-build.sh   |   4 +
>> > .github/workflows/build-and-test.yml |  31 
>> > Documentation/howto/dpdk.rst |   5 +-
>> > lib/dpif-netdev.c| 102 +++
>> > lib/netdev-dpdk.c| 243 +++
>> > lib/netdev-dpdk.h|  41 +
>> > lib/netdev-offload-dpdk.c| 101 +++
>> > lib/netdev-offload-provider.h|  30 
>> > lib/netdev-offload.c |  59 +++
>> > lib/netdev-offload.h |   9 +
>> > 10 files changed, 623 insertions(+), 2 deletions(-)
>> >
>> >--
>> >2.30.2

___
dev mailing list
d...@openvswitch.org
https://mail.openvswitch.org/mailman/listinfo/ovs-dev


[ovs-dev] [PATCH] docs: Add HyperThreading notes for auto-lb usage.

2023-01-07 Thread Cheng Li
In my test, if one logical core is pinned to PMD thread while the
other logical(of the same physical core) is not. The PMD
performance is affected the by the not-pinned logical core load.
This maks it difficult to estimate the loads during a dry-run.

Signed-off-by: Cheng Li 
---
 Documentation/topics/dpdk/pmd.rst | 4 
 1 file changed, 4 insertions(+)

diff --git a/Documentation/topics/dpdk/pmd.rst 
b/Documentation/topics/dpdk/pmd.rst
index 9006fd4..b220199 100644
--- a/Documentation/topics/dpdk/pmd.rst
+++ b/Documentation/topics/dpdk/pmd.rst
@@ -312,6 +312,10 @@ If not set, the default variance improvement threshold is 
25%.
 when all PMD threads are running on cores from a single NUMA node. In this
 case cross-NUMA datapaths will not change after reassignment.
 
+For the same reason, please ensure that the pmd threads are pinned to SMT
+siblings if HyperThreading is enabled. Otherwise, PMDs within a NUMA may
+not have the same performance.
+
 The minimum time between 2 consecutive PMD auto load balancing iterations can
 also be configured by::
 
-- 
1.8.3.1

___
dev mailing list
d...@openvswitch.org
https://mail.openvswitch.org/mailman/listinfo/ovs-dev


Re: [ovs-dev] [PATCH 0/2] ovsdb: Don't convert unchanged columns.

2023-01-07 Thread Han Zhou
On Tue, Jan 3, 2023 at 9:47 AM Ilya Maximets  wrote:
>
> Relevant discussion:
>
https://mail.openvswitch.org/pipermail/ovs-discuss/2023-January/052158.html
>
> Ilya Maximets (2):
>   ovsdb-types: Add functions to compare types for equality.
>   ovsdb: Don't convert unchanged columns during database conversion.
>
>  lib/ovsdb-types.c | 61 +++
>  lib/ovsdb-types.h |  3 +++
>  ovsdb/file.c  | 59 -
>  3 files changed, 112 insertions(+), 11 deletions(-)
>
> --
> 2.38.1
>

Thanks Ilya! For this series:
Acked-by: Han Zhou 
___
dev mailing list
d...@openvswitch.org
https://mail.openvswitch.org/mailman/listinfo/ovs-dev


Re: [ovs-dev] [PATCH] system-dpdk: Fix error message in ping vhost-user ports.

2023-01-07 Thread David Marchand
On Fri, Jan 6, 2023 at 11:57 AM Eelco Chaudron  wrote:
>
> In some environments, ovs-vswitchd gets shutdown before the pkill of
> testpmd has been completed, which results in the following error messages:
>
>   Removing port 'dpdkvhostuser0' while vhost device still attached.
>   To restore connectivity after re-adding of port, VM on socket '' must be 
> restarted.
>
> This patch will wait for the socket disconnect to be handled by the
> vhost-user before shutting down OVS.
>
> Signed-off-by: Eelco Chaudron 
> Signed-off-by: David Marchand 
> Co-authored-by: David Marchand 

Just confirming that the patch lgtm.
Thanks Eelco.


-- 
David Marchand

___
dev mailing list
d...@openvswitch.org
https://mail.openvswitch.org/mailman/listinfo/ovs-dev