aboutsummaryrefslogtreecommitdiff
path: root/platform/linux-generic/include-abi
diff options
context:
space:
mode:
authorJerin Jacob <jerinj@marvell.com>2021-02-15 15:29:42 +0530
committerMatias Elo <matias.elo@nokia.com>2021-07-21 11:02:15 +0300
commit2a6bd22254c74a4bc5b28460aa0d0131ee8c8f3d (patch)
treee92b996dbc12569b1acb69e2a05c06313bbd2549 /platform/linux-generic/include-abi
parentd9aaba1b356856713023775534ac34cb34e5dac8 (diff)
api: proto_stats: introduce generic protocol stats framework
Add generic protocol stats framework where protocol stats object supports basic operations like creation, lookup, access and destroy of stats object is supported. Each object supports a set of stats based on object params. This generic framework is also useful when we have to associate stats objects to fast path with minimal overhead as it is as close to HW implementation as possible. Signed-off-by: Nithin Dabilpuram <ndabilpuram@marvell.com> Signed-off-by: Jerin Jacob <jerinj@marvell.com> Reviewed-by: Janne Peltonen <janne.peltonen@nokia.com>
Diffstat (limited to 'platform/linux-generic/include-abi')
-rw-r--r--platform/linux-generic/include-abi/odp/api/abi/proto_stats.h37
1 files changed, 37 insertions, 0 deletions
diff --git a/platform/linux-generic/include-abi/odp/api/abi/proto_stats.h b/platform/linux-generic/include-abi/odp/api/abi/proto_stats.h
new file mode 100644
index 000000000..2ebfa57cd
--- /dev/null
+++ b/platform/linux-generic/include-abi/odp/api/abi/proto_stats.h
@@ -0,0 +1,37 @@
+/* SPDX-License-Identifier: BSD-3-Clause
+ * Copyright(C) 2021 Marvell.
+ */
+
+/**
+ * @file
+ *
+ * ODP proto stats
+ */
+
+#ifndef ODP_API_ABI_PROTO_STATS_H_
+#define ODP_API_ABI_PROTO_STATS_H_
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+#include <odp/api/std_types.h>
+#include <odp/api/plat/strong_types.h>
+
+/** @ingroup odp_proto_stats
+ * @{
+ */
+
+typedef ODP_HANDLE_T(odp_proto_stats_t);
+
+#define ODP_PROTO_STATS_INVALID _odp_cast_scalar(odp_proto_stats_t, 0)
+
+/**
+ * @}
+ */
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif