From 2ae441d42411d416e9e3f39c60f6c14d23708f74 Mon Sep 17 00:00:00 2001 From: "Eric S. Raymond" Date: Thu, 31 Oct 2013 23:49:55 -0400 Subject: Contain the assumption that time hinting is done to NTPD. Because it might be going to chrony. Or something else. No logic changes, just name changes and one new derived #define, TIMEHINT_ENABLE. --- drivers.c | 102 +++++++++++++++++++++++++++++++------------------------------- 1 file changed, 51 insertions(+), 51 deletions(-) (limited to 'drivers.c') diff --git a/drivers.c b/drivers.c index b6727417..90eb5689 100644 --- a/drivers.c +++ b/drivers.c @@ -101,9 +101,9 @@ const struct gps_type_t unknown = { #ifdef CONTROLSEND_ENABLE .control_send = NULL, /* how to send control strings */ #endif /* CONTROLSEND_ENABLE */ -#ifdef NTPSHM_ENABLE - .ntp_offset = NULL, /* no method for NTP fudge factor */ -#endif /* NTPSHM_ ENABLE */ +#ifdef TIMEHINT_ENABLE + .time_offset = NULL, /* no method for NTP fudge factor */ +#endif /* TIMEHINT_ENABLE */ }; /* *INDENT-ON* */ @@ -265,9 +265,9 @@ const struct gps_type_t nmea = { #ifdef CONTROLSEND_ENABLE .control_send = nmea_write, /* how to send control strings */ #endif /* CONTROLSEND_ENABLE */ -#ifdef NTPSHM_ENABLE - .ntp_offset = NULL, /* no method for NTP fudge factor */ -#endif /* NTPSHM_ ENABLE */ +#ifdef TIMEHINT_ENABLE + .time_offset = NULL, /* no method for NTP fudge factor */ +#endif /* TIMEHINT_ENABLE */ }; /* *INDENT-ON* */ @@ -366,9 +366,9 @@ const struct gps_type_t garmin = { #ifdef CONTROLSEND_ENABLE .control_send = nmea_write, /* how to send control strings */ #endif /* CONTROLSEND_ENABLE */ -#ifdef NTPSHM_ENABLE - .ntp_offset = NULL, /* no method for NTP fudge factor */ -#endif /* NTPSHM_ ENABLE */ +#ifdef TIMEHINT_ENABLE + .time_offset = NULL, /* no method for NTP fudge factor */ +#endif /* TIMEHINT_ENABLE */ }; /* *INDENT-ON* */ #endif /* GARMIN_ENABLE && NMEA_ENABLE */ @@ -428,9 +428,9 @@ const struct gps_type_t ashtech = { #ifdef CONTROLSEND_ENABLE .control_send = nmea_write, /* how to send control strings */ #endif /* CONTROLSEND_ENABLE */ -#ifdef NTPSHM_ENABLE - .ntp_offset = NULL, /* no method for NTP fudge factor */ -#endif /* NTPSHM_ ENABLE */ +#ifdef TIMEHINT_ENABLE + .time_offset = NULL, /* no method for NTP fudge factor */ +#endif /* TIMEHINT_ENABLE */ }; /* *INDENT-ON* */ #endif /* ASHTECH_ENABLE */ @@ -479,9 +479,9 @@ const struct gps_type_t fv18 = { #ifdef CONTROLSEND_ENABLE .control_send = nmea_write, /* how to send control strings */ #endif /* CONTROLSEND_ENABLE */ -#ifdef NTPSHM_ENABLE - .ntp_offset = NULL, /* no method for NTP fudge factor */ -#endif /* NTPSHM_ ENABLE */ +#ifdef TIMEHINT_ENABLE + .time_offset = NULL, /* no method for NTP fudge factor */ +#endif /* TIMEHINT_ENABLE */ }; /* *INDENT-ON* */ #endif /* FV18_ENABLE */ @@ -533,9 +533,9 @@ const struct gps_type_t gpsclock = { #ifdef CONTROLSEND_ENABLE .control_send = nmea_write, /* how to send control strings */ #endif /* CONTROLSEND_ENABLE */ -#ifdef NTPSHM_ENABLE - .ntp_offset = NULL, /* no method for NTP fudge factor */ -#endif /* NTPSHM_ ENABLE */ +#ifdef TIMEHINT_ENABLE + .time_offset = NULL, /* no method for NTP fudge factor */ +#endif /* TIMEHINT_ENABLE */ }; /* *INDENT-ON* */ #endif /* GPSCLOCK_ENABLE */ @@ -588,9 +588,9 @@ static const struct gps_type_t tripmate = { #ifdef CONTROLSEND_ENABLE .control_send = nmea_write, /* how to send control strings */ #endif /* CONTROLSEND_ENABLE */ -#ifdef NTPSHM_ENABLE - .ntp_offset = NULL, /* no method for NTP fudge factor */ -#endif /* NTPSHM_ ENABLE */ +#ifdef TIMEHINT_ENABLE + .time_offset = NULL, /* no method for NTP fudge factor */ +#endif /* TIMEHINT_ENABLE */ }; /* *INDENT-ON* */ #endif /* TRIPMATE_ENABLE */ @@ -639,9 +639,9 @@ static const struct gps_type_t earthmate = { #ifdef CONTROLSEND_ENABLE .control_send = nmea_write, /* never actually used. */ #endif /* CONTROLSEND_ENABLE */ -#ifdef NTPSHM_ENABLE - .ntp_offset = NULL, /* no method for NTP fudge factor */ -#endif /* NTPSHM_ ENABLE */ +#ifdef TIMEHINT_ENABLE + .time_offset = NULL, /* no method for NTP fudge factor */ +#endif /* TIMEHINT_ENABLE */ }; /*@ -redef @*/ /* *INDENT-ON* */ @@ -762,9 +762,9 @@ const struct gps_type_t trueNorth = { #ifdef CONTROLSEND_ENABLE .control_send = tnt_control_send, /* how to send control strings */ #endif /* CONTROLSEND_ENABLE */ -#ifdef NTPSHM_ENABLE - .ntp_offset = NULL, -#endif /* NTPSHM_ ENABLE */ +#ifdef TIMEHINT_ENABLE + .time_offset = NULL, +#endif /* TIMEHINT_ENABLE */ }; /* *INDENT-ON* */ #endif @@ -840,9 +840,9 @@ static const struct gps_type_t oceanServer = { #ifdef CONTROLSEND_ENABLE .control_send = nmea_write, /* how to send control strings */ #endif /* CONTROLSEND_ENABLE */ -#ifdef NTPSHM_ENABLE - .ntp_offset = NULL, -#endif /* NTPSHM_ ENABLE */ +#ifdef TIMEHINT_ENABLE + .time_offset = NULL, +#endif /* TIMEHINT_ENABLE */ }; /* *INDENT-ON* */ #endif @@ -907,9 +907,9 @@ static const struct gps_type_t fury = { #ifdef CONTROLSEND_ENABLE .control_send = nmea_write, /* how to send control strings */ #endif /* CONTROLSEND_ENABLE */ -#ifdef NTPSHM_ENABLE - .ntp_offset = NULL, -#endif /* NTPSHM_ ENABLE */ +#ifdef TIMEHINT_ENABLE + .time_offset = NULL, +#endif /* TIMEHINT_ENABLE */ }; /* *INDENT-ON* */ @@ -961,9 +961,9 @@ static const struct gps_type_t rtcm104v2 = { #ifdef CONTROLSEND_ENABLE .control_send = NULL, /* how to send control strings */ #endif /* CONTROLSEND_ENABLE */ -#ifdef NTPSHM_ENABLE - .ntp_offset = NULL, -#endif /* NTPSHM_ ENABLE */ +#ifdef TIMEHINT_ENABLE + .time_offset = NULL, +#endif /* TIMEHINT_ENABLE */ }; /* *INDENT-ON* */ #endif /* RTCM104V2_ENABLE */ @@ -1007,9 +1007,9 @@ static const struct gps_type_t rtcm104v3 = { #ifdef CONTROLSEND_ENABLE .control_send = NULL, /* how to send control strings */ #endif /* CONTROLSEND_ENABLE */ -#ifdef NTPSHM_ENABLE - .ntp_offset = NULL, -#endif /* NTPSHM_ ENABLE */ +#ifdef TIMEHINT_ENABLE + .time_offset = NULL, +#endif /* TIMEHINT_ENABLE */ }; /* *INDENT-ON* */ #endif /* RTCM104V3_ENABLE */ @@ -1042,9 +1042,9 @@ static const struct gps_type_t garmintxt = { #ifdef CONTROLSEND_ENABLE .control_send = NULL, /* how to send control strings */ #endif /* CONTROLSEND_ENABLE */ -#ifdef NTPSHM_ENABLE - .ntp_offset = NULL, -#endif /* NTPSHM_ ENABLE */ +#ifdef TIMEHINT_ENABLE + .time_offset = NULL, +#endif /* TIMEHINT_ENABLE */ }; /* *INDENT-ON* */ #endif /* GARMINTXT_ENABLE */ @@ -1136,9 +1136,9 @@ const struct gps_type_t mtk3301 = { #ifdef CONTROLSEND_ENABLE .control_send = nmea_write, /* how to send control strings */ #endif /* CONTROLSEND_ENABLE */ -#ifdef NTPSHM_ENABLE - .ntp_offset = NULL, -#endif /* NTPSHM_ ENABLE */ +#ifdef TIMEHINT_ENABLE + .time_offset = NULL, +#endif /* TIMEHINT_ENABLE */ }; /* *INDENT-ON* */ #endif /* MTK3301_ENABLE */ @@ -1374,9 +1374,9 @@ const struct gps_type_t aivdm = { #ifdef CONTROLSEND_ENABLE .control_send = NULL, /* no control sender */ #endif /* CONTROLSEND_ENABLE */ -#ifdef NTPSHM_ENABLE - .ntp_offset = NULL, /* no NTP communication */ -#endif /* NTPSHM_ ENABLE */ +#ifdef TIMEHINT_ENABLE + .time_offset = NULL, /* no NTP communication */ +#endif /* TIMEHINT_ENABLE */ }; /* *INDENT-ON* */ #endif /* AIVDM_ENABLE */ @@ -1472,9 +1472,9 @@ const struct gps_type_t json_passthrough = { #ifdef CONTROLSEND_ENABLE .control_send = NULL, /* how to send control strings */ #endif /* CONTROLSEND_ENABLE */ -#ifdef NTPSHM_ENABLE - .ntp_offset = NULL, /* no method for NTP fudge factor */ -#endif /* NTPSHM_ ENABLE */ +#ifdef TIMEHINT_ENABLE + .time_offset = NULL, /* no method for NTP fudge factor */ +#endif /* TIMEHINT_ENABLE */ }; /* *INDENT-ON* */ -- cgit v1.2.1