[prev in list] [next in list] [prev in thread] [next in thread] 

List:       busybox
Subject:    [PATCH] - deprecate IPTOS_LOWDELAY in favor of IPTOS_DSCP_AF21
From:       Codarren Velvindron <codarren () hackers ! mu>
Date:       2018-04-15 16:37:50
Message-ID: 20180415163750.GA3721 () hackers ! mu
[Download RAW message or body]

commit d114c7146341622517644da70c85e837fd45d5eb
Author: Codarren Velvindron <codarren@hackers.mu>
Date:   Sun Apr 15 20:29:21 2018 +0400

    Update QoS markers
    Use DSCP AF21 for interactive traffic. DSCP is defined in RFC2474. Many modern \
equipment no longer support IPTOS.

diff --git a/networking/ntpd.c b/networking/ntpd.c
index 6cd4970..a1b8ac5 100644
--- a/networking/ntpd.c
+++ b/networking/ntpd.c
@@ -93,10 +93,10 @@
 
 #include "libbb.h"
 #include <math.h>
-#include <netinet/ip.h> /* For IPTOS_LOWDELAY definition */
+#include <netinet/ip.h> /* For IPTOS_DSCP_AF21 definition */
 #include <sys/timex.h>
-#ifndef IPTOS_LOWDELAY
-# define IPTOS_LOWDELAY 0x10
+#ifndef IPTOS_DSCP_AF21
+# define IPTOS_DSCP_AF21 0x48
 #endif
 
 
@@ -910,7 +910,7 @@ send_query_to_peer(peer_t *p)
 #if ENABLE_FEATURE_IPV6
 		if (family == AF_INET)
 #endif
-			setsockopt_int(fd, IPPROTO_IP, IP_TOS, IPTOS_LOWDELAY);
+			setsockopt_int(fd, IPPROTO_IP, IP_TOS, IPTOS_DSCP_AF21);
 		free(local_lsa);
 	}
 
@@ -2320,7 +2320,7 @@ static NOINLINE void ntp_init(char **argv)
 				xfunc_die();
 		}
 		socket_want_pktinfo(G_listen_fd);
-		setsockopt_int(G_listen_fd, IPPROTO_IP, IP_TOS, IPTOS_LOWDELAY);
+		setsockopt_int(G_listen_fd, IPPROTO_IP, IP_TOS, IPTOS_DSCP_AF21);
 	}
 #endif
 	/* I hesitate to set -20 prio. -15 should be high enough for timekeeping */
_______________________________________________
busybox mailing list
busybox@busybox.net
http://lists.busybox.net/mailman/listinfo/busybox


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic