提交 b47723ab 编写于 作者: S Szabolcs Nagy 提交者: Rich Felker

netinet/tcp.h: add tcp_info fields from linux v4.19

new fields for RFC 4898 tcp stats in linux
tcpi_bytes_sent added in commit ba113c3aa79a7f941ac162d05a3620bdc985c58d
tcpi_bytes_retrans added in commit fb31c9b9f6c85b1bad569ecedbde78d9e37cd87b
tcpi_dsack_dups added in commit 7e10b6554ff2ce7f86d5d3eec3af5db8db482caa
tcpi_reord_seen added in commit 7ec65372ca534217b53fd208500cf7aac223a383

The new fields change the size of a public struct and thus an ABI break,
but this is how the getsockopt TCP_INFO api is designed: the tcp_info
type must only be used with a length parameter in extern interfaces.
上级 df4b017b
......@@ -72,6 +72,10 @@ enum {
TCP_NLA_SND_SSTHRESH,
TCP_NLA_DELIVERED,
TCP_NLA_DELIVERED_CE,
TCP_NLA_BYTES_SENT,
TCP_NLA_BYTES_RETRANS,
TCP_NLA_DSACK_DUPS,
TCP_NLA_REORD_SEEN,
};
#if defined(_GNU_SOURCE) || defined(_BSD_SOURCE)
......@@ -225,6 +229,10 @@ struct tcp_info {
uint64_t tcpi_sndbuf_limited;
uint32_t tcpi_delivered;
uint32_t tcpi_delivered_ce;
uint64_t tcpi_bytes_sent;
uint64_t tcpi_bytes_retrans;
uint32_t tcpi_dsack_dups;
uint32_t tcpi_reord_seen;
};
#define TCP_MD5SIG_MAXKEYLEN 80
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册