[ovs-dev] [PATCH] mac-learning: Fix learned fdb entries are not age out issue.

2022-07-29 Thread miterv
From: Lin Huang After user add a static fdb entry, the get_lru() function will always return the static fdb entry. That's normal fdb entries will not age out through mac_learning_run(). Fix the issue by modify the get_lru() function to check the entry->expires field and not return the entry wh

Re: [ovs-dev] [PATCH RFC] ofproto-dpif-xlate: Optimize the clone for patch ports

2022-07-29 Thread Ilya Maximets
On 7/28/22 13:49, Ales Musil wrote: > When the packet was traveling through patch port boundary > OvS would check if any of the actions is reversible, > if not it would clone the packet. However, the check > was only at the first level of the second bridge. > That caused some issues when the packet

Re: [ovs-dev] [PATCH RFC] ofproto-dpif-xlate: Optimize the clone for patch ports

2022-07-29 Thread Ales Musil
On Fri, Jul 29, 2022 at 1:50 PM Ilya Maximets wrote: > On 7/28/22 13:49, Ales Musil wrote: > > When the packet was traveling through patch port boundary > > OvS would check if any of the actions is reversible, > > if not it would clone the packet. However, the check > > was only at the first leve

Re: [ovs-dev] [PATCH] xenserver: Remove xenserver

2022-07-29 Thread David Marchand
Hello Greg, On Wed, Jul 27, 2022 at 7:37 PM Greg Rose wrote: > > Remove the current xenserver implementation - it is obsolete and > since 3.0 we do not support kernel module builds [1]. > > 1. https://mail.openvswitch.org/pipermail/ovs-dev/2022-July/395789.html > > Passes build tests here: > htt

Re: [ovs-dev] [PATCH RFC] ofproto-dpif-xlate: Optimize the clone for patch ports

