summaryrefslogtreecommitdiffhomepage
path: root/pkg/abi/linux
diff options
context:
space:
mode:
authorgVisor bot <gvisor-bot@google.com>2021-01-28 00:27:45 +0000
committergVisor bot <gvisor-bot@google.com>2021-01-28 00:27:45 +0000
commitb161e5d2a3a9a8518e8408116e6c5f0269557d12 (patch)
tree4a1b4538ffccbae2b7ad96ed75b9f3efc3420dd3 /pkg/abi/linux
parent309913688384e2e1ba64927192fab22cc925eb5d (diff)
parent99988e45ed651f64e16e2f2663b06b4a1eee50d4 (diff)
Merge release-20210112.0-104-g99988e45e (automated)
Diffstat (limited to 'pkg/abi/linux')
-rw-r--r--pkg/abi/linux/linux_abi_autogen_unsafe.go26
-rw-r--r--pkg/abi/linux/socket.go12
-rw-r--r--pkg/abi/linux/tcp.go9
3 files changed, 46 insertions, 1 deletions
diff --git a/pkg/abi/linux/linux_abi_autogen_unsafe.go b/pkg/abi/linux/linux_abi_autogen_unsafe.go
index 4960295ae..19f823232 100644
--- a/pkg/abi/linux/linux_abi_autogen_unsafe.go
+++ b/pkg/abi/linux/linux_abi_autogen_unsafe.go
@@ -8951,7 +8951,7 @@ func (s *SockAddrUnix) WriteTo(writer io.Writer) (int64, error) {
// SizeBytes implements marshal.Marshallable.SizeBytes.
func (t *TCPInfo) SizeBytes() int {
- return 192
+ return 224
}
// MarshalBytes implements marshal.Marshallable.MarshalBytes.
@@ -9048,6 +9048,18 @@ func (t *TCPInfo) MarshalBytes(dst []byte) {
dst = dst[8:]
usermem.ByteOrder.PutUint64(dst[:8], uint64(t.SndBufLimited))
dst = dst[8:]
+ usermem.ByteOrder.PutUint32(dst[:4], uint32(t.Delievered))
+ dst = dst[4:]
+ usermem.ByteOrder.PutUint32(dst[:4], uint32(t.DelieveredCe))
+ dst = dst[4:]
+ usermem.ByteOrder.PutUint64(dst[:8], uint64(t.BytesSent))
+ dst = dst[8:]
+ usermem.ByteOrder.PutUint64(dst[:8], uint64(t.BytesRetrans))
+ dst = dst[8:]
+ usermem.ByteOrder.PutUint32(dst[:4], uint32(t.DSACKDups))
+ dst = dst[4:]
+ usermem.ByteOrder.PutUint32(dst[:4], uint32(t.ReordSeen))
+ dst = dst[4:]
}
// UnmarshalBytes implements marshal.Marshallable.UnmarshalBytes.
@@ -9144,6 +9156,18 @@ func (t *TCPInfo) UnmarshalBytes(src []byte) {
src = src[8:]
t.SndBufLimited = uint64(usermem.ByteOrder.Uint64(src[:8]))
src = src[8:]
+ t.Delievered = uint32(usermem.ByteOrder.Uint32(src[:4]))
+ src = src[4:]
+ t.DelieveredCe = uint32(usermem.ByteOrder.Uint32(src[:4]))
+ src = src[4:]
+ t.BytesSent = uint64(usermem.ByteOrder.Uint64(src[:8]))
+ src = src[8:]
+ t.BytesRetrans = uint64(usermem.ByteOrder.Uint64(src[:8]))
+ src = src[8:]
+ t.DSACKDups = uint32(usermem.ByteOrder.Uint32(src[:4]))
+ src = src[4:]
+ t.ReordSeen = uint32(usermem.ByteOrder.Uint32(src[:4]))
+ src = src[4:]
}
// Packed implements marshal.Marshallable.Packed.
diff --git a/pkg/abi/linux/socket.go b/pkg/abi/linux/socket.go
index 8591acbf2..cb33c37bd 100644
--- a/pkg/abi/linux/socket.go
+++ b/pkg/abi/linux/socket.go
@@ -416,6 +416,18 @@ type TCPInfo struct {
RwndLimited uint64
// SndBufLimited is the time in microseconds limited by send buffer.
SndBufLimited uint64
+
+ Delievered uint32
+ DelieveredCe uint32
+
+ // BytesSent is RFC4898 tcpEStatsPerfHCDataOctetsOut.
+ BytesSent uint64
+ // BytesRetrans is RFC4898 tcpEStatsPerfOctetsRetrans.
+ BytesRetrans uint64
+ // DSACKDups is RFC4898 tcpEStatsStackDSACKDups.
+ DSACKDups uint32
+ // ReordSeen is the number of reordering events seen.
+ ReordSeen uint32
}
// SizeOfTCPInfo is the binary size of a TCPInfo struct.
diff --git a/pkg/abi/linux/tcp.go b/pkg/abi/linux/tcp.go
index 2a8d4708b..1a3c0916f 100644
--- a/pkg/abi/linux/tcp.go
+++ b/pkg/abi/linux/tcp.go
@@ -59,3 +59,12 @@ const (
MAX_TCP_KEEPINTVL = 32767
MAX_TCP_KEEPCNT = 127
)
+
+// Congestion control states from include/uapi/linux/tcp.h.
+const (
+ TCP_CA_Open = 0
+ TCP_CA_Disorder = 1
+ TCP_CA_CWR = 2
+ TCP_CA_Recovery = 3
+ TCP_CA_Loss = 4
+)