Received: by 2002:a05:6a10:2785:0:0:0:0 with SMTP id ia5csp1619402pxb; Sun, 10 Jan 2021 04:52:12 -0800 (PST) X-Google-Smtp-Source: ABdhPJwkszXlnOw4wUQ2juDiA1xRCFrcWUr66ocvePSxW+4UgCofoU6/qutsB7UHuapB9iUlmpko X-Received: by 2002:a17:906:edb2:: with SMTP id sa18mr7582877ejb.264.1610283132606; Sun, 10 Jan 2021 04:52:12 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1610283132; cv=none; d=google.com; s=arc-20160816; b=M8sCk7pJ2uxaKh43wrfFSfMnG8oaAIs6n8To/wFeIlDvTwX7oooMsjxOSeK6Hcwcz+ VmuPtrCk68S8t4bGnjIm61B7HaUvnCyuPaKOmesYVAIMZJMmSjYu+yVAKyeqPbw8aP2e adtBHF9hBggKCfIGur8W/gJRchxUz9A1jtY8zZA6pIi2XmcG7ZgD53fGNr+nwUh5RHUF mTk6iAObkJ4Im6hgmCRVEBQLsLCtCpDzzvlFPmzyCEUDgpEdeA9tvcMNi8sS8LwGvvl7 1wOJ1c0uSWtf+r7OgLfcdsG6TEFOwsWSoelxAbpfo+bzfVdirMq4cwyyc/4QbxA8SAyD vSBA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from; bh=Sz2p/c0BOunz+arWQmKH3tzHc4DqS45sVwmVW9Tlnxo=; b=o4v0FxI9ymSJNTqryc2b3rQd+Mt+ayurlv3nmywj2I9yzmyJ5BU6m5r9HXeAei7vaB W+xeucX/8rSs7E8tjJ17RJ3s4uKyjPcq8g1bTMjzOXmj9uGYpSH+CyFh5WebTxq1KUHB 4vyOFVAWaYhxs3nQPQQxY5/PZWZisjNZhyzw9PkijnGljyAO53ack2V2IkczDM4CwmlK kwp6IjFeeqnBuOpqEA4l8qv1UU5HX8eqx4m+jCI3IyTaQPSAhsTQkXJMQXZPtj23mqbQ Vw+JQCzmV7DfHQ8KyjoilBF83q1bJL8DgirvdZKz/6lr27pLOYx4LQ2DgIDMCILP8mTl eubA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id x91si5872093ede.370.2021.01.10.04.51.48; Sun, 10 Jan 2021 04:52:12 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726394AbhAJMvF (ORCPT + 99 others); Sun, 10 Jan 2021 07:51:05 -0500 Received: from smtp07.smtpout.orange.fr ([80.12.242.129]:47329 "EHLO smtp.smtpout.orange.fr" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726267AbhAJMvF (ORCPT ); Sun, 10 Jan 2021 07:51:05 -0500 Received: from localhost.localdomain ([153.202.107.157]) by mwinf5d13 with ME id F0p42400E3PnFJp030pJLG; Sun, 10 Jan 2021 13:49:21 +0100 X-ME-Helo: localhost.localdomain X-ME-Auth: bWFpbGhvbC52aW5jZW50QHdhbmFkb28uZnI= X-ME-Date: Sun, 10 Jan 2021 13:49:21 +0100 X-ME-IP: 153.202.107.157 From: Vincent Mailhol To: Marc Kleine-Budde , linux-can@vger.kernel.org, Jeroen Hofstee Cc: Vincent Mailhol , Wolfgang Grandegger , "David S. Miller" , Jakub Kicinski , netdev@vger.kernel.org (open list:NETWORKING DRIVERS), linux-kernel@vger.kernel.org (open list) Subject: [PATCH v3 0/1] Add software TX timestamps to the CAN devices Date: Sun, 10 Jan 2021 21:49:02 +0900 Message-Id: <20210110124903.109773-1-mailhol.vincent@wanadoo.fr> X-Mailer: git-send-email 2.26.2 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org With the ongoing work to add BQL to Socket CAN, I figured out that it would be nice to have an easy way to mesure the latency. And one easy way to do so it to check the round trip time of the packet by doing the difference between the software rx timestamp and the software tx timestamp. rx timestamps are already available. This patch gives the missing piece: add a tx software timestamp feature to the CAN devices. Of course, the tx software timestamp might also be used for other purposes such as performance measurements of the different queuing disciplines (e.g. by checking the difference between the kernel tx software timestamp and the userland tx software timestamp). v2 was a mistake, please ignore it (fogot to do git add, changes were not reflected...) v3 reflects the comments that Jeroen made in https://lkml.org/lkml/2021/1/10/54 Vincent Mailhol (1): can: dev: add software tx timestamps drivers/net/can/dev.c | 1 + 1 file changed, 1 insertion(+) -- 2.26.2