We are implementing IEEE 1588 (using the PTPD from sourceforge) for syncing two systems connected to each other using Ethernet. The following commands were used on the two systems to execute PTP daemon:
# ./ptpd -b eth2 -z linux_hw -y 0
In the source code ixgbe_main.c located at /linux-2.6.38/drivers/net/ixgbe, we have set the following settings fpr PTPV1 Rx filters in the function "static int ixgbe_hwtstamp_ioctl()"
1. Ethertype Filter Queue Filter : 0 /* As V1 msg, there's no ethernet header setting like 0x88F7. So, it should be 0. */
2. SDPQF0 : 0x013F013F ; /* src port 319 : : src port,  dst port */
3. L34T_IMIR0 : (1<12) | (1<<19) | (1<<20))
/* 12th bit : Size Bypass, 19th bit : as in the datasheet, 20th bit : as in the datasheet, but I am not sure. */
4. FTQF0 : ( 0x01 | /* UDP */
(0x13<<25) /* source port and destination port filter enabled, source/target address masked (not enabled)*/ )
The issue is that at the Rx side, the HW timestamping is not working properly. The reason we suspect that its not working fine is because as per the Intel 82599 Documentation (page 252, 82599_datasheet.pdf from the intel website), in section 188.8.131.52 Advanced Receive Descriptors — Write-Back Format, the 16th bit in the "Extended Status / NEXTP" group which is the "TS" bit (page 255, Table 7.17. Receive Status (RDESC.STATUS) Layout of Last Descriptor) is not being set to 1.
We have checked this from /var/log/syslog which prints
"May 25 07:15:35 ubuntu2 kernel: [87648.986178] ixgbe: rx_stamp -> staterr : 0x400000f3"
which is the Rx advanced descriptor value, where the 16th bit is seen to be set as 0.
We have also set TSYNCRXCTL and RXMTRL registers, as well. We are stuck at this point and unable to proceed. Any inputs on this issue would be highly appreciated..
Please get back to us with any questions or clarifications..
The in kernel ixgbe driver does not have IEEE1588 support yet. We are working on doing that enablement but it's not released yet. So I'm assuming that you are adding this support yourself? Also, since 1588 support is in the 2.6.38 kernel already there is no need to use the ptpd. Please look at this link which explains how this works in teh new kenrel:
We will be adding the 1588 HW acceleration support to the ixgbe driver in the near future.