Re: [Linuxptp-users] recvmsg tx timestamp failed: Resource temporarily unavailable
PTP IEEE 1588 stack for Linux
Brought to you by:
rcochran
From: Richard C. <ric...@gm...> - 2013-02-07 08:44:58
|
On Thu, Feb 07, 2013 at 12:28:30PM +0530, Rayagond Kokatanur wrote: > > How to verify that time stamp are working with my driver ? How about this: 1. Send sync messages to the device at the rate of once per second. 2. Print out the received time stamps and verify that they are about one second apart. Then repeat the excercise for the delay request message transmission. Also, you should try the Linux kernel test program in Documentation/networking/timestamping. > I send time stamp like this to stack, > > 1. read the tx/rx timestamp low and high value into "u64 ns;" variable. > 2. convert the raw timstamp value to ktime using - "ns_to_ktime()" api. > 3. assign the converted value to .hwtstamp field of struct > skb_shared_hwtstamps struct. > 3. finally pass the struct skb_shared_hwtstamps to stack. > > I am not manipulating other field of struct skb_shared_hwtstamps ie syststamp. > > Also I have configured device to capture time stamp for all received packets. > > Please let me if my procedure is wrong ? Sounds okay, but you have not shown us any code, so you never know. I encourage you to post your driver on the Linux netdev list. HTH, Richard |