From patchwork Wed May 3 20:13:32 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ihar Hrachyshka X-Patchwork-Id: 1776643 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=140.211.166.137; helo=smtp4.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=De6xXcZn; dkim-atps=neutral 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 ECDSA (P-384) server-digest SHA384) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4QBSnx1JYvz20fg for ; Thu, 4 May 2023 06:13:57 +1000 (AEST) Received: from localhost (localhost [127.0.0.1]) by smtp4.osuosl.org (Postfix) with ESMTP id 3363A41DF8; Wed, 3 May 2023 20:13:54 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp4.osuosl.org 3363A41DF8 Authentication-Results: smtp4.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=De6xXcZn 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 ZwuPFEwyyX5c; Wed, 3 May 2023 20:13:52 +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 94D8A40884; Wed, 3 May 2023 20:13:51 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp4.osuosl.org 94D8A40884 Received: from lf-lists.osuosl.org (localhost [127.0.0.1]) by lists.linuxfoundation.org (Postfix) with ESMTP id 66EEFC008C; Wed, 3 May 2023 20:13:49 +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 3280EC0037 for ; Wed, 3 May 2023 20:13:47 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by smtp1.osuosl.org (Postfix) with ESMTP id 07E9F81493 for ; Wed, 3 May 2023 20:13:47 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp1.osuosl.org 07E9F81493 Authentication-Results: smtp1.osuosl.org; dkim=pass (1024-bit key) header.d=redhat.com header.i=@redhat.com header.a=rsa-sha256 header.s=mimecast20190719 header.b=De6xXcZn 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 LlZ_FPrYNDN7 for ; Wed, 3 May 2023 20:13:45 +0000 (UTC) X-Greylist: domain auto-whitelisted by SQLgrey-1.8.0 DKIM-Filter: OpenDKIM Filter v2.11.0 smtp1.osuosl.org A4AEC81404 Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.129.124]) by smtp1.osuosl.org (Postfix) with ESMTPS id A4AEC81404 for ; Wed, 3 May 2023 20:13:45 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1683144824; 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=De6xXcZnnXS09NEMaRP7UyJz5VcniVJ1nL9lDq7hZcXGZy88BvVfsUeUVK40G1I7vsbFch x0E/kOoQZCcnB0wjrEoEV0QlAK4dKy5yy63lL5egIOVeLgoc+stqrZTZmGHBiyHWFvUnkM z4iiYI/QaTdUWvSsi5GS7JDmGcgrsss= Received: from mail-qv1-f69.google.com (mail-qv1-f69.google.com [209.85.219.69]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-477-7oGAzpWNOd6L4N4VzbW8cg-1; Wed, 03 May 2023 16:13:43 -0400 X-MC-Unique: 7oGAzpWNOd6L4N4VzbW8cg-1 Received: by mail-qv1-f69.google.com with SMTP id 6a1803df08f44-61b5bcb4c09so23695206d6.2 for ; Wed, 03 May 2023 13:13:43 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1683144823; x=1685736823; 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=PmAEsy1cCdXGrh5X0WVgWepfejT5sU1W9y66lKJeI0wUb+NpnHCU7/DPP/5pEGXci1 UEvxzZev4XTL9aMgFaSeKScUOXxQJIYrEy+dueYhz0qY6LFKOEHAfGZpjCyhD2Vr1DBj zpae/ydDZWaM9iG0ZoJ25AvKLVObe2hDOFTufYUg5TQErQXXsrI26jb+bxOBgjkf2izO 8rxEr+aM52WYmQPrsz/JxQxDB5Bfh4Ts8DQv4f2sUKBFtp6JVTdUjp0bq+lmlC+Q8+gd ML2skfTdTPYUybp/8USwrd5lwiCqxMzcxwrUo401aejkgXOtegB8LLGNVnYtQEpIxrv8 GZ1w== X-Gm-Message-State: AC+VfDyrQDrWJkaVPAK6sBGzJjfXWb38I0EYJm0ZiNb8xRFmq9dGKx6e z+ISZI+Z3py8qfLbwMtOjU06TO92FcoyIJ6cjYZI4v+3LN/tRLdS2VrVXPOOyMSNSLOmJVbES4B qFObiu4H4bkXliTSBuylc/kFv05CnM36g+oYPIZs4wUHynZ3NAwIfA8ZvSR4QGZ81TP8KNNP3 X-Received: by 2002:ad4:5f4a:0:b0:61a:197b:605 with SMTP id p10-20020ad45f4a000000b0061a197b0605mr12119255qvg.1.1683144822813; Wed, 03 May 2023 13:13:42 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ7NWK1RjzI/j1gDqZJIBTXQ3JNfj4TeC4TbWRN0fypBrm09jdbsRVM0b4THh/QHEneVArP6pg== X-Received: by 2002:ad4:5f4a:0:b0:61a:197b:605 with SMTP id p10-20020ad45f4a000000b0061a197b0605mr12119226qvg.1.1683144822447; Wed, 03 May 2023 13:13:42 -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 z13-20020a0cda8d000000b005ef442226bbsm2476138qvj.8.2023.05.03.13.13.41 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 03 May 2023 13:13:41 -0700 (PDT) From: Ihar Hrachyshka To: dev@openvswitch.org Date: Wed, 3 May 2023 20:13:32 +0000 Message-Id: <20230503201337.46104-2-ihrachys@redhat.com> X-Mailer: git-send-email 2.38.1 In-Reply-To: <20230503201337.46104-1-ihrachys@redhat.com> References: <20230503201337.46104-1-ihrachys@redhat.com> MIME-Version: 1.0 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Subject: [ovs-dev] [PATCH ovn v2 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 Acked-by: Dumitru Ceara --- 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,