From patchwork Fri Apr 1 08:16:50 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Vladislav Odintsov X-Patchwork-Id: 1612082 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: bilbo.ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.a=rsa-sha256 header.s=20210112 header.b=FevaeFt5; dkim-atps=neutral Authentication-Results: ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=openvswitch.org (client-ip=2605:bc80:3010::137; helo=smtp4.osuosl.org; envelope-from=ovs-dev-bounces@openvswitch.org; receiver=) Received: from smtp4.osuosl.org (smtp4.osuosl.org [IPv6:2605:bc80:3010::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 bilbo.ozlabs.org (Postfix) with ESMTPS id 4KVCgy0ftKz9sFy for ; Fri, 1 Apr 2022 19:17:02 +1100 (AEDT) Received: from localhost (localhost [127.0.0.1]) by smtp4.osuosl.org (Postfix) with ESMTP id 67AE242509; Fri, 1 Apr 2022 08:16:59 +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 zT7C8CldPeRW; Fri, 1 Apr 2022 08:16:58 +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 48683424FF; Fri, 1 Apr 2022 08:16:57 +0000 (UTC) Received: from lf-lists.osuosl.org (localhost [127.0.0.1]) by lists.linuxfoundation.org (Postfix) with ESMTP id 1D25EC002C; Fri, 1 Apr 2022 08:16:57 +0000 (UTC) X-Original-To: dev@openvswitch.org Delivered-To: ovs-dev@lists.linuxfoundation.org Received: from smtp1.osuosl.org (smtp1.osuosl.org [140.211.166.138]) by lists.linuxfoundation.org (Postfix) with ESMTP id 4942DC0012 for ; Fri, 1 Apr 2022 08:16:56 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by smtp1.osuosl.org (Postfix) with ESMTP id 2A8A984454 for ; Fri, 1 Apr 2022 08:16:56 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Authentication-Results: smtp1.osuosl.org (amavisd-new); dkim=pass (2048-bit key) header.d=gmail.com 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 5DHEGS-lXXAR for ; Fri, 1 Apr 2022 08:16:55 +0000 (UTC) X-Greylist: whitelisted by SQLgrey-1.8.0 Received: from mail-lj1-x22d.google.com (mail-lj1-x22d.google.com [IPv6:2a00:1450:4864:20::22d]) by smtp1.osuosl.org (Postfix) with ESMTPS id 68D9584445 for ; Fri, 1 Apr 2022 08:16:55 +0000 (UTC) Received: by mail-lj1-x22d.google.com with SMTP id q14so2850763ljc.12 for ; Fri, 01 Apr 2022 01:16:55 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=naHjjfAEIFfUoqD2252HauLui4n+kN8PWDYC9eStV58=; b=FevaeFt5Zs0fOPr+Oe7iJqOZ6pRNRHHNdXRNc/ieE2dN2nt2AIAZ/oq9l6Uvv4d44F BocRIeJ6abZ9sPljMG2nwAxCnlo8OgifPBCX0yvoseM2lyHu6eiICfxUCKrEGlnD4kjY gP/brmw32t1QrsM/wV+zhsck+ljltdWQ9ZBPi5sk/z/2iZz3IKu59zq50txE/bTCxcvt /NMXtlW+mWLITCASUvrk5tiDpJFmwjhrbKm6ArjagNK2MTy1jPz7Euv9gXdjODaE2ESi rmxfR9l9elhC/Py6VF6+11uV9BUY5demQbEouZhyLfb0+IZvDdKQE23x65RnRNTW2AaN APwA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=naHjjfAEIFfUoqD2252HauLui4n+kN8PWDYC9eStV58=; b=t5xgBMgJiK/LtzzZHUarhtjYeOB39YuTIBFtjAho2iwg6z1W2bRGrAyNVfG86ALR1h I8QqcETsgwPeSNcXOnKHqfKpTUSSM1kNasMrSiVd4dUQs9pxjcdEgvOvdrniMv8A/Lh3 LpUDMHBkGtejsvuV6FoCo7Q5ol6+EtqcdfCrEFY8xpgs0+rXGEn+Wv/P7iUQQM0KLeIV cTahwKj9JBXip/z/S1DrtPzntGmZVfLM3hyzUDWUSnTUugRnoRVs7sYdpzN9wHuEEwYi 101cgQY+fZdSmfMAB8vR3qURmyFyYOj81sEkFtt0tMw8XzJsKbBNWRnbiJfil24gp3wC GcCA== X-Gm-Message-State: AOAM531+IqEYcPnsC21o1LPgc9+E96d3DXxTtyMEpqtA/oINnWfOq6m7 PPybtJxyRQ32F0Tc11i6U/e51XP95Bo= X-Google-Smtp-Source: ABdhPJwWQKirjJpmYVlJgzR/x6QEhrDJB9DCS3NIt/r2T8qIvK0DZt7148XjbU61rG6ycUqFNE6c2Q== X-Received: by 2002:a2e:2d0a:0:b0:248:7c35:28b4 with SMTP id t10-20020a2e2d0a000000b002487c3528b4mr12293227ljt.175.1648801013051; Fri, 01 Apr 2022 01:16:53 -0700 (PDT) Received: from ip-10-70-112-12.vpc-1e810be1.internal (c2-217-73-63-80.elastic.cloud.croc.ru. [217.73.63.80]) by smtp.gmail.com with ESMTPSA id x28-20020a19e01c000000b0044a3aca1c39sm166568lfg.255.2022.04.01.01.16.52 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 01 Apr 2022 01:16:52 -0700 (PDT) From: Vladislav Odintsov To: dev@openvswitch.org Date: Fri, 1 Apr 2022 11:16:50 +0300 Message-Id: <20220401081650.1579214-1-odivlad@gmail.com> X-Mailer: git-send-email 2.26.3 MIME-Version: 1.0 Cc: Vladislav Odintsov Subject: [ovs-dev] [PATCH ovn 1/2] vtep: correctly bring vtep lport up in SBDB 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" Signed-off-by: Vladislav Odintsov Acked-by: Mark Michelson --- controller-vtep/binding.c | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/controller-vtep/binding.c b/controller-vtep/binding.c index 01d5a16d2..7c7bea90a 100644 --- a/controller-vtep/binding.c +++ b/controller-vtep/binding.c @@ -109,12 +109,11 @@ update_pb_chassis(const struct sbrec_port_binding *port_binding_rec, port_binding_rec->chassis->name, chassis_rec->name); } - sbrec_port_binding_set_chassis(port_binding_rec, chassis_rec); - if (port_binding_rec->n_up) { - bool up = true; - sbrec_port_binding_set_up(port_binding_rec, &up, 1); - } + } + else if (port_binding_rec->n_up) { + bool up = true; + sbrec_port_binding_set_up(port_binding_rec, &up, 1); } }