summaryrefslogtreecommitdiff
path: root/include/uapi/rdma
diff options
context:
space:
mode:
authorMichael Margolin <mrgolin@amazon.com>2026-07-22 08:36:00 +0000
committerLeon Romanovsky <leon@kernel.org>2026-07-22 05:45:47 -0400
commitc1c13e596f65c2b2744c6d4f1471d7b7058195d3 (patch)
treea92067e3654240375ade10ba3882c81826ca26d5 /include/uapi/rdma
parent45e537bf580d540132bcabd8ae3af483461fa1c1 (diff)
downloadlinux-c1c13e596f65c2b2744c6d4f1471d7b7058195d3.tar.gz
linux-c1c13e596f65c2b2744c6d4f1471d7b7058195d3.zip
RDMA/core: Expose Completion Counter capabilities to userspace
Add a dedicated query interface for completion counter capabilities via UVERBS_METHOD_QUERY_COMP_CNTR_CAPS on the device object. The query returns the maximum number of counters, maximum counter value, and a bitmask of supported QP attach operations. Each field is an optional ioctl attribute, allowing userspace to request only the capabilities it needs. Drivers implement the query_comp_cntr_caps operation to report device-specific capabilities. Reviewed-by: Yonatan Nachum <ynachum@amazon.com> Signed-off-by: Michael Margolin <mrgolin@amazon.com> Link: https://patch.msgid.link/20260722083603.30334-4-mrgolin@amazon.com Signed-off-by: Leon Romanovsky <leon@kernel.org>
Diffstat (limited to 'include/uapi/rdma')
-rw-r--r--include/uapi/rdma/ib_user_ioctl_cmds.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/include/uapi/rdma/ib_user_ioctl_cmds.h b/include/uapi/rdma/ib_user_ioctl_cmds.h
index 19a94b91987e..6a3d59d03f54 100644
--- a/include/uapi/rdma/ib_user_ioctl_cmds.h
+++ b/include/uapi/rdma/ib_user_ioctl_cmds.h
@@ -76,6 +76,7 @@ enum uverbs_methods_device {
UVERBS_METHOD_QUERY_GID_TABLE,
UVERBS_METHOD_QUERY_GID_ENTRY,
UVERBS_METHOD_QUERY_PORT_SPEED,
+ UVERBS_METHOD_QUERY_COMP_CNTR_CAPS,
};
enum uverbs_attrs_invoke_write_cmd_attr_ids {
@@ -94,6 +95,12 @@ enum uverbs_attrs_query_port_speed_cmd_attr_ids {
UVERBS_ATTR_QUERY_PORT_SPEED_RESP,
};
+enum uverbs_attrs_query_comp_cntr_caps_attr_ids {
+ UVERBS_ATTR_QUERY_COMP_CNTR_CAPS_MAX_COUNTERS,
+ UVERBS_ATTR_QUERY_COMP_CNTR_CAPS_MAX_VALUE,
+ UVERBS_ATTR_QUERY_COMP_CNTR_CAPS_SUPPORTED_QP_ATTACH_OPS,
+};
+
enum uverbs_attrs_get_context_attr_ids {
UVERBS_ATTR_GET_CONTEXT_NUM_COMP_VECTORS,
UVERBS_ATTR_GET_CONTEXT_CORE_SUPPORT,