On Fri, Nov 12, 2021 at 10:45:53AM -0600, Ed Branch wrote:
> On 11/12/21 10:36, Vladimir Oltean wrote:
> >
> > What is your use case for the char device symlinks exactly? The
> > canonical way of finding the PTP char device corresponding to an
> > interface is to use "ethtool -T eth0 | grep 'PTP Hardware Clock'".
> >
>
> There is no network interface associated with this clock. Similar to the
> following from the stock Debian 10 entry in
> /lib/udev/rules.d/50-udev-default.rules:
>
> SUBSYSTEM=="ptp", ATTR{clock_name}=="KVM virtual PTP", SYMLINK += "ptp_kvm"
To be honest with you, I'm a bit concerned that it still won't work as
intended even if I remove the error from posix_clock_add(). This is
because find_dst_clock() from phc2sys finds clocks by phc_index. When
you run phc2sys between this /dev/ptp_kvm and CLOCK_REALTIME, I think it
might happen for this function to find the unintended clock, since both
of them have clock->phc_index = -1.
_______________________________________________
Linuxptp-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/linuxptp-users