From patchwork Sat May 8 15:08:02 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Han Zhou X-Patchwork-Id: 1475878 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=openvswitch.org (client-ip=140.211.166.137; helo=smtp4.osuosl.org; envelope-from=ovs-dev-bounces@openvswitch.org; receiver=) Received: from smtp4.osuosl.org (smtp4.osuosl.org [140.211.166.137]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 4FcrLB2Ghrz9vFY for ; Sun, 9 May 2021 01:08:34 +1000 (AEST) Received: from localhost (localhost [127.0.0.1]) by smtp4.osuosl.org (Postfix) with ESMTP id B89B94185E; Sat, 8 May 2021 15:08:31 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from smtp4.osuosl.org ([127.0.0.1]) by localhost (smtp4.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 36vH_I4IcbAk; Sat, 8 May 2021 15:08:30 +0000 (UTC) Received: from lists.linuxfoundation.org (lf-lists.osuosl.org [140.211.9.56]) by smtp4.osuosl.org (Postfix) with ESMTP id AEE6C40643; Sat, 8 May 2021 15:08:29 +0000 (UTC) Received: from lf-lists.osuosl.org (localhost [127.0.0.1]) by lists.linuxfoundation.org (Postfix) with ESMTP id 80FBDC000E; Sat, 8 May 2021 15:08:29 +0000 (UTC) X-Original-To: dev@openvswitch.org Delivered-To: ovs-dev@lists.linuxfoundation.org Received: from smtp1.osuosl.org (smtp1.osuosl.org [IPv6:2605:bc80:3010::138]) by lists.linuxfoundation.org (Postfix) with ESMTP id B033FC0001 for ; Sat, 8 May 2021 15:08:27 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by smtp1.osuosl.org (Postfix) with ESMTP id 8639083E10 for ; Sat, 8 May 2021 15:08:27 +0000 (UTC) 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 0YAmnHXgePjW for ; Sat, 8 May 2021 15:08:26 +0000 (UTC) X-Greylist: domain auto-whitelisted by SQLgrey-1.8.0 Received: from relay3-d.mail.gandi.net (relay3-d.mail.gandi.net [217.70.183.195]) by smtp1.osuosl.org (Postfix) with ESMTPS id 3A86583DD9 for ; Sat, 8 May 2021 15:08:25 +0000 (UTC) X-Originating-IP: 98.42.113.153 Received: from localhost.net (unknown [98.42.113.153]) (Authenticated sender: hzhou@ovn.org) by relay3-d.mail.gandi.net (Postfix) with ESMTPSA id D8DCF60006; Sat, 8 May 2021 15:08:21 +0000 (UTC) From: Han Zhou To: dev@openvswitch.org Date: Sat, 8 May 2021 08:08:02 -0700 Message-Id: <20210508150802.3778566-1-hzhou@ovn.org> X-Mailer: git-send-email 2.30.2 MIME-Version: 1.0 Cc: Dumitru Ceara Subject: [ovs-dev] [PATCH ovn v2] ovn-northd.c: Don't use DPG for MC_UNKNOWN related lflows. 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" In commit b468c2c1 it avoided using DPG for multicast related lflows, but commit dd94f126 update the MC_UNKNOWN related lflows with DPG used again by mistake. This patch fixes it to avoid problems when a lflow using MC_UNKNOWN is monitored by a ovn-controller before the related mc-group is monitored, which could cause ovn-controller problem due to an incomplete dependency handling in I-P. This change can be removed (and applying DPG for all the other mc-group related lflows) when the I-P dependency handling problem is fixed. This change didn't address the ovn-northd-ddlog part because commit b468c2c1 didn't update ovn-northd-ddlog either. To be consistent, the ddlog change will be added together for all mc-group related flows. Fixes: dd94f1266c ("northd: MAC learning: Add logical flows for fdb.") Cc: Numan Siddique Acked-by: Dumitru Ceara Signed-off-by: Han Zhou --- v1 -> v2: Addresses Dumitru's comment about commit msg with corrected "Fixes" tag and reworded the message. northd/ovn-northd.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/northd/ovn-northd.c b/northd/ovn-northd.c index 1d4c5b67b..cccb9f3ed 100644 --- a/northd/ovn-northd.c +++ b/northd/ovn-northd.c @@ -6767,9 +6767,9 @@ build_lswitch_flows(struct hmap *datapaths, struct hmap *lflows) "outport = get_fdb(eth.dst); next;"); if (od->has_unknown) { - ovn_lflow_add(lflows, od, S_SWITCH_IN_L2_UNKNOWN, 50, - "outport == \"none\"", - "outport = \""MC_UNKNOWN"\"; output;"); + ovn_lflow_add_unique(lflows, od, S_SWITCH_IN_L2_UNKNOWN, 50, + "outport == \"none\"", + "outport = \""MC_UNKNOWN "\"; output;"); } else { ovn_lflow_add(lflows, od, S_SWITCH_IN_L2_UNKNOWN, 50, "outport == \"none\"", "drop;");