mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-30 03:27:44 -04:00
tcp: Add SNMP counters for backlog and min_ttl drops
Commit6b03a53a(tcp: use limited socket backlog) added the possibility of dropping frames when backlog queue is full. Commitd218d111(tcp: Generalized TTL Security Mechanism) added the possibility of dropping frames when TTL is under a given limit. This patch adds new SNMP MIB entries, named TCPBacklogDrop and TCPMinTTLDrop, published in /proc/net/netstat in TcpExt: line netstat -s | egrep "TCPBacklogDrop|TCPMinTTLDrop" TCPBacklogDrop: 0 TCPMinTTLDrop: 0 Signed-off-by: Eric Dumazet <[email protected]> Signed-off-by: David S. Miller <[email protected]>
This commit is contained in:
parent
4045635318
commit
6cce09f87a
4 changed files with 11 additions and 3 deletions
|
|
@ -1740,8 +1740,9 @@ process:
|
|||
if (!tcp_prequeue(sk, skb))
|
||||
ret = tcp_v6_do_rcv(sk, skb);
|
||||
}
|
||||
} else if (sk_add_backlog(sk, skb)) {
|
||||
} else if (unlikely(sk_add_backlog(sk, skb))) {
|
||||
bh_unlock_sock(sk);
|
||||
NET_INC_STATS_BH(net, LINUX_MIB_TCPBACKLOGDROP);
|
||||
goto discard_and_relse;
|
||||
}
|
||||
bh_unlock_sock(sk);
|
||||
|
|
|
|||
Loading…
Reference in a new issue