From 9a69e5e5080fd0727e7e2c1579a9b61513fc89ce Mon Sep 17 00:00:00 2001 From: Martin Pieuchot Date: Tue, 28 Aug 2018 15:15:03 +0000 Subject: Add per-TDB counters and a new SADB extension to export them to userland. Inputs from markus@, ok sthen@ --- sys/netinet/ip_output.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'sys/netinet/ip_output.c') diff --git a/sys/netinet/ip_output.c b/sys/netinet/ip_output.c index 162803b7264..c963f7c5014 100644 --- a/sys/netinet/ip_output.c +++ b/sys/netinet/ip_output.c @@ -1,4 +1,4 @@ -/* $OpenBSD: ip_output.c,v 1.347 2018/07/12 15:51:50 mpi Exp $ */ +/* $OpenBSD: ip_output.c,v 1.348 2018/08/28 15:15:02 mpi Exp $ */ /* $NetBSD: ip_output.c,v 1.28 1996/02/13 23:43:07 christos Exp $ */ /* @@ -635,8 +635,10 @@ ip_output_ipsec_send(struct tdb *tdb, struct mbuf *m, struct route *ro, int fwd) /* Callee frees mbuf */ error = ipsp_process_packet(m, tdb, AF_INET, 0); - if (error) + if (error) { ipsecstat_inc(ipsec_odrops); + tdb->tdb_odrops++; + } return error; } #endif /* IPSEC */ -- cgit v1.2.3