diff options
| author | Marcelo Ricardo Leitner <[email protected]> | 2015-05-20 23:35:41 +0000 |
|---|---|---|
| committer | David S. Miller <[email protected]> | 2015-05-22 03:25:21 +0000 |
| commit | 2efd055c53c06b7e89c167c98069bab9afce7e59 (patch) | |
| tree | 4930a37c5ae972395c0945d6b786ad1e1fd07c0e /net/unix/af_unix.c | |
| parent | ipv6: reject locally assigned nexthop addresses (diff) | |
| download | kernel-2efd055c53c06b7e89c167c98069bab9afce7e59.tar.gz kernel-2efd055c53c06b7e89c167c98069bab9afce7e59.zip | |
tcp: add tcpi_segs_in and tcpi_segs_out to tcp_info
This patch tracks the total number of inbound and outbound segments on a
TCP socket. One may use this number to have an idea on connection
quality when compared against the retransmissions.
RFC4898 named these : tcpEStatsPerfSegsIn and tcpEStatsPerfSegsOut
These are a 32bit field each and can be fetched both from TCP_INFO
getsockopt() if one has a handle on a TCP socket, or from inet_diag
netlink facility (iproute2/ss patch will follow)
Note that tp->segs_out was placed near tp->snd_nxt for good data
locality and minimal performance impact, while tp->segs_in was placed
near tp->bytes_received for the same reason.
Join work with Eric Dumazet.
Note that received SYN are accounted on the listener, but sent SYNACK
are not accounted.
Signed-off-by: Marcelo Ricardo Leitner <[email protected]>
Signed-off-by: Eric Dumazet <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
Diffstat (limited to 'net/unix/af_unix.c')
0 files changed, 0 insertions, 0 deletions
