[ovs-dev] [PATCH ovn 3/3] northd: Use dynamic mac-binding for virtual port IPs.

2023-02-22 Thread Han Zhou
Today ARP resolve flows (static mac-bindings) are programmed for virtual ports once their virtual parent is claimed. As a result, during virtual parent failover, the traffic won't switch to the new parent until the ARP resolve flow is updated by ovn-northd, triggered by the port-binding update.

[ovs-dev] [PATCH ovn 1/3] ovn.at: Fix virtual port tests.

2023-02-22 Thread Han Zhou
The check_virtual_offlows_not_present() function in the case "virtual ports" has the wrong table id 45, which should be 44. However, correcting the table id makes the case failing, because the two ACLs added by the case were in fact overlapping: check ovn-nbctl acl-add sw0 to-lport 1000

[ovs-dev] [PATCH ovn 0/3] virtual port faster failover.

2023-02-22 Thread Han Zhou
Han Zhou (3): ovn.at: Fix virtual port tests. system-ovn.at: Add system test for virtual port with floating IP. northd: Use dynamic mac-binding for virtual port IPs. northd/northd.c | 103 northd/ovn-northd.8.xml | 37 ++ tests/atlocal.in

[ovs-dev] [PATCH ovn 2/3] system-ovn.at: Add system test for virtual port with floating IP.

2023-02-22 Thread Han Zhou
Signed-off-by: Han Zhou --- tests/atlocal.in| 3 + tests/system-ovn.at | 146 2 files changed, 149 insertions(+) diff --git a/tests/atlocal.in b/tests/atlocal.in index 0b9a312761c9..5526adac5241 100644 --- a/tests/atlocal.in +++

Re: [ovs-dev] [PATCH ovn 0/2] fix IP fragmented traffic hitting LB

2023-02-22 Thread Ales Musil
On Wed, Feb 22, 2023 at 4:58 PM Lorenzo Bianconi < lorenzo.bianc...@redhat.com> wrote: > Lorenzo Bianconi (2): > northd: move defrag router pipeline stage forward > northd: add flows to defrag IP traffic > > northd/northd.c | 50 ++-- > northd/ovn-northd.8.xml | 60 +++-- >

Re: [ovs-dev] [PATCH v6] netdev-offload-tc: del ufid mapping if device not exist

2023-02-22 Thread Faicker Mo
I can run the fail-test more easier. There exists a flow in verbose log like this, recirc_id(0),in_port(2),eth(src=aa:1a:54:e9:c5:56,dst=86:29:2a:05:94:90),eth_type(0x0800),ipv4(frag=no), packets:1, bytes:84, used:12.240s, actions:3 The env is strict. The hmap should be expanded exactly only

Re: [ovs-dev] [RFC] dpdk: Allow retaining cap_sys_rawio privileges

2023-02-22 Thread 0-day Robot
Bleep bloop. Greetings Aaron Conole, I am a robot and I have tried out your patch. Thanks for your contribution. I encountered some error that I wasn't expecting. See the details below. checkpatch: WARNING: Line is 103 characters long (recommended limit is 79) #112 FILE:

Re: [ovs-dev] [PATCH v6] netdev-offload-tc: del ufid mapping if device not exist

2023-02-22 Thread Simon Horman
On Wed, Feb 22, 2023 at 04:19:37PM +0100, Simon Horman wrote: > On Wed, Feb 22, 2023 at 06:33:50PM +0800, Faicker Mo wrote: > > It's not easy to add a fail test without the changed code. > > But I test it failed with the old code manually following these steps, > > 1. Apply this patch(with test in

Re: [ovs-dev] [RFC] dpdk: Allow retaining cap_sys_rawio privileges

2023-02-22 Thread Aaron Conole
Apologies - I mis-typed Gaetan's email when I entered it into my mail file. CC'd correctly on this email (but I can resend the patch, if you think it is better). Aaron Conole writes: > Open vSwitch generally tries to let the underlying operating system > managed the low level details of

[ovs-dev] [RFC] dpdk: Allow retaining cap_sys_rawio privileges

