From patchwork Fri Sep 3 19:27:41 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Frode Nordahl X-Patchwork-Id: 1524518 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=canonical.com header.i=@canonical.com header.a=rsa-sha256 header.s=20210705 header.b=oYcwgRQG; dkim-atps=neutral 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 4H1SW75X5Zz9sCD for ; Sat, 4 Sep 2021 05:28:03 +1000 (AEST) Received: from localhost (localhost [127.0.0.1]) by smtp4.osuosl.org (Postfix) with ESMTP id 840BD426EE; Fri, 3 Sep 2021 19:28:01 +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 93G6h4U9ELNS; Fri, 3 Sep 2021 19:27:59 +0000 (UTC) Received: from lists.linuxfoundation.org (lf-lists.osuosl.org [IPv6:2605:bc80:3010:104::8cd3:938]) by smtp4.osuosl.org (Postfix) with ESMTPS id F3E8E426EC; Fri, 3 Sep 2021 19:27:58 +0000 (UTC) Received: from lf-lists.osuosl.org (localhost [127.0.0.1]) by lists.linuxfoundation.org (Postfix) with ESMTP id 95D94C0028; Fri, 3 Sep 2021 19:27:56 +0000 (UTC) X-Original-To: dev@openvswitch.org Delivered-To: ovs-dev@lists.linuxfoundation.org Received: from smtp2.osuosl.org (smtp2.osuosl.org [IPv6:2605:bc80:3010::133]) by lists.linuxfoundation.org (Postfix) with ESMTP id 58318C000E for ; Fri, 3 Sep 2021 19:27:54 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by smtp2.osuosl.org (Postfix) with ESMTP id B94834027D for ; Fri, 3 Sep 2021 19:27:53 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Authentication-Results: smtp2.osuosl.org (amavisd-new); dkim=pass (2048-bit key) header.d=canonical.com Received: from smtp2.osuosl.org ([127.0.0.1]) by localhost (smtp2.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id t898mHAflpxh for ; Fri, 3 Sep 2021 19:27:52 +0000 (UTC) X-Greylist: domain auto-whitelisted by SQLgrey-1.8.0 Received: from smtp-relay-canonical-1.canonical.com (smtp-relay-canonical-1.canonical.com [185.125.188.121]) by smtp2.osuosl.org (Postfix) with ESMTPS id A66C74070E for ; Fri, 3 Sep 2021 19:27:52 +0000 (UTC) Received: from frode-threadripper.. (1.general.frode.uk.vpn [10.172.193.250]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by smtp-relay-canonical-1.canonical.com (Postfix) with ESMTPSA id B2A9B401A1; Fri, 3 Sep 2021 19:27:49 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=canonical.com; s=20210705; t=1630697269; bh=fPwJn5/TF25PMr/cW1eQsgGFwM82CilyyWuBLLmBmVE=; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References: MIME-Version; b=oYcwgRQGfji+k3XlU9gUg1CJM22vBaasrsnLUnlUIW0EG1F/zhpADBAUOCPGxF8cI WYE8Bykyh9ZnuTMEerXLSIP7QExIxszqbzuw7u+Q6dSIaKTEAd7UktDDXg9MDfaNZt 4mOjgMiZ0f9UroerUrMuj+fC8EeJXLkhFMBFjBLsogRln7eCzpMVsijCev1LiGb9ay KxXf+IN7bkmlgvKuyjvL1cqHReAK3AoAdDsjbq0sHSipiRxehiYSNJbYGAOcOynZVu Qjng6S77p3n8x/qhTpx3Vw+VS2Mg7BnoTJpkKMFaGf+yVZ/lDV+/n5M/YfyUM7FniB O9dhTMl0mr1Iw== From: Frode Nordahl To: dev@openvswitch.org Date: Fri, 3 Sep 2021 21:27:41 +0200 Message-Id: <20210903192748.1408062-3-frode.nordahl@canonical.com> X-Mailer: git-send-email 2.32.0 In-Reply-To: <20210903192748.1408062-1-frode.nordahl@canonical.com> References: <20210903192748.1408062-1-frode.nordahl@canonical.com> MIME-Version: 1.0 Subject: [ovs-dev] [PATCH ovn v4 2/9] tests: Stop using non-existent requested-chassis 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" A couple of tests refers to non-existent chassis to validate that the ovn-controller would release ports that otherwise was destined for it when requested-chassis points somewhere else. With upcoming changes to have the ovn-controller use the new Port_Binding:requested_chassis column maintained by northd instead of processing the options itself, referring to a non-existant chassis will no longer work as the tests expect. With this patch we instead add a throw-away chassis to the simulation and point the requested-chassis option at that chassis. Signed-off-by: Frode Nordahl --- tests/ovn.at | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) diff --git a/tests/ovn.at b/tests/ovn.at index 5104a6895..2914018e8 100644 --- a/tests/ovn.at +++ b/tests/ovn.at @@ -9434,6 +9434,11 @@ ovn-nbctl lsp-add bar bar3 \ # Create two hypervisor and create OVS ports corresponding to logical ports. net_add n1 +sim_add hv-foo +as hv-foo +ovs-vsctl add-br br-phys +ovn_attach n1 br-phys 192.168.0.253 + sim_add hv1 as hv1 ovs-vsctl add-br br-phys @@ -9603,7 +9608,7 @@ as hv1 ovs-appctl netdev-dummy/receive vm1 $packet OVN_CHECK_PACKETS([hv1/vm1-tx.pcap], [expected1]) # Test binding of parent and container ports. -ovn-nbctl lsp-set-options vm1 requested-chassis=foo +ovn-nbctl lsp-set-options vm1 requested-chassis=hv-foo OVS_WAIT_UNTIL([test xdown = x$(ovn-nbctl lsp-get-up vm1)]) OVS_WAIT_UNTIL([test xdown = x$(ovn-nbctl lsp-get-up foo1)]) @@ -13454,6 +13459,10 @@ ovn-nbctl ls-add ls0 ovn-nbctl lsp-add ls0 lsp0 net_add n1 +sim_add hv-foo +as hv-foo +ovs-vsctl add-br br-phys +ovn_attach n1 br-phys 192.168.0.10 sim_add hv1 as hv1 ovs-vsctl add-br br-phys @@ -13473,7 +13482,7 @@ wait_column "$hv1_uuid" Port_Binding chassis logical_port=lsp0 AT_CHECK([as hv1 ovs-ofctl dump-flows br-int table=0 | grep in_port=1], [0], [ignore]) AT_CHECK([as hv1 ovs-ofctl dump-flows br-int table=65 | grep actions=output:1], [0], [ignore]) -check ovn-nbctl --wait=hv lsp-set-options lsp0 requested-chassis=non-existant-chassis +check ovn-nbctl --wait=hv lsp-set-options lsp0 requested-chassis=hv-foo OVS_WAIT_UNTIL([test 1 = $(grep -c "Releasing lport lsp0 from this chassis" hv1/ovn-controller.log)]) check ovn-nbctl --wait=hv sync wait_column '' Port_Binding chasssi logical_port=lsp0