Patchwork Add TCP_TX_DELAY from Linux 5.3 to netinet/tcp.h

login
register
mail settings
Submitter Joseph Myers
Date Sept. 20, 2019, 8:29 p.m.
Message ID <alpine.DEB.2.21.1909202028570.25525@digraph.polyomino.org.uk>
Download mbox | patch
Permalink /patch/34624/
State New
Headers show

Comments

Joseph Myers - Sept. 20, 2019, 8:29 p.m.
This patch adds the new TCP_TX_DELAY constant from Linux 5.3 to
sysdeps/gnu/netinet/tcp.h.

Tested for x86_64.

2019-09-20  Joseph Myers  <joseph@codesourcery.com>

	* sysdeps/gnu/netinet/tcp.h (TCP_TX_DELAY): New macro.
Joseph Myers - Sept. 27, 2019, 11:55 a.m.
Ping.  This patch 
<https://sourceware.org/ml/libc-alpha/2019-09/msg00336.html> is pending 
review.
Carlos O'Donell - Sept. 27, 2019, 12:43 p.m.
On 9/20/19 4:29 PM, Joseph Myers wrote:
> This patch adds the new TCP_TX_DELAY constant from Linux 5.3 to
> sysdeps/gnu/netinet/tcp.h.
> 
> Tested for x86_64.
> 
> 2019-09-20  Joseph Myers  <joseph@codesourcery.com>
> 
> 	* sysdeps/gnu/netinet/tcp.h (TCP_TX_DELAY): New macro.
> 
> diff --git a/sysdeps/gnu/netinet/tcp.h b/sysdeps/gnu/netinet/tcp.h
> index 1a164a9649..41ca11b5f5 100644
> --- a/sysdeps/gnu/netinet/tcp.h
> +++ b/sysdeps/gnu/netinet/tcp.h
> @@ -79,6 +79,7 @@
>  #define TCP_INQ			 36 /* Notify bytes available to read
>  				       as a cmsg on read.  */
>  #define TCP_CM_INQ		 TCP_INQ
> +#define TCP_TX_DELAY		 37 /* Delay outgoing packets by XX usec.  */
>  
>  #define TCP_REPAIR_ON		 1
>  #define TCP_REPAIR_OFF		 0
> 

OK for master. Matches UAPI headers as of da05b5ea12c1e50b2988a63470d6b69434796f8b.
Upstream linux duplicates the constant in two places, which looks like a bad design
to me.

Reviewed-by: Carlos O'Donell <carlos@redhat.com>

Patch

diff --git a/sysdeps/gnu/netinet/tcp.h b/sysdeps/gnu/netinet/tcp.h
index 1a164a9649..41ca11b5f5 100644
--- a/sysdeps/gnu/netinet/tcp.h
+++ b/sysdeps/gnu/netinet/tcp.h
@@ -79,6 +79,7 @@ 
 #define TCP_INQ			 36 /* Notify bytes available to read
 				       as a cmsg on read.  */
 #define TCP_CM_INQ		 TCP_INQ
+#define TCP_TX_DELAY		 37 /* Delay outgoing packets by XX usec.  */
 
 #define TCP_REPAIR_ON		 1
 #define TCP_REPAIR_OFF		 0