2023-02-22 Thread Aaron Conole
Open vSwitch generally tries to let the underlying operating system managed the low level details of hardware, for example DMA mapping, bus arbitration, etc. However, when using DPDK, the underlying operating system yields control of many of these details to userspace for management. In the case

Re: [ovs-dev] [PATCH ovn 1/2] northd: move defrag router pipeline stage forward

2023-02-22 Thread 0-day Robot
Bleep bloop. Greetings Lorenzo Bianconi, I am a robot and I have tried out your patch. Thanks for your contribution. I encountered some error that I wasn't expecting. See the details below. checkpatch: WARNING: Line is 101 characters long (recommended limit is 79) #69 FILE:

[ovs-dev] [PATCH ovn 1/2] northd: move defrag router pipeline stage forward

2023-02-22 Thread Lorenzo Bianconi
Introduce a post_defrag router ingress pipeline stage and move current defrag code in post_defrag stage. This is a preliminary patch to just defrag IP fragment traffic (without performing DNAT) before accessing L4 info (e.g. L4 protocol port) since they are not available in all IP fragment.

[ovs-dev] [PATCH ovn 2/2] northd: add flows to defrag IP traffic

2023-02-22 Thread Lorenzo Bianconi
Introduce a priority-100 flow in the ingress router defrag stage in order to just perform IP traffic defragmentation without doing any dnat operation. This change is necessary since the logical flow reported below fails for IP fragmented traffic since L4 port info is available just in the first

[ovs-dev] [PATCH ovn 0/2] fix IP fragmented traffic hitting LB

2023-02-22 Thread Lorenzo Bianconi
Lorenzo Bianconi (2): northd: move defrag router pipeline stage forward northd: add flows to defrag IP traffic northd/northd.c | 50 ++-- northd/ovn-northd.8.xml | 60 +++-- tests/ovn-northd.at | 526 tests/ovn.at| 52 ++--

[ovs-dev] [PATCH v9] netdev-dpdk: add control plane protection support

2023-02-22 Thread Robin Jarry
Some control protocols are used to maintain link status between forwarding engines (e.g. LACP). When the system is not sized properly, the PMD threads may not be able to process all incoming traffic from the configured Rx queues. When a signaling packet of such protocols is dropped, it can cause

Re: [ovs-dev] [PATCH v6] netdev-offload-tc: del ufid mapping if device not exist

2023-02-22 Thread Simon Horman
On Wed, Feb 22, 2023 at 06:33:50PM +0800, Faicker Mo wrote: > It's not easy to add a fail test without the changed code. > But I test it failed with the old code manually following these steps, > 1. Apply this patch(with test in it) > 2. Revert the changed code in netdev-offload-tc.c > 3. Run the

Re: [ovs-dev] [PATCH ovn v2] dbctl: Fix a couple of memory leaks

2023-02-22 Thread Simon Horman
On Wed, Feb 22, 2023 at 01:56:51PM +0100, Ales Musil wrote: > Nothing is being freed wherever we are calling > ctl_fatal which is fine because the program is > about to shutdown anyway however one of the > leaks was caught by address sanitizer. > Fix most of the leaks that are happening before >

Re: [ovs-dev] [PATCH v3 2/2] ipfix: make template and stats interval configurable

2023-02-22 Thread Adrian Moreno
On 2/20/23 19:00, Ilya Maximets wrote: On 2/10/23 17:03, Adrián Moreno wrote: From: Adrian Moreno Add options to the IPFIX table configure the interval to send statistics and template information. Signed-off-by: Adrian Moreno --- - v3: - Removed unit tests which generate errors in

Re: [ovs-dev] [PATCH v5 4/5] ovs-router: Introduce src option in ovs/route/add command.

2023-02-22 Thread Simon Horman
On Wed, Feb 22, 2023 at 07:29:51PM +0900, Nobuhiro MIKI wrote: > When adding a route with ovs/route/add command, the source address > in "ovs_router_entry" structure is always the FIRST address that the > interface has. See "ovs_router_get_netdev_source_address" > function for more information. >

Re: [ovs-dev] [PATCH v5 3/5] ofproto: Fix mam page for tunnel related commands.

2023-02-22 Thread Simon Horman
On Wed, Feb 22, 2023 at 07:29:50PM +0900, Nobuhiro MIKI wrote: > These commands already support both IPv4 and IPv6. > > Signed-off-by: Nobuhiro MIKI Reviewed-by: Simon Horman ___ dev mailing list d...@openvswitch.org

[ovs-dev] [PATCH ovn v2] dbctl: Fix a couple of memory leaks

2023-02-22 Thread Ales Musil
Nothing is being freed wherever we are calling ctl_fatal which is fine because the program is about to shutdown anyway however one of the leaks was caught by address sanitizer. Fix most of the leaks that are happening before call to ctl_fatal. Direct leak of 64 byte(s) in 1 object(s) allocated

Re: [ovs-dev] [PATCH ovn] dbctl: Fix a couple of memory leaks

2023-02-22 Thread Ales Musil
On Wed, Feb 22, 2023 at 1:38 PM Ilya Maximets wrote: > + > +if (cmd_result) { > +free(cmd_result); > +} > + > +if (cmd_error) { > +free(cmd_error); > +} > >>> > >>> I don't think the cmd_result and cmd_error conditions are

Re: [ovs-dev] [PATCH 1/1] tc: Fix cleaning chains

2023-02-22 Thread Simon Horman
On Wed, Feb 22, 2023 at 12:30:17PM +0200, Roi Dayan via dev wrote: > Sometimes there is a need to clean empty chains as done in > delete_chains_from_netdev(). The cited commit doesn't remove > the chain completely which cause adding ingress_block later to fail. > This can be reproduced with

Re: [ovs-dev] [PATCH ovn] dbctl: Fix a couple of memory leaks

2023-02-22 Thread Ilya Maximets
+ +if (cmd_result) { +free(cmd_result); +} + +if (cmd_error) { +free(cmd_error); +} >>> >>> I don't think the cmd_result and cmd_error conditions are required >>> as free should do nothing when passed NULL. >>> >> >> Isn't

Re: [ovs-dev] [PATCH ovn] dbctl: Fix a couple of memory leaks

2023-02-22 Thread Simon Horman
On Wed, Feb 22, 2023 at 11:24:04AM +0100, Ales Musil wrote: > On Wed, Feb 22, 2023 at 10:59 AM Simon Horman > wrote: ... Hi Ales, > Hi Simon, > thank you for your review. you are welcome. > > > --- > > > utilities/ovn-dbctl.c | 76 +++ > > > 1 file

Re: [ovs-dev] [PATCH v6] netdev-offload-tc: del ufid mapping if device not exist

2023-02-22 Thread Faicker Mo
It's not easy to add a fail test without the changed code. But I test it failed with the old code manually following these steps, 1. Apply this patch(with test in it) 2. Revert the changed code in netdev-offload-tc.c 3. Run the test Yes, the fail-test above sometimes may pass because of the env

[ovs-dev] [PATCH 1/1] tc: Fix cleaning chains

2023-02-22 Thread Roi Dayan via dev
Sometimes there is a need to clean empty chains as done in delete_chains_from_netdev(). The cited commit doesn't remove the chain completely which cause adding ingress_block later to fail. This can be reproduced with adding bond as ovs port which makes ovs use ingress_block for it. While at it

[ovs-dev] [PATCH v5 5/5] route-table: Retrieving the preferred source address from Netlink.

2023-02-22 Thread Nobuhiro MIKI
We can use the "ip route add ... src ..." command to set the preferred source address for each entry in the kernel FIB. OVS has a mechanism to cache the FIB, but the preferred source address is ignored and calculated with its own logic. This patch resolves the difference between kernel FIB and OVS

[ovs-dev] [PATCH v5 2/5] ovs-router: Cleanup parser for ovs/route/add command.

2023-02-22 Thread Nobuhiro MIKI
This patch cleans up the parser to accept pkt_mark and gw in any order. pkt_mark and gw are normally expected to be specified exactly once. However, as with other tools, if specified multiple times, the last specification is used. Also, pkt_mark and gw have separate prefix strings so they can be

