RE: [PATCH v2 net-next 12/14] net: enetc: add PTP synchronization support for ENETC v4
From: Wei Fang
Date: Tue Jul 22 2025 - 09:41:55 EST
> On Fri, Jul 18, 2025 at 05:08:09AM +0300, Wei Fang wrote:
> > > > > > +static inline bool enetc_ptp_clock_is_enabled(struct enetc_si *si) {
> > > > > > + if (is_enetc_rev1(si))
> > > > > > + return IS_ENABLED(CONFIG_FSL_ENETC_PTP_CLOCK);
> > > > > > +
> > > > > > + return IS_ENABLED(CONFIG_PTP_1588_CLOCK_NETC);
> > > > > > +}
> > > > > > +
> > > > >
> > > > > why v1 check CONFIG_FSL_ENETC_PTP_CLOCK and other check
> > > > > CONFIG_PTP_1588_CLOCK_NETC
> > > >
> > > > Because they use different PTP drivers, so the configs are different.
> > >
> > > But name CONFIG_FSL_ENETC_PTP_CLOCK and
> > > CONFIG_PTP_1588_CLOCK_NETC is quite
> > > similar, suppose CONFIG_PTP_1588_CLOCK_NETC should be
> > > CONFIG_PTP_1588_CLOCK_NETC_V4
> > >
> > Okay, it looks good
>
> The help text is also very confusing, nowhere is it specified that the
> new driver is for NETCv4, the reader can just as well interpret it that
> the LS1028A ENETC can use this PTP timer driver.
>
> + This driver adds support for using the NXP NETC Timer as a PTP
> + clock. This clock is used by ENETC MAC or NETC Switch for PTP
> + synchronization. It also supports periodic output signal (e.g.
> + PPS) and external trigger timestamping.
Thanks for pointing out this, let me improve the description in the next
version.