Does anyone had been tried to enable the HW timestamp on Linux? I try to fix the driver 1.1.19v on Ubuntu 10.4 according to datasheet but no luck. Below is my senerio:
- HW TX
- The EXTCMD:TS bit is enable according to datasheet 188.8.131.52 & 184.108.40.206.5.
- Enable TX timestamp TSYNCTXCTL.
- HW RX
- Set RXCFGL to 0x0800(IPV4) or 0x88F7 (ieee1588 ethertype), V2 messageID set to 0x0(SYNC packet)
- Set RXUDP to 0x013F (port 319)
- Config TIMINCA
- Config SYSTIMH & SYSTIML
- Enable TSYNCRXCTL and select mode
- Send SYNC packet from ieee1588 devices
- Watchdog query TSYNCRXCTL bit 0, if bit became 1b, then queries RXSTMPH/RXSTMPL/RXSATRL/RXSATRH.
TEST CASE & QUESTION:
- I use wireshark to sniff the packet, and double check the messageId/versionPTP. The incoming packets seem to be corrected. TSYNCRXCTL bit still remain 0 except no-locking mode 100b. In no-locking mode, RXSTMPH/RXSTMPL/RXSATRL/RXSATRH value change everytime SYNC packet receive.
- The main differentiation between mode 100b and other mode is locking, could be somewhere has lock the register (I make a assumption that mode 100b work)?
- I try to read the RXSTMPL/RXSTMPH in watchdog timer but still no luck at all. According to datasheet 220.127.116.11, time stamp values will be unlocked after software access, that mean by read the RXSTMPL/RXSTMPH will unlock the timer ?
- Do i need to set filter around other registers?
Anyone, please hint me if you have answer :), i would like to share for opensource community as soon as i merge it with ptpv2d.
Hello, I've fiddled with hw time stamping on Kawela and Barton Hills cards, and I'm intererested in your ptpv2 daemon implementation. My project was an untergraduate laboratory with ptpd. Initially I tried to refit the v2 version with hw timestamping, but when i started the original code was far from perfect so I decided to finish the v1 daemon instead. I will post the new code till the end of summer (on sf.net). Later I want to benchmark the different versions under various conditions. Any reply would be appreciated :)
i could enable hw timestamp function on my 82574 GbE NIC, just do the folloing step that u have known:
Set RXCFGL to 0x0800(IPV4) or 0x88F7 (ieee1588 ethertype), V2 messageID set to 0x0(SYNC packet) ----------------> not really needed, hw has reset valueSet RXUDP to 0x013F (port 319) ----------> not really needed, hw has reset valueSet RXCTL to 0x14 ----------> enable hwtstamp function, and select '010' mode(V2 event message)Config TIMINCA Config SYSTIMH & SYSTIML Enable TSYNCRXCTL and select modeSend SYNC packet from ieee1588 devices
when u complish the initialization work, u colud read bit 0 in RXCTL register, it indicate a hw timestamp has been taken, then u could read RXSTMPL & RXSTMPH registers, good luck.