public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Vladimir Oltean <vladimir.oltean@nxp.com>
To: Richard Cochran <richardcochran@gmail.com>
Cc: Miroslav Lichvar <mlichvar@redhat.com>,
	Andrew Lunn <andrew@lunn.ch>,
	"netdev@vger.kernel.org" <netdev@vger.kernel.org>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	David Miller <davem@davemloft.net>,
	Grygorii Strashko <grygorii.strashko@ti.com>,
	Jakub Kicinski <kuba@kernel.org>,
	Joakim Zhang <qiangqing.zhang@nxp.com>,
	Kurt Kanzenbach <kurt@linutronix.de>,
	Russell King <linux@arm.linux.org.uk>
Subject: Re: [PATCH RFC V1 net-next 3/4] net: Let the active time stamping layer be selectable.
Date: Tue, 25 Jan 2022 15:37:12 +0000	[thread overview]
Message-ID: <20220125153712.dnujk6k3nfxczmi3@skbuf> (raw)
In-Reply-To: <20220124153716.GB28194@hoboy.vegasvil.org>

On Mon, Jan 24, 2022 at 07:37:16AM -0800, Richard Cochran wrote:
> On Mon, Jan 24, 2022 at 10:28:23AM +0100, Miroslav Lichvar wrote:
> 
> > FWIW, scm_timestamping has three fields and the middle one no longer
> > seems to be used. If a new socket/timestamping option enabled all
> > three (SW, MAC, PHY) timestamps in the cmsg, I think that would be a
> > nice feature.
> 
> This won't work because:
> 
> - There would need to be seven^W eight, not three slots.
> 
> - Even with just three, the CMSG would have to have a bit that clearly
>   identifies the new format.
>  
> > From an admin point of view, it makes sense to me to have an option to
> > disable PHY timestamps for the whole device if there are issues with
> > it. For debugging and applications, it would be nice to have an option
> > to get all of them at the same time.
> 
> Right.  Those are two different use cases.  The present series
> addresses the first one.  The second one entails making a new flavor
> of time stamping API.

I agree that they are different use cases, but with the runtime PHC
change being now possible, there isn't really a clear-cut moment when an
application can now say "from this moment on, I'm only getting
timestamps from the new PHC". Especially when you switch over from the
PHY to the MAC, a few tens of ms may pass until you get an RX timestamp
from the PHY, and the MAC PHC may well be up and operational in the
meantime, and ptp4l synchronizing based on its timestamps.

I don't have a clear idea how to put it in practice, either. I'll think
about it, but the problem I see is that the phc_index reported by
"ethtool -T" becomes a fuzzy concept in the presence of multiple PHCs.
Adding the ability to retrieve timestamps from all of them doesn't make
it any easier to select which one gets reported to ethtool.
Maybe there's room for both the sysfs and the socket option after all.

  reply	other threads:[~2022-01-25 15:40 UTC|newest]

Thread overview: 28+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-01-03 23:25 [PATCH RFC V1 net-next 3/4] net: Let the active time stamping layer be selectable Richard Cochran
2022-01-03 23:53 ` Russell King (Oracle)
2022-01-04  1:42   ` Richard Cochran
2022-04-04 15:05     ` Michael Walle
2022-04-04 15:20       ` Andrew Lunn
2022-04-04 17:12         ` Michael Walle
2022-04-05  5:59           ` Richard Cochran
2022-04-05  8:48             ` Michael Walle
2022-04-05 15:46               ` Richard Cochran
2022-04-05  9:01           ` Kurt Kanzenbach
2022-04-05  9:19             ` Michael Walle
2022-04-05 11:19               ` Kurt Kanzenbach
2022-04-05 13:15                 ` Grygorii Strashko
2022-04-05 13:29                   ` Andrew Lunn
2022-04-05 15:48                     ` Richard Cochran
2022-04-06 11:18                       ` Grygorii Strashko
2022-01-20 16:48 ` Vladimir Oltean
2022-01-21  3:38   ` Andrew Lunn
2022-01-21  4:05     ` Richard Cochran
2022-01-21 14:50       ` Vladimir Oltean
2022-01-21 15:28         ` Richard Cochran
2022-01-21 16:23           ` Vladimir Oltean
2022-01-22  2:08             ` Richard Cochran
2022-01-24  9:28           ` Miroslav Lichvar
2022-01-24 15:37             ` Richard Cochran
2022-01-25 15:37               ` Vladimir Oltean [this message]
2022-01-21 11:05   ` Kurt Kanzenbach
2022-01-21 15:31     ` Richard Cochran

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=20220125153712.dnujk6k3nfxczmi3@skbuf \
    --to=vladimir.oltean@nxp.com \
    --cc=andrew@lunn.ch \
    --cc=davem@davemloft.net \
    --cc=grygorii.strashko@ti.com \
    --cc=kuba@kernel.org \
    --cc=kurt@linutronix.de \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux@arm.linux.org.uk \
    --cc=mlichvar@redhat.com \
    --cc=netdev@vger.kernel.org \
    --cc=qiangqing.zhang@nxp.com \
    --cc=richardcochran@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