net/tcp: Add TCP-AO segments counters
Introduce segment counters that are useful for troubleshooting/debugging as well as for writing tests. Now there are global snmp counters as well as per-socket and per-key. Co-developed-by: Francesco Ruggeri <fruggeri@arista.com> Signed-off-by: Francesco Ruggeri <fruggeri@arista.com> Co-developed-by: Salam Noureddine <noureddine@arista.com> Signed-off-by: Salam Noureddine <noureddine@arista.com> Signed-off-by: Dmitry Safonov <dima@arista.com> Acked-by: David Ahern <dsahern@kernel.org> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
parent
0a3a809089
commit
af09a341dc
9 changed files with 77 additions and 15 deletions
|
|
@ -297,6 +297,10 @@ enum
|
|||
LINUX_MIB_TCPMIGRATEREQSUCCESS, /* TCPMigrateReqSuccess */
|
||||
LINUX_MIB_TCPMIGRATEREQFAILURE, /* TCPMigrateReqFailure */
|
||||
LINUX_MIB_TCPPLBREHASH, /* TCPPLBRehash */
|
||||
LINUX_MIB_TCPAOREQUIRED, /* TCPAORequired */
|
||||
LINUX_MIB_TCPAOBAD, /* TCPAOBad */
|
||||
LINUX_MIB_TCPAOKEYNOTFOUND, /* TCPAOKeyNotFound */
|
||||
LINUX_MIB_TCPAOGOOD, /* TCPAOGood */
|
||||
__LINUX_MIB_MAX
|
||||
};
|
||||
|
||||
|
|
|
|||
|
|
@ -404,9 +404,15 @@ struct tcp_ao_info_opt { /* setsockopt(TCP_AO_INFO) */
|
|||
__u32 set_current :1, /* corresponding ::current_key */
|
||||
set_rnext :1, /* corresponding ::rnext */
|
||||
ao_required :1, /* don't accept non-AO connects */
|
||||
reserved :29; /* must be 0 */
|
||||
set_counters :1, /* set/clear ::pkt_* counters */
|
||||
reserved :28; /* must be 0 */
|
||||
__u16 reserved2; /* padding, must be 0 */
|
||||
__u8 current_key; /* KeyID to set as Current_key */
|
||||
__u8 rnext; /* KeyID to set as Rnext_key */
|
||||
__u64 pkt_good; /* verified segments */
|
||||
__u64 pkt_bad; /* failed verification */
|
||||
__u64 pkt_key_not_found; /* could not find a key to verify */
|
||||
__u64 pkt_ao_required; /* segments missing TCP-AO sign */
|
||||
} __attribute__((aligned(8)));
|
||||
|
||||
/* setsockopt(fd, IPPROTO_TCP, TCP_ZEROCOPY_RECEIVE, ...) */
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue