ibv_query_comp_cntr_caps(3) Libibverbs Programmer’s Manual ibv_query_comp_cntr_caps(3)

ibv_query_comp_cntr_caps - Query completion counter capabilities

#include <infiniband/verbs.h>
int ibv_query_comp_cntr_caps(struct ibv_context *context,
                             struct ibv_comp_cntr_caps *caps);

ibv_query_comp_cntr_caps() queries the completion counter capabilities of the RDMA device associated with context.

struct ibv_comp_cntr_caps {
    uint64_t max_value;
    uint32_t max_counters;
    uint32_t supported_qp_attach_ops;
};
The maximum value a completion counter can hold. A subsequent increment that would exceed this value wraps the counter to zero.
The maximum number of completion counters that can be created on this device.
A bitmask of ibv_qp_attach_comp_cntr_op values indicating which attach operations are supported by the device. See ibv_qp_attach_comp_cntr(3) for the list of operations.

ibv_query_comp_cntr_caps() returns 0 on success, or the value of errno on failure (which indicates the failure reason).

Completion counters are not supported on this device.

ibv_create_comp_cntr(3), ibv_qp_attach_comp_cntr(3)

Michael Margolin mrgolin@amazon.com

2026-07-17 libibverbs