[ovs-dev] [PATCH v5 4/5] ovs-router: Introduce src option in ovs/route/add command.

2023-02-22 Thread Nobuhiro MIKI
When adding a route with ovs/route/add command, the source address in "ovs_router_entry" structure is always the FIRST address that the interface has. See "ovs_router_get_netdev_source_address" function for more information. If an interface has multiple ipv4 and/or ipv6 addresses, there are use

[ovs-dev] [PATCH v5 1/5] netdev-dummy: Support multiple IP addresses.

2023-02-22 Thread Nobuhiro MIKI
This is useful in test cases where multiple IPv4/IPv6 addresses are assigned together. Reviewed-by: Simon Horman Signed-off-by: Nobuhiro MIKI --- lib/netdev-dummy.c | 67 +- 1 file changed, 43 insertions(+), 24 deletions(-) diff --git

[ovs-dev] [PATCH v5 0/5] Add support for preffered src address in ovs-router

2023-02-22 Thread Nobuhiro MIKI
With this series, the preferred source address in ovs-router is obtained from both ovs/route/add command and kernel FIB. v5: - Add patch to fix man page v4: - Add cleanup patch for ovs/route/add - Remove unrelated code v3: - Fix netdev-dummy to support multiple IP addresses - Add validation and

[ovs-dev] [PATCH v5 3/5] ofproto: Fix mam page for tunnel related commands.

2023-02-22 Thread Nobuhiro MIKI
These commands already support both IPv4 and IPv6. Signed-off-by: Nobuhiro MIKI --- ofproto/ofproto-tnl-unixctl.man | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/ofproto/ofproto-tnl-unixctl.man b/ofproto/ofproto-tnl-unixctl.man index 13a465119a90..0c0a392820fb

Re: [ovs-dev] [PATCH ovn] dbctl: Fix a couple of memory leaks

2023-02-22 Thread Ales Musil
On Wed, Feb 22, 2023 at 10:59 AM Simon Horman wrote: > On Wed, Feb 22, 2023 at 09:02:10AM +0100, Ales Musil wrote: > > Nothing is being freed wherever we are calling > > ctl_fatal which is fine because the program is > > about to shutdown anyway however one of the > > leaks was caught by address

Re: [ovs-dev] [PATCH v4 3/4] ovs-router: Introduce src option in ovs/route/add command.

2023-02-22 Thread Simon Horman
On Wed, Feb 22, 2023 at 06:31:55PM +0900, Nobuhiro MIKI wrote: > On 2023/02/22 18:04, Simon Horman wrote: > > On Wed, Feb 22, 2023 at 05:12:36PM +0900, Nobuhiro MIKI wrote: ... > >> diff --git a/ofproto/ofproto-tnl-unixctl.man > >> b/ofproto/ofproto-tnl-unixctl.man > >> index

Re: [ovs-dev] [PATCH ovn] dbctl: Fix a couple of memory leaks

2023-02-22 Thread Simon Horman
On Wed, Feb 22, 2023 at 09:02:10AM +0100, Ales Musil wrote: > Nothing is being freed wherever we are calling > ctl_fatal which is fine because the program is > about to shutdown anyway however one of the > leaks was caught by address sanitizer. > Fix most of the leaks that are happening before >

Re: [ovs-dev] [PATCH v4 3/4] ovs-router: Introduce src option in ovs/route/add command.

2023-02-22 Thread Nobuhiro MIKI
On 2023/02/22 18:04, Simon Horman wrote: > On Wed, Feb 22, 2023 at 05:12:36PM +0900, Nobuhiro MIKI wrote: >> When adding a route with ovs/route/add command, the source address >> in "ovs_router_entry" structure is always the FIRST address that the >> interface has. See

Re: [ovs-dev] [PATCH v4 2/4] ovs-router: Cleanup parser for ovs/route/add command.

