6LoWPAN devices have an EUI-64 address rather than an EUI-48 address.
Use the full EUI-64 address when generating the clock identity to
avoid duplicates.
The constant ARPHRD_6LOWPAN is not yet present in the glibc version of
if_arp.h, so define it locally if necessary.
Signed-off-by: Michael
The function ts_add() currently performs open-coded manipulation of a
struct timespec instead of using the tmv_t abstractions.
Prepare for the removal of this code by storing ingressLatency and
egressLatency as corrections (matching the behaviour for
delayAsymmetry).
Signed-off-by: Michael Brown
of code review.
Patch 0001 temporarily introduces an overlength line, which is
subsequently shortened in patch 0004.
Michael Brown (7):
clock: Remove open-coded conversion of struct timespec
port: Treat ingressLatency and egressLatency as corrections
port: Match calling convention
accepting a pointer to a struct Timestamp.
Signed-off-by: Michael Brown <mbr...@fensystems.co.uk>
---
port.c | 20 +++-
1 file changed, 11 insertions(+), 9 deletions(-)
diff --git a/port.c b/port.c
index 3791e59..76f8c91 100644
--- a/port.c
+++ b/port.c
@@ -393,11 +393,13 @@
() instead of open-coded manipulation of a
struct timespec and struct Timestamp in ts_to_Timestamp()
- use tmv_is_zero() instead of open-coded manipulation of a struct
timespec in msg_sots_valid()
Signed-off-by: Michael Brown <mbr...@fensystems.co.uk>
---
msg.h | 4 ++--
nsm.c | 4 ++--
clockcheck_sample().
Signed-off-by: Michael Brown <mbr...@fensystems.co.uk>
---
clock.c | 6 ++
clock.h | 2 +-
port.c | 3 ++-
3 files changed, 5 insertions(+), 6 deletions(-)
diff --git a/clock.c b/clock.c
index 199c0cb..cf087e8 100644
--- a/clock.c
+++ b/clock.c
@@ -1767,11 +1767,9 @
-by: Michael Brown <mbr...@fensystems.co.uk>
---
v2: Local definition of ARPHRD_6LOWPAN moved to missing.h as requested
by Miroslav Lichvar
missing.h | 5 +
sk.c | 5 +
2 files changed, 10 insertions(+)
diff --git a/missing.h b/missing.h
index 16ae97a..d85c5ad
Signed-off-by: Michael Brown <mbr...@fensystems.co.uk>
---
makefile | 2 +-
tmv.c| 136 +++
tmv.h| 112 +---
3 files changed, 156 insertions(+), 94 deletions(-)
creat
Add converters between hardware timestamps and the internal
representation, and remove code that directly manipulates the timespec
within a hardware timestamp.
This is a prerequisite for the use of hardware timestamps with
sub-nanosecond granularity.
Signed-off-by: Michael Brown <
for your excellent work on linuxptp!
Michael Brown (13):
tmv: Add missing uses of tmv_zero()
tmv: Add missing uses of tmv_is_zero()
tmv: Add missing uses of tmv_dbl()
tmv: Add missing uses of tmv_to_nanoseconds()
tmv: Generalise tmv_eq() to tmv_cmp()
tmv: Add tmv_sign()
tmv: Convert tmv_t
Signed-off-by: Michael Brown <mbr...@fensystems.co.uk>
---
clock.c | 24 +++-
1 file changed, 11 insertions(+), 13 deletions(-)
diff --git a/clock.c b/clock.c
index c887a11..d72efb2 100644
--- a/clock.c
+++ b/clock.c
@@ -545,15 +545,15 @@ static void clock_stats_update(
Signed-off-by: Michael Brown <mbr...@fensystems.co.uk>
---
tsproc.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/tsproc.c b/tsproc.c
index 06c0184..b50c8e5 100644
--- a/tsproc.c
+++ b/tsproc.c
@@ -214,7 +214,7 @@ int tsproc_update_offset(struct tsproc *tsp, tmv_t *
Signed-off-by: Michael Brown <mbr...@fensystems.co.uk>
---
tsproc.c | 12 +---
1 file changed, 5 insertions(+), 7 deletions(-)
diff --git a/tsproc.c b/tsproc.c
index a871049..0597f40 100644
--- a/tsproc.c
+++ b/tsproc.c
@@ -134,11 +134,10 @@ tmv_t get_raw_delay(struct tspro
Signed-off-by: Michael Brown <mbr...@fensystems.co.uk>
---
clock.c | 4 ++--
port.c | 2 +-
2 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/clock.c b/clock.c
index 4532664..7af87fc 100644
--- a/clock.c
+++ b/clock.c
@@ -581,7 +581,7 @@ static enum servo_state clock_no_
Signed-off-by: Michael Brown <mbr...@fensystems.co.uk>
---
mave.c | 2 +-
tsproc.c | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/mave.c b/mave.c
index fd09e5a..1a64f79 100644
--- a/mave.c
+++ b/mave.c
@@ -58,7 +58,7 @@ static void mave_reset(struct filter *
Time values are compared using an inequality test in mmedian.c
Generalise tmv_eq() to tmv_cmp() (by analogy with memcmp()) and
replace existing uses of tmv_eq().
Signed-off-by: Michael Brown <mbr...@fensystems.co.uk>
---
clock.c | 2 +-
mmedian.c | 3 ++-
port.c| 2 +-
tmv.h
Enforce the use of the tmv_t wrapper functions by converting tmv_t
from an int64_t to a struct containing an int64_t.
Signed-off-by: Michael Brown <mbr...@fensystems.co.uk>
---
tmv.h | 47 ---
1 file changed, 32 insertions(+), 15 deletions(-)
calculations on absolute times therefore cannot
make use of fractional nanoseconds. At present, only the PI servo is
structured in a way that allows fractional nanoseconds to be used.
Signed-off-by: Michael Brown <mbr...@fensystems.co.uk>
---
clock.c | 2 +-
linreg.c| 3 ++-
nt
Signed-off-by: Michael Brown <mbr...@fensystems.co.uk>
---
clock.c | 2 +-
tsproc.c | 10 ++
2 files changed, 7 insertions(+), 5 deletions(-)
diff --git a/clock.c b/clock.c
index 7af87fc..e9e5d74 100644
--- a/clock.c
+++ b/clock.c
@@ -419,7 +419,7 @@ stat
The sign of time values is tested in tsproc.c. Add an abstraction
tmv_sign() to return the sign of a time value.
Signed-off-by: Michael Brown <mbr...@fensystems.co.uk>
---
tmv.h| 5 +
tsproc.c | 5 +++--
2 files changed, 8 insertions(+), 2 deletions(-)
diff --git a/tmv.h b/tmv.h
On 01/03/18 06:40, Richard Cochran wrote:
At first glance this series looks good. I expect to merge the first
half or so, because we really do want the tmv_t operations to be used
consistently.
Regarding changing the implementation, I think we'll want to hold off
on that until kernel support
On 09/03/18 11:22, Michael Brown wrote:
Also, will you be able to mainline your driver? It helps new kernel
API acceptance when there is an actual, realistic use case and users.
>
I'm aiming to get the code up on GitHub as an out-of-tree driver today
or early next week, and we
On 12/03/18 12:36, Michael Brown wrote:
This is a revised patch series to ensure that the tmv_t operations are
used consistently for calculations involving hardware timestamps.
The ugly hwts_to_tmv() and hwts_sw_to_tmv() wrappers from the previous
patch series are gone. Instead we convert
On 08/03/18 04:39, Richard Cochran wrote:
but is used in various places that care about the internal time
representation. Move this definition to tmv.h as a more natural home.
I'm not taking this patch because a) its not technically needed and b)
I disagree about what is more natural.
The
On 08/03/18 04:46, Richard Cochran wrote:
On Thu, Mar 01, 2018 at 06:12:27PM +, Michael Brown wrote:
Add converters between hardware timestamps and the internal
representation, and remove code that directly manipulates the timespec
within a hardware timestamp.
Although I can see the point
On 09/03/18 01:40, Richard Cochran wrote:
For the kernel, I (and others) would like to get away from the clunky
timespec altogether. Dividing a time value into two fields might have
made sense 30 years ago when operations on eight byte words were
expensive, but today it makes no sense. It only
Signed-off-by: Michael Brown <mbr...@fensystems.co.uk>
---
clock.c | 2 +-
tsproc.c | 10 ++
2 files changed, 7 insertions(+), 5 deletions(-)
diff --git a/clock.c b/clock.c
index e4f939a..53d9c75 100644
--- a/clock.c
+++ b/clock.c
@@ -419,7 +419,7 @@ stat
Signed-off-by: Michael Brown <mbr...@fensystems.co.uk>
---
clock.c | 4 ++--
port.c | 2 +-
2 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/clock.c b/clock.c
index e733bdf..e4f939a 100644
--- a/clock.c
+++ b/clock.c
@@ -581,7 +581,7 @@ static enum servo_state clock_no_
Signed-off-by: Michael Brown <mbr...@fensystems.co.uk>
---
mave.c | 2 +-
tsproc.c | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/mave.c b/mave.c
index fd09e5a..1a64f79 100644
--- a/mave.c
+++ b/mave.c
@@ -58,7 +58,7 @@ static void mave_reset(struct filter *
Signed-off-by: Michael Brown <mbr...@fensystems.co.uk>
---
tsproc.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/tsproc.c b/tsproc.c
index 06c0184..b50c8e5 100644
--- a/tsproc.c
+++ b/tsproc.c
@@ -214,7 +214,7 @@ int tsproc_update_offset(struct tsproc *tsp, tmv_t *
The sign of time values is tested in tsproc.c. Add an abstraction
tmv_sign() to return the sign of a time value.
Signed-off-by: Michael Brown <mbr...@fensystems.co.uk>
---
tmv.h| 5 +
tsproc.c | 5 +++--
2 files changed, 8 insertions(+), 2 deletions(-)
diff --git a/tmv.h b/tmv.h
Prepare for sub-nanosecond timestamps by passing clock offsets as
floating point values to stats_add_value().
Signed-off-by: Michael Brown <mbr...@fensystems.co.uk>
---
clock.c | 13 +
1 file changed, 5 insertions(+), 8 deletions(-)
diff --git a/clock.c b/clock.c
index f
Time values are compared using an inequality test in mmedian.c
Generalise tmv_eq() to tmv_cmp() (by analogy with memcmp()) and
replace existing uses of tmv_eq().
Signed-off-by: Michael Brown <mbr...@fensystems.co.uk>
---
clock.c | 2 +-
mmedian.c | 3 ++-
port.c| 2 +-
tmv.h
Add converters between hardware timestamps and the internal
representation, and remove code that directly manipulates the timespec
within a hardware timestamp.
Signed-off-by: Michael Brown <mbr...@fensystems.co.uk>
---
clock.c | 6 ++
clock.h | 2 +-
port.c
onsistently across the codebase.
Michael Brown (10):
clock: Pass floating point values to stats_add_value()
tmv: Add missing uses of tmv_zero()
tmv: Add missing uses of tmv_is_zero()
tmv: Add missing uses of tmv_dbl()
tmv: Add missing uses of tmv_to_nanoseconds()
tmv: Generalise tmv_eq() to tm
Use tmv_dbl() to obtain the floating point value passed to
stats_add_value() rather than relying on the existing implicit cast
from the result of tmv_to_nanoseconds().
Signed-off-by: Michael Brown <mbr...@fensystems.co.uk>
---
clock.c | 13 +
1 file changed, 5 insertions
The definition of struct hw_timestamp is not used anywhere in msg.c,
but is used in various places that care about the internal time
representation. Move this definition to tmv.h as a more natural home.
Signed-off-by: Michael Brown <mbr...@fensystems.co.uk>
---
msg.h | 13 -
-by: Michael Brown <mbr...@fensystems.co.uk>
---
tmv.h | 53 +++--
1 file changed, 35 insertions(+), 18 deletions(-)
diff --git a/tmv.h b/tmv.h
index 001963f..edfa577 100644
--- a/tmv.h
+++ b/tmv.h
@@ -53,90 +53,107 @@ struct hw_tim
38 matches
Mail list logo