diff --git a/clock.c b/clock.c index c88504b..7acb18e 100644 --- a/clock.c +++ b/clock.c @@ -407,7 +407,7 @@ static int clock_management_fill_response(struct clock *c, struct port *p, break; case TLV_TIME_STATUS_NP: tsn = (struct time_status_np *) tlv->data; - tsn->master_offset = c->master_offset; + tsn->master_offset = tmv_to_nanoseconds(c->master_offset); tsn->ingress_time = tmv_to_nanoseconds(c->ingress_ts); tsn->cumulativeScaledRateOffset = (Integer32) (c->status.cumulativeScaledRateOffset + diff --git a/tsproc.c b/tsproc.c index b50c8e5..91bae37 100644 --- a/tsproc.c +++ b/tsproc.c @@ -134,10 +134,11 @@ tmv_t get_raw_delay(struct tsproc *tsp) delay = tmv_div(tmv_add(t23, t41), 2); if (delay < 0) { - pr_debug("negative delay %10" PRId64, delay); + pr_debug("negative delay %10" PRId64, + tmv_to_nanoseconds(delay)); pr_debug("delay = (t2 - t3) * rr + (t4 - t1)"); - pr_debug("t2 - t3 = %+10" PRId64, t23); - pr_debug("t4 - t1 = %+10" PRId64, t41); + pr_debug("t2 - t3 = %+10" PRId64, tmv_to_nanoseconds(t23)); + pr_debug("t4 - t1 = %+10" PRId64, tmv_to_nanoseconds(t41)); pr_debug("rr = %.9f", tsp->clock_rate_ratio); } @@ -156,7 +157,8 @@ int tsproc_update_delay(struct tsproc *tsp, tmv_t *delay) tsp->filtered_delay_valid = 1; pr_debug("delay filtered %10" PRId64 " raw %10" PRId64, - tsp->filtered_delay, raw_delay); + tmv_to_nanoseconds(tsp->filtered_delay), + tmv_to_nanoseconds(raw_delay)); if (!delay) { return 0;