aboutsummaryrefslogtreecommitdiff
path: root/sys/netinet
diff options
context:
space:
mode:
authorRandall Stewart <rrs@FreeBSD.org>2025-11-18 15:18:25 +0000
committerRandall Stewart <rrs@FreeBSD.org>2025-11-18 15:18:25 +0000
commit8f2f66b323ac3ea29ebedf12cad06fbbb76edd3c (patch)
tree66183762051f3961e2f9b51f7a1287e4d532cc2b /sys/netinet
parent38829592dc77e9ead4259785e0bfb93bd4c2fe34 (diff)
Diffstat (limited to 'sys/netinet')
-rw-r--r--sys/netinet/tcp_hpts.h11
1 files changed, 11 insertions, 0 deletions
diff --git a/sys/netinet/tcp_hpts.h b/sys/netinet/tcp_hpts.h
index 6b05f9701ac2..13527f7f9a4a 100644
--- a/sys/netinet/tcp_hpts.h
+++ b/sys/netinet/tcp_hpts.h
@@ -32,6 +32,10 @@
#define HPTS_MSEC_IN_SEC 1000
#define HPTS_USEC_IN_MSEC 1000
+/*
+ * The following functions should also be available
+ * to userspace as well.
+ */
static inline uint32_t
tcp_tv_to_usec(const struct timeval *sv)
{
@@ -50,6 +54,13 @@ tcp_tv_to_lusec(const struct timeval *sv)
return ((uint64_t)((sv->tv_sec * HPTS_USEC_IN_SEC) + sv->tv_usec));
}
+static inline uint64_t
+tcp_tv_to_lusectick(const struct timeval *sv)
+{
+ return ((uint64_t)((sv->tv_sec * HPTS_USEC_IN_SEC) + sv->tv_usec));
+}
+
+
struct hpts_diag {
uint32_t p_hpts_active; /* bbr->flex7 x */
uint32_t p_nxt_slot; /* bbr->flex1 x */