On some platforms, time_t has recently switched from "long" to "long
long" [1]. For these platforms it is necessary to use "%lld" as printf
format specifier because the ABI differs between "long" and "long long".
I found no way for creating something similar to PRId64 for time_t. No
idea how to determine whether it's "long" or "long long". So I cast
everything to "long long" instead.
[1] https://git.musl-libc.org/cgit/musl/commit/?id=38143339646a4ccce8afe298c34467767c899f51
Signed-off-by: Christian Eggers <ceggers@arri.de>
Don't require each port to have its own master table specified in the
config. Instead of ports claming configured tables, clone the table in
each port, so different ports don't interfere with each other.
Signed-off-by: Miroslav Lichvar <mlichvar@redhat.com>
It will be used to store the current value of Pdelay Request Interval.
It will be represented as power of two in seconds.
Signed-off-by: Vedang Patel <vedang.patel@intel.com>
Make port_signaling_construct() to create a generic signaling
ptp_message. Move the unicast specific code to
port_signaling_uc_construct().
This is done to support the creation of Message Interval Request TLV (as
defined in 802.1AS Section 10.5.4.3). This TLV can be used to request
change in Announce Interval, Sync Interval or Link Delay Interval on a
remote system.
[ RC - fix trivial rebase conflict on top of targetPortIdentity check. ]
Signed-off-by: Vedang Patel <vedang.patel@intel.com>
Signed-off-by: Richard Cochran <richardcochran@gmail.com>
IEEE 1588 specifies dropping signaling messages if the
targetPortIdentity does not match the receiving port. Up until now
the unicast code did check that field, but only for the unicast
transmission request and cancel operations.
This patch moves the target port identity check so that it applies to
each and every received signaling message.
Signed-off-by: Richard Cochran <richardcochran@gmail.com>
This patch adds new code that runs the state machine and handles the
TLVs for requesting unicast service from a remote master.
Signed-off-by: Richard Cochran <richardcochran@gmail.com>