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 66F9DA054F; Tue, 16 Mar 2021 19:59:44 +0100 (CET) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 28FAE40A4B; Tue, 16 Mar 2021 19:59:44 +0100 (CET) Received: from mail-pg1-f175.google.com (mail-pg1-f175.google.com [209.85.215.175]) by mails.dpdk.org (Postfix) with ESMTP id 12ACE406A2 for ; Tue, 16 Mar 2021 19:59:42 +0100 (CET) Received: by mail-pg1-f175.google.com with SMTP id p21so23225019pgl.12 for ; Tue, 16 Mar 2021 11:59:42 -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=y098Dv3w6hG/V0/YLGH057Nr820BBMpLFoDmF7xLSvY=; b=rJZ23zhJTyTRdFw6adoQpdWK3NtcW+CgvYWYhtQY0ARRsy3W91dWrZ/mEI6TbfVL+h h+/lxgFGd4O7pRiKsNM6vWKO0550VdLqFcB1aI3NVg6M0PtOFmKusXKNoK1lDlbKQlOp QLcighRP0ODaYm0KaqJO0Ko9Cg+aI5vjuiRitEcLSgtAq7snPwagzTIcTxrlLOuaxSwB fdA56VnRnOrsBt+O5Yhreg6L8Tu702zf6ETfnYAFLDTdnT88WwZIuIFDc8gdTahOpNMu q0DiJ8cb3JfcleRNUcenFINR0HNgEgss2DKUgWSMluKyHy4+OJ6cfDroYeEoy02QzB17 Ijlw== 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=y098Dv3w6hG/V0/YLGH057Nr820BBMpLFoDmF7xLSvY=; b=TI38ZXc30HF4XJN3h+x35u9jYlu5p0SfdQ/a0W/N/s54NwsLIOxrrqy9su2pF6u4IC gtxVvqcZzGkX8F8ALth4dthj4XLkK5UI7qIu+BRzXNxynhJNkv5SyQtcv3ynG7zPf/Ah T8UBlRK6diprTEatRDLljAZOcT/tZcml9J/+DT4mGRsXTpms5C6P3SZOeGT9pnuS0ekm ZdKZf+KNm91E38eop30DO2HMDYIkBPifv4ZTcn7ACacT7Odc9twHKRbhIdXJEeqY4tGB y1qDsj2ZjZl3LsJMWHYBcdyl7xah7T9EYLto8f/jjCmz0MptU32CZSahdhnFR/u9QXo3 nhew== X-Gm-Message-State: AOAM533FaMI1umhZhfGVRk/KaavGHpptwje948I9vc3Go/eI+JN7W6pd oUmIW1QY/kswxuWgupEMo6s5ag== X-Google-Smtp-Source: ABdhPJxRVsMiKM9xZIFiMq8d/e1MGdoy0Ig1rrLg/te1AjdqvqMBi6h+QDjxMCG9tRcsChQgKAm0bw== X-Received: by 2002:aa7:969d:0:b029:1f5:b02c:eed3 with SMTP id f29-20020aa7969d0000b02901f5b02ceed3mr716258pfk.75.1615921182211; Tue, 16 Mar 2021 11:59:42 -0700 (PDT) Received: from hermes.local (76-14-218-44.or.wavecable.com. [76.14.218.44]) by smtp.gmail.com with ESMTPSA id j20sm588121pji.3.2021.03.16.11.59.41 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 16 Mar 2021 11:59:41 -0700 (PDT) Date: Tue, 16 Mar 2021 11:59:33 -0700 From: Stephen Hemminger To: Dmitry Kozlyuk Cc: dev@dpdk.org, Tyler Retzlaff , Mike Wells , Narcisa Ana Maria Vasile , Dmitry Malloy , Pallavi Kadam , Ray Kinsella , Neil Horman Message-ID: <20210316115933.06d1f9de@hermes.local> In-Reply-To: <20210214021616.26970-2-dmitry.kozliuk@gmail.com> References: <20210214012013.23165-1-dmitry.kozliuk@gmail.com> <20210214021616.26970-1-dmitry.kozliuk@gmail.com> <20210214021616.26970-2-dmitry.kozliuk@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Subject: Re: [dpdk-dev] [PATCH v2 1/6] eal: add internal API for current time 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 Sender: "dev" On Sun, 14 Feb 2021 05:16:11 +0300 Dmitry Kozlyuk wrote: > +rte_time_get_us(struct rte_time_us *now) > +{ > + struct timeval sys; > + > + gettimeofday(&sys, NULL); > + now->sec = sys.tv_sec; > + now->usec = sys.tv_usec; > +} Why would drivers want the default (wall clock) time instead of using monotonic clock. The wall clock gets changed by NTP and that is rarely what you want except for the case of log messages.