From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id F183C45648; Thu, 18 Jul 2024 23:40:42 +0200 (CEST) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 7C55240662; Thu, 18 Jul 2024 23:40:42 +0200 (CEST) Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) by mails.dpdk.org (Postfix) with ESMTP id B91D240616 for ; Thu, 18 Jul 2024 23:40:40 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1721338840; 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=LAYINHI0tOXPG1sMM3ZA1FHawGyypPwUysQnkiWWJa0=; b=M91mRGCWaAJw9sXk5DuiwQOLmyy/TbVt1cWciWNIsxRIIPaNsvavMyIfRMZKf8vijyBQVB bCExHz6Tuz0WHcF7qt4487OKIeL8/6rLLnpyT/ef4NOOC5RGBFtJ0FVQf9f6zKoj+9L3GP Iz0DWgKoEyeUsnESwchC9L4lRI9c8Yk= Received: from mail-wm1-f69.google.com (mail-wm1-f69.google.com [209.85.128.69]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-628-i94grxH0OrGzF1ebYpmkRQ-1; Thu, 18 Jul 2024 17:40:39 -0400 X-MC-Unique: i94grxH0OrGzF1ebYpmkRQ-1 Received: by mail-wm1-f69.google.com with SMTP id 5b1f17b1804b1-42725ec6e0aso5175925e9.0 for ; Thu, 18 Jul 2024 14:40:38 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1721338838; x=1721943638; h=in-reply-to:references:user-agent:to:from:cc:subject:message-id :date:content-transfer-encoding:mime-version:x-gm-message-state:from :to:cc:subject:date:message-id:reply-to; bh=LAYINHI0tOXPG1sMM3ZA1FHawGyypPwUysQnkiWWJa0=; b=fHrGpNdnxp/gbGaJVsdU7En5zVZhdnjurx1qSoXP/x2JPiI4+Bgxkre+uYgggVrczw c9qbBLl0jg5PvtKa4jfp8nTe3Pti6HNthfXn6QfCR0J6WBQqHK3J4WAgPxopU760Tvxl NvMRbbC4QLu7J3RgDuoru/LOceqK1KGn7WhLHd8cyYC5GHxMmIeEFDp+3V6HmHBnPaRY h98x2W8Wi+WHcv8Rtpm1EOhTy91KplIZ56F6G8Gob8DJd/BRsMfMikN8j+xE83yob1Kn 7MguGYTe4OdAiuqfvBrMp/b/UQJSAKl8hjzC29hJ/+wJgo+LOazU0lTQSbDeHMy6sUaH k8cw== X-Gm-Message-State: AOJu0Yz6bkvWN5ALwNyVIaD7O8igOMV2a5/aU/fp1hfXqqGFMgIKIx/a UdEgJX7/Rxp4L7Pgpg9l+kgwWl+90zjN2oeRablidF5cRbZGZ/se3KlZjNU7z0RjTo6V2IMVRMG L1C9XYwBa2a/yflNPjGWFvEiS5p2+PsGP/aAwjwNZ X-Received: by 2002:a05:600c:444d:b0:426:5546:71a with SMTP id 5b1f17b1804b1-427c2caa7d6mr45120345e9.2.1721338837893; Thu, 18 Jul 2024 14:40:37 -0700 (PDT) X-Google-Smtp-Source: AGHT+IEdZgv1Bh3QwYeHV5tY+bpxOoSH/g405ZQn45UyCNFQ3NJ3alhBrMG/FFXjXL0uAu43rDM49A== X-Received: by 2002:a05:600c:444d:b0:426:5546:71a with SMTP id 5b1f17b1804b1-427c2caa7d6mr45120155e9.2.1721338837498; Thu, 18 Jul 2024 14:40:37 -0700 (PDT) Received: from localhost (2a01cb0003516600d9d313ed6b23ad48.ipv6.abo.wanadoo.fr. [2a01:cb00:351:6600:d9d3:13ed:6b23:ad48]) by smtp.gmail.com with ESMTPSA id 5b1f17b1804b1-427d2a8e436sm28539045e9.33.2024.07.18.14.40.36 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Thu, 18 Jul 2024 14:40:37 -0700 (PDT) Mime-Version: 1.0 Date: Thu, 18 Jul 2024 23:40:36 +0200 Message-Id: Subject: Re: IPv6 APIs rework Cc: , "Sunil Kumar Kori" , "Rakesh Kudurumalla" , "Vladimir Medvedkin" , "Wisam Jaddo" , "Cristian Dumitrescu" , "Konstantin Ananyev" , "Akhil Goyal" , "Fan Zhang" , "Bruce Richardson" , "Yipeng Wang" , "Sameh Gobriel" , "Nithin Dabilpuram" , "Kiran Kumar K" , "Satha Rao" , "Harman Kalra" , "Ankur Dwivedi" , "Anoob Joseph" , "Tejasree Kondoj" , "Gagandeep Singh" , "Hemant Agrawal" , "Ajit Khaparde" , "Somnath Kotur" , "Chas Williams" , "Min Hu (Connor)" , "Potnuri Bharat Teja" , "Sachin Saxena" , "Ziyang Xuan" , "Xiaoyun Wang" , "Jie Hai" , "Yisen Zhuang" , "Jingjing Wu" , "Dariusz Sosnowski" , "Viacheslav Ovsiienko" , "Bing Zhao" , "Ori Kam" , "Suanming Mou" , "Matan Azrad" , "Chaoyong He" , "Devendra Singh Rawat" , "Alok Prasad" , "Andrew Rybchenko" , "Jiawen Wu" , "Jian Wang" , "Thomas Monjalon" , "Ferruh Yigit" , "Jiayu Hu" , "Pavan Nikhilesh" , "Maxime Coquelin" , "Chenbo Xia" From: "Robin Jarry" To: "Stephen Hemminger" , =?utf-8?q?Morten_Br=C3=B8rup?= User-Agent: aerc/0.18.0-5-gd32d93015ed7 References: <98CBD80474FA8B44BF855DF32C47DC35E9F5AB@smartserver.smartshare.dk> <20240718141501.24a7c79c@hermes.local> In-Reply-To: <20240718141501.24a7c79c@hermes.local> X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=UTF-8; format=Flowed X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Stephen Hemminger, Jul 18, 2024 at 23:15: > If you look at the standard netinet/in.h the storage of IPv6 addresses > is in in6_addr. DPDK has always wanted to do its own thing... > > The in6_addr is a union with no explicit alignment. > > struct in6_addr > { > union > { > uint8_t __u6_addr8[16]; > uint16_t __u6_addr16[8]; > uint32_t __u6_addr32[4]; > } __in6_u; > > Better to not have explicit alignment and not have 64 bit value. The main reason why I didn't use the standard POSIX type is that it has=20 an alignment of 4 which means it cannot always be mapped directly to=20 packets in memory depending on the encapsulating protocol. Also, ip->__in6_u.__u6_addr8 is really ugly as a field name, even if=20 the "helper" macros (ip->s6_addr8) make them a bit better :) What do you have against adding a 64 bit value in the union?