summaryrefslogtreecommitdiffstats
path: root/rdma/stat.h
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-05-04 14:18:53 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-05-04 14:18:53 +0000
commita0e0018c9a7ef5ce7f6d2c3ae16aecbbd16a8f67 (patch)
tree8feaf1a1932871b139b3b30be4c09c66489918be /rdma/stat.h
parentInitial commit. (diff)
downloadiproute2-upstream/6.1.0.tar.xz
iproute2-upstream/6.1.0.zip
Adding upstream version 6.1.0.upstream/6.1.0upstream
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to '')
-rw-r--r--rdma/stat.h26
1 files changed, 26 insertions, 0 deletions
diff --git a/rdma/stat.h b/rdma/stat.h
new file mode 100644
index 0000000..b03a10c
--- /dev/null
+++ b/rdma/stat.h
@@ -0,0 +1,26 @@
+/* SPDX-License-Identifier: GPL-2.0 OR Linux-OpenIB */
+/*
+ * stat.h RDMA tool
+ * Authors: Mark Zhang <markz@mellanox.com>
+ * Erez Alfasi <ereza@mellanox.com>
+ */
+#ifndef _RDMA_TOOL_STAT_H_
+#define _RDMA_TOOL_STAT_H_
+
+#include "rdma.h"
+
+int res_get_hwcounters(struct rd *rd, struct nlattr *hwc_table,
+ bool print);
+
+int stat_mr_parse_cb(const struct nlmsghdr *nlh, void *data);
+int stat_mr_idx_parse_cb(const struct nlmsghdr *nlh, void *data);
+
+static const
+struct filters stat_mr_valid_filters[MAX_NUMBER_OF_FILTERS] = {
+ { .name = "mrn", .is_number = true, .is_doit = true },
+};
+
+RES_FUNC(stat_mr, RDMA_NLDEV_CMD_STAT_GET, stat_mr_valid_filters, true,
+ RDMA_NLDEV_ATTR_RES_MRN);
+
+#endif /* _RDMA_TOOL_STAT_H_ */