linux-gpio.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Dipen Patel <dipenp@nvidia.com>
To: Richard Cochran <richardcochran@gmail.com>,
	Arnd Bergmann <arnd@arndb.de>
Cc: Linus Walleij <linus.walleij@linaro.org>,
	Kent Gibson <warthog618@gmail.com>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	"thierry.reding@gmail.com" <thierry.reding@gmail.com>,
	Jon Hunter <jonathanh@nvidia.com>,
	"Bartosz Golaszewski" <bgolaszewski@baylibre.com>,
	"open list:GPIO SUBSYSTEM" <linux-gpio@vger.kernel.org>,
	linux-tegra <linux-tegra@vger.kernel.org>,
	Thomas Gleixner <tglx@linutronix.de>,
	Networking <netdev@vger.kernel.org>
Subject: Re: GTE - The hardware timestamping engine
Date: Mon, 22 Mar 2021 13:33:38 -0700	[thread overview]
Message-ID: <a58a0ec2-9da8-92bc-c08e-38b1bed6f757@nvidia.com> (raw)
In-Reply-To: <20210320153855.GA29456@hoboy.vegasvil.org>

Hi Richard,

Thanks for your input and time. Please see below follow up.

On 3/20/21 8:38 AM, Richard Cochran wrote:
> On Sat, Mar 20, 2021 at 01:44:20PM +0100, Arnd Bergmann wrote:
>> Adding Richard Cochran as well, for drivers/ptp/, he may be able to
>> identify whether this should be integrated into that framework in some
>> form.
> 
> I'm not familiar with the GTE, but it sounds like it is a (free
> running?) clock with time stamping inputs.  If so, then it could
> expose a PHC.  That gets you functionality:
> 
> - clock_gettime() and friends
> - comparison ioctl between GTE clock and CLOCK_REALTIME
> - time stamping channels with programmable input selection
> 
GTE gets or rather records the timestamps from the TSC
(timestamp system coutner) so its not attached to GTE as any
one can access TSC, so not sure if we really need to implement PHC
and/or clock_* and friends for the GTE. I believe burden to find correlation
between various clock domains should be on the clients, consider below
example.

Networking client has access to both PTP and GTE, it would be its job
to find the correlations if that is at all needed based on whatever
use case that client serves. GTE in above may come in picture if said client
has some GPIO configured and wants timestamp on it.

Sorry if I misunderstood anything, you can elaborate more as I am also
interested in how GTE can fit in PTP framework and which usecase it can
help doing so.

> The mentioned applications (robotics and autonomous vehicle, so near
> and dear to my heart) surely already use the PHC API for dealing with
> network and system time sources, and so exposing the GTE as a PHC
> means that user space programs will have a consistent API.
> 
> [ The only drawback I can see is the naming of the C language
>   identifiers in include/uapi/linux/ptp_clock.h.  If that bothers
>   people, then these can be changed to something more generic while
>   keeping compatibility aliases. ]
> 
> Thanks,
> Richard
> 

Thanks,
Best Regards,
Dipen Patel

  reply	other threads:[~2021-03-22 20:30 UTC|newest]

Thread overview: 20+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-03-17 22:33 GTE - The hardware timestamping engine Dipen Patel
2021-03-20 11:56 ` Linus Walleij
2021-03-20 12:44   ` Arnd Bergmann
2021-03-20 15:38     ` Richard Cochran
2021-03-22 20:33       ` Dipen Patel [this message]
2021-03-23  9:03         ` Thierry Reding
2021-03-23 12:51           ` Richard Cochran
2021-03-22  6:00   ` Kent Gibson
2021-03-22 20:21     ` Dipen Patel
2021-03-23  0:32       ` Kent Gibson
2021-03-23  1:53         ` Dipen Patel
2021-03-23  2:59           ` Kent Gibson
2021-03-23  4:09             ` Dipen Patel
2021-03-23  5:22               ` Kent Gibson
2021-03-23  9:08       ` Linus Walleij
2021-03-23 10:06         ` Thierry Reding
2021-03-23 18:21           ` Marc Zyngier
2021-03-23 18:25           ` Dipen Patel
2021-03-23 21:19           ` Dipen Patel
2021-03-23 18:01         ` Dipen Patel

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=a58a0ec2-9da8-92bc-c08e-38b1bed6f757@nvidia.com \
    --to=dipenp@nvidia.com \
    --cc=arnd@arndb.de \
    --cc=bgolaszewski@baylibre.com \
    --cc=jonathanh@nvidia.com \
    --cc=linus.walleij@linaro.org \
    --cc=linux-gpio@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-tegra@vger.kernel.org \
    --cc=netdev@vger.kernel.org \
    --cc=richardcochran@gmail.com \
    --cc=tglx@linutronix.de \
    --cc=thierry.reding@gmail.com \
    --cc=warthog618@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).