]> git.ipfire.org Git - thirdparty/chrony.git/commitdiff
Shorten initial delay and sampling separation to 0.2 seconds
authorMiroslav Lichvar <mlichvar@redhat.com>
Thu, 9 Dec 2010 14:14:05 +0000 (15:14 +0100)
committerMiroslav Lichvar <mlichvar@redhat.com>
Thu, 9 Dec 2010 14:14:05 +0000 (15:14 +0100)
ntp_core.c

index a62557d78f7f026b8fa2d5549e91a21a78cd9758..909f7204dd778687abb5b7730ac737b6d76b578e 100644 (file)
@@ -172,16 +172,22 @@ struct NCR_Instance_Record {
 
 /* ================================================== */
 /* Initial delay period before first packet is transmitted (in seconds) */
-#define INITIAL_DELAY 2.0
+#define INITIAL_DELAY 0.2
 
 /* Spacing required between samples for any two servers/peers (to
    minimise risk of network collisions) (in seconds) */
-#define SAMPLING_SEPARATION 2.0
+#define SAMPLING_SEPARATION 0.2
+
+/* Spacing between samples in burst mode for one server/peer */
+#define BURST_INTERVAL 2.0
 
 /* Time to wait before retransmitting in burst mode, if we did not get
    a reply to the previous probe */
 #define BURST_TIMEOUT 8.0
 
+/* Time to wait after sending echo to 'warm up' link */
+#define WARM_UP_DELAY 4.0
+
 /* The NTP protocol version that we support */
 #define NTP_VERSION 3
 
@@ -582,13 +588,6 @@ transmit_packet(NTP_Mode my_mode, /* The mode this machine wants to be */
 
 }
 
-
-/* ================================================== */
-
-/* ================================================== */
-
-#define WARM_UP_DELAY 4.0
-
 /* ================================================== */
 /* Timeout handler for transmitting to a source. */
 
@@ -1242,7 +1241,7 @@ receive_packet(NTP_Packet *message, struct timeval *now, double now_err, NCR_Ins
     case MD_BURST_WAS_OFFLINE:
 
       requeue_transmit = 1;
-      delay_time = SAMPLING_SEPARATION;
+      delay_time = BURST_INTERVAL;
       break;
 
     default: