From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dpdk.org (dpdk.org [92.243.14.124]) by inbox.dpdk.org (Postfix) with ESMTP id 337F9A04A2; Wed, 3 Jun 2020 22:11:52 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 2A21D1D59E; Wed, 3 Jun 2020 22:11:51 +0200 (CEST) Received: from mail-pf1-f193.google.com (mail-pf1-f193.google.com [209.85.210.193]) by dpdk.org (Postfix) with ESMTP id 934001D56E for ; Wed, 3 Jun 2020 22:11:49 +0200 (CEST) Received: by mail-pf1-f193.google.com with SMTP id h185so2297878pfg.2 for ; Wed, 03 Jun 2020 13:11:49 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=networkplumber-org.20150623.gappssmtp.com; s=20150623; h=date:from:to:cc:subject:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=tAdW9qka7ZV30ZyYcfbf7NG75wF2BsfkfqwiJ/aoAwI=; b=S1DRdttbLPfbvvLVtlyHT/8qsMMM/343YQMHl8eNPvH5zqJcfUVLgq0oSwz1ZNOW7U WF+eeDeOphqIZ1IPmPqGEoOdswOFdwLamsLcZo0mK4DFTICtQRCxKQ+VfDsqMJD+BtQH WHciOZ/MOhkiRFL9oZyPMnxFauhrEVMFlkqjRmgky6kDh6Yq+BbFMDZLfm7VOylxI2jm sCDA+7wz5+VZ+BiRKQxG98NaMFD7Zth60X+zFWh4HF1v3cjr6NiQTiyLecJtegIvfUoR LCTbM+TSK0J6WjdCB5MhPAsgyf5iVeiyfgEKpjceCUFiVpH4IjHybAzRClZe0t7GvbWy 8K2A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=tAdW9qka7ZV30ZyYcfbf7NG75wF2BsfkfqwiJ/aoAwI=; b=PwMR9/XTV5fLUx+9AwGBCW6b/fx3cWdaKBGgKGldmLLu+3JurV86vSdolv/OLCCkJ3 Zk6jPgvl+oF2l+vd9q4856I06cPmNIhQSxuj9wL2VCONBvV/LsPqrQjp+32cwvGdAqcc StSO1iuwmfWS2I2f7ORkbH5eg5s5QuxF2BG+2OkjEKRp8HNmxug8C0rFC/vz7lEv1O2e dhFWioGjpBugAEpgoWGE3jatOYrh4vf2/oe9biXubVLv4iHqJ4VX6CDsBhXVEekhe9/o 8Uza8CgayxGFHbqOFgO2/Ufi1Fm29pSvQNDcjO2KLEyUTQCFeP5GbP9XXe5AgCtBshTU elDA== X-Gm-Message-State: AOAM533PzjQJVlixEy/aGwYtNcLTqvzUHYDyXbbht+nkcz7CDBJ0Jonu 84y1qTFSdEzzmG4t9ZNy62mZFQ== X-Google-Smtp-Source: ABdhPJxe2nJI2w/HafN4FYj4fV4bQAG/o+Fx0b5ZQgyT0xUBGJwtpGiiwI/8/Lp2a18CrAKqlqR4Zg== X-Received: by 2002:a63:5024:: with SMTP id e36mr987491pgb.438.1591215108612; Wed, 03 Jun 2020 13:11:48 -0700 (PDT) Received: from hermes.lan (204-195-22-127.wavecable.com. [204.195.22.127]) by smtp.gmail.com with ESMTPSA id gg10sm3824887pjb.38.2020.06.03.13.11.47 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 03 Jun 2020 13:11:48 -0700 (PDT) Date: Wed, 3 Jun 2020 13:11:39 -0700 From: Stephen Hemminger To: Ferruh Yigit Cc: Vivien Didelot , dev@dpdk.org, patrick.keroulas@radio-canada.ca, thomas@monjalon.net Message-ID: <20200603131139.6f79ecc7@hermes.lan> In-Reply-To: <1d7b6c2e-84a9-5e20-1353-4f64de667b03@intel.com> References: <20200523172130.2285380-1-vivien.didelot@gmail.com> <1d7b6c2e-84a9-5e20-1353-4f64de667b03@intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Subject: Re: [dpdk-dev] [PATCH 1/2] net/pcap: support software Tx nanosecond timestamp X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" On Wed, 3 Jun 2020 18:50:51 +0100 Ferruh Yigit wrote: > On 5/23/2020 6:21 PM, Vivien Didelot wrote: > > When capturing packets into a PCAP file, DPDK currently uses > > microseconds for the timestamp. But libpcap supports interpreting > > tv_usec as nanoseconds depending on the file timestamp precision. > > > > To support this, use PCAP_TSTAMP_PRECISION_NANO when creating the > > empty PCAP file as specified by PCAP_OPEN_DEAD(3PCAP) and implement > > nanosecond timeval addition. This also ensures that the precision > > reported by capinfos is nanoseconds (9). > > Overall good idea and patch looks good. > > Only concern is change in the libpcap dependency. Do you know which libpcap > version supports 'PCAP_TSTAMP_PRECISION_NANO'? > If a user of pcap PMD updates to latest DPDK and the environment doesn't have > new version of the libpcap, this change will require an environment update and > this may or may not be easy to do. That is why not sure if the updates require > dependency change should wait for the LTS or not. > > Another things is the backward compatibility, as far as I understand the pcap > file recorded with nanosecond precision can be read and parsed without problem > by old application that doesn't know the nanosecond precision, but can you > please confirm this? We should do pcapng instead of doing the pcap with nano timestamp. My impression is that libpcap is a dormant project at this point, and the finer grain timestamp is a hack that is only in some verisions. That was one of the reasons pcapng started.