From patchwork Wed May 3 01:12:34 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ihar Hrachyshka X-Patchwork-Id: 1776084 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::133; helo=smtp2.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=X0SPi0nB; dkim-atps=neutral Received: from smtp2.osuosl.org (smtp2.osuosl.org [IPv6:2605:bc80:3010::133]) (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 4Q9zTQ4Gthz20fp for ; Wed, 3 May 2023 11:12:58 +1000 (AEST) Received: from localhost (localhost [127.0.0.1]) by smtp2.osuosl.org (Postfix) with ESMTP id 643424051F; Wed, 3 May 2023 01:12:56 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp2.osuosl.org 643424051F Authentication-Results: smtp2.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=X0SPi0nB X-Virus-Scanned: amavisd-new at osuosl.org 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 Iod6VNvDPNFi; Wed, 3 May 2023 01:12:55 +0000 (UTC) Received: from lists.linuxfoundation.org (lf-lists.osuosl.org [IPv6:2605:bc80:3010:104::8cd3:938]) by smtp2.osuosl.org (Postfix) with ESMTPS id 80043401F3; Wed, 3 May 2023 01:12:54 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp2.osuosl.org 80043401F3 Received: from lf-lists.osuosl.org (localhost [127.0.0.1]) by lists.linuxfoundation.org (Postfix) with ESMTP id 5A246C0037; Wed, 3 May 2023 01:12:54 +0000 (UTC) X-Original-To: dev@openvswitch.org Delivered-To: ovs-dev@lists.linuxfoundation.org Received: from smtp2.osuosl.org (smtp2.osuosl.org [140.211.166.133]) by lists.linuxfoundation.org (Postfix) with ESMTP id 331BDC002A for ; Wed, 3 May 2023 01:12:53 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by smtp2.osuosl.org (Postfix) with ESMTP id 01605403E5 for ; Wed, 3 May 2023 01:12:53 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp2.osuosl.org 01605403E5 X-Virus-Scanned: amavisd-new at osuosl.org 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 SvTLK9ZTNvKt for ; Wed, 3 May 2023 01:12:47 +0000 (UTC) X-Greylist: domain auto-whitelisted by SQLgrey-1.8.0 DKIM-Filter: OpenDKIM Filter v2.11.0 smtp2.osuosl.org 7832440120 Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) by smtp2.osuosl.org (Postfix) with ESMTPS id 7832440120 for ; Wed, 3 May 2023 01:12:47 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1683076366; 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: in-reply-to:in-reply-to:references:references; bh=WLiOMdwOewzw1CB8OlG1pk2Ewtva/5pI9bU4kZPZUYc=; b=X0SPi0nBC9ADdSBcnD3UXigVgiW+jRLi8omdcr5V673yetPuq/bDstFbqP0dmX9pX6OC2i gaULODbMc4Fv5mURXJ5iW72cBulEfVFQFnsEx/Wb6Q3DPZRFoOzJZ70WYgxszNgJE15g/f JhNjiVb0OhC/8kRHAvc6ykfj8sVn9qg= Received: from mail-qk1-f199.google.com (mail-qk1-f199.google.com [209.85.222.199]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-636-Q4HjFuwyOHSFXb-rTIOUaw-1; Tue, 02 May 2023 21:12:45 -0400 X-MC-Unique: Q4HjFuwyOHSFXb-rTIOUaw-1 Received: by mail-qk1-f199.google.com with SMTP id af79cd13be357-75131c05344so74781585a.1 for ; Tue, 02 May 2023 18:12:45 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1683076364; x=1685668364; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=WLiOMdwOewzw1CB8OlG1pk2Ewtva/5pI9bU4kZPZUYc=; b=IhFFH53ri18YRjE/LVJxhD7VcPxQCe3VWnG1uNqPthVm/PTeGcJ4y2ordNxvXfHWZE p5BXFPMK+MMd1x81U/UThCtTvOueoZZAojrYK7tFS2g0uIuQy/VZoTetom1kMyn2wMJj GpRLyNzzDF2xDZlytgLuIK0XCsxBpysQIy/vudBXa1HQw+AqyYHOG/fKU92a0zcQ0Q3u pr/ZRGYsawevIoxbYMPDagaMuQ2tfEuJd6+XsatZXqNr6tEQt0frcOFzAmxBmUkjhQzT 1x0ysMNGQvNjJmkq38P66C2KsFdn+K6OSM7EvQqi60kdOmQEPdJCYMgpFUm+HtEF70QM RFYw== X-Gm-Message-State: AC+VfDyftXdIvTkDYbSLu4enf4olUYrAVT3NqnNXyJskoKNdSQ1Jz826 LGvrkfv7/JgQfKi2HTrZXjm9dTg5SyzHot8LdT6V98kJAx9/ZhCz3nVKEOGkB0XwxoBNcr5ATJO +6qDdnJ6VuutpGsAJqOjsBcOviTcUpZgp8l2oQ6hQeLNqhYALPkQxqUgVZfCSM5SDixscpWkk X-Received: by 2002:a05:6214:d64:b0:61a:96d3:bd20 with SMTP id 4-20020a0562140d6400b0061a96d3bd20mr914127qvs.10.1683076364642; Tue, 02 May 2023 18:12:44 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ7iPm3vddODhn1z85RONDeIyiLqhd8mz252jcjNEeOE7fCQxpdSqyGFO/oVf/JKS6eOPgyTBg== X-Received: by 2002:a05:6214:d64:b0:61a:96d3:bd20 with SMTP id 4-20020a0562140d6400b0061a96d3bd20mr914102qvs.10.1683076364360; Tue, 02 May 2023 18:12:44 -0700 (PDT) Received: from fedora34.localdomain.com (cpe-172-73-180-250.carolina.res.rr.com. [172.73.180.250]) by smtp.gmail.com with ESMTPSA id u16-20020a0cf1d0000000b005ef42464646sm9959041qvl.118.2023.05.02.18.12.43 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 02 May 2023 18:12:43 -0700 (PDT) From: Ihar Hrachyshka To: dev@openvswitch.org Date: Wed, 3 May 2023 01:12:34 +0000 Message-Id: <20230503011239.2100488-2-ihrachys@redhat.com> X-Mailer: git-send-email 2.38.1 In-Reply-To: <20230503011239.2100488-1-ihrachys@redhat.com> References: <20230503011239.2100488-1-ihrachys@redhat.com> MIME-Version: 1.0 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Subject: [ovs-dev] [PATCH ovn 1/6] Track ip version of tunnel in chassis_tunnel struct 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" This will be used in a later patch to calculate tunneling overhead for effective path MTU. Signed-off-by: Ihar Hrachyshka --- controller/local_data.c | 2 ++ controller/local_data.h | 1 + 2 files changed, 3 insertions(+) diff --git a/controller/local_data.c b/controller/local_data.c index acaf1de6d..cf0b21bb1 100644 --- a/controller/local_data.c +++ b/controller/local_data.c @@ -22,6 +22,7 @@ #include "lib/util.h" #include "lib/vswitch-idl.h" #include "openvswitch/vlog.h" +#include "socket-util.h" /* OVN includes. */ #include "encaps.h" @@ -447,6 +448,7 @@ local_nonvif_data_run(const struct ovsrec_bridge *br_int, tun->chassis_id = xstrdup(tunnel_id); tun->ofport = u16_to_ofp(ofport); tun->type = tunnel_type; + tun->is_ipv6 = ip ? addr_is_ipv6(ip) : false; free(hash_id); free(ip); diff --git a/controller/local_data.h b/controller/local_data.h index 748f009aa..ad0fa7f94 100644 --- a/controller/local_data.h +++ b/controller/local_data.h @@ -133,6 +133,7 @@ struct chassis_tunnel { char *chassis_id; ofp_port_t ofport; enum chassis_tunnel_type type; + bool is_ipv6; }; void local_nonvif_data_run(const struct ovsrec_bridge *br_int,