1mlx5dv_dmelvxx5_dcvr_edaetvex__ccmrde_actoem_pc,mdm_lcxo5mdpv,_dmelvxx5_ddve_sdtervoxy__dcemsdt_rcooym_pc,mdg_ecto_maps,yngce(t3_)async(3)
2
3
4

NAME

6       mlx5dv_devx_create_cmd_comp  -  Create  a command completion to be used
7       for DEVX asynchronous commands.
8
9       mlx5dv_devx_destroy_cmd_comp - Destroy a devx command completion.
10
11       mlx5dv_devx_get_async_cmd_comp - Get an  asynchronous  command  compleā€
12       tion.  # SYNOPSIS
13
14              #include <infiniband/mlx5dv.h>
15
16              struct mlx5dv_devx_cmd_comp {
17                  int fd;
18              };
19
20              struct mlx5dv_devx_cmd_comp *
21              mlx5dv_devx_create_cmd_comp(struct ibv_context *context)
22
23              void mlx5dv_devx_destroy_cmd_comp(struct mlx5dv_devx_cmd_comp *cmd_comp)
24
25              struct mlx5dv_devx_async_cmd_hdr {
26                  uint64_t    wr_id;
27                  uint8_t     out_data[];
28              };
29
30              int mlx5dv_devx_get_async_cmd_comp(struct mlx5dv_devx_cmd_comp *cmd_comp,
31                                 struct mlx5dv_devx_async_cmd_hdr *cmd_resp,
32                                 size_t cmd_resp_len)
33

DESCRIPTION

35       Create or destroy a command completion to be used for DEVX asynchronous
36       commands.
37
38       The create verb exposes an mlx5dv_devx_cmd_comp object that can be used
39       as  part  of  asynchronous DEVX commands.  This lets an application run
40       asynchronously without blocking and once the response is ready read  it
41       from this object.
42
43       The  response  can be read by the mlx5dv_devx_get_async_cmd_comp() API,
44       upon response the wr_id that was supplied upon the asynchronous command
45       is returned and the out_data includes the data itself.  The application
46       must supply a large enough buffer to match any command that was  issued
47       on the cmd_comp, its size is given by the input cmd_resp_len parameter.
48

ARGUMENTS

50       context
51
52              RDMA device context to create the action on.
53
54       cmd_comp
55              The command completion object.
56
57       cmd_resp
58              The output data from the asynchronous command.
59
60       cmd_resp_len
61              The output buffer size to hold the response.
62

RETURN VALUE

64       Upon  success  mlx5dv_devx_create_cmd_comp  will  return  a  new struct
65       mlx5dv_devx_cmd_comp object, on error NULL will be returned  and  errno
66       will be set.
67
68       Upon  success  mlx5dv_devx_get_async_cmd_comp  will return 0, otherwise
69       errno will be returned.
70

SEE ALSO

72       mlx5dv_open_device(3), mlx5dv_devx_obj_create(3)
73
74       #AUTHOR
75
76       Yishai Hadas <yishaih@mellanox.com>
77
78
79
80       mlx5dv_devx_create_cmd_comp, mlx5dv_devx_destroy_cmd_comp, get_async(3)
Impressum