2022-07-29 Thread Ilya Maximets
On 7/29/22 14:44, Ales Musil wrote: > > diff --git a/lib/netlink.c b/lib/netlink.c > > index 6215282d6..8bcf56953 100644 > > --- a/lib/netlink.c > > +++ b/lib/netlink.c > > @@ -981,3 +981,31 @@ nl_attr_find_nested(const struct nlattr *nla, > uint16_t type) > >  { > >   

Re: [ovs-dev] [PATCH 1/2] netdev-offload-tc: Fix ignoring unknown tunnel keys.

2022-07-29 Thread Ilya Maximets
On 7/14/22 19:03, Roi Dayan wrote: > > > On 2022-07-14 4:18 PM, Ilya Maximets wrote: >> On 7/14/22 15:13, Roi Dayan wrote: >>> >>> >>> On 2022-07-14 4:01 PM, Roi Dayan wrote: On 2022-07-14 3:52 PM, Roi Dayan wrote: > > > On 2022-07-14 3:37 PM, Roi Dayan wrote: >> >>

[ovs-dev] [PATCH 0/3] netdev-offload-tc: Improved debug logs for bad/unused bit masks.

2022-07-29 Thread Ilya Maximets
Emerged from Roi's suggestion while discussing tunnel offload fixes. It will probably make sense to backport these down to 2.17 as it is debug-only and 2.17 will be our new LTS. Ilya Maximets (3): dynamic-string: Add function for a sparse hex dump. netdev-offload-tc: Print unused mask bits on

[ovs-dev] [PATCH 1/3] dynamic-string: Add function for a sparse hex dump.

2022-07-29 Thread Ilya Maximets
New function to dump large and sparsely populated data structures like struct flow. Signed-off-by: Ilya Maximets --- include/openvswitch/dynamic-string.h | 2 ++ lib/dynamic-string.c | 36 +--- 2 files changed, 30 insertions(+), 8 deletions(-) diff --git

[ovs-dev] [PATCH 2/3] netdev-offload-tc: Print unused mask bits on failure.

2022-07-29 Thread Ilya Maximets
This change extends the debug logging with the sparse dump of the flow mask structure to make debug process easier. Sample output: |netdev_offload_tc|DBG|offloading isn't supported, unknown attribute Unused mask bits: 0270 00 00 00 00 00 00 00 00-00 00 00 ff 00 00 00 00 In this exampl

[ovs-dev] [PATCH 3/3] tc: Use sparse hex dump while printing inconsistencies.

2022-07-29 Thread Ilya Maximets
Instead of a very long hex string something like this will be printed: |DBG|tc flower compare failed mask compare: Expected Mask: ff ff 00 00 ff ff ff ff-ff ff ff ff ff ff ff ff 0020 00 00 00 00 00 00 00 00-00 00 00 00 00 00 03 00 0090 00 00 00 00 00 00 00 00-ff ff ff ff f

Re: [ovs-dev] [PATCH] xenserver: Remove xenserver

2022-07-29 Thread Gregory Rose
On 7/29/2022 6:52 AM, David Marchand wrote: Hello Greg, On Wed, Jul 27, 2022 at 7:37 PM Greg Rose wrote: Remove the current xenserver implementation - it is obsolete and since 3.0 we do not support kernel module builds [1]. 1. https://mail.openvswitch.org/pipermail/ovs-dev/2022-July/395

[ovs-dev] [PATCH v2 0/5] tc: Fixes for tunnel offloading.

2022-07-29 Thread Ilya Maximets
This is started from the issue with broken ERSPAN tunnel reported by Eelco, but turned out a much wider problem with ignoring different tunnel keys and flags while constructing TC flower. Some of that can be fixed, some can't be fixed due to lack of support from kernel. Strictly speaking, we shou

[ovs-dev] [PATCH v2 2/5] netdev-offload-tc: Explicitly handle mask for the tunnel destination port.

2022-07-29 Thread Ilya Maximets
netdev_tc_flow_put() ignores the tunnel.tp_dst mask. That results in the exact match on the value. TC supports the masked match on this field and it does return the mask back during the flow dump even if it wasn't provided initially. OVS should correctly handle that. There is a problem though.

[ovs-dev] [PATCH v2 1/5] netdev-offload-tc: Fix the mask for tunnel metadata length.

2022-07-29 Thread Ilya Maximets
'wc.masks.tunnel.metadata.present.len' must be a mask for the same field in the flow key, but in the tc_flower structure it's the real length of metadata masks. That is correctly handled for the individual opt->length, setting all the masks to 0x1f like it's done in the tun_metadata_to_geneve_mask

[ovs-dev] [PATCH v2 3/5] netdev-offload-tc: Use masks instead of keys while parsing tunnel attributes.

2022-07-29 Thread Ilya Maximets
If the key is zero, it doesn't mean we don't need to match on it. Masks should be checked instead. For the metadata length that's a bit tricky, because the length in the mask section of the 'flower' structure represents the actual length of the mask and not the mask of the length field in the key.

[ovs-dev] [PATCH v2 4/5] netdev-offload-tc: Fix ignoring unknown tunnel keys.

2022-07-29 Thread Ilya Maximets
Current offloading code supports only limited number of tunnel keys and silently ignores everything it doesn't understand. This is causing, for example, offloaded ERSPAN tunnels to not work, because flow is offloaded, but ERSPAN options are not provided to TC. There is a number of tunnel keys, wh

[ovs-dev] [PATCH v2 5/5] netdev-offload-tc: Add missing handling of the tunnel source port.

2022-07-29 Thread Ilya Maximets
netdev_tc_flow_put() "consumes" the tunnel.tp_src value, but it's never passed down to TC, and not parsed back. Fix that. Signed-off-by: Ilya Maximets --- lib/netdev-offload-tc.c | 6 ++ lib/tc.c| 17 + 2 files changed, 23 insertions(+) diff --git a/lib/net

Re: [ovs-dev] [PATCH v2 2/5] netdev-offload-tc: Explicitly handle mask for the tunnel destination port.

2022-07-29 Thread 0-day Robot
Bleep bloop. Greetings Ilya Maximets, 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: Comment with 'xxx' marker #43 FILE: lib/netdev-offload-tc.c:1993: /* XXX: We

Re: [ovs-dev] [PATCH v2 4/5] netdev-offload-tc: Fix ignoring unknown tunnel keys.

2022-07-29 Thread 0-day Robot
Bleep bloop. Greetings Ilya Maximets, 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: Comment with 'xxx' marker #124 FILE: lib/netdev-offload-tc.c:1438: /* XXX

[ovs-dev] OVN 22.09 Soft Freeze 5 August, 2022

2022-07-29 Thread Mark Michelson
Hi everyone, Soft freeze for the OVN 22.09.0 release is in one week, 5 August. As a reminder, soft freeze is the deadline for new feature patches to be posted for review. The features do not need to be merged by this date, they just need to be posted for review. Bug fix patches will still be

Re: [ovs-dev] [RFC ovn] controller: send GARPs for LSPs in vlan-backed network scenario

2022-07-29 Thread Lorenzo Bianconi
> On Thu, Jul 14, 2022 at 3:36 AM Lorenzo Bianconi > wrote: > > > > > On 7/13/22 18:07, Lorenzo Bianconi wrote: > > > >> On 6/17/22 00:31, Lorenzo Bianconi wrote: > > > >>> When using VLAN backed networks and OVN routers leveraging the > > > >>> 'ovn-chassis-mac-mappings' option, the eth.src field

Re: [ovs-dev] [PATCH] python-c-ext: Handle initialization failures.

2022-07-29 Thread Ilya Maximets
On 7/27/22 17:05, Mike Pattrick wrote: > On Fri, Jul 22, 2022 at 3:19 PM Ilya Maximets wrote: >> >> PyModule_AddObject() may fail and it doesn't steal references >> in this case. The error condition should be handled to avoid >> possible memory leaks. >> >> And while it's not strictly specified i

Re: [ovs-dev] [PATCH 0/4] rhel, debian: Headers installation + python C extension.

2022-07-29 Thread Ilya Maximets
On 7/27/22 16:34, Frode Nordahl wrote: > Hello, Ilya, > > On Mon, Jul 25, 2022 at 2:19 PM Ilya Maximets wrote: >> >> >> Ilya Maximets (4): >> rhel: Stop installing internal headers. >> libopenvswitch.pc: Add missing libs for a static build. >> python: Add ability to pass extra libs and cfla

Re: [ovs-dev] [PATCH 0/2] m4: Replace obsolete AC_HELP_STRING and AC_TRY_RUN.

2022-07-29 Thread Ilya Maximets
On 7/27/22 19:52, Pai G, Sunil wrote: > Hi Ilya, > > Thanks for both the patches. > I tested them on Ubuntu 22.04 (autoconf (GNU Autoconf) 2.71) as well as > Ubuntu 20.04 (autoconf (GNU Autoconf) 2.69) and both works as expected, > i.e don't see any warnings(except about AC_PROG_CC_C99) generate

Re: [ovs-dev] [PATCH] test-ovsdb: Fix false-positive leaks from LeakSanitizer.

2022-07-29 Thread Ilya Maximets
On 7/29/22 08:05, Ales Musil wrote: > > On Thu, Jul 28, 2022 at 5:43 PM Ilya Maximets > wrote: > > LeakSanitizer for some reason reports these json objects as leaked, > even though we do have references to them at the moment ovs_fatal() > called from check_

[ovs-dev] [PATCH] netdev-offload-tc: Disable offload of IPv6 fragments.

2022-07-29 Thread Ilya Maximets
OVS kernel datapath and TC are parsing IPv6 fragments differently. For IPv6 later fragments, according to the original design [1], OVS always sets nw_proto=44 (IPPROTO_FRAMENT), regardless of the type of the L4 protocol. This leads to situation where flow for nw_proto=44 gets installed to TC, but

Re: [ovs-dev] [PATCH net-next 1/2] openvswitch: Fix double reporting of drops in dropwatch

2022-07-29 Thread Jakub Kicinski
On Thu, 28 Jul 2022 12:12:58 -0400 Mike Pattrick wrote: > Frames sent to userspace can be reported as dropped in > ovs_dp_process_packet, however, if they are dropped in the netlink code > then netlink_attachskb will report the same frame as dropped. > > This patch checks for error codes which ind

Re: [ovs-dev] [PATCH v5] bond: Improve bond and lacp visibility

2022-07-29 Thread David Marchand
On Wed, Jun 22, 2022 at 4:29 PM Mike Pattrick wrote: > > Add additional logging for debug and info level with a focus on code > related to bond members coming up, go down, and changing. > > Several existing log messages were modified to handle sub 1kB log > messages with more grace. Instead of rep