Menu

/sk.h Commit Log


Commit Date  
[110849] (4.2 kB) by Stephan Gatzka Stephan Gatzka , pushed by Richard Cochran Richard Cochran

Make functions and structs dealing with string literals const correct.

This allows the compiler to check if someone writes into string
literals.

Signed-off-by: Stephan Gatzka <stephan.gatzka@...>

2014-02-07 16:52:03 View
Download
[7b7e04] (4.2 kB) by Richard Cochran Richard Cochran

Add an optional extra check on sync and follow up message ordering.

Because of packet reordering that can occur in the network, in the
hardware, or in the networking stack, a follow up message can appear
to arrive in the application before the matching sync message. As this
is a normal occurrence, and the sequenceID message field ensures
proper matching, the ptp4l program accepts out of order packets.

This patch adds an additional check using the software time stamps
from the networking stack to verify that the sync message did arrive
first. This check is only useful if the sequence IDs generated by
the master might possibly be incorrect.

Signed-off-by: Richard Cochran <richardcochran@...>

2013-08-29 08:54:55 View
Download
[76e10e] (3.8 kB) by Jacob Keller Jacob Keller , pushed by Richard Cochran Richard Cochran

ptp4l: Use poll() instead of a try-again loop

This patch modifies sk_receive in order to use poll() on POLLERR instead of the
tryagain loop as this resolves issues with drivers who do not return timestamps
quickly enough. It also resolves the issue of wasting time repeating every
microsecond. It lets the kernel sleep our application until the data or timeout arrives.

This change also replaces the old tx_timestamp_retries config value with
tx_timestamp_timeout specified in milliseconds (the smallest length of time poll
accepts). This does have the side effect of increasing the minimum delay before
missing a timestamp by up to 1ms, but the poll should return sooner in the
normal case where a packet timestamp was not dropped.

This change vastly improves some devices and cleans the code up by simplifying a
race condition window due to drivers returning tx timestamp on the error queue.

[ RC - removed the unused 'try_again' variable. ]

Signed-off-by: Jacob Keller <jacob.e.keller@...>

2013-04-05 15:52:14 View
Download
[f3ac2c] (3.7 kB) by Geoff Salmon Geoff Salmon , pushed by Richard Cochran Richard Cochran

add sk_interface_addr for getting an interface's IP

2013-01-09 00:21:26 View
Download
[e6bbbb] (3.3 kB) by Richard Cochran Richard Cochran

Fixup the Doxygen comment for the sk_ts_info struct.

Signed-off-by: Richard Cochran <richardcochran@...>

2012-11-14 19:20:17 View
Download
[004b62] (3.1 kB) by Jacob Keller Jacob Keller , pushed by Richard Cochran Richard Cochran

sk: change sk_interface_phc to sk_get_ts_info

this patch changes sk_interface_phc to sk_get_ts_info, by allowing the function
to store all the data returned by Ethtool's get_ts_info IOCTL in a struct. A new
struct "sk_ts_info" contains the same data as well as a field for specifying the
structure as valid (in order to support old kernels without the IOCTL). The
valid field should be set only when the IOCTL successfully populates the fields.

A follow-on patch will add new functionality possible because of these
changes. This patch only updates the programs which use the call to perform the
minimum they already do, using the new interface.

Signed-off-by: Jacob Keller <jacob.e.keller@...>

2012-11-13 21:35:04 View
Download
[ebe6a2] (2.8 kB) by Richard Cochran Richard Cochran

Remove useless option selecting layer 2 time stamping.

Now that the code automatically falls back to transport-specific time
stamping, this option is no longer needed.

Signed-off-by: Richard Cochran <richardcochran@...>
Acked-by: Jacob Keller <jacob.e.keller@...>
Tested-by: Jiri Benc <jbenc@...>

2012-10-25 19:02:34 View
Download
[8dde0d] (2.9 kB) by Richard Cochran Richard Cochran

Pass transport type to time stamping initialization function.

Signed-off-by: Richard Cochran <richardcochran@...>
Acked-by: Jacob Keller <jacob.e.keller@...>
Tested-by: Jiri Benc <jbenc@...>

2012-10-25 13:19:31 View
Download
[ba4727] (2.8 kB) by Richard Cochran Richard Cochran

Throw an error if SIOCETHTOOL returns a bad PHC index.

If the kernel supports the ioctl, but the driver does not (like igb in
kernel version 3.5), then ptp4l will incorrectly choose the system clock.

Signed-off-by: Richard Cochran <richardcochran@...>

2012-08-22 02:43:47 View
Download
[e757b7] (2.7 kB) by Richard Cochran Richard Cochran

Add a configuration option to support 802.1AS only hardware.

Some of the time stamping hardware out there only recognizes layer 2
packets, and these do not work without changing the receive filter in
the SIOCSHWTSTAMP request.

Signed-off-by: Richard Cochran <richardcochran@...>

2012-07-27 10:00:47 View
Download
Older >
Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.