From 54f45063df4998e93b5e2344df20a1ff9df640d1 Mon Sep 17 00:00:00 2001 From: Richard Cochran Date: Sat, 15 Aug 2015 12:51:15 +0200 Subject: [PATCH] port: change 'announce_span' into a macro. This probably should not have been a variable in the first place. Signed-off-by: Richard Cochran --- ds.h | 1 - port.c | 3 ++- ptp4l.c | 1 - 3 files changed, 2 insertions(+), 3 deletions(-) diff --git a/ds.h b/ds.h index f9a5d7b..d30c418 100644 --- a/ds.h +++ b/ds.h @@ -125,7 +125,6 @@ struct portDS { #define FRI_ASAP (-128) struct port_defaults { - int announce_span; int path_trace_enabled; int follow_up_info; int freq_est_interval; /*log seconds*/ diff --git a/port.c b/port.c index c1e6151..7c7b73b 100644 --- a/port.c +++ b/port.c @@ -39,6 +39,7 @@ #include "util.h" #define ALLOWED_LOST_RESPONSES 3 +#define ANNOUNCE_SPAN 1 enum syfu_state { SF_EMPTY, @@ -950,7 +951,7 @@ static int port_set_announce_tmo(struct port *p) { return set_tmo_random(p->fda.fd[FD_ANNOUNCE_TIMER], p->announceReceiptTimeout, - p->pod.announce_span, p->logAnnounceInterval); + ANNOUNCE_SPAN, p->logAnnounceInterval); } static int port_set_delay_tmo(struct port *p) diff --git a/ptp4l.c b/ptp4l.c index 0734549..f31cec8 100644 --- a/ptp4l.c +++ b/ptp4l.c @@ -80,7 +80,6 @@ static struct config cfg_settings = { }, .pod = { - .announce_span = 1, .path_trace_enabled = 0, .follow_up_info = 0, .freq_est_interval = 1,