From patchwork Thu Jan 12 17:17:41 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ales Musil X-Patchwork-Id: 1725287 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@legolas.ozlabs.org Authentication-Results: legolas.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=openvswitch.org (client-ip=2605:bc80:3010::138; helo=smtp1.osuosl.org; envelope-from=ovs-dev-bounces@openvswitch.org; receiver=) Authentication-Results: legolas.ozlabs.org; dkim=fail reason="signature verification failed" (1024-bit key; unprotected) header.d=redhat.com header.i=@redhat.com header.a=rsa-sha256 header.s=mimecast20190719 header.b=Y9w2pH5w; dkim-atps=neutral Received: from smtp1.osuosl.org (smtp1.osuosl.org [IPv6:2605:bc80:3010::138]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-384) server-digest SHA384) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4NtB826xmqz23fk for ; Fri, 13 Jan 2023 04:17:54 +1100 (AEDT) Received: from localhost (localhost [127.0.0.1]) by smtp1.osuosl.org (Postfix) with ESMTP id 91A3D81DFD; Thu, 12 Jan 2023 17:17:52 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp1.osuosl.org 91A3D81DFD Authentication-Results: smtp1.osuosl.org; dkim=fail reason="signature verification failed" (1024-bit key) header.d=redhat.com header.i=@redhat.com header.a=rsa-sha256 header.s=mimecast20190719 header.b=Y9w2pH5w X-Virus-Scanned: amavisd-new at osuosl.org Received: from smtp1.osuosl.org ([127.0.0.1]) by localhost (smtp1.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id hqjgy81ezz2Q; Thu, 12 Jan 2023 17:17:51 +0000 (UTC) Received: from lists.linuxfoundation.org (lf-lists.osuosl.org [IPv6:2605:bc80:3010:104::8cd3:938]) by smtp1.osuosl.org (Postfix) with ESMTPS id C484F81419; Thu, 12 Jan 2023 17:17:50 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp1.osuosl.org C484F81419 Received: from lf-lists.osuosl.org (localhost [127.0.0.1]) by lists.linuxfoundation.org (Postfix) with ESMTP id A21CEC0033; Thu, 12 Jan 2023 17:17:50 +0000 (UTC) X-Original-To: dev@openvswitch.org Delivered-To: ovs-dev@lists.linuxfoundation.org Received: from smtp3.osuosl.org (smtp3.osuosl.org [140.211.166.136]) by lists.linuxfoundation.org (Postfix) with ESMTP id 220E2C002D for ; Thu, 12 Jan 2023 17:17:49 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by smtp3.osuosl.org (Postfix) with ESMTP id F1DB360B06 for ; Thu, 12 Jan 2023 17:17:48 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp3.osuosl.org F1DB360B06 Authentication-Results: smtp3.osuosl.org; dkim=pass (1024-bit key) header.d=redhat.com header.i=@redhat.com header.a=rsa-sha256 header.s=mimecast20190719 header.b=Y9w2pH5w X-Virus-Scanned: amavisd-new at osuosl.org Received: from smtp3.osuosl.org ([127.0.0.1]) by localhost (smtp3.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id v3-QQCt_QlQO for ; Thu, 12 Jan 2023 17:17:48 +0000 (UTC) X-Greylist: domain auto-whitelisted by SQLgrey-1.8.0 DKIM-Filter: OpenDKIM Filter v2.11.0 smtp3.osuosl.org 3583460A6A Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.129.124]) by smtp3.osuosl.org (Postfix) with ESMTPS id 3583460A6A for ; Thu, 12 Jan 2023 17:17:48 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1673543867; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=42brhWxxvfchTtEdUwk6wsl5qaxrOhesiTsEwk707/0=; b=Y9w2pH5wRUwwd6UFCt4fz9m/fJUacjVUCf/0Xtr3Zxl2RmxKCttGN7dQkI1WVlq7R+iHeb 36X9fJeGYHda2uadbLB3PQh9sIWOIF9P5xZcWQpvk7FTLNqi1xypF2JtRM80P58REei+dj 6rP9IyYndXIlAiIRgaz9tjgXpVm1odQ= Received: from mimecast-mx02.redhat.com (mx3-rdu2.redhat.com [66.187.233.73]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-609-b_h1cQktOQ6PAa2KXj-x5w-1; Thu, 12 Jan 2023 12:17:45 -0500 X-MC-Unique: b_h1cQktOQ6PAa2KXj-x5w-1 Received: from smtp.corp.redhat.com (int-mx02.intmail.prod.int.rdu2.redhat.com [10.11.54.2]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id 62A783C02541; Thu, 12 Jan 2023 17:17:45 +0000 (UTC) Received: from amusil.redhat.com (ovpn-193-101.brq.redhat.com [10.40.193.101]) by smtp.corp.redhat.com (Postfix) with ESMTP id 990B34078903; Thu, 12 Jan 2023 17:17:44 +0000 (UTC) From: Ales Musil To: dev@openvswitch.org Date: Thu, 12 Jan 2023 18:17:41 +0100 Message-Id: <20230112171743.245777-1-amusil@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 3.1 on 10.11.54.2 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Cc: i.maximets@ovn.org Subject: [ovs-dev] [PATCH v6 0/2] Add extension for partial CT flush X-BeenThere: ovs-dev@openvswitch.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: ovs-dev-bounces@openvswitch.org Sender: "dev" Add extension that will allow to flush connection from CT specified by full orig 5-tuple or partial match that combines orig or reply direction. Ales Musil (2): ofp, dpif: Allow CT flush based on partial match openflow: Add extension to flush CT by generic match NEWS | 9 + include/openflow/nicira-ext.h | 41 +++ include/openvswitch/ofp-msgs.h | 4 + include/openvswitch/ofp-util.h | 32 +++ lib/automake.mk | 2 + lib/ct-dpif.c | 210 +++++++-------- lib/ct-dpif.h | 4 +- lib/dpctl.c | 43 ++- lib/dpctl.man | 15 +- lib/ofp-bundle.c | 1 + lib/ofp-ct-util.c | 477 +++++++++++++++++++++++++++++++++ lib/ofp-ct-util.h | 49 ++++ lib/ofp-print.c | 20 ++ lib/ofp-util.c | 24 ++ lib/rconn.c | 1 + ofproto/ofproto-dpif.c | 8 +- ofproto/ofproto-provider.h | 7 +- ofproto/ofproto.c | 30 ++- tests/ofp-print.at | 108 ++++++++ tests/ovs-ofctl.at | 38 +++ tests/system-traffic.at | 120 ++++++++- utilities/ovs-ofctl.8.in | 22 ++ utilities/ovs-ofctl.c | 51 ++++ 23 files changed, 1165 insertions(+), 151 deletions(-) create mode 100644 lib/ofp-ct-util.c create mode 100644 lib/ofp-ct-util.h