Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 14 Jul 2018 17:12:04 +0000 (UTC)
From:      Michael Tuexen <tuexen@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r336285 - head/cddl/lib/libdtrace
Message-ID:  <201807141712.w6EHC4aX046311@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: tuexen
Date: Sat Jul 14 17:12:04 2018
New Revision: 336285
URL: https://svnweb.freebsd.org/changeset/base/336285

Log:
  Add support for TCP state names used by Solaris.
  
  For compatibility, add the TCP state names used by Solaris
  and given in the Dtrace Guide available at
  https://docs.oracle.com/cd/E37838_01/html/E61035/glhgu.html#OSDTGglhmv
  
  Reviewed by:		markj@
  Sponsored by:		Netflix, Inc.
  Differential Revision:	https://reviews.freebsd.org/D16269

Modified:
  head/cddl/lib/libdtrace/tcp.d

Modified: head/cddl/lib/libdtrace/tcp.d
==============================================================================
--- head/cddl/lib/libdtrace/tcp.d	Sat Jul 14 16:59:17 2018	(r336284)
+++ head/cddl/lib/libdtrace/tcp.d	Sat Jul 14 17:12:04 2018	(r336285)
@@ -55,6 +55,32 @@ inline int TCPS_FIN_WAIT_2 =	9;
 #pragma D binding "1.6.3" TCPS_TIME_WAIT
 inline int TCPS_TIME_WAIT =	10;
 
+/*
+ * For compatibility also provide the names used by Solaris.
+ */
+#pragma D binding "1.13" TCP_STATE_CLOSED
+inline int TCP_STATE_CLOSED =		TCPS_CLOSED;
+#pragma D binding "1.13" TCP_STATE_LISTEN
+inline int TCP_STATE_LISTEN =		TCPS_LISTEN;
+#pragma D binding "1.13" TCP_STATE_SYN_SENT
+inline int TCP_STATE_SYN_SENT =		TCPS_SYN_SENT;
+#pragma D binding "1.13" TCP_STATE_SYN_RECEIVED
+inline int TCP_STATE_SYN_RECEIVED =	TCPS_SYN_RECEIVED;
+#pragma D binding "1.13" TCP_STATE_ESTABLISHED
+inline int TCP_STATE_ESTABLISHED =	TCPS_ESTABLISHED;
+#pragma D binding "1.13" TCP_STATE_CLOSE_WAIT
+inline int TCP_STATE_CLOSE_WAIT =	TCPS_CLOSE_WAIT;
+#pragma D binding "1.13" TCP_STATE_FIN_WAIT_1
+inline int TCP_STATE_FIN_WAIT_1 =	TCPS_FIN_WAIT_1;
+#pragma D binding "1.13" TCP_STATE_CLOSING
+inline int TCP_STATE_CLOSING =		TCPS_CLOSING;
+#pragma D binding "1.13" TCP_STATE_LAST_ACK
+inline int TCP_STATE_LAST_ACK =		TCPS_LAST_ACK;
+#pragma D binding "1.13" TCP_STATE_FIN_WAIT_2
+inline int TCP_STATE_FIN_WAIT_2 =	TCPS_FIN_WAIT_2;
+#pragma D binding "1.13" TCP_STATE_TIME_WAIT
+inline int TCP_STATE_TIME_WAIT =	TCPS_TIME_WAIT;
+
 /* TCP segment flags. */
 #pragma D binding "1.6.3" TH_FIN
 inline uint8_t TH_FIN =		0x01;



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201807141712.w6EHC4aX046311>