diff --git a/src/inet/nlas.rs b/src/inet/nlas.rs index 66f518b..36141ad 100644 --- a/src/inet/nlas.rs +++ b/src/inet/nlas.rs @@ -90,8 +90,7 @@ buffer!(MemInfoBuffer(MEM_INFO_LEN) { /// documentation with a huge grain of salt. Please report any error /// you may notice. Here are the references I used: /// -/// - [https://wiki.linuxfoundation.org/networking/sk_buff](a short introduction -/// to `sk_buff`, the struct used in the kernel to store packets) +/// - [a short introduction to `sk_buff`, the struct used in the kernel to store packets](https://wiki.linuxfoundation.org/networking/sk_buff) /// - [vger.kernel.org has a lot of documentation about the low level network stack APIs](http://vger.kernel.org/~davem/skb_data.html) /// - [thorough high level explanation of buffering in the network stack](https://www.coverfire.com/articles/queueing-in-the-linux-network-stack/) /// - [understanding the backlog queue](http://veithen.io/2014/01/01/how-tcp-backlog-works-in-linux.html) @@ -155,7 +154,7 @@ pub struct MemInfo { /// Memory used for packets that have been passed down the network /// stack, i.e. that are either in the QDisc or device driver /// queues. This attribute is known as `sk_wmem_alloc` in the - /// kernel. See also [`send_queue`]. + /// kernel. See also [`send_queue`](#structfield.send_queue). pub bottom_send_queues: u32, /// The amount of memory already allocated for this socket but /// currently unused. When more memory is needed either for @@ -477,7 +476,7 @@ pub struct TcpInfo { /// `TCP_CA_DISORDER`, `TCP_CA_CWR`, `TCP_CA_RECOVERY`, /// `TCP_CA_LOSS` pub ca_state: u8, - /// + /// Number of retransmits since the last ACK pub retransmits: u8, pub probes: u8, pub backoff: u8, @@ -507,7 +506,7 @@ pub struct TcpInfo { pub sacked: u32, /// Number of segments that have been lost pub lost: u32, - /// Number of segments that have been retransmitted + /// Number of segments that are currently being retransmitted pub retrans: u32, /// Number of segments that have been FACKed pub fackets: u32, @@ -539,6 +538,7 @@ pub struct TcpInfo { pub rcv_rtt: u32, pub rcv_space: u32, + /// Number of segments that have been retransmitted during lifetime of the socket pub total_retrans: u32, pub pacing_rate: u64, diff --git a/src/unix/nlas.rs b/src/unix/nlas.rs index bfbb33a..2274be1 100644 --- a/src/unix/nlas.rs +++ b/src/unix/nlas.rs @@ -30,12 +30,8 @@ pub enum Nla { /// attribute is reported for listening sockets only. This /// attribute is known as `UNIX_DIAG_ICONS` in the kernel. PendingConnections(Vec), - /// This attribute corresponds to the `UNIX_DIAG_RQLEN`. It - /// reports the length of the socket receive queue, and the queue - /// size limit. Note that for **listening** sockets the receive - /// queue is used to store actual data sent by other sockets. It - /// is used to store pending connections. So the meaning of this - /// attribute differs for listening sockets. + /// This attribute corresponds to the `UNIX_DIAG_RQLEN`. Actual meaning of + /// this attribute differs depending on the type of socket. /// /// For **listening** sockets: ///