opencomputeproject / Time-Appliance-Project

Develop an end-to-end hypothetical reference model, network architectures, precision time tools, performance objectives and the methods to distribute, operate, monitor time synchronization within data center and much more...
MIT License
1.33k stars 101 forks source link

Why didn't you integrate at least one Ethernet MAC? #41

Closed aholzinger closed 2 years ago

aholzinger commented 2 years ago

You expose a /dev/ptpX device. The ptp stands for precision time protocol which is a network protocol. Normally /dev/ptpX are physical hardware clocks PHC of either a Ethernet PHY or Ethernet MAC. To make use of the timing card in a network one or better two Ethernet MACs/PHYs are missing, because all the precision is useless if we afterwards need to have phc2sys from timing catd's /dev/ptpX to the system cock and then sys2phc from the system clock to /dev/ptpY, the PHC in a NIC available in the system.

Wouldn't it be much more straight forward to have the MACs/PHYs already integrated in timing card? The FPGA is there, so why not use Xilinx Ethernet MAC IP and add one or two external PHYs and obviously connect the FPGA with the PCIe bus?

Having a /dev/ptpX device that is not connected to a MAC/PHY seems just not right to me.

leoleovich commented 2 years ago

Thank you for your question and suggestion. We are using ts2phc and PPS in of the network card to get to the nanoseconds precision confirmed with various certified equipment. We encourage you to try it as well.

aholzinger commented 2 years ago

Thanks for your prompt reply. I do understand the concept. It just sounds strange to me to expose a /dev/ptpX device that in reality isn't a PTP PHC.

I think that an atomic clock is already a huge effort/cost on a PCIe board, so I thought what's the difference in adding two Ethernet PHYs compared to the atomic clocks.

Having checked the cost of the atomic clock modules I wonder if for somebody who needs PTP an external Grandmaster woudn't be the better choice than a time card that is offering PTP only via the deviation by the system clock.

BTW: How do you eliminate system clock drift due to temperature drift on a PC mainboard. Can we be sure that any PC mainboard has a good temperature compensated system clock?

leoleovich commented 2 years ago

PTP is one of the many potential use cases. For example NTP server (chrony) is using the /dev/ptpX directly and does not need NIC to be synchronised at all. Other examples such as irig-b may not even require the network. So keeping a design as it is we are striving for more universal adoption.