Re: [PATCH net v2 1/1] net: fec: fix the PTP periodic output sysfs interface
From: Jakub Kicinski
Date: Mon Mar 23 2026 - 23:27:55 EST
On Tue, 24 Mar 2026 02:36:55 +0000 Wei Fang wrote:
> > > Reviewed-by: Wei Fang <wei.fang@xxxxxxx>
> >
> > I don't understand why you think that we should be exposing 4 channels
> > to the user when they can only use one. And have the user guess which
> > one should be programmed. Please explain (and Buday will have to update
> > the commit message), to me v1 looked like a much better fix.
>
> As I explained in v1, I think the "channel index" parameter of
> "/sys/class/ptp/ptp<N>/period" refers to the hardware channel number,
> rather than the software mapping to the hardware channel.
Can you cite any documentation or examples?
What would be the benefit of exposing the ID within the MAC IP (not
even the board) to the user?
As I said the benefit of having just 1 is that user doesn't have
to poke around to find out which one works.
> Although the current driver only supports one channel for output,
> the channel index should specify the correct hardware channel instead
> of a fixed 0. Perhaps Richard could share his thoughts on the channel
> index parameter.