On Tue, 27 Jan 2026 17:44:09 +0000
Cliff Burdick <[email protected]> wrote:
> +static struct ibv_mr *
> +mlx5_glue_reg_dmabuf_mr(struct ibv_pd *pd, uint64_t offset, size_t length,
> + uint64_t iova, int fd, int access)
> +{
> +#ifdef HAVE_IBV_REG_DMABUF_MR
> + return ibv_reg_dmabuf_mr(pd, offset, length, iova, fd, access);
> +#else
> + (void)pd;
> + (void)offset;
> + (void)length;
> + (void)iova;
> + (void)fd;
> + (void)access;
> + errno = ENOTSUP;
> + return NULL;
> +#endif
> +}
I would prefer the callback hook did not exist (was NULL)
if you don't have your #ifdef.
The (void) change looks messy and better handled by caller.