mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: David Woodhouse <dwmw2@infradead.org>
To: Wen Gu <guwen@linux.alibaba.com>, Jakub Kicinski <kuba@kernel.org>
Cc: Thomas Gleixner <tglx@linutronix.de>,
	Richard Cochran <richardcochran@gmail.com>,
	andrew+netdev@lunn.ch, davem@davemloft.net,  edumazet@google.com,
	pabeni@redhat.com, xuanzhuo@linux.alibaba.com,
	 dust.li@linux.alibaba.com, netdev@vger.kernel.org,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH net-next v5 1/2] ptp: introduce Alibaba CIPU PHC driver
Date: Fri, 09 Jan 2026 10:25:51 +0100	[thread overview]
Message-ID: <de8952121036deb58c07be294a044b5ff5bc00f4.camel@infradead.org> (raw)
In-Reply-To: <3e137dbb-4299-4adf-9e19-b78ce6cfe4c8@linux.alibaba.com>

[-- Attachment #1: Type: text/plain, Size: 2678 bytes --]

On Sun, 2026-01-04 at 14:11 +0800, Wen Gu wrote:
> 
> 
> On 2026/1/3 03:51, Jakub Kicinski wrote:
> > On Mon, 22 Dec 2025 15:18:19 +0800 Wen Gu wrote:
> > > The same applies to ptp_cipu, since it is already used and relies on
> > > exposing /dev/ptpX.
> > 
> > IIUC you mean that the driver is already used downstream and abandoning
> > PTP will break the OOT users? This is a non-argument upstream.
> > 
> 
> I know.
> 
> My point is that I hope ptp_cipu can use the PTP interface as these
> existing drivers, because many user programs and their ecosystems
> depend on the PTP interface, such as chrony, or other user programs
> based on `/dev/ptp*`. A new clock class device node will break this,
> requiring changes to all these user programs, otherwise they can't
> use the clock.
> 
> > > Given the historical baggage, it seems better to keep using the
> > > existing ptp framework, but separate these pure phc drivers into a
> > > new subsystem with a dedicated directory (e.g. drivers/phc/) and a
> > > MAINTAINERS entry, moving them out of the netdev maintenance scope.
> > > This should also address the concern that these pure phc drivers are
> > > not a good fit to be maintained under the networking subsystem.
> > 
> > I'd rather you left PTP completely alone with your funny read only
> > clocks. Please and thank you.
> 
> What you call 'funny' read only clocks have existed as PTP clocks for
> a long time, and there are many examples, such as ptp_kvm, ptp_vmw
> and ptp_s390. It also exists outside the drivers/ptp directory, such
> as drivers/hv/hv_util.c[1]. And there are also recent examples, such
> as drivers/virtio/virtio_rtc_ptp.c[2]. Even the PTP interface definition
> does not require that the ability to set the time must be supported.
> So I think the clock itself, as well as the use of the PTP interface
> is reasonable and not funny.
> 
> IIUC, the main block is that you don't want to maintain these pure
> phc clocks, as you mentioned in [3]. I agree with this as well. So I
> propose to group these pure phc drivers together (e.g. drivers/phc)
> and move them from the network maintenance domain to the clock maintenance
> domain.

I think that makes sense. These clocks can still be registered as PTP
clocks because that's one of the most sensible interfaces to userspace,
but the implementations can live elsewhere outside the networking
maintenance domain.

In a lot of cases we'd want to use them for RTC too, so that the
kernel's CLOCK_REALTIME can be initialised from them. And especially
for microvms I'd like to *synchronize* the kernel's clock from them
automatically too.



[-- Attachment #2: smime.p7s --]
[-- Type: application/pkcs7-signature, Size: 5069 bytes --]

  reply	other threads:[~2026-01-09  9:26 UTC|newest]

Thread overview: 23+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-10-30 12:13 [PATCH net-next v5 0/2] ptp: Alibaba CIPU PTP clock driver Wen Gu
2025-10-30 12:13 ` [PATCH net-next v5 1/2] ptp: introduce Alibaba CIPU PHC driver Wen Gu
2025-10-31 23:58   ` Jakub Kicinski
2025-11-05 10:22     ` Wen Gu
2025-11-06  0:24       ` Jakub Kicinski
2025-11-27  5:48         ` Wen Gu
2025-11-27 16:36           ` Jakub Kicinski
2025-11-28  6:22             ` Wen Gu
2025-11-28 18:24               ` Jakub Kicinski
2025-12-01  6:04                 ` Wen Gu
2025-12-12  6:50                   ` Wen Gu
2025-12-12 22:50                     ` Jakub Kicinski
2025-12-14 14:03                       ` Wen Gu
2025-12-16 21:58                         ` Jakub Kicinski
2025-12-17 12:40                           ` Wen Gu
2025-12-22  7:18                           ` Wen Gu
2026-01-02 19:51                             ` Jakub Kicinski
2026-01-04  6:11                               ` Wen Gu
2026-01-09  9:25                                 ` David Woodhouse [this message]
2026-01-12  3:45                                   ` Wen Gu
2025-12-18 12:28         ` David Woodhouse
2025-12-22 12:44           ` Wen Gu
2025-10-30 12:13 ` [PATCH net-next v5 2/2] ptp: add sysfs documentation for " Wen Gu

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=de8952121036deb58c07be294a044b5ff5bc00f4.camel@infradead.org \
    --to=dwmw2@infradead.org \
    --cc=andrew+netdev@lunn.ch \
    --cc=davem@davemloft.net \
    --cc=dust.li@linux.alibaba.com \
    --cc=edumazet@google.com \
    --cc=guwen@linux.alibaba.com \
    --cc=kuba@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=netdev@vger.kernel.org \
    --cc=pabeni@redhat.com \
    --cc=richardcochran@gmail.com \
    --cc=tglx@linutronix.de \
    --cc=xuanzhuo@linux.alibaba.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

all inboxes | Powered by JetHome®