Xilinx-CNS / sfptpd

Solarflare Enhanced PTP Daemon. Use multiple PTP and PPS sources and sync local clocks together in one integrated application with high quality timestamp filtering, supporting bonds and VLANs, real time and long term stats reporting.
Other
25 stars 4 forks source link

Clock object not created for Raspberry Pi 5 Ethernet interface #9

Closed abower-amd closed 8 months ago

abower-amd commented 8 months ago

On Raspberry Pi 5, the Ethernet interface is correctly enumerated and identified as having an associated PHC device but a corresponding 'clock' object does not get created.

The effect of this is confusion and an inability to use the NIC clock.

This was not previously a problem in testing with a CM4 but it is unconfirmed whether this is a regression or not.

abower-amd commented 8 months ago

The issue as reported was user error: not setting non_solarflare_nics on.

However, there were errors in sfptpd_clock.c causing sfptpd to interpret system clock information as if it were for a NIC clock and incorrectly refusing to operate with it. Now fixed.

Failure:

2024-03-14 09:14:38.563828: error: clock system: unable to adjust frequency - no phc device
2024-03-14 09:14:38.563837: warning: servo0: failed to adjust clock system, error No such device
2024-03-14 09:14:38.563848: notice: servo0: alarms changed: none -> clock-ctrl-failure

As fixed:

2024-03-16 19:39:42.114315 [servo0:phc0->system], offset: 64.219, freq-adj: -1132.022, in-sync: 1