2023-02-22 Thread Nobuhiro MIKI
On 2023/02/22 18:01, Simon Horman wrote: > On Wed, Feb 22, 2023 at 05:12:35PM +0900, Nobuhiro MIKI wrote: >> This patch cleans up the parser to accept pkt_mark and gw in any order. >> >> pkt_mark and gw are normally expected to be specified exactly once. >> However, as with other tools, if

Re: [ovs-dev] [PATCH v6] netdev-offload-tc: del ufid mapping if device not exist

2023-02-22 Thread Simon Horman
On Wed, Feb 22, 2023 at 10:03:07AM +0800, Faicker Mo wrote: > Sorry. > The commit message and code are not changed. > Resended when I met a bug of intel-ovs-compilation test fail and add version > descriptions. Thanks, I think I understand now. But please don't top-post on this mailing list.

Re: [ovs-dev] [PATCH v4 3/4] ovs-router: Introduce src option in ovs/route/add command.

2023-02-22 Thread Simon Horman
On Wed, Feb 22, 2023 at 05:12:36PM +0900, Nobuhiro MIKI wrote: > When adding a route with ovs/route/add command, the source address > in "ovs_router_entry" structure is always the FIRST address that the > interface has. See "ovs_router_get_netdev_source_address" > function for more information. >

Re: [ovs-dev] [PATCH v4 2/4] ovs-router: Cleanup parser for ovs/route/add command.

2023-02-22 Thread Simon Horman
On Wed, Feb 22, 2023 at 05:12:35PM +0900, Nobuhiro MIKI wrote: > This patch cleans up the parser to accept pkt_mark and gw in any order. > > pkt_mark and gw are normally expected to be specified exactly once. > However, as with other tools, if specified multiple times, the last > specification is

[ovs-dev] [PATCH v4 1/4] netdev-dummy: Support multiple IP addresses.

2023-02-22 Thread Nobuhiro MIKI
This is useful in test cases where multiple IPv4/IPv6 addresses are assigned together. Reviewed-by: Simon Horman Signed-off-by: Nobuhiro MIKI --- lib/netdev-dummy.c | 67 +- 1 file changed, 43 insertions(+), 24 deletions(-) diff --git

[ovs-dev] [PATCH v4 3/4] ovs-router: Introduce src option in ovs/route/add command.

2023-02-22 Thread Nobuhiro MIKI
When adding a route with ovs/route/add command, the source address in "ovs_router_entry" structure is always the FIRST address that the interface has. See "ovs_router_get_netdev_source_address" function for more information. If an interface has multiple ipv4 and/or ipv6 addresses, there are use

[ovs-dev] [PATCH v4 4/4] route-table: Retrieving the preferred source address from Netlink.

2023-02-22 Thread Nobuhiro MIKI
We can use the "ip route add ... src ..." command to set the preferred source address for each entry in the kernel FIB. OVS has a mechanism to cache the FIB, but the preferred source address is ignored and calculated with its own logic. This patch resolves the difference between kernel FIB and OVS

[ovs-dev] [PATCH v4 0/4] Add support for preffered src address in ovs-router

2023-02-22 Thread Nobuhiro MIKI
With this series, the preferred source address in ovs-router is obtained from both ovs/route/add command and kernel FIB. v4: - Add cleanup patch for ovs/route/add - Remove unrelated code v3: - Fix netdev-dummy to support multiple IP addresses - Add validation and unit tests for ovs/route/add -

[ovs-dev] [PATCH v4 2/4] ovs-router: Cleanup parser for ovs/route/add command.

2023-02-22 Thread Nobuhiro MIKI
This patch cleans up the parser to accept pkt_mark and gw in any order. pkt_mark and gw are normally expected to be specified exactly once. However, as with other tools, if specified multiple times, the last specification is used. Also, pkt_mark and gw have separate prefix strings so they can be

[ovs-dev] [PATCH ovn] dbctl: Fix a couple of memory leaks

2023-02-22 Thread Ales Musil
Nothing is being freed wherever we are calling ctl_fatal which is fine because the program is about to shutdown anyway however one of the leaks was caught by address sanitizer. Fix most of the leaks that are happening before call to ctl_fatal. Direct leak of 64 byte(s) in 1 object(s) allocated